[librsvg: 3/20] xmlSAXHandler: add prototypes for the startElementNs and endElementNs
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [librsvg: 3/20] xmlSAXHandler: add prototypes for the startElementNs and endElementNs
- Date: Sat, 26 Oct 2019 23:35:09 +0000 (UTC)
commit bd49bec464fd57e2a10b6af0427d9ec7ef29e96e
Author: Federico Mena Quintero <federico gnome org>
Date: Tue May 28 17:40:45 2019 -0500
xmlSAXHandler: add prototypes for the startElementNs and endElementNs
These will let us get start_element / end_element SAX events with XML
namespaces.
rsvg_internals/src/xml2.rs | 22 ++++++++++++++++++++--
1 file changed, 20 insertions(+), 2 deletions(-)
---
diff --git a/rsvg_internals/src/xml2.rs b/rsvg_internals/src/xml2.rs
index 79b30716..f7dbf39e 100644
--- a/rsvg_internals/src/xml2.rs
+++ b/rsvg_internals/src/xml2.rs
@@ -14,6 +14,8 @@ pub const XML_PARSE_NONET: libc::c_int = 1 << 11;
pub const XML_PARSE_HUGE: libc::c_int = 1 << 19;
pub const XML_PARSE_BIG_LINES: libc::c_int = 1 << 22;
+pub const XML_SAX2_MAGIC: libc::c_uint = 0xDEEDBEAF;
+
pub type xmlDocPtr = gpointer;
pub type xmlEntityPtr = gpointer;
@@ -110,8 +112,24 @@ pub struct xmlSAXHandler {
pub _private: gpointer,
- pub startElementNs: UnusedFn,
- pub endElementNs: UnusedFn,
+ pub startElementNs: Option<unsafe extern "C" fn(
+ ctx: *mut libc::c_void,
+ localname: *mut libc::c_char,
+ prefix: *mut libc::c_char,
+ uri: *mut libc::c_char,
+ nb_namespaces: libc::c_int,
+ namespaces: *mut *mut libc::c_char,
+ nb_attributes: libc::c_int,
+ nb_defaulted: libc::c_int,
+ attributes: *mut *mut libc::c_char,
+ )>,
+
+ pub endElementNs: Option<unsafe extern "C" fn(
+ ctx: *mut libc::c_void,
+ localname: *mut libc::c_char,
+ prefix: *mut libc::c_char,
+ uri: *mut libc::c_char,
+ )>,
pub serror: Option<unsafe extern "C" fn(user_data: *mut libc::c_void, error: xmlErrorPtr)>,
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]