## Display Device Driver Reference for OS/2

[prev][next][parent][TOC]

### FmCharStr

    /--- FUNCTION ---------------------------------------------\

    |                                                          |

    |    LONG FAR PASCAL                                       |

    |                                                          |

    |    FmCharStr (hfm, flOptions, pIndex, count)             |

    |                                                          |

    \----------------------------------------------------------/

Description: This function prepares the font segment for a given list of glyph list indexes. After that, the font segment will be the same as an SBCS proportional PM font. This is a privileged interface only for a display device driver.

hfm(HFM) (in) The font handle returned by FmOpenFont

flOptions(BIT32) (in) Option flags

FM_WITH_FONT-Updates glyph list indexes and font definitions. The font images are not constructed.

FM_WITHOUT_FONT-Updates glyph list indexes and font definitions. The font images are also loaded and constructed.

count(LONG) (in) Count of indexes. Must be less than or equal to 256. When the font is FM_CACHE_FONT, the length is limited by cbCache in the FMFONTINFO structure, returned by FmOpenFont and FmQueryFonts.

RETURN (LONG) Return Codes

FM_ERROR

FM_SUCCESS

Remarks The purpose of this function is to improve display device driver performance. The display device driver has a privilege level that can use the font segment as a cache without copying its contents into the data area locally allocated in the display device driver.

The Font Manager replaces DBCS glyph indexes (and SBCS indexes when FM_ CACHE_FONT is selected) by dynamically defining new SBCS glyph list indexes . Also DBCS font images at the offset address where the new SBCS glyph list index points must be prepared.

After that, the display device driver can treat all of the font images as PM font SBCS proportional characters.