#include <utf8textfield.h>


Public Member Functions | |
| UTF8TextField (const std::string &text="") | |
| virtual | ~UTF8TextField () |
| virtual void | keyPressed (KeyEvent &keyEvent) |
Protected Attributes | |
| UTF8StringEditor * | mStringEditor |
UTF-8 aware version of the TextField class.
Using UTF8StringEditor, it is able to correctly edit UTF-8 text line.
You will also need an UTF-8 aware font to be able to correctly display such text (so gcn::ImageFont can not be used).
Definition at line 48 of file utf8textfield.h.
| gcn::UTF8TextField::UTF8TextField | ( | const std::string & | text = "" |
) |
UTF8TextField constructor.
| text | Initial text. |
Definition at line 34 of file utf8textfield.cpp.
References mStringEditor.
| gcn::UTF8TextField::~UTF8TextField | ( | ) | [virtual] |
| void gcn::UTF8TextField::keyPressed | ( | KeyEvent & | keyEvent | ) | [virtual] |
Key pressed handler.
Overides gcn::TextField to handle UTF-8 character codes.
| keyEvent | Keyboard event. |
Definition at line 45 of file utf8textfield.cpp.
References gcn::UTF8StringEditor::eraseChar(), gcn::UTF8StringEditor::insertChar(), mStringEditor, gcn::UTF8StringEditor::nextChar(), and gcn::UTF8StringEditor::prevChar().
UTF8StringEditor* gcn::UTF8TextField::mStringEditor [protected] |
UTF-8 string editor suppor.
It allows the UTF8TextField to easly traverse UTF-8 strings as well as inserting and deleting characters.
Definition at line 78 of file utf8textfield.h.
Referenced by keyPressed(), UTF8TextField(), and ~UTF8TextField().
1.7.1