diff options
Diffstat (limited to 'src/document.h')
-rw-r--r-- | src/document.h | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/src/document.h b/src/document.h index d310933..4547972 100644 --- a/src/document.h +++ b/src/document.h @@ -27,11 +27,13 @@ enum hoedown_extensions { HOEDOWN_EXT_HIGHLIGHT = (1 << 6), HOEDOWN_EXT_QUOTE = (1 << 7), HOEDOWN_EXT_SUPERSCRIPT = (1 << 8), + HOEDOWN_EXT_MATH = (1 << 13), /* other flags */ HOEDOWN_EXT_LAX_SPACING = (1 << 9), HOEDOWN_EXT_NO_INTRA_EMPHASIS = (1 << 10), HOEDOWN_EXT_SPACE_HEADERS = (1 << 11), + HOEDOWN_EXT_MATH_EXPLICIT = (1 << 14), /* negative flags */ HOEDOWN_EXT_DISABLE_INDENTED_CODE = (1 << 12) @@ -48,12 +50,14 @@ enum hoedown_extensions { HOEDOWN_EXT_UNDERLINE |\ HOEDOWN_EXT_HIGHLIGHT |\ HOEDOWN_EXT_QUOTE |\ - HOEDOWN_EXT_SUPERSCRIPT ) + HOEDOWN_EXT_SUPERSCRIPT |\ + HOEDOWN_EXT_MATH ) #define HOEDOWN_EXT_FLAGS (\ HOEDOWN_EXT_LAX_SPACING |\ HOEDOWN_EXT_NO_INTRA_EMPHASIS |\ - HOEDOWN_EXT_SPACE_HEADERS ) + HOEDOWN_EXT_SPACE_HEADERS |\ + HOEDOWN_EXT_MATH_EXPLICIT ) #define HOEDOWN_EXT_NEGATIVE (\ HOEDOWN_EXT_DISABLE_INDENTED_CODE ) @@ -61,7 +65,7 @@ enum hoedown_extensions { /* list/listitem flags */ enum hoedown_listflags { HOEDOWN_LIST_ORDERED = (1 << 0), - HOEDOWN_LI_BLOCK = (1 << 1), /* <li> containing block data */ + HOEDOWN_LI_BLOCK = (1 << 1) /* <li> containing block data */ }; enum hoedown_tableflags { @@ -119,6 +123,7 @@ struct hoedown_renderer { int (*strikethrough)(hoedown_buffer *ob, const hoedown_buffer *text, void *opaque); int (*superscript)(hoedown_buffer *ob, const hoedown_buffer *text, void *opaque); int (*footnote_ref)(hoedown_buffer *ob, unsigned int num, void *opaque); + int (*math)(hoedown_buffer *ob, const hoedown_buffer *text, int displaymode, void *opaque); /* low level callbacks - NULL copies input directly into the output */ void (*entity)(hoedown_buffer *ob, const hoedown_buffer *entity, void *opaque); @@ -149,6 +154,9 @@ extern void hoedown_document_render(hoedown_document *doc, hoedown_buffer *ob, const uint8_t *document, size_t doc_size); extern void +hoedown_document_render_inline(hoedown_document *doc, hoedown_buffer *ob, const uint8_t *document, size_t doc_size); + +extern void hoedown_document_free(hoedown_document *doc); #ifdef __cplusplus |