Windows 3.1 Device Drivers (ddag31qh.hlp) (
Table of Contents;
Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
EngineRealizeFont
◄Up► ◄Next► ◄Previous►
────────────────────────────────────────────────────────────────────────────
WORD EngineRealizeFont(lplf, lpTextXForm, lpFont)
LPLOGFONT lplf; /* points to logical font information */
LPTEXTXFORM lpTextXForm; /* points to text appearance information */
LPFONT lpFont; /* points to a buffer for physical font info */
The EngineRealizeFont function creates an engine font having attributes and
an appearance that matches those specified by the given logical font and
text appearance information. A driver calls this function, while processing
calls to its RealizeObject function, to determine whether a suitable
TrueType font exists.
Import Module.Ordinal: GDI.302.
Parameter Description
────────────────────────────────────────────────────────────────────────────
lplf Points to a LOGFONT structure specifying the attributes of the
font to create.
lpTextXForm Points to a TEXTXFORM structure specifying additional
attributes of the font to create.
lpFont Points to a FONTINFO structure or is NULL. If this parameter
points to a structure, the function fills the structure with
information about the engine font. Otherwise, the function
returns the size (in bytes) of this information but does not
return the information.
Return Value
This function returns either a size or a Boolean value, depending on the
value of the lpFont parameter.
If lpFont is NULL, the function returns the size (in bytes) of the FONTINFO
structure and any additional information needed to describe the engine font.
If the return value is 0, the driver should not attempt to realize the
engine font.
If lpFont points to a FONTINFO structure, the function returns TRUE if it
successfully realizes the engine font. Otherwise, it returns FALSE.
Comments
A driver must call this function twice: first to retrieve the size (in
bytes) of font information to be returned, and second to realize the engine
font and retrieve the corresponding FONTINFO structure. The driver should
then compare its own device fonts with the realized engine font (if any) to
determine which font must closely matches the given logical font
attributes.
A driver can use the high byte of the dfType field and the dfBitsOffset and
dfBitsPointer fields for its own purpose. For example, a driver can set the
dfBitsOffset field to point to additional information after the end of the
FONTINFO structure and set bits in the high byte of the dfType field to
specify whether the font passed is an engine or device font. A driver can
use this information when GDI returns the FONTINFO structure in a call to
the StrBlt or ExtTextOut function.
See Also
EngineDeleteFont, ExtTextOut, RealizeObject, StrBlt
♦