Talk:Tileset/tile2360.py

From NetHackWiki
< Talk:Tileset
Revision as of 14:46, 29 January 2016 by Ais523 (talk | contribs) (how to escape an entire program)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

This program errors out when copied from the page. I believe this is because...

epilog=

is supposed to be...

epilog='''

It does appear correctly when viewed in edit. (I was having problems with it before I found the program on the github page.)

Emeraldragon (talk) 09:49, 28 January 2016 (UTC)

Yes, that's correct. The ''' is considered valid wiki syntax so it disappears on the page. The code section should be wrapped in some formatter to prevent this and any other markup changes. Or at least a warning should be added. -- Qazmlpok (talk) 16:53, 28 January 2016 (UTC)
Luckily, Python treats single and double quotes more or less the same.--Ray Chason (talk) 04:37, 29 January 2016 (UTC)
The "magic markup" to show an entire program verbatim is typically <pre><nowiki> at the start, and </nowiki></pre> at the end. This will show almost every possible special character as-is. Ais523 (talk) 14:46, 29 January 2016 (UTC)