[Bug 789728] New: librsvg: regression causes styles to be ignored
https://bugzilla.novell.com/show_bug.cgi?id=789728 https://bugzilla.novell.com/show_bug.cgi?id=789728#c0 Summary: librsvg: regression causes styles to be ignored Classification: openSUSE Product: openSUSE Factory Version: 12.3 Milestone 1 Platform: All OS/Version: Linux Status: NEW Severity: Critical Priority: P5 - None Component: GNOME AssignedTo: bnc-team-gnome@forge.provo.novell.com ReportedBy: jengelh@inai.de QAContact: qa-bugs@suse.de CC: os.gnome.maintainers@gmail.com Found By: Beta-Customer Blocker: --- Created an attachment (id=513190) --> (http://bugzilla.novell.com/attachment.cgi?id=513190) test case In openSUSE 12.2 and openSUSE Factory, running the "kye" game shows a lot of black graphics. I have reason to believe that this is a bug in librsvg, as - kye requires the svg loader - the viewer program "geeqie" also shows the bug - inkscape renders it fine! (and it does not use rsvg) Use the attached svg graphic file for demonstration. $ wget download.opensuse.org/distribution/12.1/repo/oss/suse/x86_64/librsvg-2-2-2.34.1-3.1.2.x86_64.rpm $ unrpm librsvg-2-2-2.34.1-3.1.2.x86_64.rpm $ LD_LIBRARY_PATH=$PWD/usr/lib64 geeqie blocke.svg If you do use the old librsvg(2.34), geeqie will show a yellowish block. With librsvg(2.36), it's just a black square. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=789728 https://bugzilla.novell.com/show_bug.cgi?id=789728#c1 Dominique Leuenberger <dimstar@opensuse.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dimstar@opensuse.org --- Comment #1 from Dominique Leuenberger <dimstar@opensuse.org> 2012-11-15 08:02:19 UTC --- For reference, the versions in question are: openSUSE 12.1: 2.34.1 (not affected) openSUSE 12.2: 2.36.1 (affected) openSUSE Factory: 2.36.4 (affected) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=789728 https://bugzilla.novell.com/show_bug.cgi?id=789728#c2 David Liang <dliang@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dliang@suse.com --- Comment #2 from David Liang <dliang@suse.com> 2012-11-15 10:25:27 UTC --- bug caused by the commit of 47920ba6e3106e9c50e93e5546f536590e791b19 Simply removing the following part of patch solves the bug. @@ -95,7 +96,8 @@ rsvg_style_handler_free (RsvgSaxHandler * self) RsvgSaxHandlerStyle *z = (RsvgSaxHandlerStyle *) self; RsvgHandle *ctx = z->ctx; - rsvg_parse_cssbuffer (ctx, z->style->str, z->style->len); + if (z->is_text_css) + rsvg_parse_cssbuffer (ctx, z->style->str, z->style->len); g_string_free (z->style, TRUE); g_free (z); -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=789728 https://bugzilla.novell.com/show_bug.cgi?id=789728#c3 David Liang <dliang@suse.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED AssignedTo|bnc-team-gnome@forge.provo. |dliang@suse.com |novell.com | --- Comment #3 from David Liang <dliang@suse.com> 2012-11-15 12:35:50 UTC --- Following that commit, I find this bug should be fixed in 'kye' as it uses the non-standard svg format images. http://www.w3.org/TR/SVG/styling.html#StyleElement For example, change <svg width="16" height="16"><style> rect { fill: tan; stroke: grey; stroke-width: 1px; } </style><rect x="2" y="2" rx="2" ry="2" width="12" height="12"/></svg> to <svg width="16" height="16"><style type="text/css"> rect { fill: tan; stroke: grey; stroke-width: 1px; } </style><rect x="2" y="2" rx="2" ry="2" width="12" height="12"/></svg> -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=789728 https://bugzilla.novell.com/show_bug.cgi?id=789728#c4 --- Comment #4 from Dominique Leuenberger <dimstar@opensuse.org> 2012-11-15 20:31:30 UTC --- (In reply to comment #3)
Following that commit, I find this bug should be fixed in 'kye' as it uses the non-standard svg format images. http://www.w3.org/TR/SVG/styling.html#StyleElement
If a ‘type’ is not provided, the value of ‘contentStyleType’ on the ‘svg’ element shall be used, which in turn defaults to "text/css" [RFC2046]. => so librsvg is not smart enough in assuming text/css as needed. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=789728 https://bugzilla.novell.com/show_bug.cgi?id=789728#c5 --- Comment #5 from David Liang <dliang@suse.com> 2012-11-16 08:02:24 UTC --- Created an attachment (id=513397) --> (http://bugzilla.novell.com/attachment.cgi?id=513397) lookup the mimetype from 'type' and 'contentStyleType' Yes, you are right, librsvg should lookup the contentStyleType if type in 'style' was not found, and use 'text/css' as the default type. I made a proper patch and comment in upstream. https://bugzilla.gnome.org/show_bug.cgi?id=514268 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=789728 https://bugzilla.novell.com/show_bug.cgi?id=789728#c6 Dominique Leuenberger <dimstar@opensuse.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution| |INVALID --- Comment #6 from Dominique Leuenberger <dimstar@opensuse.org> 2012-11-29 20:48:59 UTC --- According to upstream, the entire 'confusion' comes from a spec change... rsvg 'fixed' the spec with an erratum... dropping the default to text/css. http://www.w3.org/TR/2003/REC-SVG11-20030114/styling.html#StyleElement As such, this bug is to be invalid (And an already submitted a fix rof kye anyway :) ) -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=789728 https://bugzilla.novell.com/show_bug.cgi?id=789728#c Jan Engelhardt <jengelh@inai.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |VERIFIED -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com