CGDIFont Class
class CGDIFont: public CGDIObject
Defined in: GDIObjects.h
Class Members
CGDIFont(HFONT h = NULL, bool bOwn = true)
Attach constructor. Initializes a new instance of CGDIFont and optionally attaches a previously existing font handle. The ownership of this handle is determined by the bOwn parameter.
CGDIFont(CGDIFont& rhs, bool bTransferOwnership = true)
Copy constructor. Takes an existing CGDIFont instance and copies its contents to the new instance being constructed. If the object being copied is the owner of the handle, ownership's transference is controlled by the parameter bTransferOwnership.
CGDIFont& operator =(CGDIFont& rhs)
Copies the contents of the passed object into this instance. Ownership is always transfered if it belongs to the object being copied.
bool CreateFontIndirect(const LOGFONT* lpLogFont)
Creates a font with the parameters given in the LOGFONT structure
bool CreateFont(int nHeight, int nWidth, int nEscapement, int nOrientation, int nWeight, BYTE bItalic, BYTE bUnderline,BYTE cStrikeOut, BYTE nCharSet, BYTE nOutPrecision, BYTE nClipPrecision, BYTE nQuality, BYTE nPitchAndFamily,LPCTSTR lpszFacename)
Creates a font with the parameters passed in
bool CreatePointFont(int nPointSize, LPCTSTR lpszFaceName, HDC hdc = NULL)
Creates a font using the logical size passed in
bool CreatePointFontIndirect(const LOGFONT* lpLogFont, HDC hdc = NULL)
Creates a font using the logical size passed in
int GetLogFont(LOGFONT* pLogFont)
Retrieve the LOGFONT structure that describes this font object