├── test ├── new │ ├── escaped_angles.text │ ├── escaped_angles.html │ ├── gfm-del.text │ ├── lazy_blockquotes.text │ ├── not_a_link.text │ ├── gfm-del.html │ ├── not_a_link.html │ ├── same_bullet.text │ ├── gfm-em.text │ ├── nested_code.text │ ├── nested_square_link.text │ ├── ref_paren.text │ ├── case_insensitive_refs.html │ ├── case_insensitive_refs.text │ ├── nested_code.html │ ├── autolink_lines.text │ ├── gfm-em.html │ ├── gfm_break_text.text │ ├── ref_paren.html │ ├── extra_smartypants.text │ ├── gfm_break_text.html │ ├── gfm_links.text │ ├── list_item_text.text │ ├── hr_list_break.text │ ├── nested_square_link.html │ ├── butterfly.png │ ├── lazy_blockquotes.html │ ├── same_bullet.html │ ├── list_item_text.html │ ├── blockquote_list_item.text │ ├── mathdefs.tex │ ├── autolink_lines.html │ ├── extra_smartypants.html │ ├── javascript5.json │ ├── math-error1.mdk │ ├── gfm_links.html │ ├── blockquote_list_item.html │ ├── hr_list_break.html │ ├── extra_math2.mdk │ ├── tricky_list.text │ ├── double_link.text │ ├── pedantic_def_blocks.text │ ├── xjavascript.js │ ├── double_link.html │ ├── gfm_code.text │ ├── gfm_code.html │ ├── include.text │ ├── pedantic_def_blocks.html │ ├── extra_auto_counters.text │ ├── extra_auto_counters2.text │ ├── inline_code.text │ ├── tricky_list.html │ ├── extra_fib.text │ ├── extra_auto_labels.text │ ├── extra_para.text │ ├── extra_title.text │ ├── toplevel_paragraphs.text │ ├── extra_sup_sub.text │ ├── hilite2.text │ ├── extra_codereplacer.text │ ├── extra_toc.text │ ├── gfm_tables.text │ ├── math-pre.text │ ├── extra_sup_sub.html │ ├── math-error2.mdk │ ├── toplevel_paragraphs.html │ ├── lists.mdk │ ├── extra_lists.text │ ├── gfm-code_hr_list.text │ ├── extra_footnotes.text │ ├── borders.text │ ├── extra_boxes.text │ ├── gfm-code_hr_list.html │ ├── extra_auto_labels.html │ ├── extra_ski.text │ ├── main.html │ ├── main.text │ ├── extra_attributes.text │ ├── extra_fib.html │ ├── extra_auto_counters.html │ ├── gfm_tables.html │ ├── extra_things.text │ ├── anatomy.text │ ├── extra_ski.html │ ├── extra_footnotes.html │ └── extra_things.html ├── tests │ ├── escaped_angles.text │ ├── escaped_angles.html │ ├── gfm-del.text │ ├── not_a_link.text │ ├── lazy_blockquotes.text │ ├── not_a_link.html │ ├── gfm-del.html │ ├── nested_code.text │ ├── ref_paren.text │ ├── same_bullet.text │ ├── case_insensitive_refs.text │ ├── gfm-em.text │ ├── nested_square_link.text │ ├── autolink_lines.text │ ├── case_insensitive_refs.html │ ├── gfm-em.html │ ├── nested_code.html │ ├── ref_paren.html │ ├── extra_smartypants.text │ ├── gfm_break_text.text │ ├── nested_blockquotes.text │ ├── gfm_break_text.html │ ├── list_item_text.text │ ├── gfm_links.text │ ├── nested_square_link.html │ ├── hr_list_break.text │ ├── lazy_blockquotes.html │ ├── same_bullet.html │ ├── list_item_text.html │ ├── blockquote_list_item.text │ ├── autolink_lines.html │ ├── extra_smartypants.html │ ├── tidyness.text │ ├── gfm_links.html │ ├── blockquote_list_item.html │ ├── hr_list_break.html │ ├── strong_and_em_together.text │ ├── literal_quotes_in_titles.text │ ├── nested_blockquotes.html │ ├── tidyness.html │ ├── code_spans.text │ ├── literal_quotes_in_titles.html │ ├── blockquotes_with_code_blocks.text │ ├── tricky_list.text │ ├── double_link.text │ ├── inline_html_advanced.text │ ├── pedantic_def_blocks.text │ ├── inline_html_comments.text │ ├── inline_html_advanced.html │ ├── strong_and_em_together.html │ ├── code_spans.html │ ├── hard_wrapped_paragraphs_with_list_like_lines.text │ ├── inline_html_comments.html │ ├── code_blocks.text │ ├── double_link.html │ ├── hard_wrapped_paragraphs_with_list_like_lines.html │ ├── blockquotes_with_code_blocks.html │ ├── gfm_code.text │ ├── links_inline_style.text │ ├── links_shortcut_references.html │ ├── auto_links.text │ ├── links_shortcut_references.text │ ├── gfm_code.html │ ├── pedantic_def_blocks.html │ ├── extra_auto_counters.text │ ├── code_blocks.html │ ├── tabs.text │ ├── links_inline_style.html │ ├── tricky_list.html │ ├── extra_fib.text │ ├── extra_auto_labels.text │ ├── amps_and_angles_encoding.text │ ├── toplevel_paragraphs.text │ ├── tabs.html │ ├── extra_sup_sub.text │ ├── extra_toc.text │ ├── horizontal_rules.text │ ├── gfm_tables.text │ ├── amps_and_angles_encoding.html │ ├── auto_links.html │ ├── extra_sup_sub.html │ ├── toplevel_paragraphs.html │ ├── horizontal_rules.html │ ├── gfm-code_hr_list.text │ ├── extra_footnotes.text │ ├── inline_html_simple.text │ ├── gfm-code_hr_list.html │ ├── extra_things.text │ ├── inline_html_simple.html │ ├── links_reference_style.text │ ├── extra_auto_labels.html │ ├── extra_ski.text │ ├── main.html │ ├── main.text │ ├── extra_attributes.text │ ├── extra_fib.html │ ├── extra_auto_counters.html │ ├── links_reference_style.html │ ├── gfm_tables.html │ ├── extra_ski.html │ ├── extra_footnotes.html │ ├── ordered_and_unordered_lists.text │ └── extra_things.html ├── parent-inc.mdk ├── test.bib ├── latex │ ├── test1.mdk │ ├── cc-by.pdf │ ├── images │ │ ├── arrow.png │ │ └── butterfly.png │ ├── lipics-logo-bw.pdf │ ├── style │ │ ├── lncs.mdk │ │ └── ieee.mdk │ ├── include with spaces.mdk │ ├── parent-dirs.mdk │ ├── unicode-math.mdk │ ├── float.mdk │ ├── chinese.mdk │ ├── basic - Copy.mdk │ └── csl │ │ └── nature-biotechnology.csl ├── original │ ├── nested_blockquotes.text │ ├── tidyness.text │ ├── strong_and_em_together.text │ ├── literal_quotes_in_titles.text │ ├── nested_blockquotes.html │ ├── tidyness.html │ ├── literal_quotes_in_titles.html │ ├── code_spans.text │ ├── blockquotes_with_code_blocks.text │ ├── inline_html_advanced.text │ ├── inline_html_comments.text │ ├── code_spans.html │ ├── inline_html_advanced.html │ ├── strong_and_em_together.html │ ├── hard_wrapped_paragraphs_with_list_like_lines.text │ ├── inline_html_comments.html │ ├── code_blocks.text │ ├── hard_wrapped_paragraphs_with_list_like_lines.html │ ├── blockquotes_with_code_blocks.html │ ├── links_inline_style.text │ ├── links_shortcut_references.html │ ├── auto_links.text │ ├── links_shortcut_references.text │ ├── code_blocks.html │ ├── tabs.text │ ├── links_inline_style.html │ ├── amps_and_angles_encoding.text │ ├── tabs.html │ ├── amps_and_angles_encoding.html │ ├── horizontal_rules.text │ ├── auto_links.html │ ├── horizontal_rules.html │ ├── inline_html_simple.text │ ├── inline_html_simple.html │ ├── links_reference_style.text │ ├── links_reference_style.html │ └── ordered_and_unordered_lists.text ├── butterfly.png ├── contrib │ └── images │ │ ├── arrow.png │ │ └── butterfly.png ├── readme.txt ├── math │ └── small.mdk └── example.bib ├── styles ├── present.mdk ├── tex-nostarsections.mdk ├── tex-chapters.mdk ├── book.mdk ├── zero.mdk ├── webanchors.mdk └── bootstrap.mdk ├── src ├── cli.js ├── version.kk ├── toc.kk ├── storage-inline.cs ├── process.kk ├── process-inline.js ├── runcsl.kk └── texCommon.kk ├── doc ├── aargh.png ├── arrow.png ├── tooltip.png ├── butterfly.png ├── aligned-code.png ├── koka-doc-md.png ├── koka-doc-pdf.png ├── aligned-code2.png ├── koka-doc-html.png ├── slidedemo-html.png ├── slidedemo-mdk.png ├── slidedemo-pdf.png ├── javascript5.json ├── ignores.dic ├── reference.bib └── reference.js ├── support ├── madoko-local │ ├── src │ │ ├── cli.js │ │ ├── config.js │ │ └── date.js │ ├── static │ │ ├── images │ │ │ └── icon-madoko.ico │ │ ├── index.html │ │ └── styles │ │ │ └── main.css │ └── package.json └── sublime-text │ └── madoko │ └── madoko.sublime-settings ├── web ├── cache-template.txt ├── client │ ├── dictionaries │ │ ├── en_US │ │ │ └── en_US_extra.dic │ │ └── generic.dic │ ├── images │ │ ├── icon-me.png │ │ ├── icon-new.png │ │ ├── icon-pdf.png │ │ ├── icon-pin.png │ │ ├── icon-zip.png │ │ ├── glyph-error.png │ │ ├── icon-azure.png │ │ ├── icon-cloud.png │ │ ├── icon-commit.png │ │ ├── icon-disk.png │ │ ├── icon-empty.png │ │ ├── icon-file.png │ │ ├── icon-folder.png │ │ ├── icon-github.png │ │ ├── icon-home.png │ │ ├── icon-html.png │ │ ├── icon-http.png │ │ ├── icon-link.png │ │ ├── icon-local.png │ │ ├── icon-local2.png │ │ ├── icon-madoko.ico │ │ ├── icon-madoko.png │ │ ├── icon-open.png │ │ ├── icon-plus.png │ │ ├── icon-pull.png │ │ ├── icon-pull2.png │ │ ├── icon-reload.png │ │ ├── icon-save.png │ │ ├── icon-share.png │ │ ├── icon-signin.png │ │ ├── icon-sync.png │ │ ├── icon-unpin.png │ │ ├── icon-upload.png │ │ ├── dark │ │ │ ├── icon-me.png │ │ │ ├── button-help.png │ │ │ ├── button-sync.png │ │ │ ├── icon-close.png │ │ │ ├── icon-disk.png │ │ │ ├── icon-github.png │ │ │ ├── icon-home.png │ │ │ ├── icon-http.png │ │ │ ├── icon-local.png │ │ │ ├── icon-madoko.png │ │ │ ├── icon-upload.png │ │ │ ├── icon-users.png │ │ │ ├── button-folder.png │ │ │ ├── icon-dropbox.png │ │ │ ├── icon-onedrive.png │ │ │ ├── icon-spinner.png │ │ │ ├── icon-toolbox.png │ │ │ ├── icon-tri-down.png │ │ │ ├── icon-warning.png │ │ │ ├── spinner-sync.gif │ │ │ ├── spinner-view.gif │ │ │ ├── button-console.png │ │ │ ├── button-document.png │ │ │ ├── button-settings.png │ │ │ ├── button-view-sync.png │ │ │ ├── icon-disconnect.png │ │ │ ├── icon-localhost.png │ │ │ ├── icon-onedrive2.png │ │ │ ├── icon-onedrivepro.png │ │ │ ├── icon-user-write.png │ │ │ ├── icon-users-edit.png │ │ │ ├── icon-view-full.png │ │ │ ├── button-console-ok.png │ │ │ └── button-console-warn.png │ │ ├── glyph-warning.png │ │ ├── icon-dropbox.png │ │ ├── icon-onedrive.png │ │ ├── icon-signout.png │ │ ├── icon-snapshot.png │ │ ├── icon-spinner.gif │ │ ├── icon-tool-dl.png │ │ ├── icon-tool-img.png │ │ ├── icon-tool-ol.png │ │ ├── icon-tool-pre.png │ │ ├── icon-tool-sub.png │ │ ├── icon-tool-ul.png │ │ ├── template-ieee.png │ │ ├── template-lncs.png │ │ ├── icon-disconnect.png │ │ ├── icon-file-shared.png │ │ ├── icon-folder-repo.png │ │ ├── icon-localhost.png │ │ ├── icon-onedrive2.png │ │ ├── icon-onedrivepro.png │ │ ├── icon-tool-bold.png │ │ ├── icon-tool-bquote.png │ │ ├── icon-tool-camera.png │ │ ├── icon-tool-cite.png │ │ ├── icon-tool-code.png │ │ ├── icon-tool-color.png │ │ ├── icon-tool-figure.png │ │ ├── icon-tool-font.png │ │ ├── icon-tool-format.png │ │ ├── icon-tool-italic.png │ │ ├── icon-tool-link.png │ │ ├── icon-tool-redo.png │ │ ├── icon-tool-repo.png │ │ ├── icon-tool-super.png │ │ ├── icon-tool-symbol.png │ │ ├── icon-tool-table.png │ │ ├── icon-tool-undo.png │ │ ├── icon-user-open.png │ │ ├── icon-user-read.png │ │ ├── icon-user-write.png │ │ ├── icon-view-narrow.png │ │ ├── icon-view-normal.png │ │ ├── icon-view-wide.png │ │ ├── madoko-logo-256.png │ │ ├── madoko-logo-64.png │ │ ├── template-acmart.png │ │ ├── template-article.png │ │ ├── template-bookm.png │ │ ├── template-default.png │ │ ├── template-lipics.png │ │ ├── template-webpage.png │ │ ├── icon-folder-branch.png │ │ ├── icon-folder-owner.png │ │ ├── icon-folder-shared.png │ │ ├── icon-tool-fontsize.png │ │ ├── icon-tool-formula.png │ │ ├── icon-tool-heading.png │ │ ├── icon-tool-justify.png │ │ ├── icon-tool-aligncenter.png │ │ ├── icon-tool-alignleft.png │ │ ├── icon-tool-alignright.png │ │ ├── icon-tool-figureright.png │ │ ├── icon-tool-figurewide.png │ │ ├── icon-tool-figurewide2.png │ │ ├── icon-tool-reference.png │ │ ├── icon-tool-underline.png │ │ ├── template-presentation.png │ │ ├── template-sigplanconf.png │ │ └── icon-folder-repo-shared.png │ └── preview │ │ └── preview.html ├── maintenance │ └── index.html ├── cache-config.json ├── encode.js └── package.json ├── contrib ├── images │ ├── arrow.png │ └── butterfly.png ├── templates │ ├── cc-by.pdf │ ├── lipics-logo-bw.pdf │ ├── style │ │ ├── lncs.mdk │ │ └── ieee.mdk │ ├── default.mdk │ ├── acmclassify.mdk │ └── example.bib ├── dictionaries │ └── en_US │ │ └── README.md ├── styles │ └── example.bib └── typo │ └── license.txt ├── .hgignore ├── .gitignore └── package.json /test/new/escaped_angles.text: -------------------------------------------------------------------------------- 1 | \> 2 | -------------------------------------------------------------------------------- /test/tests/escaped_angles.text: -------------------------------------------------------------------------------- 1 | \> 2 | -------------------------------------------------------------------------------- /styles/present.mdk: -------------------------------------------------------------------------------- 1 | [INCLUDE=presentation] -------------------------------------------------------------------------------- /test/new/escaped_angles.html: -------------------------------------------------------------------------------- 1 |

>

2 | -------------------------------------------------------------------------------- /test/tests/escaped_angles.html: -------------------------------------------------------------------------------- 1 |

>

2 | -------------------------------------------------------------------------------- /test/new/gfm-del.text: -------------------------------------------------------------------------------- 1 | hello ~~hi~~ world 2 | -------------------------------------------------------------------------------- /test/parent-inc.mdk: -------------------------------------------------------------------------------- 1 | A **parent** include file. -------------------------------------------------------------------------------- /test/tests/gfm-del.text: -------------------------------------------------------------------------------- 1 | hello ~~hi~~ world 2 | -------------------------------------------------------------------------------- /test/new/lazy_blockquotes.text: -------------------------------------------------------------------------------- 1 | > hi there 2 | bud 3 | -------------------------------------------------------------------------------- /test/new/not_a_link.text: -------------------------------------------------------------------------------- 1 | \\[test](not a link) 2 | -------------------------------------------------------------------------------- /test/tests/not_a_link.text: -------------------------------------------------------------------------------- 1 | \\[test](not a link) 2 | -------------------------------------------------------------------------------- /test/new/gfm-del.html: -------------------------------------------------------------------------------- 1 |

hello hi world

2 | -------------------------------------------------------------------------------- /test/new/not_a_link.html: -------------------------------------------------------------------------------- 1 |

\[test](not a link)

2 | -------------------------------------------------------------------------------- /test/new/same_bullet.text: -------------------------------------------------------------------------------- 1 | * test 2 | + test 3 | - test 4 | -------------------------------------------------------------------------------- /test/tests/lazy_blockquotes.text: -------------------------------------------------------------------------------- 1 | > hi there 2 | bud 3 | -------------------------------------------------------------------------------- /test/tests/not_a_link.html: -------------------------------------------------------------------------------- 1 |

\[test](not a link)

2 | -------------------------------------------------------------------------------- /test/new/gfm-em.text: -------------------------------------------------------------------------------- 1 | These words should_not_be_emphasized. 2 | -------------------------------------------------------------------------------- /test/new/nested_code.text: -------------------------------------------------------------------------------- 1 | ````` hi ther `` ok ``` ````` 2 | -------------------------------------------------------------------------------- /test/new/nested_square_link.text: -------------------------------------------------------------------------------- 1 | [the `]` character](/url) 2 | -------------------------------------------------------------------------------- /test/new/ref_paren.text: -------------------------------------------------------------------------------- 1 | [hi] 2 | 3 | [hi]: /url (there) 4 | -------------------------------------------------------------------------------- /test/tests/gfm-del.html: -------------------------------------------------------------------------------- 1 |

hello hi world

2 | -------------------------------------------------------------------------------- /test/tests/nested_code.text: -------------------------------------------------------------------------------- 1 | ````` hi ther `` ok ``` ````` 2 | -------------------------------------------------------------------------------- /test/tests/ref_paren.text: -------------------------------------------------------------------------------- 1 | [hi] 2 | 3 | [hi]: /url (there) 4 | -------------------------------------------------------------------------------- /test/tests/same_bullet.text: -------------------------------------------------------------------------------- 1 | * test 2 | + test 3 | - test 4 | -------------------------------------------------------------------------------- /src/cli.js: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | 3 | require("./main.js"); 4 | -------------------------------------------------------------------------------- /test/new/case_insensitive_refs.html: -------------------------------------------------------------------------------- 1 |

hi

2 | -------------------------------------------------------------------------------- /test/new/case_insensitive_refs.text: -------------------------------------------------------------------------------- 1 | [hi] 2 | 3 | [HI]: /url 4 | -------------------------------------------------------------------------------- /test/new/nested_code.html: -------------------------------------------------------------------------------- 1 |

hi ther `` ok ```

2 | -------------------------------------------------------------------------------- /test/tests/case_insensitive_refs.text: -------------------------------------------------------------------------------- 1 | [hi] 2 | 3 | [HI]: /url 4 | -------------------------------------------------------------------------------- /test/tests/gfm-em.text: -------------------------------------------------------------------------------- 1 | These words should_not_be_emphasized. 2 | -------------------------------------------------------------------------------- /test/tests/nested_square_link.text: -------------------------------------------------------------------------------- 1 | [the `]` character](/url) 2 | -------------------------------------------------------------------------------- /test/new/autolink_lines.text: -------------------------------------------------------------------------------- 1 | hello world 2 | 3 | -------------------------------------------------------------------------------- /test/new/gfm-em.html: -------------------------------------------------------------------------------- 1 |

These words should_not_be_emphasized.

2 | -------------------------------------------------------------------------------- /test/new/gfm_break_text.text: -------------------------------------------------------------------------------- 1 | Look at the 2 | pretty line 3 | breaks. 4 | -------------------------------------------------------------------------------- /test/new/ref_paren.html: -------------------------------------------------------------------------------- 1 |

hi

2 | -------------------------------------------------------------------------------- /test/tests/autolink_lines.text: -------------------------------------------------------------------------------- 1 | hello world 2 | 3 | -------------------------------------------------------------------------------- /test/tests/case_insensitive_refs.html: -------------------------------------------------------------------------------- 1 |

hi

2 | -------------------------------------------------------------------------------- /test/tests/gfm-em.html: -------------------------------------------------------------------------------- 1 |

These words should_not_be_emphasized.

2 | -------------------------------------------------------------------------------- /test/tests/nested_code.html: -------------------------------------------------------------------------------- 1 |

hi ther `` ok ```

2 | -------------------------------------------------------------------------------- /test/tests/ref_paren.html: -------------------------------------------------------------------------------- 1 |

hi

2 | -------------------------------------------------------------------------------- /doc/aargh.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/aargh.png -------------------------------------------------------------------------------- /doc/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/arrow.png -------------------------------------------------------------------------------- /test/new/extra_smartypants.text: -------------------------------------------------------------------------------- 1 | Hello world 'how' "are" you -- today... 2 | -------------------------------------------------------------------------------- /test/new/gfm_break_text.html: -------------------------------------------------------------------------------- 1 |

Look at the
pretty line
breaks.

2 | -------------------------------------------------------------------------------- /test/test.bib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/test.bib -------------------------------------------------------------------------------- /test/tests/extra_smartypants.text: -------------------------------------------------------------------------------- 1 | Hello world 'how' "are" you -- today... 2 | -------------------------------------------------------------------------------- /test/tests/gfm_break_text.text: -------------------------------------------------------------------------------- 1 | Look at the 2 | pretty line 3 | breaks. 4 | -------------------------------------------------------------------------------- /test/tests/nested_blockquotes.text: -------------------------------------------------------------------------------- 1 | > foo 2 | > 3 | > > bar 4 | > 5 | > foo 6 | -------------------------------------------------------------------------------- /doc/tooltip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/tooltip.png -------------------------------------------------------------------------------- /test/latex/test1.mdk: -------------------------------------------------------------------------------- 1 | Here is a paragraph 2 | 3 | And another. 4 | 5 | Test. -------------------------------------------------------------------------------- /test/new/gfm_links.text: -------------------------------------------------------------------------------- 1 | This should be a link: http://example.com/hello-world. 2 | -------------------------------------------------------------------------------- /test/new/list_item_text.text: -------------------------------------------------------------------------------- 1 | * item1 2 | 3 | * item2 4 | 5 | text 6 | -------------------------------------------------------------------------------- /test/original/nested_blockquotes.text: -------------------------------------------------------------------------------- 1 | > foo 2 | > 3 | > > bar 4 | > 5 | > foo 6 | -------------------------------------------------------------------------------- /test/tests/gfm_break_text.html: -------------------------------------------------------------------------------- 1 |

