[Freeciv-Dev] (PR#10278) Xaw: xaw client does not show information about
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://RT::WebBaseURL.not.configured:80/Ticket/Display.html?id=10278 >
> [evyscr - Sep 23 18:24:44 2004]:
>
> CVS 2004 09 22, Xaw client.
>
> Xaw client has now no ability to show unit's veteran level.
Well, right name of bug is 'Xaw client use old veteran system in
update_unit_info_label'.
Attached patch (against CVS HEAD 20041005 19:47 +0400):
- fixes the bug;
- uses text.c functions in this fix.
Freeciv.in was needed to change cause of adding new line in
get_unit_info_label_text2().
Please note, that get_unit_info_label_text2() may return 4-lines
or 3-lines string (3 lines if no punit).
Thanks, evyscr.
diff -urN freeciv-orig/client/gui-xaw/mapview.c freeciv/client/gui-xaw/mapview.c
--- freeciv-orig/client/gui-xaw/mapview.c 2004-10-02 20:13:58 +0400
+++ freeciv/client/gui-xaw/mapview.c 2004-10-05 23:14:35 +0400
@@ -202,15 +202,9 @@
{
if(punit) {
char buffer[512];
- struct city *pcity;
- pcity=player_find_city_by_id(game.player_ptr, punit->homecity);
- my_snprintf(buffer, sizeof(buffer), "%s %s\n%s\n%s\n%s",
- unit_type(punit)->name,
- (punit->veteran) ? _("(veteran)") : "",
- (hover_unit==punit->id) ?
- _("Select destination") : unit_activity_text(punit),
- map_get_tile_info_text(punit->tile),
- pcity ? pcity->name : "");
+ my_snprintf(buffer, sizeof(buffer), "%s\n%s",
+ get_unit_info_label_text1(punit),
+ get_unit_info_label_text2(punit));
xaw_set_label(unit_info_label, buffer);
if (hover_unit != punit->id)
diff -urN freeciv-orig/data/Freeciv.in freeciv/data/Freeciv.in
--- freeciv-orig/data/Freeciv.in 2004-10-04 21:33:08 +0400
+++ freeciv/data/Freeciv.in 2004-10-06 00:09:23 +0400
@@ -2621,7 +2621,7 @@
Freeciv*turndonebutton.left: chainLeft
Freeciv*turndonebutton.right: chainRight
-Freeciv*unitinfolabel.label: \n\n\n\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
\
+Freeciv*unitinfolabel.label: \n\n\n\n\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
\ \ \ \ \
Freeciv*unitinfolabel.justify: left
Freeciv*unitinfolabel.fromVert: turndonebutton
Freeciv*unitinfolabel.top: chainTop
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] (PR#10278) Xaw: xaw client does not show information about veteran level,
Egor Vyscrebentsov via RT <=
|
|