X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/7ee31b00ed1aff56aa22f43f65a8604f6937ca37..10769d8c47c21fe0ec5034726791a5ad4cf19475:/include/wx/textctrl.h diff --git a/include/wx/textctrl.h b/include/wx/textctrl.h index f3a0c2a0bd..56646fa242 100644 --- a/include/wx/textctrl.h +++ b/include/wx/textctrl.h @@ -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;