]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/carbon/textctrl.cpp
adaption for CW 8.3 and quick hack for unicode text control size
[wxWidgets.git] / src / mac / carbon / textctrl.cpp
index f260ca06fce48d25e94449595d13f27d4f49de42..f05af51e4536dcd913e287475944c033da7b99d1 100644 (file)
@@ -1413,7 +1413,9 @@ void wxTextCtrl::WriteText(const wxString& str)
 {
     if ( !wxIsMainThread() )
     {
-        wxMacMPRemoteGUICall( this , &wxTextCtrl::WriteText , str ) ;
+        // unfortunately CW 8 is not able to correctly deduce the template types, so we have 
+        // to instantiate explicitely
+        wxMacMPRemoteGUICall<wxTextCtrl,wxString>( this , &wxTextCtrl::WriteText , str ) ;
         return ;
     }
     else
@@ -1516,6 +1518,13 @@ wxSize wxTextCtrl::DoGetBestSize() const
             break ; 
     }
 
+#if !wxMAC_USE_MLTE
+    // unicode text control is using client size, ie 3 pixels on every side
+    // TODO make this fit into normal window size concept, probably having 
+    // to reintroduce the margin vars
+    hText -= 6 ;
+#endif
+
     if ( m_windowStyle & wxTE_MULTILINE )
     {
          hText *= 5 ;