Add vi-ish navigation to first and last slide
[smdp.git] / sample.md
1 %title: mdp - Sample Presentation
2 %author: visit1985
3 %date: 2014-09-22
4
5 -> mdp <-
6 =========
7
8 -> A command-line based markdown presentation tool. <-
9
10 _Basic controls:_
11
12 next slide      *Enter*, *Space*, *Page Down*, *j*, *l*,
13                 *Down Arrow*, *Right Arrow*
14
15 previous slide  *Backspace*, *Page Up*, *h*, *k*,
16                 *Up Arrow*, *Left Arrow*
17
18 quit            *q*
19 reload          *r*
20 slide N         *1..9*
21 first slide     *Home*, *g*
22 last slide      *End*, *G*
23
24 -------------------------------------------------
25
26 -> # Supported markdown formatting's <-
27
28 The input file is split into multiple slides by
29 horizontal rules (hr). A hr consisting of at
30 least 3 *\** or *-*. It can also contain spaces but
31 no other characters.
32
33 Each of these represents the start of a new slide
34
35 \* \* \*
36 \---
37 \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*
38 \- - -
39
40 -------------------------------------------------
41
42 -> # Supported markdown formatting's <-
43
44 First-level headers can be prefixed by single *#*
45 or underlined by *===*.
46
47 \# first-level
48
49 becomes
50
51 # first-level
52
53 -------------------------------------------------
54
55 -> # Supported markdown formatting's <-
56
57 Second-level headers can be prefixed by *##* or
58 underlined by *---*.
59
60 second-level
61 \------------
62
63 becomes
64
65 second-level
66 ------------
67
68
69 -------------------------------------------------
70
71 -> # Supported markdown formatting's <-
72
73 Inline codes are surrounded with backticks.
74
75 C program starts with \`main()\`.
76
77 becomes
78
79 C program starts with `main()`.
80
81 -------------------------------------------------
82
83 -> # Supported markdown formatting's <-
84
85 Code blocks are automatically detected by 4
86 spaces at the beginning of a line.
87
88 Tabs are automatically expanded to 4 spaces
89 while parsing the input.
90
91 \    int main(int argc, char \*argv[]) {
92 \        printf("%s\\n", "Hello world!");
93 \    }
94
95 becomes
96
97     int main(int argc, char *argv[]) {
98         printf("%s\n", "Hello world!");
99     }
100
101 -------------------------------------------------
102
103 -> # Supported markdown formatting's <-
104
105 Quotes are auto-detected by preceding *>*.
106
107 Multiple *>* are interpreted as nested quotes.
108
109 \> quote
110 \>> nested quote 1
111 \> > nested quote 2
112
113 becomes
114
115 > quote
116 >> nested quote 1
117 > > nested quote 2
118
119 -------------------------------------------------
120
121 -> # Supported markdown formatting's <-
122
123 Inline highlighting is supported as followed:
124
125 \- *\** colors text as red
126 \- *\_* underlines text
127
128 \_some\_ \*highlighted\* \_\*text\*\_
129
130 becomes
131
132 _some_ *highlighted* _*text*_
133
134 -------------------------------------------------
135
136 -> # Supported markdown formatting's <-
137
138 Backslashes force special markdown characters
139 like *\**, *\_*, *#* and *>* to be printed as normal
140 characters.
141
142 \\\*special\\\*
143
144 becomes
145
146 \*special\*
147
148 -------------------------------------------------
149
150 -> # Supported markdown formatting's <-
151
152 Leading *\** or *-* indicate lists.
153
154 list
155 \* major
156 \    - minor
157 \        - \*important\*
158 \          detail
159 \    - minor
160
161 becomes
162
163 list
164 * major
165     - minor
166         - *important*
167           detail
168     - minor
169
170 -------------------------------------------------
171
172 -> # Supported markdown formatting's <-
173
174 Leading *->* indicates centering.
175
176 \-> # test <-
177 \-> ## test <-
178 \-> test
179 \-> \_\*test\*\_ <-
180
181 becomes
182
183 -> # test <-
184 -> ## test <-
185 -> test
186 -> _*test*_ <-
187
188 -------------------------------------------------
189
190 -> # Supported markdown formatting's <-
191
192 URL in pandoc style are supported:
193
194 \[Google](http://www.google.com/)
195
196 becomes
197
198 [Google](http://www.google.com/)
199
200 -------------------------------------------------
201
202 -> ## More information about markdown <-
203
204 can be found in the [markdown documentation](http://daringfireball.net/projects/markdown/).
205
206 -------------------------------------------------
207
208 -> # Support for UTF-8 special characters <-
209
210 Here are some examples.
211
212 ae = ä, oe = ö, ue = ü, ss = ß
213 upsilon = Ʊ, phi = ɸ
214
215 ▛▀▀▀▀▀▀▀▀▀▜
216 ▌rectangle▐
217 ▙▄▄▄▄▄▄▄▄▄▟
218
219
220 -------------------------------------------------
221
222 -> # Suspend your presentation for hands-on examples <-
223
224 Use *Ctrl + z* to suspend the presentation.
225
226 Use *fg* to resume it.
227
228 -------------------------------------------------
229
230 -> # Convert your presentation to PDF <-
231
232 To publish your presentation later on, you may
233 want to convert it to PDF.
234
235 This can be achieved by two additional tools:
236
237 \- *markdown* to convert to HTML
238 \- *wkhtmltopdf* to convert from HTML to PDF
239
240 After installing them, you can simply type:
241
242     $ markdown sample.md | wkhtmltopdf - sample.pdf
243
244 -------------------------------------------------
245
246 -> ## Last words <-
247
248 I hope you like *mdp*. But be aware, that it is
249 still in alpha status.
250
251 If you observe strange behavior, feel free to
252 open an issue on [GitHub](https://github.com/visit1985/mdp).
253
254