]> git.saurik.com Git - wxWidgets.git/blobdiff - src/stc/stc.cpp
Applied Kevin Hock's combobox patch for text update events
[wxWidgets.git] / src / stc / stc.cpp
index f96e8ffadc0e605261ab7a2ce4813ecb30427a6d..8ab07a92ab201863553defe45bd764fa7ae9afe1 100644 (file)
@@ -168,6 +168,8 @@ void wxStyledTextCtrl::Create(wxWindow *parent,
     // Put Scintilla into unicode (UTF-8) mode
     SetCodePage(wxSTC_CP_UTF8);
 #endif
+
+    SetBestFittingSize(size);
 }
 
 
@@ -2757,6 +2759,14 @@ void wxStyledTextCtrl::OnIdle(wxIdleEvent& evt) {
 }
 
 
+wxSize wxStyledTextCtrl::DoGetBestSize() const
+{
+    // What would be the best size for a wxSTC?
+    // Just give a reasonable minimum until something else can be figured out.
+    return wxSize(200,100);
+}
+
+
 //----------------------------------------------------------------------
 // Turn notifications from Scintilla into events