]> git.saurik.com Git - wxWidgets.git/commitdiff
added support for wxTE_NO_VSCROLL (patch 1588605) and documented its behaviour
authorVadim Zeitlin <vadim@wxwidgets.org>
Sun, 11 Mar 2007 02:45:48 +0000 (02:45 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sun, 11 Mar 2007 02:45:48 +0000 (02:45 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@44760 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

docs/latex/wx/text.tex
src/gtk/textctrl.cpp

index 8f6cbb2e94398ce47bb8519977cd060503746382..b137d508f902d6c6ffb34fe4c9ad86d23e4b1e3d 100644 (file)
@@ -45,6 +45,10 @@ doesn't show the selection when it doesn't have focus - use this style to force
 it to always show it. It doesn't do anything under other platforms.}
 \twocolitem{\windowstyle{wxHSCROLL}}{A horizontal scrollbar will be created and
 used, so that text won't be wrapped. No effect under wxGTK1.}
+\twocolitem{\windowstyle{wxTE\_NO\_VSCROLL}}{For multiline controls only:
+vertical scrollbar will never be created. This limits the amount of text which
+can be entered into the control to what can be displayed in it under MSW but
+not under GTK2. Currently not implemented for the other platforms.}
 \twocolitem{\windowstyle{wxTE\_LEFT}}{The text in the control will be left-justified (default).}
 \twocolitem{\windowstyle{wxTE\_CENTRE}}{The text in the control will be centered (currently wxMSW and wxGTK2 only).}
 \twocolitem{\windowstyle{wxTE\_RIGHT}}{The text in the control will be right-justified (currently wxMSW and wxGTK2 only).}
index 558d9064e56f9e0c8fb1c281d66f8f43955aa2ec..4518dbd7292ff915bafbf51c07b6c9594d23ee51 100644 (file)
@@ -711,7 +711,10 @@ bool wxTextCtrl::Create( wxWindow *parent,
         // create scrolled window
         m_widget = gtk_scrolled_window_new( NULL, NULL );
         gtk_scrolled_window_set_policy( GTK_SCROLLED_WINDOW( m_widget ),
-                                        GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC );
+                                        GTK_POLICY_AUTOMATIC,
+                                        style & wxTE_NO_VSCROLL
+                                            ? GTK_POLICY_NEVER
+                                            : GTK_POLICY_AUTOMATIC );
         // for ScrollLines/Pages
         m_scrollBar[1] = (GtkRange*)((GtkScrolledWindow*)m_widget)->vscrollbar;