7#ifndef MYGUI_EDIT_BOX_H_
8#define MYGUI_EDIT_BOX_H_
103 void eraseText(
size_t _start,
size_t _count = 1);
214 void setFontName(std::string_view _value)
override;
280 void setText(
const UString& _caption,
bool _history);
282 bool deleteTextSelect(
bool _history);
286 void eraseText(
size_t _start,
size_t _count,
bool _history);
288 void setTextSelectColour(
const Colour& _colour,
bool _history);
290 void _setTextColour(
size_t _start,
size_t _count,
const Colour& _colour,
bool _history);
292 void frameEntered(
float _frame);
294 void updateEditState();
297 void updateSelectText();
302 void commandPosition(
size_t _undo,
size_t _redo,
size_t _length,
VectorChangeInfo* _info =
nullptr);
310 void commandResetRedo();
311 void commandResetHistory();
316 void commandCopy()
const;
319 const UString& getRealString()
const;
321 void setRealString(
const UString& _caption);
323 void updateCursorPosition();
326 IntSize getContentSize()
const override;
328 IntPoint getContentPosition()
const override;
329 void setContentPosition(
const IntPoint& _point)
override;
331 IntSize getViewSize()
const override;
333 size_t getVScrollPage()
const override;
334 size_t getHScrollPage()
const override;
336 Align getContentAlign()
const override;
#define MYGUI_RTTI_DERIVED(DerivedType)
DequeUndoRedoInfo mVectorUndoChangeInfo
void setFontHeight(int _value) override
void insertText(const UString &_text, size_t _index=ITEM_NONE)
void deleteTextSelection()
size_t getTextLength() const
void setMaxTextLength(size_t _value)
Sets the max amount of text allowed in the edit field.
size_t getVScrollRange() const
size_t getVScrollPosition() const
IntCoord getTextRegion() const override
void setSize(const IntSize &_size) override
void setTextShadow(bool _value) override
ISubWidgetText * mClientText
void notifyMouseSetFocus(Widget *_sender, Widget *_old)
const UString & getCaption() const override
bool isVisibleVScroll() const
int getFontHeight() const override
void setTextSelection(size_t _start, size_t _end)
bool getEditStatic() const
void eraseText(size_t _start, size_t _count=1)
void notifyMouseDrag(Widget *_sender, int _left, int _top, MouseButton _id)
void setEditStatic(bool _value)
size_t getTextSelectionStart() const
void setEditMultiLine(bool _value)
void shutdownOverride() override
EventPair< EventHandle_WidgetVoid, EventHandle_EditPtr > eventEditTextChange
void setPropertyOverride(std::string_view _key, std::string_view _value) override
void notifyMouseReleased(Widget *_sender, int _left, int _top, MouseButton _id)
size_t getTextCursor() const
bool getEditPassword() const
void setTabPrinting(bool _value)
Char getPasswordChar() const
bool getEditMultiLine() const
void onMouseDrag(int _left, int _top, MouseButton _id) override
IntSize getTextSize() const override
void setPasswordChar(Char _char)
bool isVisibleHScroll() const
void setEditWordWrap(bool _value)
DequeUndoRedoInfo mVectorRedoChangeInfo
size_t getHScrollRange() const
void onKeyButtonPressed(KeyCode _key, Char _char) override
void updateViewWithCursor()
void setTextColour(const Colour &_value) override
void setVisibleVScroll(bool _value)
void setHScrollPosition(size_t _index)
void setTextShadowColour(const Colour &_value) override
std::string mOriginalPointer
void notifyMouseLostFocus(Widget *_sender, Widget *_new)
void setTextSelectionColour(const Colour &_colour)
void onKeyLostFocus(Widget *_new) override
void setCaption(const UString &_value) override
void notifyMouseButtonDoubleClick(Widget *_sender)
void setVisibleHScroll(bool _value)
bool getEditReadOnly() const
void notifyScrollChangePosition(ScrollBar *_sender, size_t _position)
void setPosition(const IntPoint &_point) override
size_t getTextSelectionLength() const
UString getTextInterval(size_t _start, size_t _count) const
UString getTextSelection() const
bool isTextSelection() const
void setOverflowToTheLeft(bool _value)
Sets if surplus characters should push characters off the left side rather than ignored.
bool getEditWordWrap() const
void setCoord(const IntCoord &_coord) override
size_t getHScrollPosition() const
void addText(const UString &_text)
void setOnlyText(const UString &_text)
size_t getTextSelectionEnd() const
void setInvertSelected(bool _value)
void setVScrollPosition(size_t _index)
bool getTabPrinting() const
UString getOnlyText() const
void notifyMouseWheel(Widget *_sender, int _rel)
bool getInvertSelected() const
EventPair< EventHandle_WidgetVoid, EventHandle_EditPtr > eventEditSelectAccept
void setTextAlign(Align _value) override
bool getOverflowToTheLeft() const
Returns true if surplus characters will be pushed off the left rather than ignored.
void setTextIntervalColour(size_t _start, size_t _count, const Colour &_colour)
size_t getMaxTextLength() const
Gets the max amount of text allowed in the edit field.
void setEditReadOnly(bool _value)
void setFontName(std::string_view _value) override
void onKeySetFocus(Widget *_old) override
void setEditPassword(bool _password)
void notifyMousePressed(Widget *_sender, int _left, int _top, MouseButton _id)
void initialiseOverride() override
void setTextCursor(size_t _index)
widget description should be here.
A UTF-16 string with implicit conversion to/from std::string and std::wstring.
types::TPoint< int > IntPoint
std::vector< TextCommandInfo > VectorChangeInfo
constexpr size_t ITEM_NONE
types::TCoord< int > IntCoord
types::TSize< int > IntSize
std::deque< VectorChangeInfo > DequeUndoRedoInfo
delegates::MultiDelegate< EditBox * > EventHandle_EditPtr