font color not adapted to map color

Bug #927110 reported by Kristin
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
widelands
Fix Released
Undecided
Angelo Locritani

Bug Description

The font color of the buildings (building statistics display and building label display) and speed indication is always yellow. This is quite hard to read when the map color is light, e.g. in desert (on sand) or snowland. For examples see the replays of the current tournament 2012 (first round on the map Last Bastion) or the snapshot attached. It would be nice to have a darker colored font for building description and speed in these worlds.

Tags: ui

Related branches

Revision history for this message
Kristin (ha-kripo) wrote :
Revision history for this message
Kristin (ha-kripo) wrote :

As the problem is mainly existent for building description of small buildings, another (perhaps easier to implement?) possibilty to make it more readable is perhaps to lower the description so that the building makes a darker background to the yellow font.

Revision history for this message
Nasenbaer (nasenbaer) wrote :

perhaps it would work, to add a shadow to the font? Or outlining with a darker color?

Revision history for this message
Angelo Locritani (alocritani) wrote :

Similar problem is present in mini-map (you can open it with M) - all buildings/flags/road are white, so it's quite impossible to distinguish them from the "terrain" layer in winterlands, without activating the "controlled area" layer.

Nasenbaer (nasenbaer)
Changed in widelands:
status: New → Confirmed
Revision history for this message
Angelo Locritani (alocritani) wrote :

I'm currently working to a branch that changes colors of pixel in minimap based on the world (greenland,winterland,etc...) and the visibility of other layers (like ownership layer,etc).

Regarding text colors, I'm thinking about changing the fg property of the textstyle object used for writing the text (census/statistics) can be done (function draw_help in src/logic/building.cc). I'll upload a branch during next days to explain my idea.

Revision history for this message
Angelo Locritani (alocritani) wrote :

just to show you the current status.
In attached image, the changes to minimap.
On winterland only, if the ownership layer is not shown, the color of building/flags/roads switch to orange, otherwise these elements are not visible.

Of course color can be changed, if you suggest a better one.

same logic can be applied to other worlds, also, but at the moment I think it's not needed.

Revision history for this message
Angelo Locritani (alocritani) wrote :

In that screenshot, instead, the color of text on top of building is changed

In this case I changed only the name part (statistics still in original color), and I took orange just for simplicity. Color can be adapted to different worlds (every world a different text color, if needed). I'm thinking about winterland (orange or another color) and desert (maybe blue?).

If you are interested I can post different screenshots with different colors for desert and winterland, in next days.

Changed in widelands:
assignee: nobody → Angelo Locritani (alocritani)
Revision history for this message
Angelo Locritani (alocritani) wrote :

In the attached image there are 2 possibilities that I'm currently exploring.
Left column shows the current situation; middle column shows the effect of adding a shadow under the text (gray text); right column shows the effect of adding a background box.

Sadly, at the moment I'm unable to make the rectangle semi-transparent (using an RGBAColor doesn't seems to work - any hint?).

What do you think? which solution do you prefer?

Revision history for this message
Chuck Wilder (chuckw20) wrote :

Of the three approaches in #8, I think the gray text shadow (middle option) is the most appealing.

Revision history for this message
Angelo Locritani (alocritani) wrote :

Thanks Chuck. middle solution is appealing but not sure if it creates enough contrast (especially on mountains or desert).
Maybe we can change the forecolor, also (see example #7).

In the same example please note the description of the mine half way over the mountain (that at the right of the well). I fear that, using shadow, description will not be readable enough (basically as it is now).

Revision history for this message
Chuck Wilder (chuckw20) wrote :

I attach a sample sheet of the various terrain tiles in the game. Some are outdated like the ice and water, but it should give you a tool to help compare legibility without the need to fire up a game.

Revision history for this message
Angelo Locritani (alocritani) wrote :

thanks a lot Chuck! Exactly what I was looking for!

Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Added in r6229 and r6230.

Changed in widelands:
milestone: none → build17-rc1
status: Confirmed → Fix Committed
tags: added: ui
Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Thanks a lot, Angelo! Nice to see someone finally solve this.

Though, it seems like the debug information shown in the upper left corner in debug mode does not get the added shadow. Could you please add it here as well?

Revision history for this message
Angelo Locritani (alocritani) wrote :

Hi Hans,
the missing shadow was intentional (I focused on what will be visible in the release version) but ok, I'll add it in next days (during weekend, probably...)

Revision history for this message
Hans Joachim Desserud (hjd) wrote :

That is undertandable, and I suspected something like that. :)

Revision history for this message
Hans Joachim Desserud (hjd) wrote :

understandable, even.

Revision history for this message
SirVer (sirver) wrote :

Released in build17-rc1.

Changed in widelands:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.