On Tuesday 31 March 2009 12:35:52 am Eric S. Raymond wrote:
> Patrick Parker <[email protected]>:
> > This means that ~RC(a>b) image path function syntax will need to
> > change (because it contains &gt;)
>
> That doesn't occur in text strings, does it?  Because the pango
> interpretation is only done in very specific contects; right now,
> only in message= attributes within [message].
It occurs in [message] [option] message=, if you want to have a menu with unit 
icons and multi-column* text labels, for instance. And, since most unit 
graphics have magenta bits, you'd probably be using e.g. 
units/human-magi/mage.png~RC(magenta>red) rather than just 
units/human-magi/mage.png. Note that ~RC(magenta>a_team_color_name) can 
_usually_ be replaced with ~TC(a_team_number,magenta) if you are in a game 
scenario.

Note that I implemented a separate image path function, ~RC(palette1 = 
palette2) in 1.5.x that allows to do a lower-level palette change (e.g. 
no "color range" stuff, just plain palettes). I changed its syntax to 
~PAL(palette1 > palette2) in 1.7.x before this Pango markup change was 
introduced.

Anyway, I suppose that there is no clean way to replace the old markup with 
Pango markup in option list entries yet. At least I can't think of a clean 
way to handle the multi-column (equal sign) and this-is-our-default-selection 
(asterisk) markup

Since I'd like to see Pango markup used for option lists in messages as well, 
perhaps it is time we consider replacing the RC and PAL image path 
functions' '>' with a colon, asterisk, bang, etc. Or rethinking the overall 
image path function syntax itself, since some people (including a developer) 
consider it to be rather obscure and complicated.

-- 
Regards
  Ignacio R. Morelle <shadowmaster>

[*] Which is doable with the old markup - I have seen up to three-column list; 
column 1 being a unit icon, column 2 being a text description, and column 3 
being some stuff in parentheses; seen in the campaign difficulty selection 
menu or in some ANL dialogs, for instance.

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
Wesnoth-dev mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-dev

Reply via email to