X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/77ffb5937e89927b621128789401db8921fe580f..30e13695172732216d90b578db80f3c07e6b9544:/include/wx/univ/textctrl.h?ds=sidebyside diff --git a/include/wx/univ/textctrl.h b/include/wx/univ/textctrl.h index 815b25ffe8..1c513e8b40 100644 --- a/include/wx/univ/textctrl.h +++ b/include/wx/univ/textctrl.h @@ -6,16 +6,12 @@ // Created: 15.09.00 // RCS-ID: $Id$ // Copyright: (c) 2000 SciTech Software, Inc. (www.scitechsoft.com) -// Licence: wxWidgets licence +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// #ifndef _WX_UNIV_TEXTCTRL_H_ #define _WX_UNIV_TEXTCTRL_H_ -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) - #pragma interface "univtextctrl.h" -#endif - class WXDLLEXPORT wxCaret; class WXDLLEXPORT wxTextCtrlCommandProcessor; @@ -176,8 +172,8 @@ public: // ----------------------- // caret stuff - virtual void ShowCaret(bool show = TRUE); - void HideCaret() { ShowCaret(FALSE); } + virtual void ShowCaret(bool show = true); + void HideCaret() { ShowCaret(false); } void CreateCaret(); // for the current font size // helpers for cursor movement @@ -191,6 +187,7 @@ public: void RemoveSelection(); wxString GetSelectionText() const; + virtual wxTextCtrlHitTestResult HitTest(const wxPoint& pt, long *pos) const; virtual wxTextCtrlHitTestResult HitTest(const wxPoint& pt, wxTextCoord *col, wxTextCoord *row) const; @@ -230,7 +227,7 @@ public: // override these methods to handle the caret virtual bool SetFont(const wxFont &font); - virtual bool Enable(bool enable = TRUE); + virtual bool Enable(bool enable = true); // more readable flag testing methods bool IsPassword() const { return (GetWindowStyle() & wxTE_PASSWORD) != 0; } @@ -294,7 +291,7 @@ protected: wxRect GetRealTextArea() const; // refresh the text in the given (in logical coords) rect - void RefreshTextRect(const wxRect& rect, bool textOnly = TRUE); + void RefreshTextRect(const wxRect& rect, bool textOnly = true); // refresh the line wrap marks for the given range of lines (inclusive) void RefreshLineWrapMarks(wxTextCoord rowFirst, wxTextCoord rowLast); @@ -329,7 +326,7 @@ protected: wxCoord *widthReal = NULL) const; // get the start and end of the selection for this line: if the line is - // outside the selection, both will be -1 and FALSE will be returned + // outside the selection, both will be -1 and false will be returned bool GetSelectedPartOfLine(wxTextCoord line, wxTextPos *start, wxTextPos *end) const; @@ -376,7 +373,7 @@ protected: wxTextCoord *colStart, wxTextCoord *colEnd, wxTextCoord *colRowStart, - bool devCoords = TRUE) const; + bool devCoords = true) const; // HitTest() version which takes the logical text coordinates and not the // device ones @@ -385,7 +382,7 @@ protected: wxTextCoord *row) const; // get the line and the row in this line corresponding to the given row, - // return TRUE if ok and FALSE if row is out of range + // return true if ok and false if row is out of range // // NB: this function can only be called for controls which wrap lines bool GetLineAndRow(wxTextCoord row, @@ -455,7 +452,7 @@ private: inline const wxArrayString& GetLines() const; inline size_t GetLineCount() const; - // replace a line (returns TRUE if the number of rows in thel ine changed) + // replace a line (returns true if the number of rows in thel ine changed) bool ReplaceLine(wxTextCoord line, const wxString& text); // remove a line @@ -518,6 +515,8 @@ private: DECLARE_EVENT_TABLE() DECLARE_DYNAMIC_CLASS(wxTextCtrl) + + friend class wxWrappedLineData; }; // ----------------------------------------------------------------------------