beyond markdown

bowerbird Blocked Unblock Follow Following Oct 7, 2014

— part 7

text styling and typographic niceties

this is part 7 in a series on “z.m.l.”

— zen markup language — that’s

a light-markup system you might

consider to replace markdown.

for links to the other parts, see below.

in this part, we discuss styling of

words and phrases, plus some of

the small typographical changes

made during a z.m.l. conversion,

and two special .html characters.

text styling

italics

it’s important to enable the type of

text-styling that writers often use,

primary among them being _italics_.

surround a word with _underscores_,

and z.m.l. will show the word in italics.

and for a phrase, _do_ _each_ _word_.

we will explore additional methods,

like the more-traditional “toggle” —

_successively turning italics on and off_

— but for now you must do each word.

(no, z.m.l. won’t show the underscores;

i am just doing that here, on medium,

so i can repurpose this text elsewhere.)

and yes, z.m.l. is smart enough to know

not to replace underscores in a u.r.l.,

so you don’t need to wonder about that.

unlike some flavors in other systems,

you _can_ use intraword italics in z.m.l.

because a survey of printed-books show

it’s not an unknown practice of writers,

and z.m.l. exists to serve writers’ needs.

bold

sometimes *bold* is also used, but

it should be noted that, other than

in headers, *bold* is rarely found in

printed-books. still, as it’s employed

more often online, z.m.l. supports it.

surround a word with *asterisks* and

z.m.l. will display that word in bold.

yes, for a phrase, *do* *each* *word*.

(no, the asterisks will not be shown.)

and yes, you can use asterisks in all

the other places you wanna use them,

and z.m.l. will sort them out, and if

it makes a mistake, you let me know.

monospaced

last, ~a~ ~monospaced~ ~typeface~ is

used in many tech documents, so it

is supported in z.m.l., even though

it’s almost never seen in print-books.

(except for tech-oriented ones, yes.)

to get a monospace typeface, use a

tilde or the “`” key above the tilde.

medium offers no inline monospace,

as far as i know, so no input sample.

the same rules as for italics and bold.

~a~ ~monospaced~ ~typeface~

this is what z.m.l. supports for styling

in its “default” mode, but we make it

easy for users to customize the settings

to meet the needs of a specific document.

so if you need other styling, you can get it.

if you need to disable the default, you can.

typographic considerations

we want our output to look nice,

and to this end z.m.l. supports

a few typographic conventions,

i.e., curly-quotes and em-dashes.

curly-quotes

z.m.l. will turn straight-quotes

into curly quotes automatically.

but if you prefer your document

to have straight-quotes, which is

your right, no matter what some

typographic fanatics might say,

it’s easy to disable this feature.

em-dashes

likewise with em-dashes — z.m.l.

converts a plain-text double-dash

into a long typographic em-dash —

but you can disable it if you choose.

code-blocks

note than none of these substitutions

are performed on code-blocks, of course,

because they would mess up the code.

.html special characters

there are some characters that

have special meaning in .html,

and thus need special treatment

when we do an .html conversion.

the “less than” left-angle-bracket

because the left-angle-bracket is used

to signal .html tags, z.m.l. disables it,

by turning it into its < “equivalent”.

the ampersand

the ampersand — “&* — also has to be

disabled so it won’t cause any problems.

***

ok, that’s all for today!

***

here are the articles in this series:

beyond markdown — part 1 — it’s time for the next step https://medium.com/@bbirdiman/beyond-markdown-part-1-2300665659f7

beyond markdown — part 2 — z.m.l. was built to be easy to understand https://medium.com/@bbirdiman/beyond-markdown-part-2-b3527d2b9dcf

beyond markdown — part 3 — two types of chunks — paragraphs and blocks https://medium.com/@bbirdiman/beyond-markdown-part-3-eed9bebea0da

beyond markdown — part 4 — how to “tag” a block for formatting https://medium.com/@bbirdiman/beyond-markdown-part-4-9b4dc6841d7e

beyond markdown — part 5 — shining a spotlight on sections and headers

https://medium.com/@bbirdiman/beyond-markdown-part-5-4902097723b0

beyond markdown — part 6 — notes on a few types of “special” paragraphs

https://medium.com/@bbirdiman/beyond-markdown-part-6-8056eee5b783

beyond markdown — part 7 — text styling and typographic niceties

https://medium.com/@bbirdiman/beyond-markdown-part-7-3158e23f22bf

beyond markdown — part 8 — alignment, horizontal rules, and breaks

https://medium.com/@bbirdiman/beyond-markdown-part-8-1a082d7f1f6d

beyond markdown — part 9 — pulling outside resources into your document

https://medium.com/@bbirdiman/beyond-markdown-part-9-be74bbbed369

beyond markdown — part 10 — special sections in your document

https://medium.com/@bbirdiman/beyond-markdown-part-10-3ca0c08e5641

***

and, for reference, as an extra bonus:

markdown considered harmful — or perhaps a loved but irritating old uncle

https://medium.com/@bbirdiman/markdown-considered-harmful-495ccfe24a52