Added <soft> tag that takes up no space for alignment purposes;

used this tag for magic creature types;
Added correct handling of Tribal sub types;
Fixed sort_index use by spoiler export template

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@637 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-08-28 20:49:25 +00:00
parent a360b334c5
commit 087af8360d
11 changed files with 94 additions and 66 deletions
+4 -2
View File
@@ -33,12 +33,12 @@ void TextElements::getCharInfo(RotatedDC& dc, double scale, size_t start, size_t
FOR_EACH_CONST(e, elements) {
// characters before this element, after the previous
while (out.size() < e->start) {
out.push_back(CharInfo(RealSize(0,0), BREAK_NO));
out.push_back(CharInfo());
}
e->getCharInfo(dc, scale, out);
}
while (out.size() < end) {
out.push_back(CharInfo(RealSize(0,0), BREAK_NO));
out.push_back(CharInfo());
}
}
@@ -100,6 +100,8 @@ struct TextElementsFromString {
else if (is_substr(text, tag_start, _("</sym"))) symbol -= 1;
else if (is_substr(text, tag_start, _( "<sep-soft"))) soft += 1;
else if (is_substr(text, tag_start, _("</sep-soft"))) soft -= 1;
else if (is_substr(text, tag_start, _( "<soft"))) soft += 1;
else if (is_substr(text, tag_start, _("</soft"))) soft -= 1;
else if (is_substr(text, tag_start, _( "<atom-kwpph"))) kwpph += 1;
else if (is_substr(text, tag_start, _("</atom-kwpph"))) kwpph -= 1;
else if (is_substr(text, tag_start, _( "<code-kw"))) code_kw += 1;