diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/cmark.h | 9 | ||||
-rw-r--r-- | src/node.c | 15 |
2 files changed, 24 insertions, 0 deletions
diff --git a/src/cmark.h b/src/cmark.h index 2b42486..a74fe93 100644 --- a/src/cmark.h +++ b/src/cmark.h @@ -138,6 +138,15 @@ cmark_node_get_title(cmark_node *node); CMARK_EXPORT int cmark_node_set_title(cmark_node *node, const char *title); +CMARK_EXPORT int +cmark_node_get_start_line(cmark_node *node); + +CMARK_EXPORT int +cmark_node_get_start_column(cmark_node *node); + +CMARK_EXPORT int +cmark_node_get_end_line(cmark_node *node); + // Tree manipulation CMARK_EXPORT void @@ -303,6 +303,21 @@ cmark_node_set_title(cmark_node *node, const char *title) { return 0; } +int +cmark_node_get_start_line(cmark_node *node) { + return node->start_line; +} + +int +cmark_node_get_start_column(cmark_node *node) { + return node->start_column; +} + +int +cmark_node_get_end_line(cmark_node *node) { + return node->end_line; +} + static inline bool S_is_block(cmark_node *node) { return node->type >= CMARK_NODE_FIRST_BLOCK |