Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.
Sign upNested Color Markup #2273
Nested Color Markup #2273
Comments
|
Yeah during color markup implementation I've deliberately avoided to use a color stack in order to
Things can change though. Of course written in the wiki doesn't mean written in stone. |
|
Closing tags would still be optional with a color stack. My problem derives from the fact that I have white glyphs for letters and a few special glyphs in my bitmap font. Adding a special glyph is done via "[WHITE]" + (char)540 + "[]". If the enclosing text is red I get the misbehaviour. I strongly vote for a color stack, I don't think it would be a lot slower, especially since is only done once when updating the text |
|
@badlogic @NathanSweet |
|
A stack would be nice. Aye, it might be good to do #1934 first. |
Using "This is [RED]red with [YELLOW]yellow[] text[] inside" colors everything except for "yellow" in red. It seems like this is because only the previous color is stored. This could be solved by adding a color stack, which pops the top value when a "[]" is found.