@@ -18,9 +18,9 @@ the first character(s) of every line (the "control sequence") indicates the role of that line. if no control sequence is recognized, the sequence [$.] is implied instead. the standard line classes and their associated control sequences are listed below. some control sequences have alternate forms, in order to support modern, readable unicode characters as well as plain ascii text. * paragraphs (. ¶ ❡): a paragraph is a simple block of text. the period control sequence is only necessary if the paragraph text begins with something that would otherwise be interpreted as a control sequence. -* newlines (\): inserts a line break into previous paragraph and attaches the following text. mostly useful for poetry or lyrics. +* newlines (\\): inserts a line break into previous paragraph and attaches the following text. mostly useful for poetry or lyrics. * section starts (# §): starts a new section. all sections have an associated depth, determined by the number of sequence repetitions (e.g. "###" indicates depth-three"). sections may have headers and IDs; both are optional. IDs, if present, are a sequence of raw-text immediately following the hash marks. if the line has one or more space character followed by styled-text, a header will be attached. the character immediately following the hashes can specify a particular type of section. e.g.: ** [$#] is a simple section break. ** [$#anchor] opens a new section with the ID [$anchor]. ** [$# header] opens a new section with the title "header". @@ -57,13 +57,16 @@ * strong \[*[!styled-text]\]: causes its text to stand out from the narrative, generally rendered as bold or a brighter color. * emphatic \[![!styled-text]\]: indicates that its text should be spoken with emphasis, generally rendered as italics * literal \[$[!styled-text]\]: indicates that its text is a reference to a literal sequence of characters, variable name, or other discrete token. generally rendered in monospace +* strikeout \[$[~styled-text]\]: indicates that its text should be struck through or otherwise indicated for deletion +* insertion \[$[+styled-text]\]: indicates that its text should be indicated as a new addition to the text body. +** consider using a macro definition [$\edit: [~[#1]][+[#2]]] to save typing if you are doing editing work * link \[>[!ref] [!styled-text]\]: produces a hyperlink or cross-reference denoted by [$ref], which may be either a URL specified with a reference or the name of an object like an image or section elsewhere in the document. the unicode characters [$→] and [$🔗] can also be used instead of [$>] to denote a link. * footnote \[^[!ref] [!styled-text]\]: annotates the text with a defined footnote * raw \[\\[!raw-text]\]: causes all characters within to be interpreted literally, without expansion. the only special characters are square brackets, which must have a matching closing bracket * raw literal \[$\\[!raw-text]\]: shorthand for [\[$[\…]]] -* macro \{[!name] [!arguments]}: invokes a [>ex.mac macro], specified with a reference +* macro \{[!name] [!arguments]\}: invokes a [>ex.mac macro], specified with a reference * argument \[#[!var]\]: in macros only, inserts the [$var]-th argument. otherwise, inserts a context variable provided by the renderer. * raw argument \[##[!var]\]: like above, but does not evaluate [$var]. * term \[&[!name] ([!label])\]: quotes a defined term with a link to its definition * inline image \[&@[!name]\]: shows a small image or other object inline. the unicode character [$🖼] can also be used instead of [$&@]. @@ -196,9 +199,9 @@ (the padlock emoji is shorthand for [$%ts].) ts redacts spans securely; that is, they are simply replaced with an indicator that they have been redacted, without visually leaking the length of the redacted text. -~~~ts-example example ~~~ cortav +~~~#ts-example example [cortav] ~~~ %ts word doc sorrowful-pines SORROWFUL PINES # intercept R1440 TCT S3 this communication between the ambassador of [*POLITY DOORMAT CRIMSON] "Socialist League world Glory" and an unknown noble of [*POLITY ROSE] "the Empire of a Thousand Suns" was intercepted by [*SYSTEM SUPINE WARBLE]. @@ -253,9 +256,9 @@ most of [$cortav.lua]'s implementation-specific behavior is controlled by use of [!modes]. these are namespaced options which may have a boolean, string, or numeric value. boolean modes are set with the [$-y] [$-n] flags; other modes use the [$-m] flags. most modes are defined by the renderer backend. the following modes affect the behavior of the frontend: -+ ID + type + effect ++ ID + type + effect | [$render:format]:| string | selects the [>refimpl-rend renderer] (default [$html]) | [$parse:show-tree]:| flag | dumps the parse tree to the log after parsing completes ##refimpl-rend renderers @@ -284,5 +287,4 @@ -m html:hue-spread 35 \ -y html:dark-on-light # could also be written as: $ cortav readme.ct -ommmmy readme.html render:format html html:width 40em html:accent 80 html:hue-spread 35 html:dark-on-light ~~~ -