GetTextFace

Syntax

int GetTextFace(hDC,nCount,lpFacename)

This function copies the typeface name of the selected font into a buffer pointed to by the lpFacename parameter. The typeface name is copied as a null-terminated character string. The nCount parameter specifies the maximum number of characters to be copied. If the name is longer than the number of characters specified by nCount, it is truncated.

Parameter Type/Description  

hDC HDC Identifies the device context.  
nCount int Specifies the size of the buffer in bytes.  
lpFacename LPSTR Points to the buffer that is to receive the typeface name.  

Return Value

The return value specifies the actual number of bytes copied to the buffer. It is zero if an error occurs.