# Markdown Definitions This specification defines which markdown syntax can be parsed by maddy. There is no HTML allowed in the markdown syntax - or said otherwise - it might destroy the output, if there was HTML in your markdown. The Parser expects you to use spaces and not tabs for indentation in the markdown. If a line starts with `<` and `config->isHTMLWrappedInParagraph` is false, it expects that the upcoming line is HTML and therefor will not be surrounded by a paragraph. ## Headlines ``` # h1 heading ## h2 heading ### h3 heading #### h4 heading ##### h5 heading ###### h6 heading ``` results in: ```html

h1 heading

h2 heading

h3 heading

h4 heading

h5 heading
h6 heading
``` ## Links ``` [Text of the link](http://example.com) ``` results in ```html Text of the link ``` ## Lists ### unordered Characters "*", "+" or "-" to make an unordered "bullet" list are equivalent. ``` - unordered * list + items ``` results in ```html ``` ``` * unordered * list * items * in + an - hierarchy ``` results in ```html ``` ### ordered ``` 1. ordered 2. list 3. items ``` results in ```html
  1. ordered
  2. list
  3. items
``` ``` 1. ordered * list * items ``` results in ```html
  1. ordered
  2. list
  3. items
``` ``` 1. ordered * list 1. items * in 1. an * hierarchy ``` results in ```html
  1. ordered
  2. list
    1. items
    2. in
      1. an
    3. hierarchy
``` ### combination ``` * combination * of 1. unordered and * ordered * list ``` results in ```html ``` ### checklist ``` - [ ] some item - [ ] another item - [x] some checked item ``` results in ```html ``` might not work in combination with other lists ## Code Blocks ``` some code ``` results in ```html

some code
``` ## Inline code some text `some inline code` some other text results in ```html some text some inline code some other text ``` ## quotes ``` > Some quote ``` results in ```html

Some quote

``` ## bold ``` **bold text** __bold text__ ``` results in ```html bold text bold text ``` ## italic ``` *italic text* ``` results in ```html italic text ``` ## emphasized This can be disabled by setting `config->isEmphasizedParserEnabled = false`. ``` _emphasized text_ ``` results in ```html emphasized text ``` ## strikethrough ``` ~~striked through text~~ ``` results in ```html striked through text ``` ## horizontal line ``` --- ``` results in ```html
``` ## break line ``` New\r\nLine ``` results in ```html New
Line ``` ## Images ``` ![Image alt text](http://example.com/example.png) ``` results in ```html Image alt text ``` ## Tables ``` |table> Left header | middle header | last header - | - | - cell 1 | cell 2 | cell 3 cell 4 | cell 5 | cell 6 - | - | - foot a | foot b | foot c |
Left header middle header last header
cell 1 cell 2 cell 3
cell 4 cell 5 cell 6
foot a foot b foot c
``` table header and footer are optional