summaryrefslogtreecommitdiff
path: root/rsvg-styles.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove leftover from the unsupported a:adobe-blending-modeFederico Mena Quintero2016-01-051-1/+0
|
* bgo#340047 - Add support for the "baseline-shift" text attributeMenner2016-01-051-0/+21
| | | | | | | | This commit adds support for the baseline-shift attribute for tags "sub/super/baseline". We don't support percentages of the font size or explicit lengths yet. https://bugzilla.gnome.org/show_bug.cgi?id=340047
* state: Remove unused adobe blend mode supportBenjamin Otte2015-10-221-29/+0
| | | | There's no need to keep a variable around when nobody ever looks at it.
* marker: Resolve lazilyBenjamin Otte2015-10-221-13/+28
| | | | | | | | | | | And that concludes our rework of reference cylce detection. All code that references other objects via IRIs will now call rsvg_acquire_node() which itself avoids giving out the same node a second time until rsvg_release_node() has been called. This also means that rsvg_defs_lookup() is only used in two places now: (1) by rsvg_acquire_node() (2) by public API that allows operating on objects by id.
* state: Resolve filters lazilyBenjamin Otte2015-10-221-4/+8
| | | | We're almost there resolving everything lazily...
* paint-server: Store URL instead of resolved nodeBenjamin Otte2015-10-221-3/+3
| | | | | This way, we resolve lazily only upon use and thereby can make use of our amazing new cycle detection technology.
* paint-server: Remove unused argument from functionBenjamin Otte2015-10-221-3/+3
|
* state: Look up clip path lazilyBenjamin Otte2015-10-221-3/+7
|
* state: Store mask as referenceBenjamin Otte2015-10-221-4/+8
| | | | | Instead of immediately looking up the mask, store the reference and look it up on use.
* bgo#739329 - Remove single quotes around font-family names before passing ↵Menner2015-07-021-2/+18
| | | | | | | | | | | | | | | them to Pango If you have an SVG with <text style="font-family: 'New Century Schoolbook';"> ... </text> our CSS-parsing code simply passes the singly-quoted string to Pango. In turn, Pango doesn't like the quotes because they are not part of the font's name. This is a simple patch to remove single quotes from *all* style attributes, not just strings (which is where the CSS spec allows them). We need a real CSS parser, not something built out of g_strsplit().
* bgo#744688 - Fix double g_free() when processing stroke-dasharrayFederico Mena Quintero2015-02-191-3/+5
| | | | | | | | | | | The part of rsvg_parse_style_pair() that validates the dash pattern, by seeing if any actual dash length was generated, could leave a dangling pointer after a g_free() if the dash pattern turned out to be invalid. Later, rsvg_state_inherit_run() would try to g_free() this dangling pointer as well. Found by Atte Kettunen's fuzz testing. Signed-off-by: Federico Mena Quintero <federico@gnome.org>
* Internally use 'char *' for string dataFederico Mena Quintero2015-02-121-4/+3
| | | | | | | | There was a mixture of guint8*, guchar*, gchar*, etc. Use char* because that's about as sane as we can get, and only cast where we can't change the public API or where we must interface with other libraries. *Cough* xmlChar *cough*. This removes a metric assload of compiler warnings, and I'm fine with that.
* introspection: add many missing nullable annotationsEvan Nemerson2014-06-101-2/+2
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=731182
* docs: Assorted fixes and additions to reduce gtk-doc warningsEvan Nemerson2014-06-101-2/+3
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=731182
* introspection: clean up lots of warnings emitted by g-ir-scannerEvan Nemerson2012-06-191-2/+2
|
* styles: Don't try parsing empty <style>Christian Persch2012-03-191-1/+3
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=672414
* Use mime types instead of content typesChristian Persch2012-01-281-12/+10
| | | | | Instead of converting back and forth, just use the mime types directly.
* Only apply CSS if its content type is text/cssChristian Persch2012-01-271-3/+12
|
* Add content_type out param to _rsvg_io_acquire_*Christian Persch2012-01-271-0/+1
|
* Add permission check before loading other filesChristian Persch2012-01-261-5/+4
| | | | | | Wrap _rsvg_io_acquire_* in _rsvg_handle_acquire_* that first checks whether the load should be allowed. For the moment, always allow the load; more restricted policies will be introduced in a follow-up commit.
* Split IO handling to rsvg-io.[ch]Christian Persch2012-01-131-15/+18
| | | | Add rsvg-io.[ch], move the code there, clean it up, and adapt the callers.
* Support basic vertical writing (Gnome Bug #664533)KUROSAWA Takeshi2011-11-281-6/+15
| | | | | | | | | | Support vertical writing text (writing-mode: tb-rl | tb) http://www.w3.org/TR/SVG11/text.html#SettingInlineProgressionDirection Bump pango dependency to 1.16.0 to use its vertical text APIs. Currently, we ignore both glyph-orientation-vertical and glyph-orientation-horizontal.
* Set correct value when unicode-bidi: inherit;KUROSAWA Takeshi2011-11-251-1/+1
| | | | Bug #664533.
* Plug a mem leakChristian Persch2011-11-121-7/+7
| | | | | | | | | | | | ... and don't call g_strv_length() just to find out if length is == 2 ! ==5735== 4 bytes in 1 blocks are definitely lost in loss record 18 of 356 ==5735== at 0x402AD89: malloc (vg_replace_malloc.c:236) ==5735== by 0x4566BDA: standard_malloc (gmem.c:85) ==5735== by 0x4566F80: g_malloc (gmem.c:159) ==5735== by 0x4567282: g_malloc_n (gmem.c:361) ==5735== by 0x457DFCC: g_strsplit (gstrfuncs.c:2249) ==5735== by 0x4053934: rsvg_parse_style (rsvg-styles.c:919)
* Plug a mem leakChristian Persch2011-11-111-8/+8
| | | | | | | | | | | | | | | Don't leak the CRDocHandler. ==988== 104 (92 direct, 12 indirect) bytes in 1 blocks are definitely lost in loss record 4,805 of 5,382 ==988== at 0x402AD89: malloc (vg_replace_malloc.c:236) ==988== by 0x4B40BDA: standard_malloc (gmem.c:85) ==988== by 0x4053A15: rsvg_parse_cssbuffer (rsvg-styles.c:1128) ==988== by 0x4056644: rsvg_style_handler_free (rsvg-base.c:90) ==988== by 0x4056BB9: rsvg_end_element (rsvg-base.c:681) ==988== by 0x49C28C1: xmlParseEndTag1 (parser.c:8356) ==988== by 0x49C9DEB: xmlParseTryOrFinish (parser.c:11154) ==988== by 0x49CAB24: xmlParseChunk (parser.c:11739) ==988== by 0x405A238: rsvg_handle_write (rsvg-base.c:1172)
* Avoid unnecessary strdupsChristian Persch2011-11-111-4/+33
| | | | | | | In all cases except one, the property bag does not need to store copies of the attributes and values. So make the property bag store them by reference, and add rsvg_property_bag_dup for the one case where we do need to make a bag that owns the attributes and values.
* Fix for NULL stringsKurosawa Takeshi2011-11-091-6/+13
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=624820
* Hard-depend on libcrocoChristian Persch2011-11-071-98/+6
|
* Use cairo_matrix_tChristian Persch2011-11-071-34/+52
| | | | | I've checked this quite carefully, but it still might contain stupid typo bugs ;-)
* Use cairo_line_cap_t directlyChristian Persch2011-11-071-4/+4
| | | | | Although it appears this property is only parsed, but not used when rendering...
* Use cairo_line_join_t directlyChristian Persch2011-11-071-4/+4
| | | | | Although it appears this property is only parsed, but not used when rendering...
* Use cairo_antialias_t directlyChristian Persch2011-11-071-0/+14
|
* Use cairo_fill_rule_t directlyChristian Persch2011-11-071-6/+6
|
* Use cairo_operator_t directlyChristian Persch2011-11-071-26/+26
|
* Use "const" instead G_CONST_RETURNJavier Jardón2011-06-131-1/+1
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=652213
* Don't accidentally return NULL from parse_style_value()Matthias Clasen2011-02-181-1/+4
| | | | | Callers don't expect it and things go bad... https://bugzilla.gnome.org/show_bug.cgi?id=626802
* fix indent.Hiroyuki Ikezoe2010-05-301-1/+1
|
* fix indent.Hiroyuki Ikezoe2010-05-301-4/+4
|
* [PATCH 2/3] Follow up fix of RsvgState change.Hiroyuki Ikezoe2010-05-021-2/+2
| | | | rsvg_state_current -> rsvg_current_state.
* [PATCH 1/3] RsvgState has its parent state to traverse its ancestors.Hiroyuki Ikezoe2010-05-021-32/+46
| | | | Now we can get ancestor's font-size.
* support !important directive without libcroco.Hiroyuki Ikezoe2010-05-011-2/+6
| | | | Fix for bug #617163.
* support !important directive in style attributes.Hiroyuki Ikezoe2010-04-301-7/+13
|
* fix compile error without libcroco.Hiroyuki Ikezoe2010-04-291-4/+16
|
* set proper mode-line and fix indent.Hiroyuki Ikezoe2010-04-271-21/+22
|
* Handle !important directive.Hiroyuki Ikezoe2010-04-271-238/+332
| | | | | | Fix for bug #61406. RsvgState keeps style information with "!important" in hash table.
* Handle comma separated CSS selectors without libcroco.Hiroyuki Ikezoe2010-04-241-5/+10
| | | | Fix for bug #614643.
* Apply svg element's style after loading style data.Hiroyuki Ikezoe2010-04-181-8/+12
| | | | Fix for bug #615701.
* Support .class.#id selector.Hiroyuki Ikezoe2010-04-151-6/+13
| | | | Fix for bug #615715.
* Parse presentation attributes before looking for a style matching class/id.Matthias Clasen2010-04-141-2/+3
| | | | Fix for bug #614704.
* fix CSS selector order.Hiroyuki Ikezoe2010-04-141-11/+12
| | | | Fix for 592207.