added (and documented) trivial but useful IsSingleLine() and IsMultiLine() text control methods

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16242 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2002-07-21 18:51:04 +00:00
parent 5bf75ae769
commit aa8e9a36c4
2 changed files with 26 additions and 0 deletions

View File

@@ -174,6 +174,10 @@ public:
virtual bool IsModified() const = 0;
virtual bool IsEditable() const = 0;
// more readable flag testing methods
bool IsSingleLine() const { return !(GetWindowStyle() & wxTE_MULTILINE); }
bool IsMultiLine() const { return !IsSingleLine(); }
// If the return values from and to are the same, there is no selection.
virtual void GetSelection(long* from, long* to) const = 0;