#include <Textbox.h>
Public Member Functions | |
| Textbox () | |
| Textbox (int size, Color color, bool sel) | |
| void | setFont (Font &font) |
| void | setPosition (Vector2f pos) |
| set the font of the text | |
| void | setLimit (bool ToF) |
| set the position of the text box on the screen | |
| void | setLimit (bool ToF, int lim) |
| method to set a text box with a limit or not | |
| void | setSelected (bool sel) |
| sets the text box with a specifiied limit | |
| std::string | getText () |
| sets selected to true | |
| void | drawTo (sf::RenderWindow &window) |
| grabs the text of the textbox | |
| void | typedOn (sf::Event input) |
| draws the textbox to the window | |
|
inline |
| Textbox::Textbox | ( | int | size, |
| Color | color, | ||
| bool | sel ) |
draws the textbox with the text color and character size
| void Textbox::drawTo | ( | sf::RenderWindow & | window | ) |
grabs the text of the textbox
draws the textbox to the window
| std::string Textbox::getText | ( | ) |
sets selected to true
returns the text of the textbox
| void Textbox::setFont | ( | Font & | font | ) |
sets the font of the text
| void Textbox::setLimit | ( | bool | ToF | ) |
set the position of the text box on the screen
sets the has limit bool value
| void Textbox::setLimit | ( | bool | ToF, |
| int | lim ) |
method to set a text box with a limit or not
sets the limit
| void Textbox::setPosition | ( | Vector2f | pos | ) |
set the font of the text
sets the position of the text
| void Textbox::setSelected | ( | bool | sel | ) |
sets the text box with a specifiied limit
removes the last character of the string
| void Textbox::typedOn | ( | sf::Event | input | ) |
draws the textbox to the window
if the textbox is being selected
grabs the unicode of the character
allows all characters, uses unicodes
only writes to textbox if the text is actually within the limit