diff options
| author | Tavmjong Bah <tavmjong@free.fr> | 2014-04-22 14:39:13 +0000 |
|---|---|---|
| committer | tavmjong-free <tavmjong@free.fr> | 2014-04-22 14:39:13 +0000 |
| commit | 94553ec1515b41791125ca2382419e989d54f77f (patch) | |
| tree | b008368ce25ca5119c1a5ae598f48049a644cfce /src | |
| parent | Restore ability to insert a font-family that is not on system or a font-fallb... (diff) | |
| download | inkscape-94553ec1515b41791125ca2382419e989d54f77f.tar.gz inkscape-94553ec1515b41791125ca2382419e989d54f77f.zip | |
Parse xml:lang, required for SVG (CSS uses lang)
(bzr r13297)
Diffstat (limited to 'src')
| -rw-r--r-- | src/libcroco/cr-sel-eng.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libcroco/cr-sel-eng.c b/src/libcroco/cr-sel-eng.c index 0eba2b403..4f501ee05 100644 --- a/src/libcroco/cr-sel-eng.c +++ b/src/libcroco/cr-sel-eng.c @@ -136,8 +136,9 @@ lang_pseudo_class_handler (CRSelEng *const a_this, node_iface = PRIVATE(a_this)->node_iface; - if (strqcmp (a_sel->content.pseudo->name->stryng->str, - "lang", 4) + /* "xml:lang" needed for SVG */ + if ( (strqcmp (a_sel->content.pseudo->name->stryng->str, "lang", 4 ) && + (strqcmp (a_sel->content.pseudo->name->stryng->str, "xml:lang", 8 ) ) ) || !a_sel->content.pseudo->type == FUNCTION_PSEUDO) { cr_utils_trace_info ("This handler is for :lang only"); return FALSE; @@ -149,6 +150,7 @@ lang_pseudo_class_handler (CRSelEng *const a_this, return FALSE; for (; node; node = get_next_parent_element_node (node_iface, node)) { char *val = node_iface->getProp (node, "lang"); + if (!val) val = node_iface->getProp (node, "xml:lang"); if (val) { if (!strcasecmp(val, a_sel->content.pseudo->extra->stryng->str)) { result = TRUE; |
