Bạn đang xem: Uwp là gì
In this article
UWP is one of many ways to create client applications for Windows. UWP apps use WinRT APIs to provide powerful UI and advanced asynchronous features that are ideal for internet-connected devices.
To download the tools you will need to start creating UWP apps, see Get set up, and then write your first app.
Where does UWP fit in the realchampionshipwrestling.com development story?
UWP is one choice for creating apps that run on Windows 10 and Windows 11 devices, and can be combined with other platforms. UWP apps can make use of Win32 APIs and .NET classes (see API Sets for UWP apps, Dlls for UWP apps, and .NET for UWP apps).
The realchampionshipwrestling.com development story continues to evolve, and along with initiatives such as WinUI, MSIX, and the Windows App SDK, UWP is a powerful tool for creating client apps.
Features of a UWP app
Let"s look at these in more detail.
UWP apps declare in their manifest the device capabilities they need such as access to the microphone, location, Webcam, USB devices, files, and so on. The user must acknowledge and authorize that access before the app is granted the capability.
A common API surface across all devices
Windows 10 introduces the Universal Windows Platform (UWP), which provides a common app platform on every device that runs Windows 10. The UWP core APIs are the same on all Windows devices. If your app only uses the core APIs, it will run on any Windows 10 device no matter whether you are targeting a desktop PC, Xbox, Mixed-reality headset, and so on.
A UWP app written in C++ /WinRT or C++ /CX has access to the Win32 APIs that are part of the UWP. These Win32 APIs are implemented by all Windows 10 devices.
Extension SDKs expose the unique capabilities of specific device types
If you target the universal APIs, then your app can run on all devices that run Windows 10. But if you want your UWP app to take advantage of device-specific APIs, then you can do that, too.
Extension SDKs let you call specialized APIs for different devices. For example, if your UWP app targets an IoT device, you can add the IoT extension SDK to your project to target features specific to IoT devices. For more information about adding extension SDKs, see the Extension SDKs section in Programming with extension SDKs.
You can write your app so that you expect it to run only on a particular type of device, and then limit its distribution from the realchampionshipwrestling.com Store to just that type of device. Or, you can conditionally test for the presence of an API at runtime and adapt your app"s behavior accordingly. For more information, see the Writing code section in Programming with extension SDKs.
Adaptive controls and input
UI elements respond to the size and DPI of the screen the app is running on by adjusting their layout and scale. UWP apps work well with multiple types of input such as keyboard, mouse, touch, pen, and Xbox One controllers. If you need to further tailor your UI to a specific screen size or device, new layout panels and tooling help you design UI that can adapt to the different devices and form factors that your app may run on.
Windows helps you target your UI to multiple devices with the following features:Universal controls and layout panels help you to optimize your UI for the screen resolution of the device. For example, controls such as buttons and sliders automatically adapt to device screen size and DPI density. Layout panels help adjust the layout of content based on the size of the screen. Adaptive scaling adjusts to resolution and DPI differences across devices.Common input handling allows you to receive input through touch, a pen, a mouse, a keyboard, or a controller such as a realchampionshipwrestling.com Xbox controller.Tooling that helps you to design UI that can adapt to different screen resolutions.
Some aspects of your app"s UI will automatically adapt across devices. Your app"s user-experience design, however, may need to adapt depending on the device the app is running on. For example, a photo app could adapt its UI when running on a small, handheld device to ensure that usage is ideal for single-handed use. When a photo app is running on a desktop computer, the UI should adapt to take advantage of the additional screen space.
There"s one store for all devices
A unified app store makes your app available on Windows 10 devices such as PC, tablet, Xbox, HoloLens, Surface Hub, and Internet of Things (IoT) devices. You can submit your app to the store and make it available to all types of devices, or only those you choose. You submit and manage all your apps for Windows devices in one place. Have a C++ desktop app that you want to modernize with UWP features and sell in the realchampionshipwrestling.com store? That"s okay, too.
UWP apps integrate with Application Insights for detailed telemetry and analytics—a crucial tool for understanding your users and improving your apps.
UWP apps can be packaged with MSIX and distributed via the realchampionshipwrestling.com Store, or in other ways. MSIX allows apps to be updated no matter how they are distributed, see Update non-Store published app packages from your code.
Monetize your app
You can choose how you"ll monetize your app. There are a number of ways to make money with your app. All you need to do is choose the one that works best for you, for example:A paid download is the simplest option. Just name the price.Trials let users try your app before buying it, providing easier discoverability and conversion than the more traditional "freemium" options.Sale prices to incentivize users.In-app purchases.
Deliver relevant, real-time info to your users to keep them coming back
There are a variety of ways to keep users engaged with your UWP app:Live tiles and lock screen tiles that show contextually relevant and timely info from your app at a glance.Push notifications that bring real-time alerts to your user"s attention.User Activities allow users to pick up where they left off in your app, even across devices.The Action Center organizes notifications from your app.Background execution and triggers bring your app into action when the user needs it.Your app can use voice and Bluetooth LE devices to help users interact with the world around them.Integrate Cortana to add voice command capability to your app.
Use a language you already know
Links to help you get going
Get set up
Check out Get set up to download the tools you need to start creating apps, and then write your first app.
Design your app
The realchampionshipwrestling.com design system is named Fluent. The Fluent Design System is a set of UWP features combined with best practices for creating apps that perform beautifully on all types of Windows-powered devices. Fluent experiences adapt and feel natural on devices from tablets to laptops, from PCs to televisions, and on virtual reality devices. See The Fluent Design System for UWP apps for an introduction to Fluent Design.
Good design is the process of deciding how users will interact with your app, in addition to how it will look and function. User experience plays a huge part in determining how happy people will be with your app, so don"t skimp on this step. Design basics introduces you to designing a Universal Windows app. See the device primer to help you think through the interaction experience of using your app on all the different form factors you want to target.
In addition to interaction on different devices, plan your app to embrace the benefits of working across multiple devices. For example:
Submit your app to the Store
Partner Center lets you manage and submit all of your apps for Windows devices in one place. See Publish Windows apps and games to learn how to submit your apps for publication in the realchampionshipwrestling.com Store.
New features simplify processes while giving you more control. You"ll also find detailed analytic reports combined payout details, ways to promote your app and engage with your customers, and much more.
For more introductory material, see An Introduction to Building Windows Apps for Windows 10 Devices
More advanced topics
How the Universal Windows Platform relates to Windows Runtime APIs
If you"re building a Universal Windows Platform (UWP) app, then you can get a lot of mileage and convenience out of treating the terms "Universal Windows Platform (UWP)" and "Windows Runtime (WinRT)" as more or less synonymous. But it is possible to look under the covers of the technology, and determine just what the difference is between those ideas. If you"re curious about that, then this last section is for you.
And, of course, you can call WinRT APIs from your UWP app. UWP is an application model built on top of the Windows Runtime. Technically, the UWP application model is based on CoreApplication, although that detail may be hidden from you, depending on your choice of programming language. As this topic has explained, from a value proposition point of view, the UWP lends itself to writing a single binary that can, should you choose, be published to the realchampionshipwrestling.com Store and run on any one of a great range of device form factors. The device reach of your UWP app depends on the subset of Windows Runtime APIs that you limit your app to calling, or that you call conditionally.
Hopefully, this section has been successful in describing the difference between the technology underlying Windows Runtime APIs, and the mechanism and business value of the Universal Windows Platform.