Поделиться через


COleControl::GetStockTextMetrics

Measures the text metrics for the control's stock Font property, which can be selected with the SelectStockFont function.

void GetStockTextMetrics(
   LPTEXTMETRIC lptm 
);

Параметры

Заметки

The GetStockTextMetrics function will initialize the TEXTMETRIC structure pointed to by lptm with valid metrics information if successful, or fill the structure with zeros if not successful. Use this function instead of GetTextMetrics when painting your control because controls, like any embedded OLE object, may be required to render themselves into a metafile.

The TEXTMETRIC structure for the default font is refreshed when the SelectStockFont function is called. You should call this function only after selecting the stock font to assure the information it provides is valid.

Требования

Header: afxctl.h

См. также

Основные понятия

COleControl Class

COleControl Members

Hierarchy Chart