There is an option to get the width of the text in logical units via GetTextExtentPoint32 , but I could not find how to translate them into pixels .
The crux of the matter is either to find a method of obtaining immediately in pixels , or how to translate logical units into pixels .
LPtoDPto convert a result to pixels? - AnT