CWinCtrlEditbox¶
Script: EDITBOX
It is a text editable control.
You can set the maximum rows and the maximum string size.
Callbacks arriving at :class:`CWindowBase<CWindowBase>`
void onClick(CWinCtrlBase cCtrl)
void onDrag(CWinCtrlBase cCtrl,Vector2 pos,Vector2 dragVelocity)
void onClickEnter(CWinCtrlBase cCtrl)
It is called when a input string has been determined . The input string is stored in the caption.
void onDrop(CWinCtrlBase cCtrl,CWindowBase cDragWindow,CWinCtrlBase cDragCtrl)
This callback sent to the window of cCtrl.
Example of use
// get a control.
CWinCtrlEditbox ebSentence = find<CWinCtrlEditbox>(EDITBOX_Sentence);
// get entered text.
string strSentence = ebSentence.caption;
// Called when input is complete..
override protected void onClickEnter(CWinCtrlBase cCtrl) {
switch (cCtrl.id) {
case EDITBOX_Sentence:
break;
}
}