diff options
author | John MacFarlane <jgm@berkeley.edu> | 2014-12-29 12:20:19 -0800 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2014-12-29 12:50:58 -0800 |
commit | 0566fa09cf2369cef3ea6b459f3d4fcf3a27d0fc (patch) | |
tree | adae2b1e8da52a6edfdb459cba975b257eae2f9a /src/cmark.c | |
parent | 96c7df6a8480b78ddc2540dd85877487af358ceb (diff) |
Added options parameter to renderers.
To keep the API simple and avoid API changes when new options are
added, this is just a long integer.
Set it by disjoining options that are defined as powers of 2: e.g.
`CMARK_HTML_SOURCEPOS | CMARK_HTML_HARDREAKS`.
Test options using `&`: `if (options & CMARK_HTML_SOURCEPOS)`.
Added `--hardbreaks` and `--sourcepos` command-line options.
Diffstat (limited to 'src/cmark.c')
-rw-r--r-- | src/cmark.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cmark.c b/src/cmark.c index 16817b9..1d7a500 100644 --- a/src/cmark.c +++ b/src/cmark.c @@ -13,7 +13,7 @@ char *cmark_markdown_to_html(const char *text, int len) doc = cmark_parse_document(text, len); - result = cmark_render_html(doc); + result = cmark_render_html(doc, CMARK_OPT_DEFAULT); cmark_node_free(doc); return result; |