class DocEdit : public TextCtrl
DocEdit is form of raw text editor that interprets lines as paragraphs (wraps them).
Derived from TextCtrl
DocEdit& SetFont(Font f)
Sets the font to be used by widget to f.
DocEdit& After(int a)
The height of empty block after the paragraph in pixels. Default is 0.
DocEdit& SetFilter(int (*f)(int c))
Sets the character filter f. All characters keystrokes are first altered by this function and used only if the result is not zero.
DocEdit& AutoHideSb(bool b = true)
In AutoHideSb mode, scrollbar is only visible when it is needed (text height is bigger than the height of the window). This mode is active by default.
bool IsAutoHideSb() const
Returns true if AutoHideSb is active.
DocEdit& UpDownLeave(bool u = true)
In UpDownLeave mode, Up key at the top of text or Down key at the bottom is not processed by DocEdit, which in turn means that it can be processed by parent Ctrl. In TopWindow, this will move the focus to previous / next Ctrl that IsWantFocus.
DocEdit& NoUpDownLeave()
Same as UpDownLeave(false).
bool IsUpDownLeave() const
Tests UpDownLeave mode.
DocEdit& SetScrollBarStyle(const ScrollBar::Style& s)
Sets the chameleon style of scrollbar.
DocEdit& EofLine(bool b = true)
If active, paints faint line at the end of text. Default is active.
DocEdit& NoEofLine()
Same as EofFile(false).
bool IsEofLine() const
Returns true if EofLine is active.
EditPos GetEditPos() const
Returns the edit position in the text to be restored later. Edit position comprises cursor and scrollbar positions.
void SetEditPos(const TextCtrl::EditPos& pos)
Restores the position obtained with GetEditPos.
|