BCGSuite for MFC
CSize CBCGPGlobalUtils::ScaleByDPI ( CSize  size,
const CWnd *  pWnd = NULL 
)

Returns the size scaled by the DPI (Dots Per Pixel) of the specified window.

Parameters
sizeThe size to be scaled.
pWndThe pointer to the CWnd object. If this parameter is a CWnd::wndTop address, the active (currently drawn) window will be used.
Returns
The scaled size.