(zettel (meta (back "00001007040000 00001007800000 00001007990000 00001012920513") (backward "00001007040000 00001007800000 00001007990000 00001012920513") (box-number "1") (created "20210126175322") (forward "00001007030500 00001007031200 00001007050000 00001007050200 00001008000000") (modified "20220311185110") (published "20220311185110") (role "manual") (syntax "zmk") (tags "#manual #zettelmarkup #zettelstore") (title "Zettelmarkup: Literal-like formatting")) (rights 4) (encoding "") (content "There are some reasons to mark text that should be rendered as uninterpreted:\n* Mark text as literal, sometimes as part of a program.\n* Mark text as input you give into a computer via a keyboard.\n* Mark text as output from some computer, e.g. shown at the command line.\n\n=== Literal text\nLiteral text somehow relates to [[verbatim blocks|00001007030500]]: their content should not be interpreted further, but may be rendered special.\nIt is specified by two grave accent characters (\"\"''`''\"\", U+0060), followed by the text, followed by again two grave accent characters, optionally followed by an [[attribute|00001007050000]] specification.\nSimilar to the verbatim block, the literal element allows also a modifier letter grave accent (\"\"''ˋ''\"\", U+02CB) as an alternative to the grave accent character[^On some devices, such as an iPhone / iPad, a grave accent character is harder to enter and is often confused with a modifier letter grave accent.].\nHowever, all four characters must be the same.\n\nThe literal element supports the default attribute: when given, all spaces in the text are rendered in HTML as open box characters (U+2423).\nThe use of a generic attribute allows to specify a ([[programming|00001007050200]]) language that controls syntax coloring when rendered in HTML.\n\nIf you want to specify a grave accent character in the text, either use modifier grave accent characters as delimiters for the element, or put a backslash character before the grave accent character you want to use inside the element.\nIf you want to enter a backslash character, you need to enter two of these.\n\nExamples:\n* ``\\`\\`abc def\\`\\``` is rendered in HTML as ::``abc def``::{=example}.\n* ``\\`\\`abc def\\`\\`{-}`` is rendered in HTML as ::``abc def``{-}::{=example}.\n* ``\\`\\`abc\\\\\\`def\\`\\``` is rendered in HTML as ::``abc\\`def``::{=example}.\n* ``\\`\\`abc\\\\\\\\def\\`\\``` is rendered in HTML as ::``abc\\\\def``::{=example}.\n\n=== Computer input\nTo mark text as input into a computer program, delimit your text with two apostrophe characters (\"\"''\\'''\"\", U+0027) on each side.\n\nExample:\n* ``''STRG-C''`` renders in HTML as ::''STRG-C''::{=example}.\n* ``''STRG C''{-}`` renders in HTML as ::''STRG C''{-}::{=example}.\n\nAttributes can be specified, the default attribute has the same semantic as for literal text.\n\n=== Computer output\nTo mark text as output from a computer program, delimit your text with two equal sign characters (\"\"''=''\"\", U+003D) on each side.\n\nExamples:\n* ``==The result is: 42==`` renders in HTML as ::==The result is: 42==::{=example}.\n* ``==The result is: 42=={-}`` renders in HTML as ::==The result is: 42=={-}::{=example}.\n\nAttributes can be specified, the default attribute has the same semantic as for literal text.\n\n=== Inline-zettel snippet\nTo specify an inline snippet in a different [[syntax|00001008000000]], delimit your text with two at-sign characters (\"\"''@''\"\", U+0040) on each side.\n\nYou can add some [[attributes|00001007050000]] immediate after the two closing at-sign characters to specify the syntax to use.\nEither use the attribute key \"\"syntax\"\" or use the generic attribute to specify the syntax value.\nIf no value is provided, \"\"[[text|00001008000000#text]]\"\" is assumed.\n\nExamples:\n* ``A @@-->@@ B`` renders in HTML as ::A @@-->@@ B::{=example}.\n* ``@@@@{=html}Small@@@@{=html}`` renders in HTML as ::@@@@{=html}Small@@@@{=html}::{=example}.\n\nTo some degree, an inline-zettel snippet is the @@@@{=html}smaller@@@@{=html} sibling of the [[inline-zettel block|00001007031200]].\nFor HTML syntax, the same rules apply.\n\n=== Math mode / $$\\TeX$$ input\nThis allows to enter text, that is typically interpreted by $$\\TeX$$ or similar software.\nThe main difference to all other literal-like formatting above is that the backslash character (\"\"''\\\\''\"\", U+005C) has no special meaning.\nTherefore it is well suited the enter text with a lot of backslash characters.\n\nMath mode text is delimited with two dollar signs (\"\"''$''\"\", U+0024) on each side.\n\nYou can add some [[attributes|00001007050000]] immediate after the two closing at-sign characters to specify the syntax to use.\nEither use the attribute key \"\"syntax\"\" or use the generic attribute to specify the syntax value.\nIf no syntax value is provided, math mode text roughly corresponds to literal text.\n\nCurrently, Zettelstore does not support any syntax.\nThis will probably change.\nHowever, external software might support specific syntax value, like \"\"tex\"\", \"\"latex\"\", \"\"mathjax\"\", \"\"itex\"\", or \"\"webtex\"\".\nEven an empty syntax value might be supported.\n\nExample:\n* ``Happy $$\\\\TeX$$!``is rendered as ::Happy $$\\TeX$$!::{=example}"))