Look at the
pretty line
breaks.

2 | -------------------------------------------------------------------------------- /test/tests/list_item_text.text: -------------------------------------------------------------------------------- 1 | * item1 2 | 3 | * item2 4 | 5 | text 6 | -------------------------------------------------------------------------------- /doc/butterfly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/butterfly.png -------------------------------------------------------------------------------- /support/madoko-local/src/cli.js: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env node 2 | 3 | require("./main.js"); 4 | -------------------------------------------------------------------------------- /test/butterfly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/butterfly.png -------------------------------------------------------------------------------- /test/tests/gfm_links.text: -------------------------------------------------------------------------------- 1 | This should be a link: http://example.com/hello-world. 2 | -------------------------------------------------------------------------------- /doc/aligned-code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/aligned-code.png -------------------------------------------------------------------------------- /doc/koka-doc-md.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/koka-doc-md.png -------------------------------------------------------------------------------- /doc/koka-doc-pdf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/koka-doc-pdf.png -------------------------------------------------------------------------------- /test/latex/cc-by.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/latex/cc-by.pdf -------------------------------------------------------------------------------- /test/new/hr_list_break.text: -------------------------------------------------------------------------------- 1 | * hello 2 | world 3 | * how 4 | are 5 | * * * 6 | you today? 7 | -------------------------------------------------------------------------------- /test/new/nested_square_link.html: -------------------------------------------------------------------------------- 1 |

the ] character

2 | -------------------------------------------------------------------------------- /test/tests/nested_square_link.html: -------------------------------------------------------------------------------- 1 |

the ] character

2 | -------------------------------------------------------------------------------- /doc/aligned-code2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/aligned-code2.png -------------------------------------------------------------------------------- /doc/koka-doc-html.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/koka-doc-html.png -------------------------------------------------------------------------------- /doc/slidedemo-html.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/slidedemo-html.png -------------------------------------------------------------------------------- /doc/slidedemo-mdk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/slidedemo-mdk.png -------------------------------------------------------------------------------- /doc/slidedemo-pdf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/doc/slidedemo-pdf.png -------------------------------------------------------------------------------- /test/new/butterfly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/new/butterfly.png -------------------------------------------------------------------------------- /test/new/lazy_blockquotes.html: -------------------------------------------------------------------------------- 1 |
2 |

hi there 3 | bud

4 |
5 | -------------------------------------------------------------------------------- /test/new/same_bullet.html: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /test/tests/hr_list_break.text: -------------------------------------------------------------------------------- 1 | * hello 2 | world 3 | * how 4 | are 5 | * * * 6 | you today? 7 | -------------------------------------------------------------------------------- /test/tests/lazy_blockquotes.html: -------------------------------------------------------------------------------- 1 |
2 |

hi there 3 | bud

4 |
5 | -------------------------------------------------------------------------------- /web/cache-template.txt: -------------------------------------------------------------------------------- 1 | NETWORK: 2 | * 3 | 4 | FALLBACK: 5 | 6 | CACHE: 7 | version.json -------------------------------------------------------------------------------- /web/client/dictionaries/en_US/en_US_extra.dic: -------------------------------------------------------------------------------- 1 | app/S 2 | offline 3 | online 4 | plugin/S 5 | UI -------------------------------------------------------------------------------- /contrib/images/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/contrib/images/arrow.png -------------------------------------------------------------------------------- /test/new/list_item_text.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /test/tests/same_bullet.html: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /contrib/images/butterfly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/contrib/images/butterfly.png -------------------------------------------------------------------------------- /contrib/templates/cc-by.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/contrib/templates/cc-by.pdf -------------------------------------------------------------------------------- /test/latex/images/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/latex/images/arrow.png -------------------------------------------------------------------------------- /test/new/blockquote_list_item.text: -------------------------------------------------------------------------------- 1 | This fails in markdown.pl and upskirt: 2 | 3 | * hello 4 | > world 5 | -------------------------------------------------------------------------------- /test/new/mathdefs.tex: -------------------------------------------------------------------------------- 1 | % test 2 | \newcommand{\testx}{\test} % other test 3 | \newcommand{\test}{\slambda} -------------------------------------------------------------------------------- /test/tests/list_item_text.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /test/contrib/images/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/contrib/images/arrow.png -------------------------------------------------------------------------------- /test/latex/lipics-logo-bw.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/latex/lipics-logo-bw.pdf -------------------------------------------------------------------------------- /test/new/autolink_lines.html: -------------------------------------------------------------------------------- 1 |

hello world 2 | http://example.com 3 |

4 | -------------------------------------------------------------------------------- /test/tests/blockquote_list_item.text: -------------------------------------------------------------------------------- 1 | This fails in markdown.pl and upskirt: 2 | 3 | * hello 4 | > world 5 | -------------------------------------------------------------------------------- /web/client/images/icon-me.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-me.png -------------------------------------------------------------------------------- /web/client/images/icon-new.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-new.png -------------------------------------------------------------------------------- /web/client/images/icon-pdf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-pdf.png -------------------------------------------------------------------------------- /web/client/images/icon-pin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-pin.png -------------------------------------------------------------------------------- /web/client/images/icon-zip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-zip.png -------------------------------------------------------------------------------- /test/contrib/images/butterfly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/contrib/images/butterfly.png -------------------------------------------------------------------------------- /test/latex/images/butterfly.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/test/latex/images/butterfly.png -------------------------------------------------------------------------------- /test/tests/autolink_lines.html: -------------------------------------------------------------------------------- 1 |

hello world 2 | http://example.com 3 |

4 | -------------------------------------------------------------------------------- /web/client/images/glyph-error.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/glyph-error.png -------------------------------------------------------------------------------- /web/client/images/icon-azure.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-azure.png -------------------------------------------------------------------------------- /web/client/images/icon-cloud.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-cloud.png -------------------------------------------------------------------------------- /web/client/images/icon-commit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-commit.png -------------------------------------------------------------------------------- /web/client/images/icon-disk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-disk.png -------------------------------------------------------------------------------- /web/client/images/icon-empty.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-empty.png -------------------------------------------------------------------------------- /web/client/images/icon-file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-file.png -------------------------------------------------------------------------------- /web/client/images/icon-folder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-folder.png -------------------------------------------------------------------------------- /web/client/images/icon-github.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-github.png -------------------------------------------------------------------------------- /web/client/images/icon-home.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-home.png -------------------------------------------------------------------------------- /web/client/images/icon-html.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-html.png -------------------------------------------------------------------------------- /web/client/images/icon-http.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-http.png -------------------------------------------------------------------------------- /web/client/images/icon-link.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-link.png -------------------------------------------------------------------------------- /web/client/images/icon-local.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-local.png -------------------------------------------------------------------------------- /web/client/images/icon-local2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-local2.png -------------------------------------------------------------------------------- /web/client/images/icon-madoko.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-madoko.ico -------------------------------------------------------------------------------- /web/client/images/icon-madoko.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-madoko.png -------------------------------------------------------------------------------- /web/client/images/icon-open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-open.png -------------------------------------------------------------------------------- /web/client/images/icon-plus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-plus.png -------------------------------------------------------------------------------- /web/client/images/icon-pull.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-pull.png -------------------------------------------------------------------------------- /web/client/images/icon-pull2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-pull2.png -------------------------------------------------------------------------------- /web/client/images/icon-reload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-reload.png -------------------------------------------------------------------------------- /web/client/images/icon-save.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-save.png -------------------------------------------------------------------------------- /web/client/images/icon-share.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-share.png -------------------------------------------------------------------------------- /web/client/images/icon-signin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-signin.png -------------------------------------------------------------------------------- /web/client/images/icon-sync.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-sync.png -------------------------------------------------------------------------------- /web/client/images/icon-unpin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-unpin.png -------------------------------------------------------------------------------- /web/client/images/icon-upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-upload.png -------------------------------------------------------------------------------- /test/new/extra_smartypants.html: -------------------------------------------------------------------------------- 1 | 2 |

Hello world ‘how’ “are” you – today… 3 |

-------------------------------------------------------------------------------- /test/tests/extra_smartypants.html: -------------------------------------------------------------------------------- 1 | 2 |

Hello world ‘how’ “are” you – today… 3 |

-------------------------------------------------------------------------------- /test/tests/tidyness.text: -------------------------------------------------------------------------------- 1 | > A list within a blockquote: 2 | > 3 | > * asterisk 1 4 | > * asterisk 2 5 | > * asterisk 3 6 | -------------------------------------------------------------------------------- /web/client/images/dark/icon-me.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-me.png -------------------------------------------------------------------------------- /web/client/images/glyph-warning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/glyph-warning.png -------------------------------------------------------------------------------- /web/client/images/icon-dropbox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-dropbox.png -------------------------------------------------------------------------------- /web/client/images/icon-onedrive.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-onedrive.png -------------------------------------------------------------------------------- /web/client/images/icon-signout.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-signout.png -------------------------------------------------------------------------------- /web/client/images/icon-snapshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-snapshot.png -------------------------------------------------------------------------------- /web/client/images/icon-spinner.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-spinner.gif -------------------------------------------------------------------------------- /web/client/images/icon-tool-dl.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-dl.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-img.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-img.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-ol.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-ol.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-pre.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-pre.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-sub.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-sub.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-ul.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-ul.png -------------------------------------------------------------------------------- /web/client/images/template-ieee.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-ieee.png -------------------------------------------------------------------------------- /web/client/images/template-lncs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-lncs.png -------------------------------------------------------------------------------- /contrib/templates/lipics-logo-bw.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/contrib/templates/lipics-logo-bw.pdf -------------------------------------------------------------------------------- /test/original/tidyness.text: -------------------------------------------------------------------------------- 1 | > A list within a blockquote: 2 | > 3 | > * asterisk 1 4 | > * asterisk 2 5 | > * asterisk 3 6 | -------------------------------------------------------------------------------- /web/client/images/dark/button-help.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-help.png -------------------------------------------------------------------------------- /web/client/images/dark/button-sync.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-sync.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-close.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-close.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-disk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-disk.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-github.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-github.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-home.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-home.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-http.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-http.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-local.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-local.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-madoko.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-madoko.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-upload.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-upload.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-users.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-users.png -------------------------------------------------------------------------------- /web/client/images/icon-disconnect.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-disconnect.png -------------------------------------------------------------------------------- /web/client/images/icon-file-shared.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-file-shared.png -------------------------------------------------------------------------------- /web/client/images/icon-folder-repo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-folder-repo.png -------------------------------------------------------------------------------- /web/client/images/icon-localhost.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-localhost.png -------------------------------------------------------------------------------- /web/client/images/icon-onedrive2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-onedrive2.png -------------------------------------------------------------------------------- /web/client/images/icon-onedrivepro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-onedrivepro.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-bold.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-bold.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-bquote.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-bquote.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-camera.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-camera.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-cite.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-cite.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-code.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-code.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-color.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-color.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-figure.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-figure.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-font.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-font.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-format.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-format.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-italic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-italic.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-link.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-link.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-redo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-redo.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-repo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-repo.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-super.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-super.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-symbol.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-symbol.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-table.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-table.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-undo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-undo.png -------------------------------------------------------------------------------- /web/client/images/icon-user-open.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-user-open.png -------------------------------------------------------------------------------- /web/client/images/icon-user-read.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-user-read.png -------------------------------------------------------------------------------- /web/client/images/icon-user-write.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-user-write.png -------------------------------------------------------------------------------- /web/client/images/icon-view-narrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-view-narrow.png -------------------------------------------------------------------------------- /web/client/images/icon-view-normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-view-normal.png -------------------------------------------------------------------------------- /web/client/images/icon-view-wide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-view-wide.png -------------------------------------------------------------------------------- /web/client/images/madoko-logo-256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/madoko-logo-256.png -------------------------------------------------------------------------------- /web/client/images/madoko-logo-64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/madoko-logo-64.png -------------------------------------------------------------------------------- /web/client/images/template-acmart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-acmart.png -------------------------------------------------------------------------------- /web/client/images/template-article.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-article.png -------------------------------------------------------------------------------- /web/client/images/template-bookm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-bookm.png -------------------------------------------------------------------------------- /web/client/images/template-default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-default.png -------------------------------------------------------------------------------- /web/client/images/template-lipics.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-lipics.png -------------------------------------------------------------------------------- /web/client/images/template-webpage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-webpage.png -------------------------------------------------------------------------------- /test/new/javascript5.json: -------------------------------------------------------------------------------- 1 | { 2 | "extend": "text/javascript", 3 | "extraKeywords": [ "module", "export" 4 | ] 5 | } -------------------------------------------------------------------------------- /test/new/math-error1.mdk: -------------------------------------------------------------------------------- 1 | Some paragraph 2 | 3 | ~ MathDefs 4 | [INCLUDE=mathdefs.tex] 5 | ~ 6 | 7 | A test formula $\test$. -------------------------------------------------------------------------------- /web/client/images/dark/button-folder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-folder.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-dropbox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-dropbox.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-onedrive.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-onedrive.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-spinner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-spinner.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-toolbox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-toolbox.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-tri-down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-tri-down.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-warning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-warning.png -------------------------------------------------------------------------------- /web/client/images/dark/spinner-sync.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/spinner-sync.gif -------------------------------------------------------------------------------- /web/client/images/dark/spinner-view.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/spinner-view.gif -------------------------------------------------------------------------------- /web/client/images/icon-folder-branch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-folder-branch.png -------------------------------------------------------------------------------- /web/client/images/icon-folder-owner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-folder-owner.png -------------------------------------------------------------------------------- /web/client/images/icon-folder-shared.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-folder-shared.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-fontsize.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-fontsize.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-formula.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-formula.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-heading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-heading.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-justify.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-justify.png -------------------------------------------------------------------------------- /test/new/gfm_links.html: -------------------------------------------------------------------------------- 1 |

This should be a link: 2 | http://example.com/hello-world.

3 | -------------------------------------------------------------------------------- /web/client/images/dark/button-console.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-console.png -------------------------------------------------------------------------------- /web/client/images/dark/button-document.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-document.png -------------------------------------------------------------------------------- /web/client/images/dark/button-settings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-settings.png -------------------------------------------------------------------------------- /web/client/images/dark/button-view-sync.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-view-sync.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-disconnect.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-disconnect.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-localhost.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-localhost.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-onedrive2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-onedrive2.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-onedrivepro.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-onedrivepro.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-user-write.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-user-write.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-users-edit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-users-edit.png -------------------------------------------------------------------------------- /web/client/images/dark/icon-view-full.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/icon-view-full.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-aligncenter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-aligncenter.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-alignleft.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-alignleft.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-alignright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-alignright.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-figureright.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-figureright.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-figurewide.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-figurewide.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-figurewide2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-figurewide2.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-reference.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-reference.png -------------------------------------------------------------------------------- /web/client/images/icon-tool-underline.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-tool-underline.png -------------------------------------------------------------------------------- /web/client/images/template-presentation.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-presentation.png -------------------------------------------------------------------------------- /web/client/images/template-sigplanconf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/template-sigplanconf.png -------------------------------------------------------------------------------- /test/tests/gfm_links.html: -------------------------------------------------------------------------------- 1 |

This should be a link: 2 | http://example.com/hello-world.

3 | -------------------------------------------------------------------------------- /web/client/images/dark/button-console-ok.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-console-ok.png -------------------------------------------------------------------------------- /web/client/images/icon-folder-repo-shared.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/icon-folder-repo-shared.png -------------------------------------------------------------------------------- /doc/javascript5.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "javascript5", 3 | "extend": "javascript", 4 | "extraKeywords": ["module","export","import"] 5 | } -------------------------------------------------------------------------------- /test/new/blockquote_list_item.html: -------------------------------------------------------------------------------- 1 |

This fails in markdown.pl and upskirt:

2 | 3 | 4 | -------------------------------------------------------------------------------- /web/client/images/dark/button-console-warn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/web/client/images/dark/button-console-warn.png -------------------------------------------------------------------------------- /support/madoko-local/static/images/icon-madoko.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/koka-lang/madoko/HEAD/support/madoko-local/static/images/icon-madoko.ico -------------------------------------------------------------------------------- /test/new/hr_list_break.html: -------------------------------------------------------------------------------- 1 | 7 | 8 |
9 | 10 |

you today?

11 | -------------------------------------------------------------------------------- /test/tests/blockquote_list_item.html: -------------------------------------------------------------------------------- 1 |

This fails in markdown.pl and upskirt:

2 | 3 | 4 | -------------------------------------------------------------------------------- /test/tests/hr_list_break.html: -------------------------------------------------------------------------------- 1 | 7 | 8 |
9 | 10 |

you today?

11 | -------------------------------------------------------------------------------- /test/tests/strong_and_em_together.text: -------------------------------------------------------------------------------- 1 | ***This is strong and em.*** 2 | 3 | So is ***this*** word. 4 | 5 | ___This is strong and em.___ 6 | 7 | So is ___this___ word. 8 | -------------------------------------------------------------------------------- /test/original/strong_and_em_together.text: -------------------------------------------------------------------------------- 1 | ***This is strong and em.*** 2 | 3 | So is ***this*** word. 4 | 5 | ___This is strong and em.___ 6 | 7 | So is ___this___ word. 8 | -------------------------------------------------------------------------------- /test/tests/literal_quotes_in_titles.text: -------------------------------------------------------------------------------- 1 | Foo [bar][]. 2 | 3 | Foo [bar](/url/ "Title with "quotes" inside"). 4 | 5 | 6 | [bar]: /url/ "Title with "quotes" inside" 7 | 8 | -------------------------------------------------------------------------------- /test/original/literal_quotes_in_titles.text: -------------------------------------------------------------------------------- 1 | Foo [bar][]. 2 | 3 | Foo [bar](/url/ "Title with "quotes" inside"). 4 | 5 | 6 | [bar]: /url/ "Title with "quotes" inside" 7 | 8 | -------------------------------------------------------------------------------- /test/original/nested_blockquotes.html: -------------------------------------------------------------------------------- 1 |
2 |

foo

3 | 4 |
5 |

bar

6 |
7 | 8 |

foo

9 |
10 | -------------------------------------------------------------------------------- /test/tests/nested_blockquotes.html: -------------------------------------------------------------------------------- 1 |
2 |

foo

3 | 4 |
5 |

bar

6 |
7 | 8 |

foo

9 |
10 | -------------------------------------------------------------------------------- /test/original/tidyness.html: -------------------------------------------------------------------------------- 1 |
2 |

A list within a blockquote:

3 |
    4 |
  • asterisk 1
  • 5 |
  • asterisk 2
  • 6 |
  • asterisk 3
  • 7 |
8 |
9 | -------------------------------------------------------------------------------- /test/tests/tidyness.html: -------------------------------------------------------------------------------- 1 |
2 |

A list within a blockquote:

3 |
    4 |
  • asterisk 1
  • 5 |
  • asterisk 2
  • 6 |
  • asterisk 3
  • 7 |
8 |
9 | -------------------------------------------------------------------------------- /test/new/extra_math2.mdk: -------------------------------------------------------------------------------- 1 | Title : Math Example 2 | Heading Base: 2 3 | 4 | # Math and colors 5 | 6 | Test: $\mbox{Madoko} = \mbox{\LaTeX} \times \mbox{Markdown}${background-color=Navy color=white} 7 | -------------------------------------------------------------------------------- /test/original/literal_quotes_in_titles.html: -------------------------------------------------------------------------------- 1 |

Foo bar.

2 | 3 |

Foo bar.

4 | -------------------------------------------------------------------------------- /test/tests/code_spans.text: -------------------------------------------------------------------------------- 1 | `` 2 | 3 | Fix for backticks within HTML tag: like this 4 | 5 | Here's how you put `` `backticks` `` in a code span. 6 | 7 | -------------------------------------------------------------------------------- /test/tests/literal_quotes_in_titles.html: -------------------------------------------------------------------------------- 1 |

Foo bar.

2 | 3 |

Foo bar.

4 | -------------------------------------------------------------------------------- /test/original/code_spans.text: -------------------------------------------------------------------------------- 1 | `` 2 | 3 | Fix for backticks within HTML tag: like this 4 | 5 | Here's how you put `` `backticks` `` in a code span. 6 | 7 | -------------------------------------------------------------------------------- /test/latex/style/lncs.mdk: -------------------------------------------------------------------------------- 1 | Description: 2 | Madoko settings for the LLNCS LaTeX document class. 3 | Heading base : 2 4 | @tex Maketitle: True 5 | Doc Class : style/llncs.cls 6 | Tex Header* : 7 | \pagestyle{plain} 8 | -------------------------------------------------------------------------------- /test/new/tricky_list.text: -------------------------------------------------------------------------------- 1 | **hello** _world_ 2 | 3 | * hello world 4 | 5 | **hello** _world_ 6 | 7 | * hello world 8 | 9 | **hello** _world_ 10 | 11 | * Hello world 12 | 13 | **hello** _world_ 14 | 15 | * hello world 16 | -------------------------------------------------------------------------------- /test/original/blockquotes_with_code_blocks.text: -------------------------------------------------------------------------------- 1 | > Example: 2 | > 3 | > sub status { 4 | > print "working"; 5 | > } 6 | > 7 | > Or: 8 | > 9 | > sub status { 10 | > return "working"; 11 | > } 12 | -------------------------------------------------------------------------------- /test/tests/blockquotes_with_code_blocks.text: -------------------------------------------------------------------------------- 1 | > Example: 2 | > 3 | > sub status { 4 | > print "working"; 5 | > } 6 | > 7 | > Or: 8 | > 9 | > sub status { 10 | > return "working"; 11 | > } 12 | -------------------------------------------------------------------------------- /test/tests/tricky_list.text: -------------------------------------------------------------------------------- 1 | **hello** _world_ 2 | 3 | * hello world 4 | 5 | **hello** _world_ 6 | 7 | * hello world 8 | 9 | **hello** _world_ 10 | 11 | * Hello world 12 | 13 | **hello** _world_ 14 | 15 | * hello world 16 | -------------------------------------------------------------------------------- /support/sublime-text/madoko/madoko.sublime-settings: -------------------------------------------------------------------------------- 1 | { 2 | "color_scheme": "Packages/Color Scheme - Default/Snow.tmTheme", 3 | "tab_size": 2, 4 | "translate_tabs_to_spaces": true, 5 | "use_tab_stops": true, 6 | "detect_indentation": false, 7 | } -------------------------------------------------------------------------------- /test/new/double_link.text: -------------------------------------------------------------------------------- 1 |

Already linked: http://example.com/.

