summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoralberth <alberth@openttd.org>2012-05-26 21:30:38 +0000
committeralberth <alberth@openttd.org>2012-05-26 21:30:38 +0000
commit87d5f47050cbc2a890918317d0e2636ea93fd53a (patch)
tree3efdb95fc908ad11ba17f4e32e9a29f5a26f2232
parent228e26f9305f71c776492f50bc1fd603fa8fddd5 (diff)
downloadopenttd-87d5f47050cbc2a890918317d0e2636ea93fd53a.tar.xz
(svn r24293) -Fix: Increase the left and right margins of the text in the yes/no query window.
-rw-r--r--src/misc_gui.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/misc_gui.cpp b/src/misc_gui.cpp
index 3816e7b09..6374fabf2 100644
--- a/src/misc_gui.cpp
+++ b/src/misc_gui.cpp
@@ -1297,8 +1297,8 @@ struct QueryWindow : public Window {
if (widget != WID_Q_TEXT) return;
Dimension d = GetStringMultiLineBoundingBox(this->message, *size);
- d.width += padding.width;
- d.height += padding.height;
+ d.width += WD_FRAMETEXT_LEFT + WD_FRAMETEXT_RIGHT;
+ d.height += WD_FRAMERECT_TOP + WD_FRAMERECT_BOTTOM;
*size = d;
}
@@ -1306,7 +1306,8 @@ struct QueryWindow : public Window {
{
if (widget != WID_Q_TEXT) return;
- DrawStringMultiLine(r.left, r.right, r.top, r.bottom, this->message, TC_FROMSTRING, SA_CENTER);
+ DrawStringMultiLine(r.left + WD_FRAMETEXT_LEFT, r.right - WD_FRAMETEXT_RIGHT, r.top + WD_FRAMERECT_TOP, r.bottom - WD_FRAMERECT_BOTTOM,
+ this->message, TC_FROMSTRING, SA_CENTER);
}
virtual void OnClick(Point pt, int widget, int click_count)