4

I would like to use the back-tick in regular text (not in a code snippet) in TW5. Is this possible?

YakovL
  • 7,557
  • 12
  • 62
  • 102
Ted Pudlik
  • 665
  • 8
  • 26

2 Answers2

11

It is also possible to use the hex code (`) or the HTML code (&#96) for back-tick

I wanted to display a back-tick in a code block, so used:

<code>&#x60;</code>

Using the HTML code looks like:

<code>&#96;</code>

This has the advantage that you're not disabling any parsing rules.

Mike P
  • 742
  • 11
  • 26
  • The `` or `
    ` tags are great for rendering blocks of code within a numbered list, whilst allowing the list to continue numbering where it left off.
    – mikequentel Oct 25 '17 at 19:39
6

In TiddlyWiki5 you can disable certain parsing rules using the \rules pragma

A pragma is a special component of WikiText that provides control over the way the remaining text is parsed.

http://tiddlywiki.com/#Pragma

So if you add

\rules except codeinline

at the very(!) beginning of your tiddler text, any following backtick symbol in the text is not interpreted as special character.

This comes however at the cost that you cannot use this symbol as wikitext-directive anymore to achieve inline-code for programming snippets. Instead you would need to add the html code tag manually.

Community
  • 1
  • 1
Felix K.
  • 14,171
  • 9
  • 58
  • 72