+ //
+ // returns true if we increased the limit to allow entering more text,
+ // false if we hit the limit set by SetMaxLength() and so didn't change it
+ bool AdjustSpaceLimit();
+
+#if wxUSE_RICHEDIT && (!wxUSE_UNICODE || wxUSE_UNICODE_MSLU)
+ // replace the selection or the entire control contents with the given text
+ // in the specified encoding
+ bool StreamIn(const wxString& value, wxFontEncoding encoding, bool selOnly);
+
+ // get the contents of the control out as text in the given encoding
+ wxString StreamOut(wxFontEncoding encoding, bool selOnly = false) const;
+#endif // wxUSE_RICHEDIT
+
+ // replace the contents of the selection or of the entire control with the
+ // given text
+ void DoWriteText(const wxString& text,
+ int flags = SetValue_SendEvent | SetValue_SelectionOnly);
+
+ // set the selection (possibly without scrolling the caret into view)
+ void DoSetSelection(long from, long to, int flags);
+
+ // get the length of the line containing the character at the given
+ // position
+ long GetLengthOfLineContainingPos(long pos) const;
+
+ // send TEXT_UPDATED event, return true if it was handled, false otherwise
+ bool SendUpdateEvent();