2 | 3 | Already linked: [http://example.com/](http://example.com/). 4 | 5 | Already linked: **http://example.com/**. 6 | -------------------------------------------------------------------------------- /test/new/pedantic_def_blocks.text: -------------------------------------------------------------------------------- 1 | > hello 2 | > [1]: hello 3 | 4 | * * * 5 | 6 | > hello 7 | [2]: hello 8 | 9 | 10 | * hello 11 | * [3]: hello 12 | 13 | 14 | * hello 15 | [4]: hello 16 | 17 | 18 | > foo 19 | > bar 20 | [1]: foo 21 | > bar 22 | -------------------------------------------------------------------------------- /test/tests/double_link.text: -------------------------------------------------------------------------------- 1 |

Already linked: http://example.com/.

2 | 3 | Already linked: [http://example.com/](http://example.com/). 4 | 5 | Already linked: **http://example.com/**. 6 | -------------------------------------------------------------------------------- /test/tests/inline_html_advanced.text: -------------------------------------------------------------------------------- 1 | Simple block on one line: 2 | 3 |
foo
4 | 5 | And nested without indentation: 6 | 7 |
8 |
9 |
10 | foo 11 |
12 |
13 |
14 |
bar
15 |
16 | -------------------------------------------------------------------------------- /test/tests/pedantic_def_blocks.text: -------------------------------------------------------------------------------- 1 | > hello 2 | > [1]: hello 3 | 4 | * * * 5 | 6 | > hello 7 | [2]: hello 8 | 9 | 10 | * hello 11 | * [3]: hello 12 | 13 | 14 | * hello 15 | [4]: hello 16 | 17 | 18 | > foo 19 | > bar 20 | [1]: foo 21 | > bar 22 | -------------------------------------------------------------------------------- /test/new/xjavascript.js: -------------------------------------------------------------------------------- 1 | module.exports = function(hljs) { 2 | var js = hljs.getLanguage("javascript"); 3 | var xjs = Object.create(js); 4 | var kws = Object.create(xjs.keywords); 5 | kws.special = "alert"; 6 | xjs.keywords = kws; 7 | return xjs; 8 | } 9 | -------------------------------------------------------------------------------- /test/original/inline_html_advanced.text: -------------------------------------------------------------------------------- 1 | Simple block on one line: 2 | 3 |
foo
4 | 5 | And nested without indentation: 6 | 7 |
8 |
9 |
10 | foo 11 |
12 |
13 |
14 |
bar
15 |
16 | -------------------------------------------------------------------------------- /test/tests/inline_html_comments.text: -------------------------------------------------------------------------------- 1 | Paragraph one. 2 | 3 | 4 | 5 | 8 | 9 | Paragraph two. 10 | 11 | 12 | 13 | The end. 14 | -------------------------------------------------------------------------------- /test/original/inline_html_comments.text: -------------------------------------------------------------------------------- 1 | Paragraph one. 2 | 3 | 4 | 5 | 8 | 9 | Paragraph two. 10 | 11 | 12 | 13 | The end. 14 | -------------------------------------------------------------------------------- /test/original/code_spans.html: -------------------------------------------------------------------------------- 1 |

<test a=" content of attribute ">

2 | 3 |

Fix for backticks within HTML tag: like this

4 | 5 |

Here's how you put `backticks` in a code span.

6 | 7 | -------------------------------------------------------------------------------- /test/tests/inline_html_advanced.html: -------------------------------------------------------------------------------- 1 |

Simple block on one line:

2 | 3 |
foo
4 | 5 |

And nested without indentation:

6 | 7 |
8 |
9 |
10 | foo 11 |
12 |
13 |
14 |
bar
15 |
16 | -------------------------------------------------------------------------------- /styles/tex-nostarsections.mdk: -------------------------------------------------------------------------------- 1 | Documentation: 2 | Use LaTeX `\section` commands directly (not using star-form `\section*`) and without using 3 | the Madoko labeling and numbering. Useful for certain document classes. 4 | @notex2 ~H1,~H2,~H3,~H4: before=clear tex-starform=false -------------------------------------------------------------------------------- /test/original/inline_html_advanced.html: -------------------------------------------------------------------------------- 1 |

Simple block on one line:

2 | 3 |
foo
4 | 5 |

And nested without indentation:

6 | 7 |
8 |
9 |
10 | foo 11 |
12 |
13 |
14 |
bar
15 |
16 | -------------------------------------------------------------------------------- /test/tests/strong_and_em_together.html: -------------------------------------------------------------------------------- 1 |

This is strong and em.

2 | 3 |

So is this word.

4 | 5 |

This is strong and em.

6 | 7 |

So is this word.

8 | -------------------------------------------------------------------------------- /test/original/strong_and_em_together.html: -------------------------------------------------------------------------------- 1 |

This is strong and em.

2 | 3 |

So is this word.

4 | 5 |

This is strong and em.

6 | 7 |

So is this word.

8 | -------------------------------------------------------------------------------- /test/tests/code_spans.html: -------------------------------------------------------------------------------- 1 |

<test a=" content of attribute ">

2 | 3 |

Fix for backticks within HTML tag: like this

4 | 5 |

Here's how you put `backticks` in a code span.

6 | 7 | -------------------------------------------------------------------------------- /test/original/hard_wrapped_paragraphs_with_list_like_lines.text: -------------------------------------------------------------------------------- 1 | In Markdown 1.0.0 and earlier. Version 2 | 8. This line turns into a list item. 3 | Because a hard-wrapped line in the 4 | middle of a paragraph looked like a 5 | list item. 6 | 7 | Here's one with a bullet. 8 | * criminey. 9 | -------------------------------------------------------------------------------- /test/original/inline_html_comments.html: -------------------------------------------------------------------------------- 1 |

Paragraph one.

2 | 3 | 4 | 5 | 8 | 9 |

Paragraph two.

10 | 11 | 12 | 13 |

The end.

14 | -------------------------------------------------------------------------------- /test/tests/hard_wrapped_paragraphs_with_list_like_lines.text: -------------------------------------------------------------------------------- 1 | In Markdown 1.0.0 and earlier. Version 2 | 8. This line turns into a list item. 3 | Because a hard-wrapped line in the 4 | middle of a paragraph looked like a 5 | list item. 6 | 7 | Here's one with a bullet. 8 | * criminey. 9 | -------------------------------------------------------------------------------- /test/tests/inline_html_comments.html: -------------------------------------------------------------------------------- 1 |

Paragraph one.

2 | 3 | 4 | 5 | 8 | 9 |

Paragraph two.

10 | 11 | 12 | 13 |

The end.

14 | -------------------------------------------------------------------------------- /test/new/double_link.html: -------------------------------------------------------------------------------- 1 |

Already linked: http://example.com/.

2 | 3 |

Already linked: http://example.com/.

4 | 5 |

Already linked: http://example.com/.

6 | -------------------------------------------------------------------------------- /test/tests/code_blocks.text: -------------------------------------------------------------------------------- 1 | code block on the first line 2 | 3 | Regular text. 4 | 5 | code block indented by spaces 6 | 7 | Regular text. 8 | 9 | the lines in this block 10 | all contain trailing spaces 11 | 12 | Regular Text. 13 | 14 | code block on the last line 15 | -------------------------------------------------------------------------------- /test/original/code_blocks.text: -------------------------------------------------------------------------------- 1 | code block on the first line 2 | 3 | Regular text. 4 | 5 | code block indented by spaces 6 | 7 | Regular text. 8 | 9 | the lines in this block 10 | all contain trailing spaces 11 | 12 | Regular Text. 13 | 14 | code block on the last line 15 | -------------------------------------------------------------------------------- /test/tests/double_link.html: -------------------------------------------------------------------------------- 1 |

Already linked: http://example.com/.

2 | 3 |

Already linked: http://example.com/.

4 | 5 |

Already linked: http://example.com/.

6 | -------------------------------------------------------------------------------- /test/original/hard_wrapped_paragraphs_with_list_like_lines.html: -------------------------------------------------------------------------------- 1 |

In Markdown 1.0.0 and earlier. Version 2 | 8. This line turns into a list item. 3 | Because a hard-wrapped line in the 4 | middle of a paragraph looked like a 5 | list item.

6 | 7 |

Here's one with a bullet. 8 | * criminey.

9 | -------------------------------------------------------------------------------- /test/tests/hard_wrapped_paragraphs_with_list_like_lines.html: -------------------------------------------------------------------------------- 1 |

In Markdown 1.0.0 and earlier. Version 2 | 8. This line turns into a list item. 3 | Because a hard-wrapped line in the 4 | middle of a paragraph looked like a 5 | list item.

6 | 7 |

Here's one with a bullet. 8 | * criminey.

9 | -------------------------------------------------------------------------------- /test/original/blockquotes_with_code_blocks.html: -------------------------------------------------------------------------------- 1 |
2 |

Example:

3 | 4 |
sub status {
 5 |     print "working";
 6 | }
 7 | 
8 | 9 |

Or:

10 | 11 |
sub status {
12 |     return "working";
13 | }
14 | 
15 |
16 | -------------------------------------------------------------------------------- /styles/tex-chapters.mdk: -------------------------------------------------------------------------------- 1 | Documentation: 2 | Use the `\chapter` command for `H1` elements instead of `\section`. 3 | 4 | ~H0 : tex-cmd=\part 5 | ~H1 : tex-cmd=\chapter 6 | ~H2 : tex-cmd=\section 7 | ~H3 : tex-cmd=\subsection 8 | ~H4 : tex-cmd=\subsubsection 9 | ~H5,~H6 : tex-cmd=\paragraph -------------------------------------------------------------------------------- /test/new/gfm_code.text: -------------------------------------------------------------------------------- 1 | ``` js 2 | var a = 'hello'; 3 | console.log(a + ' world'); 4 | ``` 5 | 6 | ~~~bash 7 | echo "hello, ${WORLD}" 8 | ~~~ 9 | 10 | ```````longfence 11 | Q: What do you call a tall person who sells stolen goods? 12 | ``````` 13 | 14 | ~~~~~~~~~~ ManyTildes 15 | A longfence! 16 | ~~~~~~~~~~ 17 | -------------------------------------------------------------------------------- /test/tests/blockquotes_with_code_blocks.html: -------------------------------------------------------------------------------- 1 |
2 |

Example:

3 | 4 |
sub status {
 5 |     print "working";
 6 | }
 7 | 
8 | 9 |

Or:

10 | 11 |
sub status {
12 |     return "working";
13 | }
14 | 
15 |
16 | -------------------------------------------------------------------------------- /test/tests/gfm_code.text: -------------------------------------------------------------------------------- 1 | ``` js 2 | var a = 'hello'; 3 | console.log(a + ' world'); 4 | ``` 5 | 6 | ~~~bash 7 | echo "hello, ${WORLD}" 8 | ~~~ 9 | 10 | ```````longfence 11 | Q: What do you call a tall person who sells stolen goods? 12 | ``````` 13 | 14 | ~~~~~~~~~~ ManyTildes 15 | A longfence! 16 | ~~~~~~~~~~ 17 | -------------------------------------------------------------------------------- /test/tests/links_inline_style.text: -------------------------------------------------------------------------------- 1 | Just a [URL](/url/). 2 | 3 | [URL and title](/url/ "title"). 4 | 5 | [URL and title](/url/ "title preceded by two spaces"). 6 | 7 | [URL and title](/url/ "title preceded by a tab"). 8 | 9 | [URL and title](/url/ "title has spaces afterward" ). 10 | 11 | 12 | [Empty](). 13 | -------------------------------------------------------------------------------- /test/latex/include with spaces.mdk: -------------------------------------------------------------------------------- 1 | 2 | **There is more in you of good than you know, child of the kindly West.** 3 | $\foo$ 4 | Some courage and some wisdom, blended in measure. If more of us valued 5 | food and cheer and song above hoarded gold, it would be a merrier world. 6 | But sad or merry, I must leave it now. 7 | -------------------------------------------------------------------------------- /test/original/links_inline_style.text: -------------------------------------------------------------------------------- 1 | Just a [URL](/url/). 2 | 3 | [URL and title](/url/ "title"). 4 | 5 | [URL and title](/url/ "title preceded by two spaces"). 6 | 7 | [URL and title](/url/ "title preceded by a tab"). 8 | 9 | [URL and title](/url/ "title has spaces afterward" ). 10 | 11 | 12 | [Empty](). 13 | -------------------------------------------------------------------------------- /test/tests/links_shortcut_references.html: -------------------------------------------------------------------------------- 1 |

This is the simple case.

2 | 3 |

This one has a line 4 | break.

5 | 6 |

This one has a line 7 | break with a line-ending space.

8 | 9 |

this and the other

10 | -------------------------------------------------------------------------------- /test/original/links_shortcut_references.html: -------------------------------------------------------------------------------- 1 |

This is the simple case.

2 | 3 |

This one has a line 4 | break.

5 | 6 |

This one has a line 7 | break with a line-ending space.

8 | 9 |

this and the other

10 | -------------------------------------------------------------------------------- /contrib/templates/style/lncs.mdk: -------------------------------------------------------------------------------- 1 | Description: 2 | Madoko settings for the LLNCS LaTeX document class. 3 | Heading base : 2 4 | Doc Class : style/llncs.cls 5 | 6 | Tex Header*: 7 | \pagestyle{plain} 8 | 9 | @if not (tex) { 10 | .inst { display:none } 11 | } 12 | 13 | @if tex { 14 | .inst { tex-cmd: "\inst" } 15 | } -------------------------------------------------------------------------------- /test/tests/auto_links.text: -------------------------------------------------------------------------------- 1 | 2 | Link: . 3 | 4 | With an ampersand: 5 | 6 | * In a list? 7 | * 8 | * It should. 9 | 10 | > Blockquoted: 11 | 12 | Auto-links should not occur here: `` 13 | 14 | or here: 15 | -------------------------------------------------------------------------------- /test/latex/style/ieee.mdk: -------------------------------------------------------------------------------- 1 | Description: 2 | Style file for the IEEE transactions style. 3 | Heading Base : 2 4 | Bib Style : style/IEEEtran.bst 5 | Doc Class : style/IEEEtran.cls 6 | @tex Maketitle: True 7 | 8 | @html ~H1 : font-variant=small-caps text-align=center font-weight=100 9 | @html ~H2 : font-weight=normal font-style=italic 10 | -------------------------------------------------------------------------------- /test/original/auto_links.text: -------------------------------------------------------------------------------- 1 | 2 | Link: . 3 | 4 | With an ampersand: 5 | 6 | * In a list? 7 | * 8 | * It should. 9 | 10 | > Blockquoted: 11 | 12 | Auto-links should not occur here: `` 13 | 14 | or here: 15 | -------------------------------------------------------------------------------- /test/tests/links_shortcut_references.text: -------------------------------------------------------------------------------- 1 | This is the [simple case]. 2 | 3 | [simple case]: /simple 4 | 5 | 6 | 7 | This one has a [line 8 | break]. 9 | 10 | This one has a [line 11 | break] with a line-ending space. 12 | 13 | [line break]: /foo 14 | 15 | 16 | [this] [that] and the [other] 17 | 18 | [this]: /this 19 | [that]: /that 20 | [other]: /other 21 | -------------------------------------------------------------------------------- /test/new/gfm_code.html: -------------------------------------------------------------------------------- 1 |
var a = 'hello';
2 | console.log(a + ' world');
3 |
echo "hello, ${WORLD}"
4 |
Q: What do you call a tall person who sells stolen goods?
5 |
A longfence!
6 | -------------------------------------------------------------------------------- /test/original/links_shortcut_references.text: -------------------------------------------------------------------------------- 1 | This is the [simple case]. 2 | 3 | [simple case]: /simple 4 | 5 | 6 | 7 | This one has a [line 8 | break]. 9 | 10 | This one has a [line 11 | break] with a line-ending space. 12 | 13 | [line break]: /foo 14 | 15 | 16 | [this] [that] and the [other] 17 | 18 | [this]: /this 19 | [that]: /that 20 | [other]: /other 21 | -------------------------------------------------------------------------------- /test/tests/gfm_code.html: -------------------------------------------------------------------------------- 1 |
var a = 'hello';
2 | console.log(a + ' world');
3 |
echo "hello, ${WORLD}"
4 |
Q: What do you call a tall person who sells stolen goods?
5 |
A longfence!
6 | -------------------------------------------------------------------------------- /test/new/include.text: -------------------------------------------------------------------------------- 1 | title: test includes 2 | 3 | Let's see a definition: 4 | 5 | [INCLUDE="deflist.text":25-29] 6 | 7 | Nice :-) 8 | 9 | [INCLUDE="deflist.text":25] 10 | 11 | ``` 12 | [INCLUDE="../../../AoPL/src/Declare.hs":Summ3] 13 | ``` 14 | Eval 38 15 | ``` 16 | [INCLUDE:Eval38] 17 | ``` 18 | 19 | Or just the part: 20 | ``` 21 | [INCLUDE:Impl3] 22 | ``` -------------------------------------------------------------------------------- /test/new/pedantic_def_blocks.html: -------------------------------------------------------------------------------- 1 |
2 |

hello 3 | [1]: hello

4 |
5 | 6 |
7 | 8 |
9 |

hello

10 |
11 | 12 | 13 |
    14 |
  • hello
  • 15 |
  • [3]: hello
  • 16 |
17 | 18 | 19 |
    20 |
  • hello
  • 21 |
22 | 23 | 24 |
25 |

foo 26 | bar 27 | bar

28 |
29 | -------------------------------------------------------------------------------- /test/tests/pedantic_def_blocks.html: -------------------------------------------------------------------------------- 1 |
2 |

hello 3 | [1]: hello

4 |
5 | 6 |
7 | 8 |
9 |

hello

10 |
11 | 12 | 13 |
    14 |
  • hello
  • 15 |
  • [3]: hello
  • 16 |
17 | 18 | 19 |
    20 |
  • hello
  • 21 |
22 | 23 | 24 |
25 |

foo 26 | bar 27 | bar

28 |
29 | -------------------------------------------------------------------------------- /test/tests/extra_auto_counters.text: -------------------------------------------------------------------------------- 1 | 2 | # header1 3 | 4 | Here is a reference to [Section #header1](#header1), 5 | or using a shorthand, to Section [#header12] which 6 | is the same as this reference [#header12][]. 7 | Perhaps you just want the label text #header-211? 8 | 9 | ## header11 10 | ## header12 11 | #### header1201? 12 | # header2 13 | 14 | ## header 2.1 15 | ### header 2.1.1 16 | -------------------------------------------------------------------------------- /test/original/code_blocks.html: -------------------------------------------------------------------------------- 1 |
code block on the first line
 2 | 
3 | 4 |

Regular text.

5 | 6 |
code block indented by spaces
 7 | 
8 | 9 |

Regular text.

10 | 11 |
the lines in this block  
12 | all contain trailing spaces  
13 | 
14 | 15 |

Regular Text.

16 | 17 |
code block on the last line
18 | 
19 | -------------------------------------------------------------------------------- /test/tests/code_blocks.html: -------------------------------------------------------------------------------- 1 |
code block on the first line
 2 | 
3 | 4 |

Regular text.

5 | 6 |
code block indented by spaces
 7 | 
8 | 9 |

Regular text.

10 | 11 |
the lines in this block  
12 | all contain trailing spaces  
13 | 
14 | 15 |

Regular Text.

16 | 17 |
code block on the last line
18 | 
19 | -------------------------------------------------------------------------------- /test/new/extra_auto_counters.text: -------------------------------------------------------------------------------- 1 | Section Depth: 6 2 | 3 | # header1 4 | 5 | Here is a reference to [Section #header1](#header1), 6 | or using a shorthand, to Section [#header12] which 7 | is the same as this reference [#header12][]. 8 | Perhaps you just want the label text #header-211? 9 | 10 | ## header11 11 | ## header12 12 | 13 | #### header1201? 14 | # header2 15 | 16 | ## header 2.1 17 | ### header 2.1.1 18 | -------------------------------------------------------------------------------- /test/new/extra_auto_counters2.text: -------------------------------------------------------------------------------- 1 | [INCLUDE=zero.mdk] 2 | 3 | # header1 4 | 5 | Here is a reference to [Section #header1](#header1), 6 | or using a shorthand, to Section [#header12] which 7 | is the same as this reference [#header12][]. 8 | Perhaps you just want the label text #header-211? 9 | 10 | ## header11 11 | ## header12 12 | 13 | #### header1201? 14 | # header2 15 | 16 | ## header 2.1 17 | ### header 2.1.1 18 | -------------------------------------------------------------------------------- /test/new/inline_code.text: -------------------------------------------------------------------------------- 1 | Test `code \/ \a \\ done `. 2 | Finally, the escape sequence `\/` translates to nothing; this can be very 3 | useful to separate certain constructs. For example, emphasis is suppressed 4 | if the underscores appear inside a word, as in my_example_here. Using the 5 | empty escape sequence we can emphasize inside words too: to get 6 | my\/_example_\/here, we can simply write `my\/_example_\/here`. 7 | -------------------------------------------------------------------------------- /test/tests/tabs.text: -------------------------------------------------------------------------------- 1 | + this is a list item 2 | indented with tabs 3 | 4 | + this is a list item 5 | indented with spaces 6 | 7 | Code: 8 | 9 | this code block is indented by one tab 10 | 11 | And: 12 | 13 | this code block is indented by two tabs 14 | 15 | And: 16 | 17 | + this is an example list item 18 | indented with tabs 19 | 20 | + this is an example list item 21 | indented with spaces 22 | -------------------------------------------------------------------------------- /contrib/templates/style/ieee.mdk: -------------------------------------------------------------------------------- 1 | Description: 2 | Style file for the IEEE transactions style. 3 | Heading Base : 2 4 | Bib Style : style/IEEEtran.bst 5 | Doc Class : style/IEEEtran.cls 6 | 7 | @if html { 8 | H1 { font-variant:small-caps; text-align:center; font-weight:100 } 9 | H2 { font-weight:normal; font-style:italic } 10 | .Abstract { font-weight: bold; replace:clear; before:"_Abstract_ -- " } 11 | } 12 | -------------------------------------------------------------------------------- /test/original/tabs.text: -------------------------------------------------------------------------------- 1 | + this is a list item 2 | indented with tabs 3 | 4 | + this is a list item 5 | indented with spaces 6 | 7 | Code: 8 | 9 | this code block is indented by one tab 10 | 11 | And: 12 | 13 | this code block is indented by two tabs 14 | 15 | And: 16 | 17 | + this is an example list item 18 | indented with tabs 19 | 20 | + this is an example list item 21 | indented with spaces 22 | -------------------------------------------------------------------------------- /support/madoko-local/static/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | MadokoLocal 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /test/latex/parent-dirs.mdk: -------------------------------------------------------------------------------- 1 | 2 | # Introduction 3 | There is more in you of good than you know, child of the kindly West. 4 | Some courage and some wisdom, blended in measure. If more of us valued 5 | food and cheer and song above hoarded gold, it would be a merrier world. 6 | But sad or merry, I must leave it now. 7 | 8 | [INCLUDE=../parent-inc.mdk] 9 | 10 | ~ TexRaw 11 | \input{../readme.txt} 12 | ~ 13 | 14 | Testing. 15 | -------------------------------------------------------------------------------- /test/original/links_inline_style.html: -------------------------------------------------------------------------------- 1 |

Just a URL.

2 | 3 |

URL and title.

4 | 5 |

URL and title.

6 | 7 |

URL and title.

8 | 9 |

URL and title.

10 | 11 |

Empty.

12 | -------------------------------------------------------------------------------- /test/tests/links_inline_style.html: -------------------------------------------------------------------------------- 1 |

Just a URL.

2 | 3 |

URL and title.

4 | 5 |

URL and title.

6 | 7 |

URL and title.

8 | 9 |

URL and title.

10 | 11 |

Empty.

12 | -------------------------------------------------------------------------------- /web/client/preview/preview.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | 11 | 12 |

Rendering...

13 |

Try to refresh your browser if this takes too long...

14 | 15 | 16 | -------------------------------------------------------------------------------- /test/new/tricky_list.html: -------------------------------------------------------------------------------- 1 |

hello world

2 | 3 |
    4 |
  • hello world
  • 5 |
6 | 7 |

hello world

8 | 9 |
    10 |
  • hello world
  • 11 |
12 | 13 |

hello world

14 | 15 |
    16 |
  • Hello world
  • 17 |
18 | 19 |

hello world

20 | 21 |
    22 |
  • hello world
  • 23 |
24 | -------------------------------------------------------------------------------- /test/tests/tricky_list.html: -------------------------------------------------------------------------------- 1 |

hello world

2 | 3 |
    4 |
  • hello world
  • 5 |
6 | 7 |

hello world

8 | 9 |
    10 |
  • hello world
  • 11 |
12 | 13 |

hello world

14 | 15 |
    16 |
  • Hello world
  • 17 |
18 | 19 |

hello world

20 | 21 |
    22 |
  • hello world
  • 23 |
24 | -------------------------------------------------------------------------------- /test/new/extra_fib.text: -------------------------------------------------------------------------------- 1 | Title : Examples 2 | MathJax : True 3 | Heading Base: 2 4 | ~Fib : replace='/^x?$/y/' replace='/xx(x*)/~Fib#nl\/x\1#nl~#nl~Fib#nl\1\/#nl~/' notag tight 5 | .Upper : replace='/([\s\S]*)/\U\1\E and more/' 6 | 7 | # Examples 8 | 9 | ~Fib 10 | xxxxx 11 | ~ 12 | 13 | Some [Upper case text]{.upper}. 14 | Here is an image [![monarch]]{vertical-align=top}. 15 | 16 | [monarch]: ../butterfly.png { width=2cm } 17 | 18 | -------------------------------------------------------------------------------- /test/tests/extra_fib.text: -------------------------------------------------------------------------------- 1 | Title : Examples 2 | MathJax : True 3 | Heading Base: 2 4 | ~Fib : replace='/^x?$/y/' replace='/xx(x*)/~Fib#nl\/x\1#nl~#nl~Fib#nl\1\/#nl~/' notag tight 5 | .Upper : replace='/([\s\S]*)/\U\1\E and more/' 6 | 7 | # Examples 8 | 9 | ~Fib 10 | xxxxx 11 | ~ 12 | 13 | Some [Upper case text]{.upper}. 14 | Here is an image [![monarch]]{vertical-align=top}. 15 | 16 | [monarch]: ../butterfly.png { width=2cm } 17 | 18 | -------------------------------------------------------------------------------- /contrib/dictionaries/en_US/README.md: -------------------------------------------------------------------------------- 1 | 2006-02-07 release. 2 | 3 | --- 4 | 5 | This dictionary is based on a subset of the original English wordlist created by Kevin Atkinson for Pspell and Aspell and thus is covered by his original LGPL license. The affix file is a heavily modified version of the original english.aff file which was released as part of Geoff Kuenning's Ispell and as such is covered by his BSD license. 6 | 7 | Thanks to both authors for their wonderful work. -------------------------------------------------------------------------------- /styles/book.mdk: -------------------------------------------------------------------------------- 1 | Description : Style for books 2 | 3 | Doc Class : book 4 | Package* : fancyhdr 5 | Tex Header* : 6 | \fancyhead[LE,RO]{\thepage} 7 | \fancyhead[LO]{\nouppercase\rightmark} 8 | \fancyhead[RE]{\nouppercase\leftmark} 9 | \fancyfoot{} 10 | \fancypagestyle{plain}{% 11 | \fancyhf{}% 12 | \renewcommand\headrulewidth{0pt}% 13 | } 14 | \pagestyle{fancy} 15 | 16 | @if tex { 17 | Heading Base: 1 18 | h1 { before: clear } 19 | } -------------------------------------------------------------------------------- /web/client/dictionaries/generic.dic: -------------------------------------------------------------------------------- 1 | Apple/M 2 | AngularJS 3 | bibtex 4 | Dropbox/M 5 | Google/M 6 | GitHub/M 7 | Haskell/MS 8 | HTML/M 9 | JavaScript/M 10 | Koka/M 11 | Madoko/M 12 | Markdown/M 13 | Microsoft/M 14 | Node.js 15 | OneDrive/M 16 | PDF 17 | plugin/S 18 | tex 19 | 20 | al 21 | br 22 | edn 23 | nd 24 | TitleFooter 25 | Todo 26 | 27 | dwarves 28 | Tookish 29 | leapt 30 | Baggins 31 | Gandalf 32 | Thrain's 33 | Oakenshield 34 | hobbit/S 35 | Gandalf's -------------------------------------------------------------------------------- /test/new/extra_auto_labels.text: -------------------------------------------------------------------------------- 1 | ~h2 : label="@h1#@h1-h2" 2 | 3 | # Main Section 4 | 5 | Here is a reference to [Section #header12](#header12), 6 | or using a shorthand, to Section [#header12] which 7 | is the same as this reference [#header12][]. 8 | Perhaps you just want the label text #myheader? 9 | 10 | Let's set a special label for sub-sections 11 | 12 | ## header11 { #myheader } 13 | ## header12 14 | #### header1201? 15 | # header2 16 | 17 | ## header 2.1 18 | ### header 2.1.1 19 | -------------------------------------------------------------------------------- /test/tests/extra_auto_labels.text: -------------------------------------------------------------------------------- 1 | ~h2 : label="@h1#@h1-h2" 2 | 3 | # Main Section 4 | 5 | Here is a reference to [Section #header12](#header12), 6 | or using a shorthand, to Section [#header12] which 7 | is the same as this reference [#header12][]. 8 | Perhaps you just want the label text #myheader? 9 | 10 | Let's set a special label for sub-sections 11 | 12 | ## header11 { #myheader } 13 | ## header12 14 | #### header1201? 15 | # header2 16 | 17 | ## header 2.1 18 | ### header 2.1.1 19 | -------------------------------------------------------------------------------- /test/tests/amps_and_angles_encoding.text: -------------------------------------------------------------------------------- 1 | AT&T has an ampersand in their name. 2 | 3 | AT&T is another way to write it. 4 | 5 | This & that. 6 | 7 | 4 < 5. 8 | 9 | 6 > 5. 10 | 11 | Here's a [link] [1] with an ampersand in the URL. 12 | 13 | Here's a link with an amersand in the link text: [AT&T] [2]. 14 | 15 | Here's an inline [link](/script?foo=1&bar=2). 16 | 17 | Here's an inline [link](). 18 | 19 | 20 | [1]: http://example.com/?foo=1&bar=2 21 | [2]: http://att.com/ "AT&T" 22 | -------------------------------------------------------------------------------- /test/original/amps_and_angles_encoding.text: -------------------------------------------------------------------------------- 1 | AT&T has an ampersand in their name. 2 | 3 | AT&T is another way to write it. 4 | 5 | This & that. 6 | 7 | 4 < 5. 8 | 9 | 6 > 5. 10 | 11 | Here's a [link] [1] with an ampersand in the URL. 12 | 13 | Here's a link with an amersand in the link text: [AT&T] [2]. 14 | 15 | Here's an inline [link](/script?foo=1&bar=2). 16 | 17 | Here's an inline [link](). 18 | 19 | 20 | [1]: http://example.com/?foo=1&bar=2 21 | [2]: http://att.com/ "AT&T" 22 | -------------------------------------------------------------------------------- /test/new/extra_para.text: -------------------------------------------------------------------------------- 1 | Title : Examples 2 | 3 | 7 | 8 | # Examples 9 | 10 | Here is some code: 11 | ``` 12 | function foo(); 13 | ``` 14 | and another paragraph. 15 | 16 | and another paragraph. 17 | ``` { .para-end } 18 | function bar(); 19 | ``` 20 | and the paragraphs following with an indent. 21 | {.indent} 22 | 23 | and another paragraph. 24 | With cleared code: 25 | ``` { .para-end } 26 | function bar(); 27 | ``` 28 | and the paragraphs following. 29 | 30 | -------------------------------------------------------------------------------- /test/new/extra_title.text: -------------------------------------------------------------------------------- 1 | Title : Remarrying Effects and Monads 2 | xTitle Note : Madoko Example document -- do not distribute 3 | Sub Title : Test 4 | Author : Niki Vazou, Ross Tate 5 | Author Note : A note about Niki 6 | Affiliation : UC San Diego 7 | Author : Daan Leijen & Ben Zorn 8 | Email : 9 | Affiliation : One Microsoft way 10 | Affiliation : Microsoft Research 11 | Heading Base: 2 12 | Doc Class : ../sigplanconf 13 | 14 | 15 | [TITLE] 16 | 17 | # Introduction 18 | 19 | A test of the title page. 20 | -------------------------------------------------------------------------------- /test/new/toplevel_paragraphs.text: -------------------------------------------------------------------------------- 1 | hello world 2 | how are you 3 | how are you 4 | 5 | hello world 6 | ``` 7 | how are you 8 | ``` 9 | 10 | hello world 11 | * * * 12 | 13 | hello world 14 | # how are you 15 | 16 | hello world 17 | how are you 18 | =========== 19 | 20 | hello world 21 | > how are you 22 | 23 | hello world 24 | * how are you 25 | 26 | hello world 27 |
how are you
28 | 29 | hello world 30 | how are you 31 | 32 | hello [world][how] 33 | [how]: /are/you 34 | 35 |
hello
36 | 37 | hello 38 | -------------------------------------------------------------------------------- /test/tests/toplevel_paragraphs.text: -------------------------------------------------------------------------------- 1 | hello world 2 | how are you 3 | how are you 4 | 5 | hello world 6 | ``` 7 | how are you 8 | ``` 9 | 10 | hello world 11 | * * * 12 | 13 | hello world 14 | # how are you 15 | 16 | hello world 17 | how are you 18 | =========== 19 | 20 | hello world 21 | > how are you 22 | 23 | hello world 24 | * how are you 25 | 26 | hello world 27 |
how are you
28 | 29 | hello world 30 | how are you 31 | 32 | hello [world][how] 33 | [how]: /are/you 34 | 35 |
hello
36 | 37 | hello 38 | -------------------------------------------------------------------------------- /test/new/extra_sup_sub.text: -------------------------------------------------------------------------------- 1 | Superscripts may be written by surrounding the superscripted text by ^ characters; 2 | subscripts may be written by surrounding the subscripted text by ~ characters. 3 | Thus, for example, 4 | 5 | > H~2~O is a liquid. 2^10^ is 1024. 6 | 7 | If the superscripted or subscripted text contains spaces, these spaces must be escaped with 8 | backslashes. (This is to prevent accidental superscripting and subscripting 9 | through the ordinary use of ~ and ^.) Thus, if you want the letter P with "a cat" in 10 | subscripts, use P~a\ cat~, not P~a cat~. -------------------------------------------------------------------------------- /test/original/tabs.html: -------------------------------------------------------------------------------- 1 |
    2 |
  • this is a list item 3 | indented with tabs

  • 4 |
  • this is a list item 5 | indented with spaces

  • 6 |
7 | 8 |

Code:

9 | 10 |
this code block is indented by one tab
11 | 
12 | 13 |

And:

14 | 15 |
    this code block is indented by two tabs
16 | 
17 | 18 |

And:

19 | 20 |
+   this is an example list item
21 |     indented with tabs
22 | 
23 | +   this is an example list item
24 |     indented with spaces
25 | 
26 | -------------------------------------------------------------------------------- /test/tests/tabs.html: -------------------------------------------------------------------------------- 1 |
    2 |
  • this is a list item 3 | indented with tabs

  • 4 |
  • this is a list item 5 | indented with spaces

  • 6 |
7 | 8 |

Code:

9 | 10 |
this code block is indented by one tab
11 | 
12 | 13 |

And:

14 | 15 |
    this code block is indented by two tabs
16 | 
17 | 18 |

And:

19 | 20 |
+   this is an example list item
21 |     indented with tabs
22 | 
23 | +   this is an example list item
24 |     indented with spaces
25 | 
26 | -------------------------------------------------------------------------------- /test/tests/extra_sup_sub.text: -------------------------------------------------------------------------------- 1 | Superscripts may be written by surrounding the superscripted text by ^ characters; 2 | subscripts may be written by surrounding the subscripted text by ~ characters. 3 | Thus, for example, 4 | 5 | > H~2~O is a liquid. 2^10^ is 1024. 6 | 7 | If the superscripted or subscripted text contains spaces, these spaces must be escaped with 8 | backslashes. (This is to prevent accidental superscripting and subscripting 9 | through the ordinary use of ~ and ^.) Thus, if you want the letter P with "a cat" in 10 | subscripts, use P~a\ cat~, not P~a cat~. -------------------------------------------------------------------------------- /test/new/hilite2.text: -------------------------------------------------------------------------------- 1 | Title : Highlight test èç 2 | Title Note : &date;, &time; 3 | Author : Dan Rosèn¸ 4 | 5 | ~Pre : background-color=Ivory padding=1ex border-style=dotted border-color=black border-width=1px 6 | ~Pre,~Code : language=javascript 7 | 8 | [TITLE] 9 | 10 | [TOC] 11 | 12 | # Highlighting code 13 | 14 | Here is `function foo` javascript code. 15 | And some `do "hi"`{language=haskell} haskell code too. 16 | 17 | ``` 18 | function foo 19 | ``` 20 | 21 | and explicit: 22 | 23 | ```Javascript 24 | function foo 25 | ``` -------------------------------------------------------------------------------- /test/new/extra_codereplacer.text: -------------------------------------------------------------------------------- 1 | [INCLUDE=zero] 2 | Description : Some fun replacements 3 | Title : A code replacement test 4 | ~Pre,~Code : replace="//=>/\(⇒\)//!=/\(≠\)\ 5 | //\bforall /\(∀\)//\bexist /\(∃\)\ 6 | //\*\*/\(•\)//<(?![<=])/\(⟨\)//>(?![>=])/\(⟩\)\ 7 | //\balpha\b/\(α\)//\bbeta\b/\(β\)//g" 8 | language=javascript 9 | 10 | # Testing 11 | 12 | Here is some code: 13 | 14 | forall alpha beta ** exist c => return (Stream != 0) 15 | 16 | Nice! -------------------------------------------------------------------------------- /contrib/templates/default.mdk: -------------------------------------------------------------------------------- 1 | Title : Welcome 2 | Author : You 3 | Logo : True 4 | 5 | [TITLE] 6 | 7 | # Madoko 8 | 9 | Madoko is a fast markdown processor for writing professional articles 10 | with a focus on simplicity and plain text readability. 11 | 12 | * Read the [reference manual]. 13 | * Explore the upper-right toolbox menu to discover how Markdown works. 14 | * `Alt-Q` reformats the current paragraph. 15 | 16 | Enjoy! 17 | 18 | [reference manual]: http://research.microsoft.com/en-us/um/people/daan/madoko/doc/reference.html "Madoko reference manual" 19 | -------------------------------------------------------------------------------- /test/readme.txt: -------------------------------------------------------------------------------- 1 | All the test files in this directory and its subdirectories originate from 2 | the test suite included in the Marked project which is copyrighted as: 3 | 4 | Copyright (c) 2011-2013, Christopher Jeffrey. (MIT Licensed) 5 | https://github.com/chjj/marked 6 | 7 | The file "sigplanconf.cls" is the standard SIGPLAN conference LaTeX style 8 | and is copyrighted as: 9 | 10 | Paul C. Anagnostopoulos 11 | Windfall Software 12 | (Creative Commons Attribution License) 13 | 14 | The "butterfly.png" file comes from openclipart.com and is created by Jim Turner. 15 | -------------------------------------------------------------------------------- /test/new/extra_toc.text: -------------------------------------------------------------------------------- 1 | Title: Table of contents example 2 | Heading Base: 2 3 | 4 | [TOC] 5 | 6 | # Main Section 7 | 8 | Here is a reference to Section [#header12] which 9 | is the same as this reference [#header12][]. 10 | 11 | ## A subsection 12 | 13 | ## And another { #header12 } 14 | 15 | #### A level 4 subsection? 16 | 17 | # Another main section 18 | 19 | ## A third subsection 20 | ### And one on level 3 21 | ## A fourth subsection 22 | ### And one more on level 3 23 | 24 | # Appendix {-} 25 | 26 | # Appendix Section { @h1="A" } 27 | ## With a subsection 28 | # And another -------------------------------------------------------------------------------- /test/tests/extra_toc.text: -------------------------------------------------------------------------------- 1 | Title: Table of contents example 2 | Heading Base: 2 3 | 4 | [TOC] 5 | 6 | # Main Section 7 | 8 | Here is a reference to Section [#header12] which 9 | is the same as this reference [#header12][]. 10 | 11 | ## A subsection 12 | 13 | ## And another { #header12 } 14 | 15 | #### A level 4 subsection? 16 | 17 | # Another main section 18 | 19 | ## A third subsection 20 | ### And one on level 3 21 | ## A fourth subsection 22 | ### And one more on level 3 23 | 24 | # Appendix {-} 25 | 26 | # Appendix Section { @h1="A" } 27 | ## With a subsection 28 | # And another -------------------------------------------------------------------------------- /test/new/gfm_tables.text: -------------------------------------------------------------------------------- 1 | | Heading 1 | Heading 2 2 | | --------- | --------- 3 | | Cell 1 | Cell 2 4 | | Cell 3 | Cell 4 5 | 6 | | Header 1 | Header 2 | Header 3 | Header 4 | 7 | | :------: | -------: | :------- | -------- | 8 | | Cell 1 | Cell 2 | Cell 3 | Cell 4 | 9 | | Cell 5 | Cell 6 | Cell 7 | Cell 8 | 10 | 11 | Test code 12 | 13 | Header 1 | Header 2 14 | -------- | -------- 15 | Cell 1 | Cell 2 16 | Cell 3 | Cell 4 17 | 18 | Header 1|Header 2|Header 3|Header 4 19 | :-------|:------:|-------:|-------- 20 | Cell 1 |Cell 2 |Cell 3 |Cell 4 21 | *Cell 5*|Cell 6 |Cell 7 |Cell 8 22 | -------------------------------------------------------------------------------- /test/original/amps_and_angles_encoding.html: -------------------------------------------------------------------------------- 1 |

AT&T has an ampersand in their name.

2 | 3 |

AT&T is another way to write it.

4 | 5 |

This & that.

6 | 7 |

4 < 5.

8 | 9 |

6 > 5.

10 | 11 |

Here's a link with an ampersand in the URL.

12 | 13 |

Here's a link with an amersand in the link text: AT&T.

14 | 15 |

Here's an inline link.

16 | 17 |

Here's an inline link.

18 | -------------------------------------------------------------------------------- /test/tests/horizontal_rules.text: -------------------------------------------------------------------------------- 1 | Dashes: 2 | 3 | --- 4 | 5 | --- 6 | 7 | --- 8 | 9 | --- 10 | 11 | --- 12 | 13 | - - - 14 | 15 | - - - 16 | 17 | - - - 18 | 19 | - - - 20 | 21 | - - - 22 | 23 | 24 | Asterisks: 25 | 26 | *** 27 | 28 | *** 29 | 30 | *** 31 | 32 | *** 33 | 34 | *** 35 | 36 | * * * 37 | 38 | * * * 39 | 40 | * * * 41 | 42 | * * * 43 | 44 | * * * 45 | 46 | 47 | Underscores: 48 | 49 | ___ 50 | 51 | ___ 52 | 53 | ___ 54 | 55 | ___ 56 | 57 | ___ 58 | 59 | _ _ _ 60 | 61 | _ _ _ 62 | 63 | _ _ _ 64 | 65 | _ _ _ 66 | 67 | _ _ _ 68 | -------------------------------------------------------------------------------- /test/original/horizontal_rules.text: -------------------------------------------------------------------------------- 1 | Dashes: 2 | 3 | --- 4 | 5 | --- 6 | 7 | --- 8 | 9 | --- 10 | 11 | --- 12 | 13 | - - - 14 | 15 | - - - 16 | 17 | - - - 18 | 19 | - - - 20 | 21 | - - - 22 | 23 | 24 | Asterisks: 25 | 26 | *** 27 | 28 | *** 29 | 30 | *** 31 | 32 | *** 33 | 34 | *** 35 | 36 | * * * 37 | 38 | * * * 39 | 40 | * * * 41 | 42 | * * * 43 | 44 | * * * 45 | 46 | 47 | Underscores: 48 | 49 | ___ 50 | 51 | ___ 52 | 53 | ___ 54 | 55 | ___ 56 | 57 | ___ 58 | 59 | _ _ _ 60 | 61 | _ _ _ 62 | 63 | _ _ _ 64 | 65 | _ _ _ 66 | 67 | _ _ _ 68 | -------------------------------------------------------------------------------- /test/tests/gfm_tables.text: -------------------------------------------------------------------------------- 1 | | Heading 1 | Heading 2 2 | | --------- | --------- 3 | | Cell 1 | Cell 2 4 | | Cell 3 | Cell 4 5 | 6 | | Header 1 | Header 2 | Header 3 | Header 4 | 7 | | :------: | -------: | :------- | -------- | 8 | | Cell 1 | Cell 2 | Cell 3 | Cell 4 | 9 | | Cell 5 | Cell 6 | Cell 7 | Cell 8 | 10 | 11 | Test code 12 | 13 | Header 1 | Header 2 14 | -------- | -------- 15 | Cell 1 | Cell 2 16 | Cell 3 | Cell 4 17 | 18 | Header 1|Header 2|Header 3|Header 4 19 | :-------|:------:|-------:|-------- 20 | Cell 1 |Cell 2 |Cell 3 |Cell 4 21 | *Cell 5*|Cell 6 |Cell 7 |Cell 8 22 | -------------------------------------------------------------------------------- /test/tests/amps_and_angles_encoding.html: -------------------------------------------------------------------------------- 1 |

AT&T has an ampersand in their name.

2 | 3 |

AT&T is another way to write it.

4 | 5 |

This & that.

6 | 7 |

4 < 5.

8 | 9 |

6 > 5.

10 | 11 |

Here's a link with an ampersand in the URL.

12 | 13 |

Here's a link with an amersand in the link text: AT&T.

14 | 15 |

Here's an inline link.

16 | 17 |

Here's an inline link.

18 | -------------------------------------------------------------------------------- /.hgignore: -------------------------------------------------------------------------------- 1 | syntax:glob 2 | 3 | *.log 4 | *.dic 5 | 6 | contrib/ 7 | doc/*.pdf 8 | doc/*.html 9 | lib/ 10 | libnet/ 11 | libdoc/ 12 | node_modules/ 13 | out/ 14 | out2/ 15 | support/madoko-local/test 16 | styles/csl 17 | styles/locales 18 | web/client/version.json 19 | web/client/versionlog.json 20 | web/client/madoko.appcache 21 | web/client/lib/ 22 | web/client/private/ 23 | web/client/styles/ 24 | web/client/templates/ 25 | web/client/dictionaries/ 26 | web/users/ 27 | web/ssl/ 28 | web/log*/ 29 | web/xlog*/ 30 | web/run/ 31 | test/tex/ 32 | test/local/ 33 | test/scripts/ 34 | test/math/svg/ 35 | test/latex/ 36 | test/.madoko*/ 37 | 38 | -------------------------------------------------------------------------------- /src/version.kk: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2013-2015 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | 9 | // Export the version of the program. 10 | module version 11 | 12 | // Do not edit the version, it is set in the Jakefile from package.json 13 | public val version = "1.2.3" 14 | -------------------------------------------------------------------------------- /test/new/math-pre.text: -------------------------------------------------------------------------------- 1 | title : Math pre 2 | author : Daan 3 | author note : &time; 4 | 5 | 6 | ~Pre,~Code : input=mathpre 7 | replace="/\|->>/{\dlongmapsto}/g" 8 | replace="/>->/{\longrightarrow}/g" 9 | replace="/->/{\rightarrow}/g" 10 | replace="//{\rangle}/g" 12 | 13 | # Testing 14 | 15 | Math pre: 16 | 17 | ~ MathPre 18 | @function sqr(x : int) \{\ x * x \} 19 | ~ 20 | 21 | Or indented: 22 | 23 | @function sqr(x : int) \{\ x * x \} 24 | 25 | Or fenced: 26 | 27 | ``` 28 | @function sqr(x : int) \{\ x * x \} 29 | ``` 30 | -------------------------------------------------------------------------------- /test/tests/auto_links.html: -------------------------------------------------------------------------------- 1 |

Link: http://example.com/.

2 | 3 |

With an ampersand: http://example.com/?foo=1&bar=2

4 | 5 | 10 | 11 |
12 |

Blockquoted: http://example.com/

13 |
14 | 15 |

Auto-links should not occur here: <http://example.com/>

16 | 17 |
or here: <http://example.com/>
18 | 
19 | -------------------------------------------------------------------------------- /test/original/auto_links.html: -------------------------------------------------------------------------------- 1 |

Link: http://example.com/.

2 | 3 |

With an ampersand: http://example.com/?foo=1&bar=2

4 | 5 | 10 | 11 |
12 |

Blockquoted: http://example.com/

13 |
14 | 15 |

Auto-links should not occur here: <http://example.com/>

16 | 17 |
or here: <http://example.com/>
18 | 
19 | -------------------------------------------------------------------------------- /web/maintenance/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 12 | 13 | 14 | 15 |

Madoko Maintenance

16 |

Apologies, the madoko server is currently under maintenance...

17 |

See madoko.codeplex.com for the latest status

18 | 19 | 20 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | syntax:glob 2 | 3 | *.log 4 | *.dic 5 | 6 | contrib/ 7 | doc/*.pdf 8 | doc/*.html 9 | lib/ 10 | libnet/ 11 | libdoc/ 12 | node_modules/ 13 | out/ 14 | out2/ 15 | support/madoko-local/test 16 | styles/csl 17 | styles/locales 18 | web/client/version.json 19 | web/client/versionlog.json 20 | web/client/madoko.appcache 21 | web/client/lib/ 22 | web/client/private/ 23 | web/client/styles/ 24 | web/client/templates/ 25 | web/client/dictionaries/ 26 | web/users/ 27 | web/ssl/ 28 | web/log*/ 29 | web/xlog*/ 30 | web/run/ 31 | web/stats-munge.json 32 | test/tex/ 33 | test/local/ 34 | test/scripts/ 35 | test/math/svg/ 36 | test/latex/ 37 | test/.madoko*/ 38 | 39 | -------------------------------------------------------------------------------- /test/new/extra_sup_sub.html: -------------------------------------------------------------------------------- 1 | 2 |

Superscripts may be written by surrounding the superscripted text by ^ characters; 3 | subscripts may be written by surrounding the subscripted text by ~ characters. 4 | Thus, for example, 5 |

6 |
7 |

H2O is a liquid. 210 is 1024. 8 |

9 |

If the superscripted or subscripted text contains spaces, these spaces must be escaped with 10 | backslashes. (This is to prevent accidental superscripting and subscripting 11 | through the ordinary use of ~ and ^.) Thus, if you want the letter P with “a cat” in 12 | subscripts, use Pa cat, not P~a cat~.

-------------------------------------------------------------------------------- /test/new/math-error2.mdk: -------------------------------------------------------------------------------- 1 | Tex Header: 2 | \usepackage{amsmath} 3 | \usepackage{amssymb} 4 | \usepackage{amsthm} 5 | \usepackage{stmaryrd} 6 | \usepackage{listings} 7 | \usepackage{color} 8 | \usepackage{semantic} 9 | \usepackage{framed} 10 | \usepackage[curve]{{xypic}} 11 | \usepackage{url} 12 | \usepackage{graphicx} 13 | 14 | 15 | Testing: 16 | 17 | ~ Math 18 | \begin{array}{llcll} 19 | \textrm{types} & \tau^k & ::= & \alpha^k & \textrm{(type variable)} \\ 20 | \begin{comment} 21 | % & & | & c^\kk & \textrm{(type constant)} \\ 22 | \end{comment} 23 | \end{array} 24 | ~ 25 | -------------------------------------------------------------------------------- /test/new/toplevel_paragraphs.html: -------------------------------------------------------------------------------- 1 |

hello world 2 | how are you 3 | how are you

4 | 5 |

hello world

6 |
how are you
7 | 8 |

hello world

9 |
10 | 11 |

hello world

12 |

how are you

13 | 14 |

hello world

15 |

how are you

16 | 17 |

hello world

18 |

how are you

19 | 20 |

hello world 21 | * how are you

22 | 23 |

hello world

24 |
how are you
25 | 26 |

hello world 27 | how are you

28 | 29 |

hello world 30 |

31 | 32 |
hello
33 | 34 |

hello

35 | -------------------------------------------------------------------------------- /test/tests/extra_sup_sub.html: -------------------------------------------------------------------------------- 1 | 2 |

Superscripts may be written by surrounding the superscripted text by ^ characters; 3 | subscripts may be written by surrounding the subscripted text by ~ characters. 4 | Thus, for example, 5 |

6 |
7 |

H2O is a liquid. 210 is 1024. 8 |

9 |

If the superscripted or subscripted text contains spaces, these spaces must be escaped with 10 | backslashes. (This is to prevent accidental superscripting and subscripting 11 | through the ordinary use of ~ and ^.) Thus, if you want the letter P with “a cat” in 12 | subscripts, use Pa cat, not P~a cat~.

-------------------------------------------------------------------------------- /test/tests/toplevel_paragraphs.html: -------------------------------------------------------------------------------- 1 |

hello world 2 | how are you 3 | how are you

4 | 5 |

hello world

6 |
how are you
7 | 8 |

hello world

9 |
10 | 11 |

hello world

12 |

how are you

13 | 14 |

hello world

15 |

how are you

16 | 17 |

hello world

18 |

how are you

19 | 20 |

hello world 21 | * how are you

22 | 23 |

hello world

24 |
how are you
25 | 26 |

hello world 27 | how are you

28 | 29 |

hello world 30 |

31 | 32 |
hello
33 | 34 |

hello

35 | -------------------------------------------------------------------------------- /web/cache-config.json: -------------------------------------------------------------------------------- 1 | { 2 | "version" : "0", 3 | "rootPath" : "client", 4 | "dirs" : [".","images","lib","preview","scripts","styles","templates","dictionaries"], 5 | "exts" : ["html","xml","css","json","js","ts","png","gif","svg","mdk","bib","cls","sty","dic","aff","bst","ico","pdf"], 6 | "excludes" : ["version.json","madoko.appcache", 7 | "lib/vs?*/**", 8 | "lib/vs/languages/!(json|plaintext|vsxml|javascript|css|html)/**", 9 | "lib/vs/workbench/**" 10 | ], 11 | "digestOnly": ["../server.js","../stats.js","../cache-template.txt","../cache-config.json","../package.json","../../package.json","../remotes.json"] 12 | } -------------------------------------------------------------------------------- /test/new/lists.mdk: -------------------------------------------------------------------------------- 1 | title : test lists 2 | 3 | 3. Start at 3 4 | 4. Apple 5 | 5. Banana 6 | 7 | And more: 8 | 9 | 4. Start at 4 in lower roman 10 | 6. Apple 11 | 7. Banana 12 | { list-style-type=lower-roman } 13 | 14 | And more: 15 | 16 | i. First 17 | ii. Second 18 | iii. Third 19 | 20 | And more: 21 | 22 | A. First 23 | B. Second 24 | C. Third 25 | 26 | A\. Russel is a philosopher. 27 | 28 | (C) 2004 29 | 30 | And start somewhere 31 | 32 | I. Fourth 33 | #. Fifth 34 | #. Sixth' 35 | { start=4 } 36 | 37 | 38 | #. Default ordered 39 | #. Two 40 | #. Three 41 | 42 | And some parens list: 43 | 44 | 1) One 45 | 2) Two 46 | 3) Three 47 | 48 | Done. 49 | -------------------------------------------------------------------------------- /test/new/extra_lists.text: -------------------------------------------------------------------------------- 1 | Title : Test list margins and borders 2 | Heading Base: 2 3 | 4 | 5 | # Testing 6 | 7 | Here is a paragraph 8 | 9 | - and 10 | - a 11 | - list 12 | { border-style=solid border-width=1px margin-left=1em margin-top=1ex } 13 | 14 | Test 15 | 16 | 1. and 17 | 2. a 18 | 3. list 19 | { border-style=solid border-width=1px margin-left=1em margin-top=1ex } 20 | 21 | A link to [daan] and some [email] and [crazy]. 22 | 23 | [daan]: http://research.microsoft.com/~daan 24 | [email]: a_name@foo.bar 25 | [crazy]: http://x_x^x|x@x#x~x&x$xDashes:

2 | 3 |
4 | 5 |
6 | 7 |
8 | 9 |
10 | 11 |
---
12 | 
13 | 14 |
15 | 16 |
17 | 18 |
19 | 20 |
21 | 22 |
- - -
23 | 
24 | 25 |

Asterisks:

26 | 27 |
28 | 29 |
30 | 31 |
32 | 33 |
34 | 35 |
***
36 | 
37 | 38 |
39 | 40 |
41 | 42 |
43 | 44 |
45 | 46 |
* * *
47 | 
48 | 49 |

Underscores:

50 | 51 |
52 | 53 |
54 | 55 |
56 | 57 |
58 | 59 |
___
60 | 
61 | 62 |
63 | 64 |
65 | 66 |
67 | 68 |
69 | 70 |
_ _ _
71 | 
72 | -------------------------------------------------------------------------------- /web/encode.js: -------------------------------------------------------------------------------- 1 | var crypto = require("crypto"); 2 | 3 | function encrypt(secret,value) { 4 | var cipher = crypto.createCipher('aes256', secret); 5 | var encrypted = cipher.update(value, 'utf8', 'base64') + cipher.final('base64'); 6 | return encrypted; 7 | } 8 | 9 | function decrypt(secret,value) { 10 | var decipher = crypto.createDecipher('aes256', secret); 11 | var decrypted = decipher.update(value, 'base64', 'utf8') + decipher.final('utf8'); 12 | return decrypted; 13 | } 14 | 15 | var secret = process.argv[2]; 16 | var value = process.argv[3]; 17 | 18 | var encrypted = encrypt(secret,value); 19 | console.log("encrypting: '" + value + "'\n encrypt: '" + encrypted + "'\n decrypt: '" + decrypt(secret,encrypted) + "'"); -------------------------------------------------------------------------------- /support/madoko-local/src/config.js: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2015 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | 9 | if (typeof define !== 'function') { var define = require('amdefine')(module) } 10 | define([],function() { 11 | 12 | var version = "0.9.4"; 13 | var main = "madoko-local"; 14 | 15 | return { 16 | version: version, 17 | main : main, 18 | }; 19 | 20 | }); 21 | -------------------------------------------------------------------------------- /test/math/small.mdk: -------------------------------------------------------------------------------- 1 | Embed : 0 2 | Math Svg use fonts: true 3 | Math Svg Share Paths: false 4 | Math Embed: 0 5 | 6 | # Mathematics $xy^2$ 7 | 8 | A famous equation $\hspace{1em}$ is $e = mc^2$, but another $\int_{-\infty}^\infty e^{-a x^2} d x = \sqrt{\frac{\pi}{a}}$ famous one is: 9 | ~ Equation {#eq-gaussian; caption:"The Gaussian equation" } 10 | \int_{-\infty}^\infty e^{-a x^2} d x = \sqrt{\frac{\pi}{a}} 11 | ~ 12 | 13 | Here is the baseline $x$ and $\sigma_{\lambda} = \frac{24 \pi^3}{\lambda^4 N^2}\left(\frac{n^2-1}{n^2+2}\right)^{\!2}$ problem. 14 | And as an equation: 15 | ~ Equation 16 | \sigma_{\lambda} = 17 | \frac{24 \pi^3}{\lambda^4 N^2} 18 | \left(\frac{n^2-1}{n^2+2}\right)^{\!2} 19 | ~ 20 | 21 | it looks fine. $x=2$. 22 | -------------------------------------------------------------------------------- /styles/zero.mdk: -------------------------------------------------------------------------------- 1 | Description: Leino mode: Start numbering at 0 2 | H0 { @h0: arabic0 } 3 | H1 { @h1: arabic0 } 4 | H2 { @h1-h2: arabic0 } 5 | H3 { @h1-h2-h3: arabic0 } 6 | H4 { @h1-h2-h3-h4: arabic0 } 7 | H5 { @h1-h2-h3-h4-h5: arabic0 } 8 | H6 { @h1-h2-h3-h4-h5-h6: arabic0 } 9 | Figure { @figure: arabic0 } 10 | Equation { @equation: arabic0 } 11 | Footnote { @footnote: arabic0 } 12 | Bibitem { @bib-bibitem: arabic0; @bibitem: arabic0; bibitem-label:[&cite-label;] } 13 | 14 | Tex Doc Header*: 15 | \makeatletter 16 | \ifdef\thepart{% 17 | \renewcommand\thepart{\@arabic\c@part}% 18 | \setcounter{part}{-1}}{}% 19 | \makeatother 20 | \ifdef\thechapter{\setcounter{chapter}{-1}}{}% 21 | -------------------------------------------------------------------------------- /test/latex/float.mdk: -------------------------------------------------------------------------------- 1 | Title : My Academic Paper 2 | Author : You 3 | Affiliation : Research institute 4 | Email : you@bar.com 5 | 6 | Author : My co-author 7 | Affiliation : Other institute 8 | Email : other@bar.com 9 | Package : wrapfig 10 | 11 | [INCLUDE=lipsum] 12 | 13 | 14 | &lipsum1; 15 | 16 | ~ Begin Sample 17 | ~ Figure { caption:"A formula"; width:60%; float:left; margin-right:1em } 18 | ~~ Math 19 | e = mc^2 20 | ~~ 21 | ~ 22 | "Aarghhh", he shouted but not even the next 23 | one in line noticed that something 24 | terrible had happened to him. 25 | "Aarghhh", he shouted but not even the next 26 | one in line noticed that something 27 | terrible had happened to [him.]{float:right} 28 | ~ End Sample 29 | 30 | 31 | &lipsum2; -------------------------------------------------------------------------------- /support/madoko-local/static/styles/main.css: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2015 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | body { 9 | background-color: Gainsboro; 10 | font-family: "Segoe UI", sans-serif; 11 | } 12 | 13 | 14 | html,body,#madokoframe { 15 | padding: 0pt; 16 | margin : 0pt; 17 | border : none; 18 | width : 100%; 19 | height : 100%; 20 | } 21 | 22 | html { 23 | overflow: hidden; 24 | } 25 | -------------------------------------------------------------------------------- /test/original/horizontal_rules.html: -------------------------------------------------------------------------------- 1 |

Dashes:

2 | 3 |
4 | 5 |
6 | 7 |
8 | 9 |
10 | 11 |
---
12 | 
13 | 14 |
15 | 16 |
17 | 18 |
19 | 20 |
21 | 22 |
- - -
23 | 
24 | 25 |

Asterisks:

26 | 27 |
28 | 29 |
30 | 31 |
32 | 33 |
34 | 35 |
***
36 | 
37 | 38 |
39 | 40 |
41 | 42 |
43 | 44 |
45 | 46 |
* * *
47 | 
48 | 49 |

Underscores:

50 | 51 |
52 | 53 |
54 | 55 |
56 | 57 |
58 | 59 |
___
60 | 
61 | 62 |
63 | 64 |
65 | 66 |
67 | 68 |
69 | 70 |
_ _ _
71 | 
72 | -------------------------------------------------------------------------------- /test/new/gfm-code_hr_list.text: -------------------------------------------------------------------------------- 1 | ## foo 2 | 3 | 1. bar: 4 | 5 | > - one 6 | - two 7 | - three 8 | - four 9 | - five 10 | 11 | 1. foo: 12 | 13 | ``` 14 | line 1 15 | line 2 16 | ``` 17 | 18 | 1. foo: 19 | 20 | 1. foo `bar` bar: 21 | 22 | ``` erb 23 | some code here 24 | ``` 25 | 26 | 2. foo `bar` bar: 27 | 28 | ``` erb 29 | foo 30 | --- 31 | bar 32 | --- 33 | foo 34 | bar 35 | ``` 36 | 37 | 3. foo `bar` bar: 38 | 39 | ``` html 40 | --- 41 | foo 42 | foo 43 | --- 44 | bar 45 | ``` 46 | 47 | 4. foo `bar` bar: 48 | 49 | foo 50 | --- 51 | bar 52 | 53 | 5. foo 54 | -------------------------------------------------------------------------------- /test/tests/gfm-code_hr_list.text: -------------------------------------------------------------------------------- 1 | ## foo 2 | 3 | 1. bar: 4 | 5 | > - one 6 | - two 7 | - three 8 | - four 9 | - five 10 | 11 | 1. foo: 12 | 13 | ``` 14 | line 1 15 | line 2 16 | ``` 17 | 18 | 1. foo: 19 | 20 | 1. foo `bar` bar: 21 | 22 | ``` erb 23 | some code here 24 | ``` 25 | 26 | 2. foo `bar` bar: 27 | 28 | ``` erb 29 | foo 30 | --- 31 | bar 32 | --- 33 | foo 34 | bar 35 | ``` 36 | 37 | 3. foo `bar` bar: 38 | 39 | ``` html 40 | --- 41 | foo 42 | foo 43 | --- 44 | bar 45 | ``` 46 | 47 | 4. foo `bar` bar: 48 | 49 | foo 50 | --- 51 | bar 52 | 53 | 5. foo 54 | -------------------------------------------------------------------------------- /test/tests/extra_footnotes.text: -------------------------------------------------------------------------------- 1 | This file tests support for footnotes in [Markdown Extra][]. The output 2 | adheres to what John Gruber describes at [Daring Fireball][Footnotes]. 3 | 4 | [Markdown Extra]: http://michelf.ca/projects/php-markdown/extra#footnotes 5 | [Footnotes]: http://daringfireball.net/2005/07/footnotes 6 | 7 | That's some text with a footnote.[^1] and 8 | another footnote [^test], and a duplicate[^1]. 9 | 10 | [^1]: And that's the footnote. 11 | 12 | That's the second paragraph. 13 | 14 | [^test]: More testing 15 | 16 | * with a 17 | * list in it [^3] 18 | 19 | And more text. 20 | 21 | [^1]: 22 | Second definition overrides 23 | 24 | with code 25 | in it 26 | 27 | And another paragraph 28 | 29 | [^3]: And the last footnote 30 | 31 | With another paragraph 32 | 33 | -------------------------------------------------------------------------------- /test/new/extra_footnotes.text: -------------------------------------------------------------------------------- 1 | Title: Footnotes. 2 | ~Footnote: @footnote=arabic0 3 | 4 | This file tests support for footnotes in [Markdown Extra][]. The output 5 | adheres to what John Gruber describes at [Daring Fireball][Footnotes]. 6 | 7 | [Markdown Extra]: http://michelf.ca/projects/php-markdown/extra#footnotes 8 | [Footnotes]: http://daringfireball.net/2005/07/footnotes 9 | 10 | That's some text with a footnote.[^1]^,^[^2] and 11 | another footnote[^test], and a duplicate[^1]. 12 | 13 | [^1]: And that's the footnote. 14 | 15 | That's the second paragraph. 16 | 17 | [^test]: More testing 18 | 19 | * with a 20 | * list in it [^3] 21 | 22 | And more text. 23 | 24 | [^2]: 25 | A definition 26 | 27 | with code 28 | in it 29 | 30 | And another paragraph 31 | 32 | [^3]: And the last footnote 33 | 34 | With another paragraph 35 | 36 | -------------------------------------------------------------------------------- /test/tests/inline_html_simple.text: -------------------------------------------------------------------------------- 1 | Here's a simple block: 2 | 3 |
4 | foo 5 |
6 | 7 | This should be a code block, though: 8 | 9 |
10 | foo 11 |
12 | 13 | As should this: 14 | 15 |
foo
16 | 17 | Now, nested: 18 | 19 |
20 |
21 |
22 | foo 23 |
24 |
25 |
26 | 27 | This should just be an HTML comment: 28 | 29 | 30 | 31 | Multiline: 32 | 33 | 37 | 38 | Code block: 39 | 40 | 41 | 42 | Just plain comment, with trailing spaces on the line: 43 | 44 | 45 | 46 | Code: 47 | 48 |
49 | 50 | Hr's: 51 | 52 |
53 | 54 |
55 | 56 |
57 | 58 |
59 | 60 |
61 | 62 |
63 | 64 |
65 | 66 |
67 | 68 |
69 | 70 | -------------------------------------------------------------------------------- /test/latex/chinese.mdk: -------------------------------------------------------------------------------- 1 | Title : 世界,我感觉很不好。 2 | 3 | Author : 周大平 4 | Affiliation : 锑星社会科学院 5 | Email : you@bar.com 6 | 7 | Bibliography : example.bib 8 | Doc class : [reprint,nocopyrightspace]style/sigplanconf.cls 9 | Package : [UTF8]ctex 10 | Tex Header : 11 | \def\refname{&name-references;} 12 | \renewenvironment{abstract}{\section*{&name-abstract;}\normalsize}{} 13 | 14 | name-references : 参考 15 | name-abstract : 摘要 16 | 17 | .cjk { 18 | list-style-type:none; 19 | } 20 | .cjk-li { 21 | @ol-li:"cjk-decimal"; 22 | li-label: "@ol-li"; 23 | } 24 | 25 | [TITLE] 26 | 27 | ~ Abstract 28 | 没有鱼! 29 | ~ 30 | 31 | # 糟透了 { #sec-intro } 32 | 没有超盐酸怎么养鱼[@Fberg04]。 33 | 34 | 1. 1 35 | 2. 2 36 | 3. 3 37 | 4. 4 38 | 5. 5 39 | 6. 6 40 | 7. 7 41 | 8. 8 42 | 9. 9 43 | 10. 10 44 | 11. 11 45 | { .cjk } 46 | 47 | [BIB] -------------------------------------------------------------------------------- /test/original/inline_html_simple.text: -------------------------------------------------------------------------------- 1 | Here's a simple block: 2 | 3 |
4 | foo 5 |
6 | 7 | This should be a code block, though: 8 | 9 |
10 | foo 11 |
12 | 13 | As should this: 14 | 15 |
foo
16 | 17 | Now, nested: 18 | 19 |
20 |
21 |
22 | foo 23 |
24 |
25 |
26 | 27 | This should just be an HTML comment: 28 | 29 | 30 | 31 | Multiline: 32 | 33 | 37 | 38 | Code block: 39 | 40 | 41 | 42 | Just plain comment, with trailing spaces on the line: 43 | 44 | 45 | 46 | Code: 47 | 48 |
49 | 50 | Hr's: 51 | 52 |
53 | 54 |
55 | 56 |
57 | 58 |
59 | 60 |
61 | 62 |
63 | 64 |
65 | 66 |
67 | 68 |
69 | 70 | -------------------------------------------------------------------------------- /contrib/templates/acmclassify.mdk: -------------------------------------------------------------------------------- 1 | ~~ TexRaw 2 | %% 2012 ACM Computing Classification System (CSS) concepts 3 | %% Generate at 'http://dl.acm.org/ccs/ccs.cfm'. 4 | \begin{CCSXML} 5 | 6 | 7 | 10011007.10011006.10011008 8 | Software and its engineering~General programming languages 9 | 500 10 | 11 | 12 | 10003456.10003457.10003521.10003525 13 | Social and professional topics~History of programming languages 14 | 300 15 | 16 | 17 | \end{CCSXML} 18 | 19 | \ccsdesc[500]{Software and its engineering~General programming languages} 20 | \ccsdesc[300]{Social and professional topics~History of programming languages} 21 | %% End of generated code 22 | ~~ -------------------------------------------------------------------------------- /test/new/borders.text: -------------------------------------------------------------------------------- 1 | Title : Test Css attributes 2 | Heading Base: 2 3 | 4 | # Css 5 | 6 | A paragraph 7 | 8 | A framed[^fn1] paragraph 1 9 | { border-style=solid border-width=1px \ 10 | padding=1ex margin=1ex text-indent=0pt } 11 | 12 | A framed[^fn2] paragraph 2 13 | { border-style=solid border-width=1px \ 14 | padding=1ex margin=1ex text-indent=0pt \ 15 | height=2cm } 16 | 17 | 18 | A framed paragraph 3 19 | { border-style=solid border-width=1px \ 20 | padding=1ex text-indent=0pt \ 21 | height=2cm width=4cm .align-center } 22 | 23 | A framed paragraph 4 24 | { border-style=solid border-width=1px \ 25 | padding=1ex text-indent=0pt \ 26 | height=2cm width=4cm margin-left=auto margin-right=auto } 27 | 28 | some centered text 29 | { text-align=center } 30 | 31 | some centered text 32 | { text-align=center width=2cm margin-left=auto margin-right=auto } 33 | 34 | 35 | [^fn1]: footnote 1 36 | [^fn2]: footnote 2 -------------------------------------------------------------------------------- /test/new/extra_boxes.text: -------------------------------------------------------------------------------- 1 | Title : Test Css attributes 2 | Heading Base: 2 3 | 4 | # Css 5 | 6 | A paragraph 7 | 8 | A framed[^fn1] paragraph 1 9 | { border-style=solid border-width=1px \ 10 | padding=1ex margin=1ex text-indent=0pt } 11 | 12 | A framed[^fn2] paragraph 2 13 | { border-style=solid border-width=1px \ 14 | padding=1ex margin=1ex text-indent=0pt \ 15 | height=2cm } 16 | 17 | 18 | A framed paragraph 3 19 | { border-style=solid border-width=1px \ 20 | padding=1ex text-indent=0pt \ 21 | height=2cm width=4cm .align-center } 22 | 23 | A framed paragraph 4 24 | { border-style=solid border-width=1px \ 25 | padding=1ex text-indent=0pt \ 26 | height=2cm width=4cm margin-left=auto margin-right=auto } 27 | 28 | some centered text 29 | { text-align=center } 30 | 31 | some centered text 32 | { text-align=center width=2cm margin-left=auto margin-right=auto } 33 | 34 | 35 | [^fn1]: footnote 1 36 | [^fn2]: footnote 2 -------------------------------------------------------------------------------- /styles/webanchors.mdk: -------------------------------------------------------------------------------- 1 | Description: 2 | Provides popup anchor links to headings in a web page. 3 | This makes it easier for others to link to specific sections 4 | in a large web manual or book. 5 | 6 | anchor symbol: \# 7 | 8 | @if html { 9 | h0, h1, h2, h3 { 10 | before: "[&anchor-symbol;](#&id;){.entity-anchor}" 11 | } 12 | } 13 | 14 | Css Header: 15 | h0:hover .entity-anchor, 16 | h1:hover .entity-anchor, 17 | h2:hover .entity-anchor, 18 | h3:hover .entity-anchor { 19 | display: inline-block; 20 | } 21 | 22 | a.entity-anchor { 23 | color: black; 24 | } 25 | 26 | a.localref.entity-anchor:hover { 27 | text-decoration: none; 28 | } 29 | 30 | .entity-anchor { 31 | display: none; 32 | width: 0.8em; 33 | margin-left: -0.8em; 34 | font-family: "Segoe UI Symbol", Symbola, serif; 35 | font-size: 80%; 36 | } 37 | -------------------------------------------------------------------------------- /test/new/gfm-code_hr_list.html: -------------------------------------------------------------------------------- 1 |

foo

2 |
    3 |
  1. bar:

    4 |
    5 |
      6 |
    • one
        7 |
      • two
          8 |
        • three
        • 9 |
        • four
        • 10 |
        • five
        • 11 |
        12 |
      • 13 |
      14 |
    • 15 |
    16 |
    17 |
  2. 18 |
  3. foo:

    19 |
     line 1
    20 |  line 2
    21 |
  4. 22 |
  5. foo:

    23 |
      24 |
    1. foo bar bar:

      25 |
       some code here
      26 | 
      27 |
    2. 28 |
    3. foo bar bar:

      29 |
       foo
      30 |  ---
      31 |  bar
      32 |  ---
      33 |  foo
      34 |  bar
      35 |
    4. 36 |
    5. foo bar bar:

      37 |
       ---
      38 |  foo
      39 |  foo
      40 |  ---
      41 |  bar
      42 |
    6. 43 |
    7. foo bar bar:

      44 |
       foo
      45 |  ---
      46 |  bar
      47 |
    8. 48 |
    9. foo

      49 |
    10. 50 |
    51 |
  6. 52 |
53 | -------------------------------------------------------------------------------- /test/tests/gfm-code_hr_list.html: -------------------------------------------------------------------------------- 1 |

foo

2 |
    3 |
  1. bar:

    4 |
    5 |
      6 |
    • one
        7 |
      • two
          8 |
        • three
        • 9 |
        • four
        • 10 |
        • five
        • 11 |
        12 |
      • 13 |
      14 |
    • 15 |
    16 |
    17 |
  2. 18 |
  3. foo:

    19 |
     line 1
    20 |  line 2
    21 |
  4. 22 |
  5. foo:

    23 |
      24 |
    1. foo bar bar:

      25 |
       some code here
      26 | 
      27 |
    2. 28 |
    3. foo bar bar:

      29 |
       foo
      30 |  ---
      31 |  bar
      32 |  ---
      33 |  foo
      34 |  bar
      35 |
    4. 36 |
    5. foo bar bar:

      37 |
       ---
      38 |  foo
      39 |  foo
      40 |  ---
      41 |  bar
      42 |
    6. 43 |
    7. foo bar bar:

      44 |
       foo
      45 |  ---
      46 |  bar
      47 |
    8. 48 |
    9. foo

      49 |
    10. 50 |
    51 |
  6. 52 |
53 | -------------------------------------------------------------------------------- /src/toc.kk: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2013 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | 9 | // Documentation for the Madoko program sources. 10 | 11 | module toc 12 | 13 | import std/dict 14 | import std/flags 15 | import std/regex 16 | import std/string 17 | import std/path 18 | import std/file 19 | import std/env 20 | 21 | import common 22 | import entity 23 | import attributes 24 | import options 25 | import block 26 | import inline 27 | import texParser 28 | import texFormatter 29 | import htmlFormatter 30 | import formatInline 31 | import formatBlock 32 | import definitions 33 | import madoko 34 | import main 35 | -------------------------------------------------------------------------------- /src/storage-inline.cs: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2013-2015 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | 9 | public static class BitReader 10 | { 11 | public static int readInt32( object _buffer, int offset, bool bigEndian ) { 12 | byte[] buffer = (byte[])(_buffer); 13 | if (buffer.Length <= offset + 3) { 14 | return 0; 15 | } 16 | else if (BitConverter.IsLittleEndian && !bigEndian) { 17 | return BitConverter.ToInt32( buffer, offset ); 18 | } 19 | else { 20 | byte[] buf = { buffer[offset+3], buffer[offset+2], buffer[offset+1], buffer[offset] }; 21 | return BitConverter.ToInt32( buf, 0 ); 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /test/latex/basic - Copy.mdk: -------------------------------------------------------------------------------- 1 | Heading base : 2 2 | 3 | # Introduction 4 | 5 | [INCLUDE="include with spaces"] 6 | 7 | A test paragraph. 8 | 9 | | head1 | head2 | 10 | |:-----:|-------| 11 | | cell1 | cell2 | 12 | |-------|-------| 13 | 14 | There is more in you of good than you know, child of the kindly West. 15 | Some courage and some wisdom, blended in measure. If more of us valued 16 | food and cheer and song above hoarded gold, it would be a merrier world. 17 | But sad or merry, I must leave it now. 18 | 19 | ~ Columns 20 | ~~ Column { width=20% text-align=center } 21 | col 1 22 | 23 | col 1 24 | ~~ 25 | ~~ Column { border="1px black solid" } 26 | There is more in you of good than you know, child of the kindly West. 27 | Some courage and some wisdom, blended in measure. If more of us valued 28 | food and cheer and song above hoarded gold, it would be a merrier world. 29 | But sad or merry, I must leave it now. 30 | ~~ 31 | ~~ Column { width=4em text-align=right } 32 | col 3 33 | ~~ 34 | ~ 35 | 36 | Don. 37 | -------------------------------------------------------------------------------- /test/latex/csl/nature-biotechnology.csl: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /test/tests/extra_things.text: -------------------------------------------------------------------------------- 1 | Title : Examples 2 | Script : https://google-code-prettify.googlecode.com/svn/loader/run_prettify.js?lang=scm&lang=latex 3 | Heading Base: 2 4 | 5 | ~pre : .prettyprint .linenums 6 | .upper : replace='/^[\s\S]*$/\U\0\E and more/' 7 | .fib : replace='/^x?$/y/' replace='/xx(x*)/[x\1]{.fib}[\1]{.fib}/' notag 8 | 9 | # Examples 10 | 11 | Fibonacci of 6 is how many y's? 12 | [xxxxxx]{.fib} 13 | 14 | Some [Upper case text]{.upper}. 15 | Here is an image ![monarch]. 16 | 17 | [monarch]: ../butterfly.png { width=2cm vertical-align=middle } 18 | 19 | ~ Framed {text-align=center tight} 20 | framed text 21 | ~ 22 | 23 | 24 | 25 | ``` 26 | function hello() { 27 | alert("hello world") 28 | } 29 | ``` 30 | 31 | And indented 32 | 33 | function hello() { 34 | alert("hello world") 35 | } 36 | 37 | ``` latex 38 | \begin{itemize} 39 | \item Some \textbf{latex} code. 40 | \item Good for math $2\sin$. 41 | \item But a horrible macro language :-(. 42 | \end{itemize} 43 | ``` 44 | 45 | ``` scheme {.lang-scm} 46 | (friends 'of '(parentheses)) 47 | ``` -------------------------------------------------------------------------------- /doc/ignores.dic: -------------------------------------------------------------------------------- 1 | Inline 2 | Github 3 | pre 4 | inline 5 | metadata 6 | MadokoNet 7 | Gruber 8 | tooltip 9 | CSS 10 | Gibran 11 | preformatted 12 | backticks 13 | JavaScript 14 | monospace 15 | blogger 16 | JSON 17 | CSharp 18 | Todo 19 | Dafny 20 | SMT 21 | gizmo 22 | doohickies 23 | gizmos 24 | dojigger 25 | Foo 26 | doo 27 | hickies 28 | thingabob 29 | javascript 30 | MathJax 31 | ImageMagick's 32 | PSTricks 33 | TikZ 34 | Pgf 35 | tooltips 36 | backend 37 | blockname 38 | Html 39 | css 40 | dir 41 | dpi 42 | cmd 43 | MathJaX 44 | CDN 45 | CTAN 46 | XeLaTeX 47 | exempli 48 | gratia 49 | alii 50 | backends 51 | DimGray 52 | DarkGray 53 | LightGray 54 | Gainsboro 55 | FloralWhite 56 | screenshot 57 | Aargh 58 | num 59 | arabic 60 | replacers 61 | yysep 62 | sep 63 | aysep 64 | Hanne 65 | Riis 66 | Torben 67 | Amtoft 68 | subtyping 69 | LOMAPS 70 | longauthors 71 | amscd 72 | env 73 | cmds 74 | cmdname 75 | attrname 76 | str 77 | arg 78 | html 79 | unicode 80 | UTF 81 | bslash 82 | pagebreak 83 | perc 84 | Daan 85 | Leijen 86 | Gruber's 87 | IC 88 | VTSA 89 | Nikolaj 90 | js 91 | MacOSX 92 | mb 93 | foo 94 | voil -------------------------------------------------------------------------------- /doc/reference.bib: -------------------------------------------------------------------------------- 1 | @BOOK{ Knuth:TeX, 2 | author="Knuth, Donald E.", 3 | title="The {T}e{X} book", 4 | publisher="Addison-Wesley", 5 | year=1984 6 | } 7 | 8 | @BOOK{ Lamport:LaTeX, 9 | author="Lamport, Leslie", 10 | title="{LaTeX}: A Document Preparation System (2nd Edition)", 11 | publisher="Addison-Wesley", 12 | year=1994, 13 | note="See also \cite{Knuth:Tex}." 14 | } 15 | 16 | @INBOOK{ Grandstrand, 17 | author = {O. Grandstrand}, 18 | chapter = {Innovation and Intellectual Property Rights}, 19 | crossref = {Fberg04} 20 | } 21 | 22 | @BOOK{ Fberg04, 23 | editor = {J. Fagerberg and D.C. Mowery and R.R. Nelson}, 24 | title = {Oxford Handbook of Innovation}, 25 | booktitle = {Oxford Handbook of Innovation}, 26 | publisher = {Oxford University Press}, 27 | address = {Oxford}, 28 | volume=1, 29 | year = 2004 30 | } 31 | 32 | @book{Goo93, 33 | author = "Goossens, Michel and Mittelbach, Frank and Samarin, Alexander", 34 | title = "The LaTeX Companion", 35 | year = "1993", 36 | publisher = "Addison-Wesley", 37 | address = "Reading, Massachusetts" 38 | } 39 | -------------------------------------------------------------------------------- /test/example.bib: -------------------------------------------------------------------------------- 1 | @BOOK{ Knuth:TeX, 2 | author="Knuth, Donald E.", 3 | title="The {T}e{X} book", 4 | publisher="Addison-Wesley", 5 | year=1984 6 | } 7 | 8 | @BOOK{ Lamport:LaTeX, 9 | author="Lamport, Leslie", 10 | title="{LaTeX}: A Document Preparation System (2nd Edition)", 11 | publisher="Addison-Wesley", 12 | year=1994, 13 | note="See also \cite{Knuth:Tex}." 14 | } 15 | 16 | @INBOOK{ Grandstrand, 17 | author = {O. Grandstrand}, 18 | chapter = {Innovation and Intellectual Property Rights}, 19 | crossref = {Fberg04} 20 | } 21 | 22 | @BOOK{ Fberg04, 23 | editor = {J. Fagerberg and D.C. Mowery and R.R. Nelson}, 24 | title = {Oxford Handbook of Innovation}, 25 | booktitle = {Oxford Handbook of Innovation}, 26 | publisher = {Oxford University Press}, 27 | address = {Oxford}, 28 | volume=1, 29 | year = 2004 30 | } 31 | 32 | @book{Goo93, 33 | author = "Goossens, Michel and Mittelbach, Frank and Samarin, Alexander", 34 | title = "The LaTeX Companion", 35 | year = "1993", 36 | publisher = "Addison-Wesley", 37 | address = "Reading, Massachusetts" 38 | } 39 | -------------------------------------------------------------------------------- /test/original/inline_html_simple.html: -------------------------------------------------------------------------------- 1 |

Here's a simple block:

2 | 3 |
4 | foo 5 |
6 | 7 |

This should be a code block, though:

8 | 9 |
<div>
10 |     foo
11 | </div>
12 | 
13 | 14 |

As should this:

15 | 16 |
<div>foo</div>
17 | 
18 | 19 |

Now, nested:

20 | 21 |
22 |
23 |
24 | foo 25 |
26 |
27 |
28 | 29 |

This should just be an HTML comment:

30 | 31 | 32 | 33 |

Multiline:

34 | 35 | 39 | 40 |

Code block:

41 | 42 |
<!-- Comment -->
43 | 
44 | 45 |

Just plain comment, with trailing spaces on the line:

46 | 47 | 48 | 49 |

Code:

50 | 51 |
<hr />
52 | 
53 | 54 |

Hr's:

55 | 56 |
57 | 58 |
59 | 60 |
61 | 62 |
63 | 64 |
65 | 66 |
67 | 68 |
69 | 70 |
71 | 72 |
73 | -------------------------------------------------------------------------------- /test/tests/inline_html_simple.html: -------------------------------------------------------------------------------- 1 |

Here's a simple block:

2 | 3 |
4 | foo 5 |
6 | 7 |

This should be a code block, though:

8 | 9 |
<div>
10 |     foo
11 | </div>
12 | 
13 | 14 |

As should this:

15 | 16 |
<div>foo</div>
17 | 
18 | 19 |

Now, nested:

20 | 21 |
22 |
23 |
24 | foo 25 |
26 |
27 |
28 | 29 |

This should just be an HTML comment:

30 | 31 | 32 | 33 |

Multiline:

34 | 35 | 39 | 40 |

Code block:

41 | 42 |
<!-- Comment -->
43 | 
44 | 45 |

Just plain comment, with trailing spaces on the line:

46 | 47 | 48 | 49 |

Code:

50 | 51 |
<hr>
52 | 
53 | 54 |

Hr's:

55 | 56 |
57 | 58 |
59 | 60 |
61 | 62 |
63 | 64 |
65 | 66 |
67 | 68 |
69 | 70 |
71 | 72 |
73 | -------------------------------------------------------------------------------- /test/original/links_reference_style.text: -------------------------------------------------------------------------------- 1 | Foo [bar] [1]. 2 | 3 | Foo [bar][1]. 4 | 5 | Foo [bar] 6 | [1]. 7 | 8 | [1]: /url/ "Title" 9 | 10 | 11 | With [embedded [brackets]] [b]. 12 | 13 | 14 | Indented [once][]. 15 | 16 | Indented [twice][]. 17 | 18 | Indented [thrice][]. 19 | 20 | Indented [four][] times. 21 | 22 | [once]: /url 23 | 24 | [twice]: /url 25 | 26 | [thrice]: /url 27 | 28 | [four]: /url 29 | 30 | 31 | [b]: /url/ 32 | 33 | * * * 34 | 35 | [this] [this] should work 36 | 37 | So should [this][this]. 38 | 39 | And [this] []. 40 | 41 | And [this][]. 42 | 43 | And [this]. 44 | 45 | But not [that] []. 46 | 47 | Nor [that][]. 48 | 49 | Nor [that]. 50 | 51 | [Something in brackets like [this][] should work] 52 | 53 | [Same with [this].] 54 | 55 | In this case, [this](/somethingelse/) points to something else. 56 | 57 | Backslashing should suppress \[this] and [this\]. 58 | 59 | [this]: foo 60 | 61 | 62 | * * * 63 | 64 | Here's one where the [link 65 | breaks] across lines. 66 | 67 | Here's another where the [link 68 | breaks] across lines, but with a line-ending space. 69 | 70 | 71 | [link breaks]: /url/ 72 | -------------------------------------------------------------------------------- /test/tests/links_reference_style.text: -------------------------------------------------------------------------------- 1 | Foo [bar] [1]. 2 | 3 | Foo [bar][1]. 4 | 5 | Foo [bar] 6 | [1]. 7 | 8 | [1]: /url/ "Title" 9 | 10 | 11 | With [embedded [brackets]] [b]. 12 | 13 | 14 | Indented [once][]. 15 | 16 | Indented [twice][]. 17 | 18 | Indented [thrice][]. 19 | 20 | Indented [four][] times. 21 | 22 | [once]: /url 23 | 24 | [twice]: /url 25 | 26 | [thrice]: /url 27 | 28 | [four]: /url 29 | 30 | 31 | [b]: /url/ 32 | 33 | * * * 34 | 35 | [this] [this] should work 36 | 37 | So should [this][this]. 38 | 39 | And [this] []. 40 | 41 | And [this][]. 42 | 43 | And [this]. 44 | 45 | But not [that] []. 46 | 47 | Nor [that][]. 48 | 49 | Nor [that]. 50 | 51 | [Something in brackets like [this][] should work] 52 | 53 | [Same with [this].] 54 | 55 | In this case, [this](/somethingelse/) points to something else. 56 | 57 | Backslashing should suppress \[this] and [this\]. 58 | 59 | [this]: foo 60 | 61 | 62 | * * * 63 | 64 | Here's one where the [link 65 | breaks] across lines. 66 | 67 | Here's another where the [link 68 | breaks] across lines, but with a line-ending space. 69 | 70 | 71 | [link breaks]: /url/ 72 | -------------------------------------------------------------------------------- /contrib/styles/example.bib: -------------------------------------------------------------------------------- 1 | @BOOK{ Knuth:TeX, 2 | author="Knuth, Donald E.", 3 | title="The {T}e{X} book", 4 | publisher="Addison-Wesley", 5 | year=1984 6 | } 7 | 8 | @BOOK{ Lamport:LaTeX, 9 | author="Lamport, Leslie", 10 | title="{LaTeX}: A Document Preparation System (2nd Edition)", 11 | publisher="Addison-Wesley", 12 | year=1994, 13 | note="See also \cite{Knuth:Tex}." 14 | } 15 | 16 | @INBOOK{ Grandstrand, 17 | author = {O. Grandstrand}, 18 | chapter = {Innovation and Intellectual Property Rights}, 19 | crossref = {Fberg04} 20 | } 21 | 22 | @BOOK{ Fberg04, 23 | editor = {J. Fagerberg and D.C. Mowery and R.R. Nelson}, 24 | title = {Oxford Handbook of Innovation}, 25 | booktitle = {Oxford Handbook of Innovation}, 26 | publisher = {Oxford University Press}, 27 | address = {Oxford}, 28 | volume=1, 29 | year = 2004 30 | } 31 | 32 | @book{Goo93, 33 | author = "Goossens, Michel and Mittelbach, Frank and Samarin, Alexander", 34 | title = "The LaTeX Companion", 35 | year = "1993", 36 | publisher = "Addison-Wesley", 37 | address = "Reading, Massachusetts" 38 | } 39 | -------------------------------------------------------------------------------- /test/new/extra_auto_labels.html: -------------------------------------------------------------------------------- 1 | 2 |

1.   Main Section

3 |

Here is a reference to Section 1#2, 4 | or using a shorthand, to Section 1#2 which 5 | is the same as this reference 1#2. 6 | Perhaps you just want the label text 1#1? 7 |

8 |

Let's set a special label for sub-sections 9 |

10 |

1#1.   header11

11 |

1#2.   header12

12 |

header1201?

13 |

2.   header2

14 |

2#1.   header 2.1

15 |

2.1.1.   header 2.1.1

-------------------------------------------------------------------------------- /test/tests/extra_auto_labels.html: -------------------------------------------------------------------------------- 1 | 2 |

1.   Main Section

3 |

Here is a reference to Section 1#2, 4 | or using a shorthand, to Section 1#2 which 5 | is the same as this reference 1#2. 6 | Perhaps you just want the label text 1#1? 7 |

8 |

Let's set a special label for sub-sections 9 |

10 |

1#1.   header11

11 |

1#2.   header12

12 |

header1201?

13 |

2.   header2

14 |

2#1.   header 2.1

15 |

2.1.1.   header 2.1.1

-------------------------------------------------------------------------------- /contrib/templates/example.bib: -------------------------------------------------------------------------------- 1 | @BOOK{ Knuth:TeX, 2 | author = "Knuth, Donald E.", 3 | title = "The {T}e{X} book", 4 | publisher= "Addison-Wesley", 5 | year = 1984 6 | } 7 | 8 | @BOOK{ Lamport:LaTeX, 9 | author = "Lamport, Leslie", 10 | title = "{LaTeX}: A Document Preparation System (2nd Edition)", 11 | publisher = "Addison-Wesley", 12 | year = 1994, 13 | note = "See also \cite{Knuth:TeX}." 14 | } 15 | 16 | @INBOOK{ Grandstrand, 17 | author = {O. Grandstrand}, 18 | title = {Innovation and Intellectual Property Rights}, 19 | chapter = 10, 20 | crossref = {Fberg04} 21 | } 22 | 23 | @BOOK{ Fberg04, 24 | editor = {J. Fagerberg and D.C. Mowery and R.R. Nelson}, 25 | title = {Oxford Handbook of Innovation}, 26 | booktitle = {Oxford Handbook of Innovation}, 27 | publisher = {Oxford University Press}, 28 | address = {Oxford}, 29 | volume = 1, 30 | year = 2004 31 | } 32 | 33 | @BOOK{Goo93, 34 | author = "Goossens, Michel and Mittelbach, Frank and Samarin, Alexander", 35 | title = "The LaTeX Companion", 36 | year = "1993", 37 | publisher = "Addison-Wesley", 38 | address = "Reading, Massachusetts" 39 | } 40 | -------------------------------------------------------------------------------- /styles/bootstrap.mdk: -------------------------------------------------------------------------------- 1 | Version : 3.2.0 2 | Theme : 3 | Bootstrap Url : https://maxcdn.bootstrapcdn.com/bootstrap/&version;/ 4 | Bootswatch Url: https://maxcdn.bootstrapcdn.com/bootswatch/&version;/&theme;/bootstrap.min.css 5 | Css : &bootstrap-url;css/bootstrap.min.css 6 | Css : &bootstrap-url;css/bootstrap-theme.min.css 7 | Css : &bootswatch-url; 8 | Html Meta : http-equiv="X-UA-Compatible" content="IE=edge" 9 | Html Meta : name="viewport" content="width=device-width, initial-scale=1" 10 | Heading Depth : 0 11 | Toc Depth : 2 12 | Html Header : 13 | 17 | 24 | Html Footer : 25 | 26 | -------------------------------------------------------------------------------- /test/new/extra_ski.text: -------------------------------------------------------------------------------- 1 | Title : SKI combinator example 2 | Heading Base: 2 3 | 4 | Comment: SKI combinator example. Because we cannot describe proper nested parenthesis 5 | in a regular expression, we encode this up to a certain depth. An argument 6 | with a maximal nesting depth of 4 can be defined as: 7 | 8 | arg0 : [^()] 9 | arg1 : (?:&arg0;|\(&arg0;+\)) 10 | arg2 : (?:&arg0;|\(&arg1;+\)) 11 | arg3 : (?:&arg0;|\(&arg2;+\)) 12 | arg4 : (?:&arg0;|\(&arg3;+\)) 13 | arg : &arg4; 14 | 15 | Comment: Then, we encode SKI evaluation using the following rules. 16 | The first rule removes initial parenthesis, the next three the SKI combinators, 17 | and the last rule skips initial evaluated terms. 18 | 19 | ~ski: replace="/^\(((?:&arg;)+)\)(.*)$/[\1\2]{.ski}/" 20 | replace="/^I(&arg;)(.*)$/[\1\2]{.ski}/" 21 | replace="/^K(&arg;)(&arg;)(.*)$/[\1\3]{.ski}/" 22 | replace="/^S(&arg;)(&arg;)(&arg;)(.*)$/[\1\3(\2\3)\4]{.ski}/" 23 | replace="/^([^IKS(\[])(.*)$/\1[\2]{.ski}/" 24 | 25 | ~skishow: replace="`&source;` evaluates to '[&source;]{.ski}'" 26 | 27 | # Examples 28 | 29 | This example encodes SKI combinator logic. 30 | Here we reverse α and β where [S(K(SI))Kαβ]{.skishow} 31 | -------------------------------------------------------------------------------- /test/tests/extra_ski.text: -------------------------------------------------------------------------------- 1 | Title : SKI combinator example 2 | MathJax : True 3 | Heading Base: 2 4 | 5 | Comment: SKI combinator example. Because we cannot describe proper nested parenthesis 6 | in a regular expression, we encode this up to a certain depth. An argument 7 | with a maximal nesting depth of 4 can be defined as: 8 | 9 | arg0 : [^()] 10 | arg1 : (?:#arg0|\(#arg0+\)) 11 | arg2 : (?:#arg0|\(#arg1+\)) 12 | arg3 : (?:#arg0|\(#arg2+\)) 13 | arg4 : (?:#arg0|\(#arg3+\)) 14 | arg : #arg4 15 | 16 | Comment: Then, we encode SKI evaluation using the following rules. 17 | The first rule removes initial parenthesis, the next three the SKI combinators, 18 | and the last rule skips initial evaluated terms. 19 | 20 | ~ski: replace="/^\(((?:#arg)+)\)(.*)$/[\1\2]{.ski}/" 21 | replace="/^I(#arg)(.*)$/[\1\2]{.ski}/" 22 | replace="/^K(#arg)(#arg)(.*)$/[\1\3]{.ski}/" 23 | replace="/^S(#arg)(#arg)(#arg)(.*)$/[\1\3(\2\3)\4]{.ski}/" 24 | replace="/^([^IKS(\[])(.*)$/\1[\2]{.ski}/" 25 | 26 | ~skishow: replace="`#source` evaluates to '[#source]{.ski}'" 27 | 28 | # Examples 29 | 30 | This example encodes SKI combinator logic. 31 | Here we reverse α and β where [S(K(SI))Kαβ]{.skishow} 32 | -------------------------------------------------------------------------------- /web/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "madoko.net", 3 | "author": "Daan Leijen, Microsoft Corp.", 4 | "version": "1.2.0", 5 | "homepage": "http://madoko.codeplex.com", 6 | "description": "Madoko is a fast scholarly Markdown processor written in Koka", 7 | "licenses": [ 8 | { 9 | "type": "Apache License 2.0", 10 | "url": "http://www.apache.org/licenses/LICENSE-2.0.html" 11 | } 12 | ], 13 | "keywords": [ 14 | "Madoko", 15 | "Markdown", 16 | "LaTeX", 17 | "Koka", 18 | "Microsoft", 19 | "Scholarly", 20 | "Academic" 21 | ], 22 | "engines": { 23 | "node": ">=0.10.0" 24 | }, 25 | "dependencies": { 26 | "amdefine": ">=0.0.4", 27 | "requirejs": ">=2.1", 28 | "request": ">=2", 29 | "mkdirp": "^0.3.5" 30 | }, 31 | "devDependencies": { 32 | "jake": ">=0.7.6", 33 | "express": "=4.1.1", 34 | "body-parser": "=1.0.2", 35 | "cookie-session": "=1.0.2", 36 | "rimraf": ">=2.2.8", 37 | "recursive-readdir": ">=1.2.0", 38 | "minimatch": ">=2.0.1", 39 | "compression": ">=1.6.0", 40 | "commander": ">=2.8.1" 41 | }, 42 | "repository": { 43 | "type": "hg", 44 | "url": "https://hg.codeplex.com/madoko" 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /test/new/main.html: -------------------------------------------------------------------------------- 1 |

A heading

Just a note, I've found that I can't test my markdown parser vs others. For example, both markdown.js and showdown code blocks in lists wrong. They're also completely inconsistent with regards to paragraphs in list items.

A link. Not anymore.

  • List Item 1

  • List Item 2

    • New List Item 1 Hi, this is a list item.
    • New List Item 2 Another item
      Code goes here.
      3 | Lots of it...
    • New List Item 3 The last item
  • List Item 3 The final item.

  • List Item 4 The real final item.

Paragraph.

  • bq Item 1
  • bq Item 2
    • New bq Item 1
    • New bq Item 2 Text here

Another blockquote! I really need to get more creative with mockup text.. markdown.js breaks here again

Another Heading

Hello world. Here is a link. And an image alt.

Code goes here.
4 | Lots of it...
5 | -------------------------------------------------------------------------------- /test/tests/main.html: -------------------------------------------------------------------------------- 1 |

A heading

Just a note, I've found that I can't test my markdown parser vs others. For example, both markdown.js and showdown code blocks in lists wrong. They're also completely inconsistent with regards to paragraphs in list items.

A link. Not anymore.

  • List Item 1

  • List Item 2

    • New List Item 1 Hi, this is a list item.
    • New List Item 2 Another item
      Code goes here.
      3 | Lots of it...
    • New List Item 3 The last item
  • List Item 3 The final item.

  • List Item 4 The real final item.

Paragraph.

  • bq Item 1
  • bq Item 2
    • New bq Item 1
    • New bq Item 2 Text here

Another blockquote! I really need to get more creative with mockup text.. markdown.js breaks here again

Another Heading

Hello world. Here is a link. And an image alt.

Code goes here.
4 | Lots of it...
5 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "madoko", 3 | "author": "Daan Leijen, Microsoft Corp.", 4 | "version": "1.2.3", 5 | "homepage": "http://madoko.codeplex.com", 6 | "description": "Madoko is a fast scholarly Markdown processor written in Koka", 7 | "licenses": [ 8 | { 9 | "type": "Apache License 2.0", 10 | "url": "http://www.apache.org/licenses/LICENSE-2.0.html" 11 | } 12 | ], 13 | "keywords": [ 14 | "Madoko", 15 | "Markdown", 16 | "LaTeX", 17 | "Koka", 18 | "Microsoft", 19 | "Scholarly", 20 | "Academic" 21 | ], 22 | "preferGlobal": true, 23 | "main": "./lib/madoko.js", 24 | "bin": { 25 | "madoko": "./lib/cli.js" 26 | }, 27 | "directories": { 28 | "lib": "./lib", 29 | "doc": "./doc" 30 | }, 31 | "files": [ 32 | "lib", 33 | "styles", 34 | "Jakefile.js", 35 | "readme.md", 36 | "license.txt" 37 | ], 38 | "engines": { 39 | "node": ">=0.10.0" 40 | }, 41 | "dependencies": { 42 | "amdefine": "^1.0.1", 43 | "mkdirp": "^0.3.5", 44 | "requirejs": "^2.3.6", 45 | "rimraf": "^3.0.1" 46 | }, 47 | "devDependencies": { 48 | "jake": ">=0.7.6" 49 | }, 50 | "repository": { 51 | "type": "hg", 52 | "url": "https://github.com/koka-lang/madoko" 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /doc/reference.js: -------------------------------------------------------------------------------- 1 | function initTOC() { 2 | var toc = document.getElementById('toc'); 3 | if (toc == null) return; 4 | var tocHeader = document.getElementById('toc-header'); 5 | if (tocHeader== null) return; 6 | 7 | var tocToggle = document.getElementById('toc-toggle'); 8 | if (tocToggle==null) { 9 | tocHeader.innerHTML = "" + tocHeader.innerHTML; 10 | tocToggle = document.getElementById('toc-toggle'); 11 | } 12 | if (tocToggle==null) return; 13 | 14 | function showToc() { 15 | toc.style.display = 'block'; 16 | if (tocToggle){ 17 | tocToggle.innerHTML = '▼' 18 | tocToggle.style.fontSize = 'medium' 19 | } 20 | } 21 | function hideToc() { 22 | toc.style.display = 'none'; 23 | if (tocToggle) { 24 | tocToggle.innerHTML = '▶'; 25 | tocToggle.style.fontSize = 'medium'; 26 | } 27 | } 28 | function switchToc() { 29 | (toc.style.display != 'none' ? hideToc() : showToc()); 30 | } 31 | 32 | if (tocHeader) { 33 | tocHeader.onclick = switchToc; 34 | tocHeader.style.cursor = "pointer"; 35 | } 36 | hideToc() 37 | } 38 | 39 | document.addEventListener("DOMContentLoaded", function(event) { 40 | initTOC(); 41 | }); 42 | -------------------------------------------------------------------------------- /test/new/main.text: -------------------------------------------------------------------------------- 1 | [test]: http://google.com/ "Google" 2 | 3 | # A heading 4 | 5 | Just a note, I've found that I can't test my markdown parser vs others. 6 | For example, both markdown.js and showdown code blocks in lists wrong. They're 7 | also completely [inconsistent][test] with regards to paragraphs in list items. 8 | 9 | A link. Not anymore. 10 | 11 | 13 | 14 | * List Item 1 15 | 16 | * List Item 2 17 | * New List Item 1 18 | Hi, this is a list item. 19 | * New List Item 2 20 | Another item 21 | Code goes here. 22 | Lots of it... 23 | * New List Item 3 24 | The last item 25 | 26 | * List Item 3 27 | The final item. 28 | 29 | * List Item 4 30 | The real final item. 31 | 32 | Paragraph. 33 | 34 | > * bq Item 1 35 | > * bq Item 2 36 | > * New bq Item 1 37 | > * New bq Item 2 38 | > Text here 39 | 40 | * * * 41 | 42 | > Another blockquote! 43 | > I really need to get 44 | > more creative with 45 | > mockup text.. 46 | > markdown.js breaks here again 47 | 48 | Another Heading 49 | ------------- 50 | 51 | Hello *world*. Here is a [link](//hello). 52 | And an image ![alt](src). 53 | 54 | Code goes here. 55 | Lots of it... 56 | -------------------------------------------------------------------------------- /test/tests/main.text: -------------------------------------------------------------------------------- 1 | [test]: http://google.com/ "Google" 2 | 3 | # A heading 4 | 5 | Just a note, I've found that I can't test my markdown parser vs others. 6 | For example, both markdown.js and showdown code blocks in lists wrong. They're 7 | also completely [inconsistent][test] with regards to paragraphs in list items. 8 | 9 | A link. Not anymore. 10 | 11 | 13 | 14 | * List Item 1 15 | 16 | * List Item 2 17 | * New List Item 1 18 | Hi, this is a list item. 19 | * New List Item 2 20 | Another item 21 | Code goes here. 22 | Lots of it... 23 | * New List Item 3 24 | The last item 25 | 26 | * List Item 3 27 | The final item. 28 | 29 | * List Item 4 30 | The real final item. 31 | 32 | Paragraph. 33 | 34 | > * bq Item 1 35 | > * bq Item 2 36 | > * New bq Item 1 37 | > * New bq Item 2 38 | > Text here 39 | 40 | * * * 41 | 42 | > Another blockquote! 43 | > I really need to get 44 | > more creative with 45 | > mockup text.. 46 | > markdown.js breaks here again 47 | 48 | Another Heading 49 | ------------- 50 | 51 | Hello *world*. Here is a [link](//hello). 52 | And an image ![alt](src). 53 | 54 | Code goes here. 55 | Lots of it... 56 | -------------------------------------------------------------------------------- /test/new/extra_attributes.text: -------------------------------------------------------------------------------- 1 | # header test { .heading } 2 | 3 | This tests attributes of 'Markdown Extra'. 4 | We can mark most block elements using braced attributes. 5 | 6 | Like in a line header { .myheading } 7 | ----------------------------- 8 | 9 | ## header with {braces} { .myheading .other } 10 | 11 | ## header with {braces} ## { .myheading #header3 } 12 | 13 | ```javascript { #jscode-example } 14 | var x = 1 15 | ``` 16 | 17 | Here is a [top link][toplink] for use in frames. 18 | And a [link][mylink] by reference. 19 | 20 | [mylink]: http://foo.com { #mylink2 } 21 | [toplink]: http://foo.com { target=_top #mylink } 22 | 23 | --------- { width=50% } 24 | 25 | We can also attribute tables: 26 | 27 | A | B | C 28 | --- | --- | --- 29 | a | b | c 30 | { #table-id1 } 31 | 32 | Or like this 33 | 34 | | A | B | C | 35 | | --- | --- | --- | 36 | | a | b | c | 37 | { #table-id2 } 38 | 39 | 40 | * we can attribute 41 | * a list too 42 | {#listid} 43 | 44 | > an attributed 45 | > block quote 46 | {#blockquote} 47 | 48 | We can mark any paragraph 49 | now with attributes. 50 | {#id} 51 | 52 | {We can start paragraphs with braces} 53 | {and it will be fine} to use braces 54 | as part of a paragraph 55 | 56 | Or we can 57 | \{escape to end with braces if we want} 58 | -------------------------------------------------------------------------------- /test/tests/extra_attributes.text: -------------------------------------------------------------------------------- 1 | # header test { .heading } 2 | 3 | This tests attributes of 'Markdown Extra'. 4 | We can mark most block elements using braced attributes. 5 | 6 | Like in a line header { .myheading } 7 | ----------------------------- 8 | 9 | ## header with {braces} { .myheading .other } 10 | 11 | ## header with {braces} ## { .myheading #header3 } 12 | 13 | ```javascript { #jscode-example } 14 | var x = 1 15 | ``` 16 | 17 | Here is a [top link][toplink] for use in frames. 18 | And a [link][mylink] by reference. 19 | 20 | [mylink]: http://foo.com { #mylink2 } 21 | [toplink]: http://foo.com { target=_top #mylink } 22 | 23 | --------- { width=50% } 24 | 25 | We can also attribute tables: 26 | 27 | A | B | C 28 | --- | --- | --- 29 | a | b | c 30 | { #table-id1 } 31 | 32 | Or like this 33 | 34 | | A | B | C | 35 | | --- | --- | --- | 36 | | a | b | c | 37 | { #table-id2 } 38 | 39 | 40 | * we can attribute 41 | * a list too 42 | {#listid} 43 | 44 | > an attributed 45 | > block quote 46 | {#blockquote} 47 | 48 | We can mark any paragraph 49 | now with attributes. 50 | {#id} 51 | 52 | {We can start paragraphs with braces} 53 | {and it will be fine} to use braces 54 | as part of a paragraph 55 | 56 | Or we can 57 | \{escape to end with braces if we want} 58 | -------------------------------------------------------------------------------- /test/new/extra_fib.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Examples 7 | 8 | 17 | 20 | 21 | 22 | 23 | 24 | 25 |

1.   Examples

yyyyyyyy 26 |

Some UPPER CASE TEXT and more. 27 | Here is an image monarch. 28 |

29 | 30 | 31 | -------------------------------------------------------------------------------- /test/tests/extra_fib.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Examples 7 | 8 | 17 | 20 | 21 | 22 | 23 | 24 | 25 |

1.   Examples

yyyyyyyy 26 |

Some UPPER CASE TEXT and more. 27 | Here is an image monarch. 28 |

29 | 30 | 31 | -------------------------------------------------------------------------------- /test/new/extra_auto_counters.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |

1.   header1

4 |

Here is a reference to Section 1, 5 | or using a shorthand, to Section 1.2 which 6 | is the same as this reference 1.2. 7 | Perhaps you just want the label text 2.1.1? 8 |

9 |

1.1.   header11

10 |

1.2.   header12

11 |

header1201?

12 |

2.   header2

13 |

2.1.   header 2.1

14 |

2.1.1.   header 2.1.1

-------------------------------------------------------------------------------- /test/tests/extra_auto_counters.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |

1.   header1

4 |

Here is a reference to Section 1, 5 | or using a shorthand, to Section 1.2 which 6 | is the same as this reference 1.2. 7 | Perhaps you just want the label text 2.1.1? 8 |

9 |

1.1.   header11

10 |

1.2.   header12

11 |

header1201?

12 |

2.   header2

13 |

2.1.   header 2.1

14 |

2.1.1.   header 2.1.1

-------------------------------------------------------------------------------- /src/process.kk: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2013 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | module process 9 | 10 | import std/path 11 | import std/dict 12 | 13 | external include { 14 | cs file "process-inline.cs" 15 | js file "process-inline.js" 16 | } 17 | 18 | external import { 19 | js "child_process" 20 | } 21 | 22 | // quote file and command names for shell execution 23 | public function quote( s : string ) : string { 24 | "\"" + s + "\"" 25 | } 26 | 27 | public function system( cmd : string, callback : (int,string,string) -> (), timeout : int = 0, cwd : string = "", env : list<(string,string)> = []) : () { 28 | systemx(cmd,callback,timeout,cwd,if (env.isNil) then Nothing else Just(dict(env))) 29 | } 30 | 31 | external systemx( cmd : string, callback : (int,string,string) -> (), timeout : int = 0, cwd : string = "", env : maybe> = Nothing ) : () { 32 | cs inline "ShellCommand.system(#1,#2,#3,#4)" // TODO: environment 33 | js inline "system_exec(#1,#2,#3,#4,#5)" 34 | } 35 | -------------------------------------------------------------------------------- /test/original/links_reference_style.html: -------------------------------------------------------------------------------- 1 |

Foo bar.

2 | 3 |

Foo bar.

4 | 5 |

Foo bar.

6 | 7 |

With embedded [brackets].

8 | 9 |

Indented once.

10 | 11 |

Indented twice.

12 | 13 |

Indented thrice.

14 | 15 |

Indented [four][] times.

16 | 17 |
[four]: /url
18 | 
19 | 20 |
21 | 22 |

this should work

23 | 24 |

So should this.

25 | 26 |

And this.

27 | 28 |

And this.

29 | 30 |

And this.

31 | 32 |

But not [that] [].

33 | 34 |

Nor [that][].

35 | 36 |

Nor [that].

37 | 38 |

[Something in brackets like this should work]

39 | 40 |

[Same with this.]

41 | 42 |

In this case, this points to something else.

43 | 44 |

Backslashing should suppress [this] and [this].

45 | 46 |
47 | 48 |

Here's one where the link 49 | breaks across lines.

50 | 51 |

Here's another where the link 52 | breaks across lines, but with a line-ending space.

53 | -------------------------------------------------------------------------------- /test/tests/links_reference_style.html: -------------------------------------------------------------------------------- 1 |

Foo bar.

2 | 3 |

Foo bar.

4 | 5 |

Foo bar.

6 | 7 |

With embedded [brackets].

8 | 9 |

Indented once.

10 | 11 |

Indented twice.

12 | 13 |

Indented thrice.

14 | 15 |

Indented [four][] times.

16 | 17 |
[four]: /url
18 | 
19 | 20 |
21 | 22 |

this should work

23 | 24 |

So should this.

25 | 26 |

And this.

27 | 28 |

And this.

29 | 30 |

And this.

31 | 32 |

But not [that] [].

33 | 34 |

Nor [that][].

35 | 36 |

Nor [that].

37 | 38 |

[Something in brackets like this should work]

39 | 40 |

[Same with this.]

41 | 42 |

In this case, this points to something else.

43 | 44 |

Backslashing should suppress [this] and [this].

45 | 46 |
47 | 48 |

Here's one where the link 49 | breaks across lines.

50 | 51 |

Here's another where the link 52 | breaks across lines, but with a line-ending space.

53 | -------------------------------------------------------------------------------- /test/new/gfm_tables.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
Heading 1Heading 2
Cell 1Cell 2
Cell 3Cell 4
10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
Header 1Header 2Header 3Header 4
Cell 1Cell 2Cell 3Cell 4
Cell 5Cell 6Cell 7Cell 8
19 |
Test code
20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
Header 1Header 2
Cell 1Cell 2
Cell 3Cell 4
29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 |
Header 1Header 2Header 3Header 4
Cell 1Cell 2Cell 3Cell 4
Cell 5Cell 6Cell 7Cell 8
38 | 39 | -------------------------------------------------------------------------------- /test/tests/gfm_tables.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
Heading 1Heading 2
Cell 1Cell 2
Cell 3Cell 4
10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
Header 1Header 2Header 3Header 4
Cell 1Cell 2Cell 3Cell 4
Cell 5Cell 6Cell 7Cell 8
19 |
Test code
20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 |
Header 1Header 2
Cell 1Cell 2
Cell 3Cell 4
29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 |
Header 1Header 2Header 3Header 4
Cell 1Cell 2Cell 3Cell 4
Cell 5Cell 6Cell 7Cell 8
38 | 39 | -------------------------------------------------------------------------------- /test/new/extra_things.text: -------------------------------------------------------------------------------- 1 | Title : Examples 2 | XScript : https://google-code-prettify.googlecode.com/svn/loader/run_prettify.js?lang=scm&lang=latex 3 | Heading Base: 2 4 | 5 | ~pre : .prettyprint .linenums 6 | .upper : replace='/^[\s\S]*$/\U\0\E and more/c' 7 | .fib : replace='/^x?$/y/' replace='/xx(x*)/[x\1]{.fib}[\1]{.fib}/' notag 8 | 9 | Highlight Language : ../test/new/xjavascript.js 10 | 11 | 16 | 17 | # Examples 18 | 19 | Fibonacci of 6 is how many y's? 20 | [xxxxxx]{.fib} 21 | 22 | Some [Upper case text]{.upper}. 23 | Here is an image ![monarch]. 24 | 25 | [monarch]: ../butterfly.png { width=2cm vertical-align=middle } 26 | 27 | ~ Framed {text-align=center tight} 28 | framed text 29 | ~ 30 | 31 | 32 | ``` xjavascript 33 | function hello() { 34 | alert("hello world") 35 | < > & 36 | } 37 | ``` 38 | 39 | ``` javascript 40 | function hello() { 41 | alert("hello world") 42 | < > & 43 | } 44 | ``` 45 | 46 | And indented 47 | 48 | function hello() { 49 | alert("hello world") 50 | } 51 | 52 | ``` tex 53 | \begin{itemize} 54 | \item Some \textbf{latex} code. 55 | \item Good for math $2\sin$. 56 | \item But a horrible macro language :-(. 57 | \end{itemize} 58 | ``` 59 | 60 | ``` lisp 61 | (def lazy-fib (concat [0 1] ((fn rfib [a b] (lazy-cons (+ a b) (rfib b (+ a b)))) 0 1))) 62 | ``` 63 | -------------------------------------------------------------------------------- /test/new/anatomy.text: -------------------------------------------------------------------------------- 1 | Title : Anatomy book examples 2 | Heading Base: 2 3 | ~dl,.test : border-left-style=solid border-color=Blue border-width=10px padding-left=5px 4 | 5 | # Expressions, Syntax, and Evaluation {#Chapter1} 6 | 7 | This chapter introduces three fundamental concepts in programming 8 | languages: *expressions*, *syntax* and *evaluation*. These concepts are 9 | illustrated by a simple language of arithmetic expressions. 10 | {data-tag=Expr2} 11 | 12 | expression 13 | ~ An *expression* is a combination of variables, values 14 | and operations over these values. For example, the arithmetic expression `2+3` 15 | uses two numeric values `2` and `3` and an operation `+` that operates on 16 | numeric values. 17 | syntax 18 | ~ The *syntax* of an expression prescribes how the various 19 | components of the expressions can be combined. In general it is not the case that 20 | the components of expressions can be combined arbitrarily: they must obey certain 21 | rules. For example `2 3` or `+ +` are not valid arithmetic expressions. 22 | evaluation 23 | ~ Each expression has a meaning (or value), which is defined by the 24 | *evaluation* of that expression. Evaluation is a process where expressions 25 | composed of various components get simplified until eventually we get a value. 26 | For example evaluating `2 + 3` results in `5`. 27 | {data-tag=Expr3} 28 | 29 | Here is a paragraph 30 | 31 | * and 32 | * a 33 | * list 34 | 35 | Test -------------------------------------------------------------------------------- /support/madoko-local/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "madoko-local", 3 | "author": "Daan Leijen, Microsoft Research", 4 | "version": "0.9.4", 5 | "homepage": "http://madoko.codeplex.com", 6 | "description": "Madoko-Local provides local disk access to Madoko.net", 7 | "licenses": [ 8 | { 9 | "type": "Apache License 2.0", 10 | "url": "http://www.apache.org/licenses/LICENSE-2.0.html" 11 | } 12 | ], 13 | "keywords": [ 14 | "Madoko", 15 | "Markdown", 16 | "LaTeX", 17 | "Koka", 18 | "Microsoft", 19 | "Scholarly", 20 | "Academic", 21 | "Local" 22 | ], 23 | "preferGlobal": true, 24 | "main": "./src/cli.js", 25 | "bin": { 26 | "madoko-local": "./src/cli.js" 27 | }, 28 | "directories": { 29 | "bin": "./src" 30 | }, 31 | "files": [ 32 | "src", 33 | "static", 34 | "readme.md", 35 | "license.txt" 36 | ], 37 | "engines": { 38 | "node": ">=0.10.0" 39 | }, 40 | "dependencies": { 41 | "amdefine": ">=0.0.4", 42 | "requirejs": ">=2.1", 43 | "mkdirp": ">=1.0.0", 44 | "rimraf": ">=2.4.4", 45 | "mime": ">=1.3.4", 46 | "commander": ">=2.8.1", 47 | "express": ">=4.1.1", 48 | "body-parser": ">=1.0.2", 49 | "cookie-session": "=1.0.2", 50 | "os-homedir": ">=1.0.0", 51 | "open": ">=0.0.5" 52 | }, 53 | "devDependencies": { 54 | "jake": ">=0.7.6" 55 | }, 56 | "repository": { 57 | "type": "hg", 58 | "url": "https://hg.codeplex.com/madoko" 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /contrib/typo/license.txt: -------------------------------------------------------------------------------- 1 | Copyright (c) 2011, Christopher Finke 2 | All rights reserved. 3 | 4 | Redistribution and use in source and binary forms, with or without 5 | modification, are permitted provided that the following conditions are met: 6 | * Redistributions of source code must retain the above copyright 7 | notice, this list of conditions and the following disclaimer. 8 | * Redistributions in binary form must reproduce the above copyright 9 | notice, this list of conditions and the following disclaimer in the 10 | documentation and/or other materials provided with the distribution. 11 | * The name of the author may not be used to endorse or promote products 12 | derived from this software without specific prior written permission. 13 | 14 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 15 | ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 16 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 17 | DISCLAIMED. IN NO EVENT SHALL THE AUTHOR FINKE BE LIABLE FOR ANY 18 | DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 19 | (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 20 | LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 21 | ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 23 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -------------------------------------------------------------------------------- /test/new/extra_ski.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SKI combinator example 7 | 8 | 17 | 20 | 21 | 22 | 23 | 24 | 25 |

1.   Examples

26 |

This example encodes SKI combinator logic. 27 | Here we reverse α and β where S(K(SI))Kαβ evaluates to ‘βα 28 |

29 | 30 | 31 | -------------------------------------------------------------------------------- /test/tests/extra_ski.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | SKI combinator example 7 | 8 | 17 | 20 | 21 | 22 | 23 | 24 | 25 |

1.   Examples

26 |

This example encodes SKI combinator logic. 27 | Here we reverse α and β where S(K(SI))Kαβ evaluates to ‘βα 28 |

29 | 30 | 31 | -------------------------------------------------------------------------------- /src/process-inline.js: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2013-2015 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | 9 | function system_exec(cmds, callback, timeout, cwd, env) { 10 | //js inline "child_process.exec(#1,{timeout:#3,cwd:(#4!=''?#4:undefined),env:(#5?(#5).unJust:undefined),windowsVerbatimArguments:true},function(err,stdout,stderr) { (#2)(err?err.code:0,stdout,stderr); });" 11 | // console.log("systemx exec: " + cmds); 12 | var options = { 13 | timeout: timeout, 14 | cwd: (cwd!=''?cwd:undefined), 15 | env: (env?(env).unJust:undefined), 16 | windowsVerbatimArguments: true, 17 | }; 18 | var allout = ""; 19 | var allerr = ""; 20 | var lasterr = 0; 21 | var commands = cmds.split(";"); 22 | var count = commands.length; 23 | var i; 24 | for(i = 0; i < count; i++) { 25 | var cmd = commands[i]; 26 | // console.log(" exec: " + cmd); 27 | child_process.exec(cmd, options, function(err,stdout,stderr) { 28 | allout += stdout + "\n"; 29 | allerr += stderr + "\n"; 30 | if (err) lasterr = err.code; 31 | count--; 32 | if (count<=0) { 33 | (callback)( lasterr, allout, allerr); 34 | } 35 | }); 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /test/new/extra_footnotes.html: -------------------------------------------------------------------------------- 1 | 2 |

This file tests support for footnotes in Markdown Extra. The output 3 | adheres to what John Gruber describes at Daring Fireball. 4 |

5 |

That's some text with a footnote.3 and 6 | another footnote 2, and a duplicate3. 7 |

8 |
9 |
10 | 11 |
    12 |
  1. 13 |

    And that's the footnote. 14 |

    15 |

    That's the second paragraph. 16 |

  2. 17 |
  3. 18 |

    More testing 19 |

    20 |
      21 |
    • with a 22 |
    • 23 |
    • list in it 4 24 |
    25 | 26 |

    And more text. 27 |

  4. 28 |
  5. 29 |

    Second definition overrides 30 |

    31 |
    32 | with code
    33 | in  it
    34 |

    And another paragraph 35 |

  6. 36 |
  7. 37 |

    And the last footnote 38 |

    39 |

    With another paragraph 40 |

-------------------------------------------------------------------------------- /test/tests/extra_footnotes.html: -------------------------------------------------------------------------------- 1 | 2 |

This file tests support for footnotes in Markdown Extra. The output 3 | adheres to what John Gruber describes at Daring Fireball. 4 |

5 |

That's some text with a footnote.3 and 6 | another footnote 2, and a duplicate3. 7 |

8 |
9 |
10 | 11 |
    12 |
  1. 13 |

    And that's the footnote. 14 |

    15 |

    That's the second paragraph. 16 |

  2. 17 |
  3. 18 |

    More testing 19 |

    20 |
      21 |
    • with a 22 |
    • 23 |
    • list in it 4 24 |
    25 | 26 |

    And more text. 27 |

  4. 28 |
  5. 29 |

    Second definition overrides 30 |

    31 |
    32 | with code
    33 | in  it
    34 |

    And another paragraph 35 |

  6. 36 |
  7. 37 |

    And the last footnote 38 |

    39 |

    With another paragraph 40 |

-------------------------------------------------------------------------------- /test/original/ordered_and_unordered_lists.text: -------------------------------------------------------------------------------- 1 | ## Unordered 2 | 3 | Asterisks tight: 4 | 5 | * asterisk 1 6 | * asterisk 2 7 | * asterisk 3 8 | 9 | 10 | Asterisks loose: 11 | 12 | * asterisk 1 13 | 14 | * asterisk 2 15 | 16 | * asterisk 3 17 | 18 | * * * 19 | 20 | Pluses tight: 21 | 22 | + Plus 1 23 | + Plus 2 24 | + Plus 3 25 | 26 | 27 | Pluses loose: 28 | 29 | + Plus 1 30 | 31 | + Plus 2 32 | 33 | + Plus 3 34 | 35 | * * * 36 | 37 | 38 | Minuses tight: 39 | 40 | - Minus 1 41 | - Minus 2 42 | - Minus 3 43 | 44 | 45 | Minuses loose: 46 | 47 | - Minus 1 48 | 49 | - Minus 2 50 | 51 | - Minus 3 52 | 53 | 54 | ## Ordered 55 | 56 | Tight: 57 | 58 | 1. First 59 | 2. Second 60 | 3. Third 61 | 62 | and: 63 | 64 | 1. One 65 | 2. Two 66 | 3. Three 67 | 68 | 69 | Loose using tabs: 70 | 71 | 1. First 72 | 73 | 2. Second 74 | 75 | 3. Third 76 | 77 | and using spaces: 78 | 79 | 1. One 80 | 81 | 2. Two 82 | 83 | 3. Three 84 | 85 | Multiple paragraphs: 86 | 87 | 1. Item 1, graf one. 88 | 89 | Item 2. graf two. The quick brown fox jumped over the lazy dog's 90 | back. 91 | 92 | 2. Item 2. 93 | 94 | 3. Item 3. 95 | 96 | 97 | 98 | ## Nested 99 | 100 | * Tab 101 | * Tab 102 | * Tab 103 | 104 | Here's another: 105 | 106 | 1. First 107 | 2. Second: 108 | * Fee 109 | * Fie 110 | * Foe 111 | 3. Third 112 | 113 | Same thing but with paragraphs: 114 | 115 | 1. First 116 | 117 | 2. Second: 118 | * Fee 119 | * Fie 120 | * Foe 121 | 122 | 3. Third 123 | 124 | 125 | This was an error in Markdown 1.0.1: 126 | 127 | * this 128 | 129 | * sub 130 | 131 | that 132 | -------------------------------------------------------------------------------- /test/tests/ordered_and_unordered_lists.text: -------------------------------------------------------------------------------- 1 | ## Unordered 2 | 3 | Asterisks tight: 4 | 5 | * asterisk 1 6 | * asterisk 2 7 | * asterisk 3 8 | 9 | 10 | Asterisks loose: 11 | 12 | * asterisk 1 13 | 14 | * asterisk 2 15 | 16 | * asterisk 3 17 | 18 | * * * 19 | 20 | Pluses tight: 21 | 22 | + Plus 1 23 | + Plus 2 24 | + Plus 3 25 | 26 | 27 | Pluses loose: 28 | 29 | + Plus 1 30 | 31 | + Plus 2 32 | 33 | + Plus 3 34 | 35 | * * * 36 | 37 | 38 | Minuses tight: 39 | 40 | - Minus 1 41 | - Minus 2 42 | - Minus 3 43 | 44 | 45 | Minuses loose: 46 | 47 | - Minus 1 48 | 49 | - Minus 2 50 | 51 | - Minus 3 52 | 53 | 54 | ## Ordered 55 | 56 | Tight: 57 | 58 | 1. First 59 | 2. Second 60 | 3. Third 61 | 62 | and: 63 | 64 | 1. One 65 | 2. Two 66 | 3. Three 67 | 68 | 69 | Loose using tabs: 70 | 71 | 1. First 72 | 73 | 2. Second 74 | 75 | 3. Third 76 | 77 | and using spaces: 78 | 79 | 1. One 80 | 81 | 2. Two 82 | 83 | 3. Three 84 | 85 | Multiple paragraphs: 86 | 87 | 1. Item 1, graf one. 88 | 89 | Item 2. graf two. The quick brown fox jumped over the lazy dog's 90 | back. 91 | 92 | 2. Item 2. 93 | 94 | 3. Item 3. 95 | 96 | 97 | 98 | ## Nested 99 | 100 | * Tab 101 | * Tab 102 | * Tab 103 | 104 | Here's another: 105 | 106 | 1. First 107 | 2. Second: 108 | * Fee 109 | * Fie 110 | * Foe 111 | 3. Third 112 | 113 | Same thing but with paragraphs: 114 | 115 | 1. First 116 | 117 | 2. Second: 118 | * Fee 119 | * Fie 120 | * Foe 121 | 122 | 3. Third 123 | 124 | 125 | This was an error in Markdown 1.0.1: 126 | 127 | * this 128 | 129 | * sub 130 | 131 | that 132 | -------------------------------------------------------------------------------- /test/new/extra_things.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Examples 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 |

1.   Examples

15 |

Fibonacci of 6 is how many y's? 16 | yyyyyyyyyyyyy 17 |

18 |

Some UPPER CASE TEXT and more. 19 | Here is an image monarch. 20 |

21 |
framed text
22 |
23 | function hello() {
24 |     alert("hello world")
25 | }
26 |

And indented 27 |

28 |
29 | function hello() {
30 |     alert("hello world")
31 | }
32 |
33 | \begin{itemize}
34 | \item Some \textbf{latex} code.
35 | \item Good for math $2\sin$. 
36 | \item But a horrible macro language :-(.
37 | \end{itemize}
38 |
39 | (friends 'of '(parentheses))
40 | 41 | 42 | -------------------------------------------------------------------------------- /test/tests/extra_things.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Examples 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 |

1.   Examples

15 |

Fibonacci of 6 is how many y's? 16 | yyyyyyyyyyyyy 17 |

18 |

Some UPPER CASE TEXT and more. 19 | Here is an image monarch. 20 |

21 |
framed text
22 |
23 | function hello() {
24 |     alert("hello world")
25 | }
26 |

And indented 27 |

28 |
29 | function hello() {
30 |     alert("hello world")
31 | }
32 |
33 | \begin{itemize}
34 | \item Some \textbf{latex} code.
35 | \item Good for math $2\sin$. 
36 | \item But a horrible macro language :-(.
37 | \end{itemize}
38 |
39 | (friends 'of '(parentheses))
40 | 41 | 42 | -------------------------------------------------------------------------------- /src/runcsl.kk: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2015 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | module runcsl 9 | 10 | import std/path 11 | import texParser 12 | 13 | external import { 14 | js csl "./csl-madoko" 15 | } 16 | 17 | 18 | public struct fileinfo( 19 | filename: string, 20 | contents: string 21 | ) 22 | 23 | public struct citeinfo( 24 | id: string, 25 | lineinfo: string 26 | ) 27 | 28 | public struct cslresult( 29 | bibliography: string, 30 | bib : string, 31 | warnings : string, 32 | errors : string, 33 | citeformat : string 34 | ) 35 | 36 | 37 | public function runCsl( 38 | citations : list, bibs : list, bibstyle : fileinfo, 39 | madokoStyle : fileinfo, localeStyle : fileinfo, id : string, attrs0 : string ) : cslresult 40 | { 41 | val preid = if (id.bool) then id + ":" else "" 42 | val attrs = "data-style:'" + bibstyle.filename.stemname + "'; " + attrs0 43 | makeBiblX( citations.unlist, 44 | bibs.unlist, bibstyle, madokoStyle, localeStyle, 45 | fun(tex) { parseTex(tex) }, preid, attrs ) 46 | } 47 | 48 | external makeBiblX( citations : primarray, bibtexs: primarray, 49 | bibstyle : fileinfo, 50 | madokoStyle : fileinfo, localeStyle : fileinfo, 51 | convertTex : (string) -> string, 52 | pre: string, attrs : string ) : cslresult 53 | { 54 | js inline "csl.makeBibliography(#1,#2,#3,#4,#5,#6, {preid:#7,attrs:#8})" 55 | } 56 | -------------------------------------------------------------------------------- /support/madoko-local/src/date.js: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2015 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | 9 | if (typeof define !== 'function') { var define = require('amdefine')(module) } 10 | define([],function() { 11 | 12 | var rxISO = /^(\d\d\d\d)\-?(\d\d)\-?(\d\d)(?:T(\d\d):?(\d\d)(?:[:]?(\d\d)(?:[\.,](\d\d\d))?)?(?:Z|([\+\-])(\d\d)(?:[:]?(\d\d))?)?)?$/i; 13 | 14 | function dateFromISO(s) { 15 | function parseNum(n) { 16 | var i = parseInt(n,10); 17 | return (isNaN(i) ? undefined : i); 18 | } 19 | 20 | var utc = null; 21 | var cap = rxISO.exec( s.replace(/\s+/g, "") ); 22 | if (cap) { 23 | var utcx = new Date( Date.UTC( parseNum(cap[1]), parseNum(cap[2])-1, parseNum(cap[3]), 24 | parseNum(cap[4]), parseNum(cap[5]), parseNum(cap[6]), parseNum(cap[7]) ) ); 25 | if (utcx && !isNaN(utcx)) { 26 | utc = utcx; 27 | var tz = (cap[8]=="+" ? -1 : 1) * ((parseNum(cap[9])||0) * 60 + (parseNum(cap[10])||0)); 28 | if (tz !== 0) utc.setUTCMinutes( utc.getUTCMinutes + tz ); 29 | } 30 | } 31 | if (!utc) { 32 | console.log("dateFromISO: cannot convert: " + s); 33 | utc = new Date(0); 34 | } 35 | else if (utc.toISOString() !== s) { 36 | console.log( "dateFromISO: illegal conversion:\n original: " + s + "\n parsed : " + utc.toISOString()); 37 | } 38 | return utc; 39 | } 40 | 41 | return { 42 | dateFromISO: dateFromISO, 43 | }; 44 | }); -------------------------------------------------------------------------------- /src/texCommon.kk: -------------------------------------------------------------------------------- 1 | /*--------------------------------------------------------------------------- 2 | Copyright 2013 Microsoft Corporation. 3 | 4 | This is free software; you can redistribute it and/or modify it under the 5 | terms of the Apache License, Version 2.0. A copy of the License can be 6 | found in the file "license.txt" at the root of this distribution. 7 | ---------------------------------------------------------------------------*/ 8 | 9 | // Common TeX entities 10 | 11 | module texCommon 12 | 13 | import std/dict 14 | import std/regex 15 | import common 16 | 17 | public val texAccents = [ 18 | ("`","grave"), 19 | ("'","acute"), 20 | ("^","circ"), 21 | ("\"","uml"), 22 | ("~","tilde"), 23 | ("r","ring"), 24 | ("c","cedil"), 25 | ("v","caron"), 26 | ("u","breve"), 27 | ("=","macron"), 28 | ("k","ogonek"), 29 | (".","dota"), 30 | ("d","dotb"), 31 | ("H","huml"), 32 | ("b","barb"), 33 | ("r","ring"), 34 | ("t","tie"), 35 | ("G","dgrave"), 36 | ("H","dacute"), 37 | ].dict 38 | 39 | function texnest(s:string) = @"(?:" + texval + @"|(?:\{" + s + @"\}))" 40 | val texcmd = @"\\[@a-zA-Z]+\b\s*" 41 | val texval = @"(?:[^\\{}]|" + texcmd + @"|\\.\s*)" 42 | val texarg0 = texval + "*" 43 | val texarg1 = texnest(texarg0) + "*" 44 | val texarg2 = texnest(texarg1) + "*" 45 | val texarg3 = texnest(texarg2) + "*" 46 | 47 | public val texarg = @"(" + texnest(texarg3) + @")" 48 | public val texargs = @"(" + texnest(texarg3) + "*)" 49 | 50 | public val optarg = @"(?:\[([^\]]*)\]\s*)" 51 | public val optargs = optarg + @"*" 52 | 53 | // captures most tex commands 54 | public val rxTexCmd = @"(?:\\(?:begin|end)\b\s*" + optargs + texarg + "|" + texcmd + optargs + ")" 55 | 56 | public val texlen = @"\-?\d+(?:\.\d+)?(?:pt|mm|cm|in|ex|em|bp|pc|dd|cc|sp|fil{1,3})\b" 57 | public val texdim = @"(" + texlen + @")\s*(?:plus\b\s*(" + texlen + @")\s*)?(?:minus\b\s*(" + texlen + @")\s*)?" 58 | --------------------------------------------------------------------------------