summaryrefslogtreecommitdiff
path: root/src/text.h
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2015-07-27 02:37:09 +0300
committerAndrei Karas <akaras@inbox.ru>2015-07-27 14:00:01 +0300
commit94eb2cb314e2629a659245554106ffe5e48f4d62 (patch)
tree83f5b6212270cb53af0d7fbd372bb7d1489c4bc9 /src/text.h
parent6c80045c4da5094014d623e3b855e31bfa8bf301 (diff)
downloadmv-94eb2cb314e2629a659245554106ffe5e48f4d62.tar.gz
mv-94eb2cb314e2629a659245554106ffe5e48f4d62.tar.bz2
mv-94eb2cb314e2629a659245554106ffe5e48f4d62.tar.xz
mv-94eb2cb314e2629a659245554106ffe5e48f4d62.zip
Add method for get text object width.
Diffstat (limited to 'src/text.h')
-rw-r--r--src/text.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/text.h b/src/text.h
index ae53a5984..38709f83b 100644
--- a/src/text.h
+++ b/src/text.h
@@ -76,6 +76,14 @@ class Text notfinal
virtual void draw(Graphics *const graphics,
const int xOff, const int yOff) A_NONNULL(2);
+ int getWidth() A_WARN_UNUSED;
+
+ int getX() A_WARN_UNUSED
+ { return mX; }
+
+ int getY() A_WARN_UNUSED
+ { return mY; }
+
private:
Font *mFont; /**< The font of the text */
TextChunk mTextChunk;