游子日月长

笑渐不闻声渐悄,多情却被无情恼!

导航

如何获得以像素计算的字体宽度

BOOL GetTextExtentPoint32(

    HDC hdc, // handle of device context 
    LPCTSTR lpString, // address of text string 
    int cbString, // number of characters in string 
    LPSIZE lpSize // address of structure for string size   
   ); 
只能获得字符串的宽度

posted on 2017-02-07 15:25  游子日月长  阅读(244)  评论(0编辑  收藏  举报