Author: mordante
Date: Sun Sep 21 12:33:57 2008
New Revision: 29613
URL: http://svn.gna.org/viewcvs/wesnoth?rev=29613&view=rev
Log:
Some fixes to the scroll label.
* Render the text a the right location.
* Make the label grow properly.
Modified:
trunk/data/gui/default/widget/scroll_label_default.cfg
trunk/src/gui/widgets/scroll_label.cpp
Modified: trunk/data/gui/default/widget/scroll_label_default.cfg
URL:
http://svn.gna.org/viewcvs/wesnoth/trunk/data/gui/default/widget/scroll_label_default.cfg?rev=29613&r1=29612&r2=29613&view=diff
==============================================================================
--- trunk/data/gui/default/widget/scroll_label_default.cfg (original)
+++ trunk/data/gui/default/widget/scroll_label_default.cfg Sun Sep 21 12:33:57
2008
@@ -49,6 +49,8 @@
[row]
[column]
+ horizontal_grow
= "true"
+ vertical_grow =
"true"
[label]
id =
"_label"
Modified: trunk/src/gui/widgets/scroll_label.cpp
URL:
http://svn.gna.org/viewcvs/wesnoth/trunk/src/gui/widgets/scroll_label.cpp?rev=29613&r1=29612&r2=29613&view=diff
==============================================================================
--- trunk/src/gui/widgets/scroll_label.cpp (original)
+++ trunk/src/gui/widgets/scroll_label.cpp Sun Sep 21 12:33:57 2008
@@ -120,9 +120,12 @@
void tscroll_label::set_content_size(const SDL_Rect& rect)
{
- //maybe add a get best height for a label with a given width...
assert(label_);
+ // Set the dummy spacer.
+ find_spacer()->set_size(rect);
+
+ //maybe add a get best height for a label with a given width...
SDL_Rect size = { 0, 0, get_best_size().x, get_best_size().y };
label_->set_size(size);
_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits