summaryrefslogtreecommitdiff
path: root/src/interface/Textbox.h
diff options
context:
space:
mode:
authorbuild.powdertoy.co.uk <admin@powdertoy.co.uk>2012-07-19 17:08:34 (GMT)
committer build.powdertoy.co.uk <admin@powdertoy.co.uk>2012-07-19 17:08:34 (GMT)
commitd328b84b1330b0e8f3a7f87ce48b9b20ea4b6d01 (patch)
treedb311c7849270ddd2510cbd65a192b059f8a3c77 /src/interface/Textbox.h
parentd71af3706a7a14e8ae65523e1a062417818b8fe2 (diff)
parent4d961117bde4398ae4d72f2db96eef381371e2df (diff)
downloadpowder-d328b84b1330b0e8f3a7f87ce48b9b20ea4b6d01.zip
powder-d328b84b1330b0e8f3a7f87ce48b9b20ea4b6d01.tar.gz
Merge branch 'master' of github.com:FacialTurd/PowderToypp
Diffstat (limited to 'src/interface/Textbox.h')
-rw-r--r--src/interface/Textbox.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/interface/Textbox.h b/src/interface/Textbox.h
index 120194e..e8e9d22 100644
--- a/src/interface/Textbox.h
+++ b/src/interface/Textbox.h
@@ -22,17 +22,20 @@ class Textbox : public Label
protected:
bool mouseDown;
bool masked, border;
- int cursor, cursorPosition;
+ int cursor, cursorPositionX, cursorPositionY;
TextboxAction *actionCallback;
std::string backingText;
+ std::string placeHolder;
public:
- Textbox(Point position, Point size, std::string textboxText);
+ Textbox(Point position, Point size, std::string textboxText = "", std::string textboxPlaceholder = "");
virtual ~Textbox();
virtual void SetDisplayText(std::string text);
virtual void SetText(std::string text);
virtual std::string GetText();
+ virtual void SetPlaceholder(std::string text);
+
void SetBorder(bool border) { this->border = border; };
void SetHidden(bool hidden) { masked = hidden; }
bool GetHidden() { return masked; }