- virtual void SetSelection(long from, long to) = 0;
- virtual void SelectAll();
- virtual void SetEditable(bool editable) = 0;
+ DECLARE_NO_COPY_CLASS(wxTextAreaBase)
+};
+
+// this class defines wxTextCtrl interface, wxTextCtrlBase actually implements
+// too much things because it derives from wxTextEntry and not wxTextEntryBase
+// and so any classes which "look like" wxTextCtrl (such as wxRichTextCtrl)
+// but don't need the (native) implementation bits from wxTextEntry should
+// actually derive from this one and not wxTextCtrlBase
+class WXDLLIMPEXP_CORE wxTextCtrlIface : public wxTextAreaBase,
+ public wxTextEntryBase
+{
+public:
+ wxTextCtrlIface() { }
+
+private:
+ DECLARE_NO_COPY_CLASS(wxTextCtrlIface)
+};
+
+// ----------------------------------------------------------------------------
+// wxTextCtrl: a single or multiple line text zone where user can edit text
+// ----------------------------------------------------------------------------
+
+class WXDLLEXPORT wxTextCtrlBase : public wxControl,
+#if wxHAS_TEXT_WINDOW_STREAM
+ public wxSTD streambuf,
+#endif
+ public wxTextAreaBase,
+ public wxTextEntry
+{
+public:
+ // creation
+ // --------
+
+ wxTextCtrlBase() { }
+ virtual ~wxTextCtrlBase() { }
+
+
+ // more readable flag testing methods
+ bool IsSingleLine() const { return !HasFlag(wxTE_MULTILINE); }
+ bool IsMultiLine() const { return !IsSingleLine(); }