Formula engine: change undocumented string substitution syntax

It used to use {}, which gets caught by the preprocessor.
Now it uses [] instead.
This commit is contained in:
Celtic Minstrel 2016-03-04 04:02:48 -05:00
parent 240b5f61a7
commit 03bbc79367
2 changed files with 3 additions and 3 deletions

View file

@ -9,7 +9,7 @@
y = 0
w = {SIZE}
h = {SIZE}
name = "('buttons/misc/orb{STATE}.png" + <<~RC(magenta>{icon})')>>
name = "('buttons/misc/orb{STATE}.png~RC(magenta>[icon])')"
[/image]
#enddef

View file

@ -558,8 +558,8 @@ public:
subs_()
{
std::string::iterator i;
while((i = std::find(str.begin(), str.end(), '{')) != str.end()) {
std::string::iterator j = std::find(i, str.end(), '}');
while((i = std::find(str.begin(), str.end(), '[')) != str.end()) {
std::string::iterator j = std::find(i, str.end(), ']');
if(j == str.end()) {
break;
}