Retrieves font-metric information from a scalable font file.
The information to retrieve is identified by specifying an offset into the font file and the length of the information to return.
An application can sometimes use the GetFontData member function to save a TrueType font with a document. To do this, the application determines whether the font can be embedded and then retrieves the entire font file, specifying 0 for the dwTable, dwOffset, and cbData parameters.
Applications can determine whether a font can be embedded by checking the otmfsType member of the OUTLINETEXTMETRIC structure. If bit 1 of otmfsType is set, embedding is not permitted for the font. If bit 1 is clear, the font can be embedded. If bit 2 is set, the embedding is read only.
If an application attempts to use this function to retrieve information for a non-TrueType font, the GetFontData member function returns –1.