I have a
LOGFONT.lfHeight
int height = abs((pixels * DOTSY) / 72);
LOGFONT
int pixels = abs((height / DOTSY) * 72);
Yes. DOTSY will be 96, which is the default monitor resolution in DPI in Windows. You will need to ensure that this value is correct for the device you're writing to - printers will usually have a much higher resolution, and the monitor resolution can be changed. lfHeight is negative to indicate that the font mapper should use character height instead of cell height to match, so only the absolute value is important here.