From: Michael Bedward <mbedward@ozemail.com.au>
Date: Thu, 5 Aug 1999 06:14:06 +0000 (+0000)
Subject: Added a line to set m_font in the wxWindowDC ctor (with window arg) so that GetTextEx... 
X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/60f5b8804baa6d005afd8a595850037a614f0d3c

Added a line to set m_font in the wxWindowDC ctor (with window arg) so that GetTextExtent will work properly


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3283 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
---

diff --git a/src/motif/dcclient.cpp b/src/motif/dcclient.cpp
index 1d4cca6560..bda0770424 100644
--- a/src/motif/dcclient.cpp
+++ b/src/motif/dcclient.cpp
@@ -127,6 +127,7 @@ wxWindowDC::wxWindowDC( wxWindow *window )
     wxASSERT_MSG( (window != (wxWindow*) NULL), "You must pass a valid wxWindow to wxWindowDC/wxClientDC/wxPaintDC constructor." );
 
     m_window = window;
+    m_font = window->GetFont();
     m_gc = (WXGC) 0;
     m_gcBacking = (WXGC) 0;
     m_backgroundPixel = -1;