Windows Universal App Window Incorrect Size

Just starting monogame. I have no experience with Universal apps at all, though I do use wpf all day at work. I’m following the tutorial over here, and having difficulty getting the window size to change.

I’ve tried setting the preferredbackbuffer height and width, manually setting the height and width on the swapchainpanel, and changing the “emulated” screen on GamePage.xaml to the desired 23" Desktop (1920x1080). The viewport shows a 1920x1080 resolution, but the Window.Current.CoreWindow, when passed into MonoGame.Framework.XamlGame.Create() always has the values 1200x900, no matter what I do, which gives a 1200x900 window when running.

I’ve applied the suggested fix here to no avail. Am I doing it wrong, or is this a bug? It’s making me want murder to happen. :slight_smile:

I also have that fix in my App.xaml.cs file. I’ve haven’t had a great deal of luck either experimenting with forcing a particular size on startup but, in fact, what I really wanted was full-screen. If that’s also the case for you then I’ve got the following in my Game.Initialize method:

GraphicsDevice.PresentationParameters.IsFullScreen = true;

Edit: it’s got #if WINDOWS_UAP wrapped round it as well…

1 Like