Tweaked the inline keyword regex a bit; "\"0:" now becomes a mana symbol if the " is a curly quote.

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@483 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-07-05 00:34:42 +00:00
parent 470fbcb9a7
commit 3b84643050
+7 -2
View File
@@ -206,7 +206,7 @@ init script:
# context in which mana symbols are found
mana_context :=
"(?ix) # case insensitive, ignore whitespace
(^|[[:space:]\"(]) # start of a word
(^|[[:space:]\"(“']) # start of a word
( <match>: # G: something
| <match>, # G, tap: something
| <match>[ ]can[ ]be[ ]pay
@@ -241,7 +241,12 @@ init script:
) +
# step 2b : move action keywords' reminder text to the end of the line
replace_rule(
match: "(<atom-reminder-action>.*</atom-reminder-action></kw[^>]*>)([^\n(]+)",
match: "(<atom-reminder-action>(?:(?!<kw-).)*</atom-reminder-action></kw[^>]*>)(((?!<atom-reminder| ?<kw-)[^\n(])+)",
replace: "\\2\\1"
) +
# step 2c : remove duplicate reminder text
replace_rule(
match: "(<atom-reminder-[^>]*>[^)]+[)]</atom-reminder-[^>]*>)([^\n]+)\\1"
replace: "\\2\\1"
) +
# step 3a : expand shortcut words ~ and CARDNAME