Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Making an app scalable to high DPI screens
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Divers
Thread ID:
00627460
Message ID:
00627468
Vues:
15
Interesting observation (by my calculations, which are always suspect): It would require an LCD display with a diagonal dimension of about 23.4" to display the entire 1600 x 1200 virtual desktop that I pan over with my 1024x768 15" LCD display.

>A part of the problem is that the screen resolution does not accurately predict the size of the rendered font. It's a combination of the DPI setting (in sofware) PLUS the actual construction of the LCD display. Obviously, a 15" UXGA (1600x1200) LCD display has its pixels packed closer than does a 15" 1024x768 XGA display. If the UXGA display was rendered on an 18" screen instead of 15", then it would look fine at 96 DPI. Unfortunately, this situation can get even more confusing: For example, I use my notebook PC at 1600 x 1200, but it has a 1024x768 display. How? I use the virtual desktop capability that many notebook PC's have, where you can pan the physical display over a much larger virtual workarea. So 96 DPI works _great_ on my 15" notebook even though SysMetric will tell you I'm using a 1600x1200 display.
>
>>>The more I look, the more I don't understand...
>>>Many of today's newer notebook PC's have UXGA (1600x1200) LCD displays, and because these are only 15" panels, they are designed to work in a higher DPI setting... typically at either 125% or 150% of the "standard" 96 DPI. I notice with VFP that when I change the display's DPI settings (and reboot), that my VFP forms don't change at all... that is, all the form's controls are still rendered as if a 96 DPI font were used, which is both good and bad. Good because I don't have to worry about the contents of a control becomming too big for it (and similar things, like a command button's text becoming too large for it)... in other words, apparently no scaling is being done. Bad because a form that looks good at 1024x768 becomes nearly unreadable at 1600x1200 on a 15" LCD display... the fonts become tiny... and stay that way no matter what I set for the display's DPI setting.
>>>
>>>What's the solution?
>>
>>One thing you can do is detect the current resolution with SYSMETRIC(), and adjust your form accordingly, say, to 80% screen width x 60% screen height.
>>
>>You would also have to adjust the position and size of all form objects, and font sizes, accordingly.
>>
>>This is a lot of trouble - but I don't know whether there is an easier solution.
>>
>>Hilmar.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform