In Delphi, use the function GetTextExtentPointA order to calculate the position and size of buttons in dialog boxes, called standard Delphi functions like MessageDlg. Perhaps the same mechanism is used in other applications to calculate the position and size of controls. I'm not sure whether the difference in this feature on other apps, but perhaps it indirectly affects some programs. I wrote a small utility that tests the output of the function. Just can't understand why the values in ROS and Windows are different.