From 9c879e5e172b38ed054d2268c5839c5f3f38832b Mon Sep 17 00:00:00 2001 From: Laytan Laats Date: Wed, 20 Mar 2024 17:42:20 +0100 Subject: [PATCH] commonmark: add missing on_exit api --- vendor/commonmark/cmark.odin | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/vendor/commonmark/cmark.odin b/vendor/commonmark/cmark.odin index 3563dff16..9ad71da3f 100644 --- a/vendor/commonmark/cmark.odin +++ b/vendor/commonmark/cmark.odin @@ -366,6 +366,16 @@ foreign lib { // Returns `true` on success, `false`on failure. node_set_on_enter :: proc(node: ^Node, on_enter: cstring) -> (success: b32) --- + // Returns the literal "on exit" text for a custom 'node', or + // an empty string if no on_exit is set. Returns NULL if + // called on a non-custom node. + node_get_on_exit :: proc(node: ^Node) -> (on_exit: cstring) --- + + // Sets the literal text to render "on exit" for a custom 'node'. + // Any children of the node will be rendered before this text. + // Returns 1 on success 0 on failure. + node_set_on_exit :: proc(node: ^Node, on_exit: cstring) -> (success: b32) --- + // Returns the line on which `node` begins. node_get_start_line :: proc(node: ^Node) -> (line: c.int) ---