terrain2wiki: Wrap .string and .aliasof column contents in <code>...
...and use | instead of the Unicode broken bar (fixes bug #19678) This also extends the vertical bar escaping to the .aliasof column contents (in case we ever get base terrains with vertical bars) By using <code> we should be able to stick to byte-accurate contents without compromising readability, by styling terrain type strings in a default monospace font suitable for code display (i.e. | and l should be distinguishable from each other).
This commit is contained in:
parent
0c8990bb98
commit
15510a8dcd
1 changed files with 4 additions and 4 deletions
|
@ -62,14 +62,14 @@ def parse_terrain(data):
|
|||
data += """|-
|
||||
| %s
|
||||
| %s
|
||||
| %s
|
||||
| %s
|
||||
| <code>%s</code>
|
||||
| <code>%s</code>
|
||||
| %s
|
||||
""" % (
|
||||
"http://svn.gna.org/svn/wesnoth/trunk/data/core/images/terrain/%s.png" % (content['editor_image'] if 'editor_image' in content else content['symbol_image']),
|
||||
content['editor_name'][4:-1] if 'editor_name' in content else content['name'][4:-1],
|
||||
content['string'].replace("# wmllint: ignore", "").replace("|", "¦"),
|
||||
content['aliasof'] if 'aliasof' in content else "",
|
||||
content['string'].replace("# wmllint: ignore", "").replace("|", "|"),
|
||||
content['aliasof'].replace("|", "|") if 'aliasof' in content else "",
|
||||
content['editor_group'])
|
||||
|
||||
data += "|}"
|
||||
|
|
Loading…
Add table
Reference in a new issue