Thursday, July 18, 2013

this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;

is superior to...

this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Inherit;

 
 

or certianly the default...

this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;

 
 

...in the name of getting fonts to display at consistent sizes within a WinForms form. The font size may contort otherwise when one changes this display setting:

...which is found by right-clicking on the Desktop in Windows 7 and picking "Personalize" and then clicking the "Display" link at the dialog box which appears.

No comments:

Post a Comment