Code: Select all
monospace
The integer division by 8 of the byte#27 of their LOGFONT structure classify the fonts.
Code: Select all
fontClass()=fontClassAux(PitchAndFamily,PitchAndFamily div 8) :-
F=selectedFont,
PitchAndFamily=binary::getIndexed_unsigned8(F,27),
succeed().
fontClassAux(_,1)=monospace :-
!.
fontClassAux(_,6)=monospace :-
!.
fontClassAux(_,_)=proportional.
EnumFontFamiliesEx
to cycle over the installed fonts and requires an user callback function to do the filtering as above.
Great! That procedure is present in the Win32.lib of my VIP 7.5 PE.
The problems are:
- How can a call it from a Prolog main program?
- In general, if I read a manual page in MSDN like http://msdn.microsoft.com/en-us/library ... 85%29.aspx, what are the counterparts of the variable types among the Prolog domains?