[librsvg: 10/95] Rename rsvg_parse_style_pairs() -> rsvg_parse_presentation_attributes()
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [librsvg: 10/95] Rename rsvg_parse_style_pairs() -> rsvg_parse_presentation_attributes()
- Date: Thu, 22 Feb 2018 03:13:59 +0000 (UTC)
commit 0d8dba0ce4e07d7f4243173848998f2cc893cda5
Author: Federico Mena Quintero <federico gnome org>
Date: Thu Feb 8 12:47:34 2018 -0600
Rename rsvg_parse_style_pairs() -> rsvg_parse_presentation_attributes()
Because that's what it is intended to do. In the style parsing code,
we'll make a distinction between key/value pairs coming from CSS
styles or the "style" attribute in SVG elements, and presentation
attributes in SVG elements.
rsvg-styles.c | 4 ++--
rsvg-styles.h | 2 +-
rust/src/stop.rs | 8 ++++----
3 files changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/rsvg-styles.c b/rsvg-styles.c
index ee1b5fac..19a37eab 100644
--- a/rsvg-styles.c
+++ b/rsvg-styles.c
@@ -1172,7 +1172,7 @@ atts_enumerate_cb (const char *key, const char *value, gpointer data)
/* take a pair of the form (fill="#ff00ff") and parse it as a style */
void
-rsvg_parse_style_pairs (RsvgState * state, RsvgPropertyBag * atts)
+rsvg_parse_presentation_attributes (RsvgState * state, RsvgPropertyBag * atts)
{
rsvg_property_bag_enumerate (atts,
atts_enumerate_cb,
@@ -1547,7 +1547,7 @@ rsvg_parse_style_attrs (RsvgHandle *handle,
state = rsvg_node_get_state (node);
if (rsvg_property_bag_size (atts) > 0)
- rsvg_parse_style_pairs (state, atts);
+ rsvg_parse_presentation_attributes (state, atts);
/* Try to properly support all of the following, including inheritance:
* *
diff --git a/rsvg-styles.h b/rsvg-styles.h
index 442d62e5..6f0e5781 100644
--- a/rsvg-styles.h
+++ b/rsvg-styles.h
@@ -208,7 +208,7 @@ G_GNUC_INTERNAL
void rsvg_state_free_all (RsvgState * state);
G_GNUC_INTERNAL
-void rsvg_parse_style_pairs (RsvgState * state, RsvgPropertyBag * atts);
+void rsvg_parse_presentation_attributes (RsvgState * state, RsvgPropertyBag * atts);
G_GNUC_INTERNAL
void rsvg_parse_style (RsvgState *state, const char *str);
G_GNUC_INTERNAL
diff --git a/rust/src/stop.rs b/rust/src/stop.rs
index 0cc1f628..7e29ede0 100644
--- a/rust/src/stop.rs
+++ b/rust/src/stop.rs
@@ -68,7 +68,7 @@ impl NodeTrait for NodeStop {
let state = node.get_state ();
// FIXME: this is the only place where rsvg_parse_style() and
- // rsvg_parse_style_pairs() are called outside of the
+ // rsvg_parse_presentation_attributes() are called outside of the
// rsvg-base.c machinery. That one indirectly calls them via
// rsvg_parse_style_attrs().
//
@@ -82,7 +82,7 @@ impl NodeTrait for NodeStop {
}
unsafe {
- rsvg_parse_style_pairs (state, pbag.ffi());
+ rsvg_parse_presentation_attributes (state, pbag.ffi());
}
let inherited_state = drawing_ctx::state_new ();
@@ -172,8 +172,8 @@ fn u32_from_rgba (rgba: cssparser::RGBA) -> u32 {
}
extern "C" {
- fn rsvg_parse_style_pairs(state: *mut RsvgState, pbag: FfiRsvgPropertyBag);
- fn rsvg_parse_style(state: *mut RsvgState, string: *const libc::c_char);
+ fn rsvg_parse_presentation_attributes (state: *mut RsvgState, pbag: FfiRsvgPropertyBag);
+ fn rsvg_parse_style (state: *mut RsvgState, string: *const libc::c_char);
}
#[no_mangle]
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]