1
votes

Good day everyone.

I have a problem with Delphi 7 application being used for Windows 7.

It works perfect for older windows like XP, but on Win7 the form is scaled to higher dpi which completely breaks everything on the form.

So, my question - is there a way to fix it to work correctly on win7, or to somehow completely disable scaling?

I tried to search, but couldn't find anything that would work for me, and I would really appreciate your help.

1
Why do you want to disable scaling? What about users that have sight deficiencies? Does it occur to you that those users enabled font scaling for a reason?David Heffernan
@NewProger are you aware that Windows 7 has a setting for Font Size which affects this in the first place? Because as I read your question, it appears as if you think that's just how Windows 7 works, as opposed to XP.Jerry Dodge
I was able to fix the issue after googling for about 20 hours straight and then by changing some properties and parts of my code. Now I don't know what would be the best way to contribute to the site, because even if I try answering my own question it would be just too specific for my particular case... I guess someone might answer with a link to some good tutorial and I will tick this answer as a selected answer.NewProger
@NewProger You can answer your own question. I have this issue and would like to know what your solution was.Jamie Kitson

1 Answers

2
votes

I saw this phenomenon (as a hired consultant) on XP with Large Fonts on a (then) big 22" about 2003: Buttons on an MS C++ application disappeared to the right outside the form. At the time, the developers (500 kms away) had never seen this phenomenon before.

I recently solved similar problem in my D7 by:

  1. Setting large fonts on the old developer machine and fiddling with the (rather medium) form size to accomodate visible components. However, setting large fonts made the old win2000 crash and never completely recover...
  2. On more modern machine (XP with D7), I set a Scaling property to False on Form1 with good results, i.e. the fonts were smaller. The program(s) in question run on a couple of wall mounted touchscreen PCs preinstalled Win7 with incredibly large fonts (because it's a touchscreen).

I can't find out a better method than to temporarily set Silly Large Fonts on one's developer machine and see what happens. (I see there are many related questions here now!...)