summaryrefslogtreecommitdiff
path: root/plugins/mTextControl
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/mTextControl')
-rw-r--r--plugins/mTextControl/src/FormattedTextDraw.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/mTextControl/src/FormattedTextDraw.cpp b/plugins/mTextControl/src/FormattedTextDraw.cpp
index f40edb1d00..fe8b0b27ea 100644
--- a/plugins/mTextControl/src/FormattedTextDraw.cpp
+++ b/plugins/mTextControl/src/FormattedTextDraw.cpp
@@ -215,14 +215,14 @@ HRESULT CFormattedTextDraw::get_NaturalSize(void *hdcDraw, long *Width, long *He
cf.bCharSet = lf.lfCharSet;
cf.yHeight = 1440 * abs(lf.lfHeight) / GetDeviceCaps((HDC)hdcDraw, LOGPIXELSY);
wsprintf(cf.szFaceName, lf.lfFaceName);
- m_spTextServices->TxSendMessage(EM_SETCHARFORMAT, (WPARAM)(SCF_ALL), (LPARAM)&cf, &lResult);
-
- SIZEL szExtent;
-// HDC hdcDraw;
if (!m_spTextServices)
return S_FALSE;
+ m_spTextServices->TxSendMessage(EM_SETCHARFORMAT, (WPARAM)(SCF_ALL), (LPARAM)&cf, &lResult);
+
+ SIZEL szExtent;
+// HDC hdcDraw;
// hdcDraw = GetDC(NULL);
*Height = 1;
szExtent.cx = *Width;