The International Simutrans Forum

 

Author Topic: Inconsistent colours in server name list  (Read 236 times)

0 Members and 1 Guest are viewing this topic.

Offline ACarlotti

  • *
  • Posts: 405
Inconsistent colours in server name list
« on: January 13, 2019, 02:21:43 AM »
The server frame list seems to use inconsistent (or at least strange) colours. At the moment when it loads it displays servers names in COL_BLUE (if they are online) or SYSCOL_TEXT_STRONG (if they aren't). When clicking the names the colour then changes to SYSCOL_TEXT_STRONG if the server is reported offline or there is an error fetching game info, or SYSCOL_TEXT otherwise. The effect of this is that servers listings that are online change from blue to black when clicked, while other listings are black at all times. I doubt this is the intended behaviour, but I'm not sure exactly what is intended or desired.

Perhaps there should be three colours: online and matched version, online and mismatched version, or offline. There is also perhaps a case for updating the colour (to offline?) if there is an error getting info from the server (as is the case at present), although that is currectly made more complicated by the serverlist being freshly downloaded when the checkboxes are pressed.

My suggestions for colour would be black for online+match, red for online+mismatch and blue for offline; this is, however, different to what seems to have been the past intentions, so perhaps my intuition for appropriate colours is wrong.

The relevant code is lines 367 and 398-412 of gui/server_frame.cc