Commit graph

36 commits

Author SHA1 Message Date
Karl Bartel
7fa950993c End list when indent is not reached
Otherwise
```
- foo
- bar
+ baz
```
will become a nested list
2020-07-01 08:56:22 +02:00
Karl Bartel
7228740ed1 Fix paragraphs after ruler
```
- - -

foo
```
did not work because the empty line was swallowed when parsing the
ruler.
2020-07-01 08:56:22 +02:00
Karl Bartel
68edb1b8fd Support literal quotes in titles
I could not find this in the markdown spec, but
https://github.com/michelf/mdtest/blob/master/Markdown.mdtest/Literal%20quotes%20in%20titles.text
includes it in the test suite and I actually prefer the implementation
after this change.
2020-07-01 08:56:22 +02:00
Karl Bartel
a9636129cc Keep HTML comments in output
See https://spec.commonmark.org/0.29/#example-621
2020-07-01 08:56:22 +02:00
Karl Bartel
1793559632 Ignore single space around code span
According to https://spec.commonmark.org/0.29/#code-spans :

> If the resulting string both begins and ends with a space character,
but does not consist entirely of space characters, a single space
character is removed from the front and back. This allows you to include
code that begins or ends with backtick characters, which must be
separated by whitespace from the opening or closing backtick strings.
2020-07-01 08:56:22 +02:00
Karl Bartel
b76e431cc2 Skip empty lines at end of code block
See https://spec.commonmark.org/0.29/#example-87
2020-07-01 08:56:22 +02:00
Karl Bartel
3e00caedeb Code blocks need four spaces indentation 2020-07-01 08:56:22 +02:00
Karl Bartel
beca8029f4 Code blocks should contain the ending newline
See https://spec.commonmark.org/0.29/#example-1
2020-07-01 08:56:22 +02:00
Karl Bartel
0bb70e62b8 Allow link target in angular brackets
Example:

[URL wrapped in angle brackets](</url/>).
2020-07-01 08:56:22 +02:00
Karl Bartel
c21412ce48 Handle nested parens in links
Example input:

[With parens in the URL](http://en.wikipedia.org/wiki/WIMP_(computing))
2020-07-01 08:56:22 +02:00
Enno Boland
2181caf0c4 fix shortlinks when -n is not given. #4 2016-01-20 23:13:50 +01:00
Enno Boland
8ddcbc040b apply whitespace cleaning by Hiltjo Posthuma. Thanks mate! 2014-11-28 10:07:00 +01:00
Enno Boland
913a387aff apply img and anchor support written by Hiltjo Posthuma. Thanks mate! 2014-11-28 10:06:32 +01:00
Ypnose
3dcb798637 Remove newline after <p> 2014-05-14 22:32:35 +02:00
Steven Dee
b8bb25f4a7 Fix escaping with surrounds
When we assigned stop = strstr(start, search), we'd grab the first
match even if it was escaped. Instead, we update stop as we go.
2013-06-22 16:14:25 -04:00
Enno Boland (Gottox)
1b0c0b16d1 small fixes reported by Johannes. Thx btw :) 2008-07-03 08:55:01 +02:00
Enno Boland (Gottox)
c499a2afe1 adding reallocz, adding workaround for segfault, some reformating. 2008-07-02 09:43:21 +02:00
Enno Boland (Gottox)
cf7d7b62f2 don't remove comments when -n is set. 2008-07-01 22:10:40 +02:00
Enno Boland (Gottox)
5fff5fdbe8 rewriting dohtml, adding docomment, rewriting arg-loop. 2008-07-01 22:01:33 +02:00
Enno Boland (Gottox)
3584331433 Adding args unlib patch. 2008-06-28 21:06:02 +02:00
Enno Boland (Gottox)
b2712c1480 turning smu into a library, thanks arg. 2008-06-18 08:00:18 +02:00
Enno Boland (Gottox)
4536588aad typo fix 2008-03-16 13:48:41 +01:00
gottox@work
2f223a46e0 preventing from unwanted output. 2008-01-28 14:13:58 +01:00
gottox@work
fc9310966e More documentation; fixed dosurround 2008-01-28 14:10:32 +01:00
gottox@work
c87f6e21b6 Removing unsigned where values are signed :/ 2008-01-28 13:08:15 +01:00
gottox@rootkit.lan
fa0d368d7e Added workaround for strong and emphatic texts. 2008-01-26 12:45:49 +01:00
gottox@rootkit
f20e7b5516 renamed smutest into testdoc. Added documentation. Changed copyright.
--HG--
rename : smutest => testdoc
2008-01-22 10:50:18 +01:00
gottox@rootkit.lan
1d7d3a4598 dogtlt filled 2008-01-14 14:19:29 +01:00
gottox@rootkit.lan
44bcd35d56 <hr /> is now more proper. 2008-01-14 13:52:56 +01:00
gottox@rootkit.lan
f6967fe581 smu handles big files correctly now. 2008-01-14 13:43:25 +01:00
gottox@rootkit.lan
9bb4f5d434 hr works again.
It's a little hacky :/
2008-01-05 22:55:48 +01:00
gottox@rootkit.lan
a2af303ce1 Removed comments and unneeded replace rules ('- - -' should be readded later.) 2008-01-04 12:04:15 +01:00
gottox@rootkit.lan
b8d1753e09 dd function dogtlt; added Szabolcs' patch 2008-01-04 11:52:10 +01:00
gottox@rootkit.lan
f7cd9bb510 dolineprefix can now work without newblock 2008-01-01 20:02:20 +01:00
gottox@rootkit.lan
6a94a6b5ec Fixed bugs reported by nsz_ 2008-01-01 15:30:04 +01:00
gottox@rootkit.lan
4f419311ff renamed project to smu - simple markup
--HG--
rename : cmarkdown.1 => smu.1
rename : cmarkdown.c => smu.c
2008-01-01 14:52:08 +01:00
Renamed from cmarkdown.c (Browse further)