uwp

How to properly enable dpi-scaling on uwp app

假装没事ソ 提交于 2019-12-05 12:34:20
I've created my first UWP app. It's a Windows 8.1 UWP app which will help with scheduling courses at my university who's current system is awful. I've been working on it with my Windows 10 desktop computer with a 1080p monitor at default system scaling (100%). I deployed a test build and installed it on my laptop. The laptop is also Windows 10 and 1080p but has a smaller screen so I have system scaling set to 125%. My problem is that instead of this higher scaling factor making my app have bigger features, it does the opposite and shrinks everything in the app. Here are two screenshots from my

Transparent tile but colored icon for the Windows Store

故事扮演 提交于 2019-12-05 11:22:33
I want to have transparent square tile for my app, but in the Store it should have green background behind same icon. Is there any way to achieve that? In 8.1 we had (still have) 300x300 "App tile icon" which is used for the Store I believe, but now it seems store using image from Package.appxmanifest, and even if I explicitly set non-transparent image for "Store Logo", it doesn't work. Question is: is that at all possible to have transparent tile for start screen but solid-color background icon in the Store? Yes, "App tile icon" is used only on Windows Phone 8.1 or earlier and in practice for

Can a Java Swing desktop application be converted to a UWP centennial app (AppX)?

时光总嘲笑我的痴心妄想 提交于 2019-12-05 11:14:39
I have been reading about project centennial ( https://msdn.microsoft.com/windows/uwp/porting/desktop-to-uwp-root#preparing-your-desktop-app-for-conversion-to-uwp ), and it occurs to me that there are many legacy line-of-business apps that are written in Java (not to mention Python/Tkinter, insert language/gui toolkit here , etc). I can see a benefit in being able to market/distribute these through the Windows store (either internally for an enterprise or to the general public). I was wondering if it is possible to turn a Java application into an AppX bundle (possibly using something like

Minimize UWP application to system tray

最后都变了- 提交于 2019-12-05 10:50:31
Is there a way to minimize a windows 10 UWP application to the system tray. I've tried googling about this but all i can see is about wpf and windows forms. Thanks. This isn't possible. However, according to your description in the comments it is not needed, Cortana will launch your app. You probably have some other problems in handling arguments and finding which methods to override, but as there is nothing specific in your question about that, I can only guess... 来源: https://stackoverflow.com/questions/35310926/minimize-uwp-application-to-system-tray

What is the 'right' way to resize a SymbolIcon?

时光总嘲笑我的痴心妄想 提交于 2019-12-05 10:41:23
I want to be able to define a style and set the style on the icon (or on the button that holds the icon). Setting the button h/w doesn't enlarge the symbol and adding a Viewbox works, but I can't figure out how to set that from a style. <Button x:Name="ZoomInButton" Style="{ThemeResource HeaderButtonStyle}" Grid.Column="1" Grid.Row="0" Click="ZoomInButton_Click"> <SymbolIcon Symbol="ZoomIn" /> </Button> Any help very much appreciated! Seems so easy, but I'm stumped! In UWP apps, the standard glyphs are provided by the Segoe MDL2 Assets font, you can directly use a TextBlock with FontFamily=

How to get Assembly from a Type object in UWP (aka .NET Core)

不想你离开。 提交于 2019-12-05 10:07:32
问题 The Type class has got an Assembly attribute in .NET Framework. However this attribute is gone when you are writing an UWP which is of course using .NET Core. Only the AssemblyQualifiedName attribute is available. How can I get to the Assembly from this name? Please bear in mind that lot of the usual classes are not available in .NET Core, so your usual .NET Framework answer might not work. E.g. there is no such thing as AppDomain, etc. 回答1: You can use typeof(xxx).GetTypeInfo().Assembly to

UWP App Won't Start

ぃ、小莉子 提交于 2019-12-05 09:30:39
I have a UWP app. I'm using Visual Studio 2017 15.4.1. The UWP app is a store app and has been deployed to the Microsoft Store. My app was working fine in the store, and it was also working fine when I hit play in Visual Studio. Then recently, an isolated storage issue started occurring so I went in to the app in "Apps & Features" and hit Advanced Options -> Reset. Somehow this has fried my app installation on my machine. Our app no longer shows up as an installed app, and when I try to install the app from the store, I get an error with a code of 0x80073CF9. So, I can't uninstall, or

Error using using RenderTargetBitmap in UWP

浪子不回头ぞ 提交于 2019-12-05 08:36:49
I'm trying to create a bitmap image, and have the following code: RenderTargetBitmap renderTargetBitmap = new RenderTargetBitmap(); await renderTargetBitmap.RenderAsync(uielement); IBuffer pixels = await renderTargetBitmap.GetPixelsAsync(); . . . var pixelArray = pixels.ToArray(); In order to get a ToArray() extension, I came across this question. So I added: using System.Runtime.InteropServices.WindowsRuntime; // For ToArray To my code. However, when I run, I get the following error: Exception thrown: 'System.ArgumentException' in System.Runtime.WindowsRuntime.dll Additional information: The

Merged ResourceDictionary initalization in UWP app

和自甴很熟 提交于 2019-12-05 08:27:05
During development of my UWP app I have noticed and intersting oddity which I have hard time explaining. I user MvvmLight and I decided to add the ViewModelLocator resource instance in a separate ResourceDictionary Core.xaml which will be referenced from MergedDictionaries in App.xaml . Following is the content of App.xaml : <Application ...> <Application.Resources> <ResourceDictionary> <ResourceDictionary.MergedDictionaries> <ResourceDictionary Source="Resources/Core.xaml" /> <ResourceDictionary Source="Resources/Converters.xaml" /> </ResourceDictionary.MergedDictionaries> <

Change default User-Agent in WebView UWP

人走茶凉 提交于 2019-12-05 08:22:06
I need set custom UA and I use httpRequestMessage.Headers.Add("User-Agent", "blahblah"); theWebView.NavigateWithHttpRequestMessage(httpRequestMessage); But if I click any link on page this UA erased and set default UA. I found same question WebView - Define User-Agent on every request but maybe it fixed in 1607? Jay Zuo WebView is not a general-purpose browser, it does have some "limitations" that not supported now. There is no API can set the default User-Agent that used in every request. As a workaround we can use WebView.NavigationStarting event along with WebView