resilience with kindness & purpose


Markup Cheat-sheet

How to write text for the editable parts of this website, using “RedCloth”. Each definition here is a link to the official documentation, which you can also browse here.

Paragraphs := Paragraphs are separated by a blank line.

Line breaks := Lines that don’t have a blank line in between are part of the same paragraph.

Centered paragraph := Put “p=. “ at the start of the paragraph (note the space after the “.”)

Headings := Put “h1. “ at the start of the line. Leave a blank line after each heading. You can use h1 (main heading) through h6 (minor sub-heading).

Bullet list := Leave a blank line before and after the list. Put each list item on a new line, and put a “* “ at the start of each list item.

Numbered list := Leave a blank line before and after the list. Put each list item on a new line, and put a “# “ at the start of each list item. Note the space after the #.

To start a numbered list from a different number (not 1), put the number after the hash.
#4 This list will start from 4.

To continue a list’s numbering from where you previous ordered list finished, you can let textile know using the continuation character:

#_ Continuing list item, numbered as 5
# Item 6

Bold text := Surround the text with asterisks.

Italic text := Surround the text with underscores.

Underlined text := Surround text with %s. Also have (uline) after the first %.
   %(uline)the fishy%
   will print: the fishy

Table := Separate each cell with vertical pipes. Make sure there’s no white-space before or after each line, eg:
|first|second|
|3rd|4th|

Link := Put the text of the link in quotes, followed by a colon and the url.
eg. "Your website":http://glastonbury.com.au/

Image :=
eg. p=. <img src="!1_almost_summit.jpg!">

Image with link := Put a colon and the link url after the image.
eg. !http://www.w3.org/Icons/valid-html401!:http://validator.w3.org/check?uri=referer

Superscript (whole word) := Surround the text with ^s
eg. ^TM^ will produce TM.

Superscript (attached to other text, eg 6th) := Put square brackets around the ^ stuff
eg. 6[^th^] will produce 6th

Subscript := Put [~ ~] around the text
eg. CO[~2~] will produce CO2

Pagebreak (all formats of book)
p(pagebreak). &nbsp;

 

PDF tags

<pdf:toc>   Table of Contents page

<pdf:page-break>

 

<pdf:blank-page>

<pdf:print-only-totally-blank>

 
Start page numbers – it’s a decorator for a main heading. Should be at the start of a text file:
h1{page:pdf_start_page_numbers}. Put Heading Here.

 

Section break.

p(section_break). &nbsp;

Even though there’s no visible text, you need the “section_break” style so the next paragraph doesn’t get indented.

Special symbols:

®   &reg;
©   &copy;
°   &deg;
¾   &frac34;
½   &frac12;
¼   &frac14;
£   &pound;
&   &amp;
é   &eacute;
à   &agrave;
ö   &ouml;
Δ   &Delta;
→   &rarr;

&nbsp; non-breaking space. Looks like a space but tells the PDF generator don’t line-wrap at this point. So I’ve used it in equations and stuff.

 

Block Quotes

There are lots of examples in Part One of Pat’s book.

bq. (at start of each paragraph in quote) Block quote. Italic text. Extra line before & after the block. Extra-wide margins to left & right of text.

bq=. Block quote, centered.

 

Indenting (or not) first line of paragraph.

Most paragraphs should have an indented first line, except if it’s immediately after some not-normal-paragraph text (eg. after a heading or a section-break). Hopefully this will Just Work.

These terms go in brackets at a paragraph marker or block-quote marker, eg.
p(with_indent). – paragraph with indented first line
p(no_indent). – paragraph with unindented first line

bq(with_indent). – block-quote with indent
bq(no_indent). – block-quote with no indent

 

Footnotes.

In text: put the number of the footnote in square brackets, like this[2]

At end of chapter:

- put a horizontal line <hr/> at start of footnote section

- leave a blank line after the <hr/> and between footnotes

- start each footnote like this (using the number for that footnote):

fn2^. footnote here.

 

Letters in Pat’s Book.

example:

bq(letter_address_indent). Monday, 30th of May, 1960.

bq(letter_greeting_paragraph). %(letter_greeting)Dear Hal,% Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris consectetur arcu dictum ligula porttitor ultrices. Sed in turpis eu urna molestie varius maximus nec.

bq. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Mauris consectetur arcu dictum ligula porttitor ultrices. Sed in turpis eu urna.

bq(letter_signoff_indent). Love from
Judith