TerGetFontParam
Retrieve the font parameters.
int TerGetFontParam( FontId, type)
boolean TerGetFontParam( FontId, type, out color)
int FontId; | FontId (0 to TotalFonts-1). Set to 0 to specify the default font. You can also use this function to get the font information for a stylesheet item by specifying the style id as a negative value for this parameter. Also, use the following constant to specify normal or the current style item. |
| SID_NORMAL | 'Normal' style item. |
| SID_CUR | Style item being currently edited. |
int type; | One of the following parameter types can be used: |
| FONTINFO_CHARSET | The character set for the font |
| FONTINFO_PICT_WIDTH | The picture width in twips assuming that the FontId represents a picture. |
| FONTINFO_PICT_HEIGHT | The picture height in twips assuming that the FontId represents a picture. |
| FONTINFO_ULINE_COLOR | The color of the underline bar. |
| FONTINFO_AUX_ID | The auxiliary id for the font. |
| FONTINFO_FLAGS | Font flags. The following font flags are available: FFLAG_AUTO_SPELL: Font with wave underline. |
| FONTINFO_FRAME_TYPE | The frame type for a floating picture assuming that the FontId represents a picture.. Please refer to the TerSetPictFrame2 function for a list of PFRAME_ constants. |
| FONTINFO_FRAME_ID | The frame id for a floating picture assuming that the FontId represents a picture. |
| FONTINFO_OFFSET | Return the character offset (twips) from the baseline. |
| FONTINFO_IS_PICT | Returns 1 if the FontId represents a picture, otherwise returns 0. |
| FONTINFO_IS_CTL | Returns 1 if the FontId represents a control, otherwise returns 0. |
| FONTINFO_FIELD | Field id used for the font. |
| FONTINFO_INS_REV_ID | Reviewer id for inserted text. |
| FONTINFO_DEL_REV_ID | Reviewer id for deleted text. |
| FONTINFO_SIZE | Return the font styles. Please refer to the GetFontInfo function for the definition of style constants. |
| FONTINFO_STYLE | Return the font style constants. Please refer to the GetFontInfo function for the font style constant values. |
| FONTINFO_TEXT_COLOR | Return the text color |
| FONTINFO_BK_COLOR | Return the text background color |
| FONTINFO_WLINE_COLOR | Return the color of the wave line under the text. |
Color color; | The 'out' parameter to retrieve the color parameter. This parameter is valid only for the parameter types which return a color value. |
Return Value: This first method returns the value of the requested parameter. It returns -1 to indicate an error condition.
The second override method returns True if successful, otherwise it returns a False value.