High dpi problem for deployed gui
9 views (last 30 days)
Show older comments
Hi all,
My GUI does not show correctly as a deployed application on high DPI displays. The GUI should be 1330 x 740. Strangely, the height (740) is shown perfectly, but the width is only 1162 in deployed mode on a high DPI. If I deploy my application to a pc without high DPI, the GUI shows perfectly.
The GUI still shows all elements, but they are all narrower. Strings are therefor not readable anymore.
Another striking thing: I use Yair's findjobj function to center some table content horizontally. However, also those cells are not centered, but instead these cells are off-center to the right. I think this indicates that the underlying java CAN detect the intended width of the table columns, but the GUI is just wrongly scaled. Here's a picture:
I disabled Windows 10 application scaling. I created the GUI with GUIDE. The figure is set in characters (but the problem persists if I set the figure to "normalized"). The figure is non-resizable. I use both MATLAB 2016a and 2017a (and I have the problem in both versions). The screen resolution is 1920x1080.
Does anybody know a fix or a workaround? Any help is appreciated!
Thanks, Vincent
0 Comments
Answers (1)
Brad
on 21 Dec 2017
A workaround would be to go into the application's properties\compatibility and select "Override high DPI scaling behavior" performed by System. Seems to do the trick.
0 Comments
See Also
Categories
Find more on Verification, Validation, and Test in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!