src/widget/widget_button_txt.cpp
branchcpp_gui
changeset 6264 9fc3b5467396
parent 6258 a2f86b8fd99b
child 6289 be3d8bd9fb02
--- a/src/widget/widget_button_txt.cpp	Tue Feb 27 13:26:47 2007 +0000
+++ b/src/widget/widget_button_txt.cpp	Tue Feb 27 22:47:59 2007 +0000
@@ -15,5 +15,18 @@
 #include "../table/sprites.h"
 #include "../genworld.h"
 #include "../helpers.hpp"
+#include "window_events.hpp"
+
+namespace gui {
+
+/*virtual*/ void TextButton::OnPaint(EvtPaint &ev)
+{
+	DrawBackground(ev);
+	Point center = CenterPt();
+	if (m_pushed) center += Point(1, 1);
+	DrawStringCentered(center.x, center.y - 5, m_text, 0);
+	ev.SetHandled();
+}
 
 
+}; // namespace gui