Setup.exe: Font issue
Mon May 19 13:11:00 GMT 2003
I always used to have problems with the package selection page in
setup.exe (on W2K, using a custom screen resolution of 144 dpi). The
package list never showed the vertical scrollbar. In the current
version the mouse wheel didn't work either (another patch coming), so
I couldn't scroll the list at all.
I tracked this down now to a font issue. Turns out that the main
window of the PropertySheet wizard uses the font alias "MS Shell Dlg"
as its base font (as seen in the DLGTEMPLATE passed to
PSCB_PRECREATE). The individual pages use the font alias "MS Sans
Serif" as set in the resource file. With larger screen resolutions,
this results in widely different ideas about the size of the dialog
units that are used to measure dialogs and controls. The result is
that the vertical scrollbar of the list was outside of the clipping
region that the main window had set up.
The simplest fix was to change the font in the resource file (patch
attached). This is certainly better than the current situation, but I
am not sure this is the best solution, as I am not sure that it is
documented and garanteed that the wizard will use this specific font
Ideally we want either set the font for the main window to "MS Sans
Serif" at an apropriate time (i.e. before dialog units are converted
to pixel units), or in some other way synchronize the font for the
individual sheets with the main window at runtime. I have not found a
simple way to do this yet, though.
If there is interest I can at least provide the code that I used to
check the font that the main window is using and to write that to the
so long, benny
2003-05-19 Benjamin Riefenstahl <Benjamin.Riefenstahl@epost.de>
* res.rc (all dialogs): Change font from "MS Sans Serif" to "MS
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 4667 bytes
Desc: not available
More information about the Cygwin-apps