Multi-colored names for multi-owned systems

Programmers discuss here anything related to FreeOrion programming. Primarily for the developers to discuss.

Moderator: Committer

Post Reply
Message
Author
Mitten.O
Programmer
Posts: 255
Joined: Sun Apr 06, 2014 4:15 pm

Multi-colored names for multi-owned systems

#1 Post by Mitten.O »

This patch implements the feature request at
http://sourceforge.net/p/freeorion/feat ... uests/159/.

It makes the name of a system which has planets of multiple empires
be coloured with all of their colors. (As long as the name is longer than there are owners)

I had to refactor ShadowedTextControl to use composition instead of inheritance
to avoid the rgba tags colouring the shadow.
Attachments

[The extension patch has been deactivated and can no longer be displayed.]

Any code by me in this post is released under GPL 2.0 or later.

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 13587
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Multi-colored names for multi-owned systems

#2 Post by Geoff the Medio »

Screenshot?

Mitten.O
Programmer
Posts: 255
Joined: Sun Apr 06, 2014 4:15 pm

Re: Multi-colored names for multi-owned systems

#3 Post by Mitten.O »

Here you go.

EDIT: Add a more complex one.
Attachments
multiname.png
multiname.png (151.6 KiB) Viewed 1309 times
multiname.png
multiname.png (89.11 KiB) Viewed 1309 times
Any code by me in this post is released under GPL 2.0 or later.

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 13587
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Multi-colored names for multi-owned systems

#4 Post by Geoff the Medio »

Builds OK for me.

Anyone have comments on the look?

User avatar
MatGB
Creative Contributor
Posts: 3310
Joined: Fri Jun 28, 2013 11:45 pm

Re: Multi-colored names for multi-owned systems

#5 Post by MatGB »

From those screenshots it looks close to perfect.
Mat Bowles

Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.

User avatar
Dilvish
AI Lead and Programmer Emeritus
Posts: 4768
Joined: Sat Sep 22, 2012 6:25 pm

Re: Multi-colored names for multi-owned systems

#6 Post by Dilvish »

It would be nice if something could be done to improve the legibility of the darker letters (perhaps a light shadow for them rather than black), but I suppose that's an existing issue & not a reason to hold up this. I'm not entirely sure we'll want to stick with this anymore than we liked the multiple colors for starlanes when I made a patch for that, but it's worth rolling out, giving it a try & getting feedback.
If I provided any code, scripts or other content here, it's released under GPL 2.0 and CC-BY-SA 3.0

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 13587
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Multi-colored names for multi-owned systems

#7 Post by Geoff the Medio »


User avatar
MatGB
Creative Contributor
Posts: 3310
Joined: Fri Jun 28, 2013 11:45 pm

Re: Multi-colored names for multi-owned systems

#8 Post by MatGB »

Feedback, noticed a system on my map in my new game with the new install.

I love it, it makes things so much clearer, and doesn't appear to have any issues.
Mat Bowles

Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.

Post Reply