summaryrefslogtreecommitdiff
path: root/src/cairo-svg-surface.c
Commit message (Collapse)AuthorAgeFilesLines
* PDF Type 3 color fontsAdrian Johnson2023-01-291-8/+0
| | | | | | | | | This implements Type 3 color fonts for PDF for any font with a CAIRO_SCALED_GLYPH_INFO_RECORDING_SURFACE. This includes user-fonts, SVG fonts, and COLR fonts. Glyphs with foreground colors are not yet implemented as Type 3 glyphs and will be rendered as images by cairo-surface.
* svg: Fix invalid output when image size is 0x0Adrian Johnson2022-06-261-12/+16
| | | | cairo_surface_write_to_png_stream fails if width or height is 0
* Fix a use after free in _cairo_svg_surface_create_for_stream_internalFeysh INC2022-04-221-1/+0
| | | | | | | | | | | When `_cairo_svg_surface_create_for_document()` failed, it will free the `document` by `_cairo_svg_document_destroy()`. But after `_cairo_svg_surface_create_for_document` return a error status, the `document` is still used and destoryed by `_cairo_svg_document_destroy()`. We remove the redundant `_cairo_svg_document_destroy()` in `_cairo_svg_surface_create_for_stream_internal` to avoid this bug. This fixes #561. Signed-off-by: Feysh INC <opensource@feysh.com>
* Support color fonts that use the foreground colorAdrian Johnson2021-08-281-0/+2
| | | | | | | | | | | | | COLR fonts can have a layer with the same color as the current text color. This change passes the current color (if solid) through to the font backend where it can be used to render color fonts. scaled_glyph_lookup checks if the foreground color has changed (for glyph that require it) and requests a new color surface if required. This also fixes a bug where scaled_glyph_lookup would always request a color surface for glyphs for glyphs in color fonts that do not have color.
* Fix some warningsAdrian Johnson2021-08-221-15/+12
|
* Added hairline support to cairoRick Yorgason2021-08-151-7/+17
|
* Merge branch 'issue-263' into 'master'Uli Schlachter2021-07-271-0/+1
|\ | | | | | | | | | | | | Win 64-bit fix pointer to long cast size mismatch Closes #263 See merge request cairo/cairo!216
| * Fix some win32 compile warningsAdrian Johnson2021-07-251-0/+1
| |
* | svg: Fix create-for-stream test caseUli Schlachter2021-07-241-1/+1
|/ | | | | | | | | | | | | | | | | | | | | | Commit 2fbd53 added another test to create-for-stream that failed for cairo-pdf. Manual testing shows that this test also fails for cairo-svg. However, this was not noticed because even before this addition to the test, create-for-stream already failed for cairo-svg. Since the introduction on CI was done based on "let's ignore all current failures", this hid the error. This commit applies the trivial fix for cairo-svg to make this test pass. It is basically the same error that cairo-pdf had. Additionally, this removes the hack to ignore create-for-stream failures in CI since it is now no longer necessary. Thanks to Knut Peterson for reporting this [0]. [0]: https://lists.cairographics.org/archives/cairo/2021-July/029291.html Signed-off-by: Uli Schlachter <psychon@znc.in>
* Fix remaining testsAnton Danilkin2021-05-051-19/+22
|
* Fix applying shifted operatorsAnton Danilkin2021-05-031-78/+202
|
* Fix painting of glyphsAnton Danilkin2021-05-031-4/+5
|
* Fix operators in ChromeAnton Danilkin2021-05-031-48/+46
|
* Use g instead of symbol for glyphsAnton Danilkin2021-05-031-2/+2
|
* Migrate from cairo_output_stream_t to cairo_svg_stream_tAnton Danilkin2021-05-021-777/+945
|
* Do not try to emulate the fill_stroke operations ourselvesAnton Danilkin2021-05-021-14/+1
|
* Disable support for SVG 2 operatorsAnton Danilkin2021-05-011-1/+17
|
* Add support for CAIRO_CONTENT_COLORAnton Danilkin2021-05-011-10/+27
|
* Emit a transparent paint in "lerp_compositing_group"s to extends the bounds ↵Anton Danilkin2021-05-011-0/+2
| | | | of the REMOVE_COLOR_AND_INVERT_ALPHA filter
* Add a small padding around paintsAnton Danilkin2021-04-131-0/+15
|
* Skip the color to alpha filter when possibleAnton Danilkin2021-04-131-4/+13
|
* Implement attempting to recognize a common pattern for a bitmap font and ↵Anton Danilkin2021-04-131-11/+55
| | | | extract the original glyph image from it
* Fix warnings and pipeline failureAnton Danilkin2021-04-131-13/+5
|
* Revert "Fix filter being used on the use element causing the content to be ↵Anton Danilkin2021-04-131-9/+4
| | | | | | clipped" This reverts commit 2a8672d06ef98b5375c6eee825791c2797bef078.
* Add support for PDF Type 3 fontsAnton Danilkin2021-04-131-14/+59
|
* Emit bitmap glyph data as images instead of as a bunch of squares, as this ↵Anton Danilkin2021-04-131-36/+49
| | | | results in smaller file size and better quality, allowing the use of shades of gray
* Do not emit empty glyph pathsAnton Danilkin2021-04-121-7/+9
|
* Fix filter being used on the use element causing the content to be clippedAnton Danilkin2021-04-121-4/+9
|
* Mark CAIRO_PATTERN_TYPE_MESH as unsupported and impose a limit on recording ↵Anton Danilkin2021-04-111-7/+21
| | | | surfaces depth
* Do not use parent_matrix in the mask operationAnton Danilkin2021-04-111-12/+10
|
* Fix clip-rule being emitted on the wrong elementsAnton Danilkin2021-04-111-9/+10
|
* Add my name to the header of cairo-svg-surface.cAnton Danilkin2021-04-111-0/+2
|
* Move cairo_svg_surface_t to cairo-svg-surface.cAnton Danilkin2021-04-111-4/+42
|
* Finish implementing correct paints in transformed recording patternsAnton Danilkin2021-04-111-75/+156
|
* Start implementing correct paints in transformed recording patternsAnton Danilkin2021-04-111-157/+283
|
* Simplify _cairo_svg_surface_emit_composite_surface_patternAnton Danilkin2021-04-111-55/+52
|
* Simplify ignoring of statusesAnton Danilkin2021-04-111-76/+47
|
* Simplify SVG document generationAnton Danilkin2021-04-111-71/+52
|
* Fix and clarify _cairo_svg_surface_do_operatorAnton Danilkin2021-04-111-196/+240
|
* Do not create temporary single-color patterns. Also, do not try to support ↵Anton Danilkin2021-04-111-47/+14
| | | | CAIRO_CONTENT_COLOR
* Fix problems with radial gradientsAnton Danilkin2021-04-111-131/+104
|
* Change the default SVG unit to user unitAnton Danilkin2021-04-111-3/+2
|
* Do not use the style attributeAnton Danilkin2021-04-111-289/+282
|
* Implement the rest of the operatorsAnton Danilkin2021-04-111-133/+220
|
* Implement most of the non-blending operatorsAnton Danilkin2021-04-111-31/+211
|
* Implement the in operatorAnton Danilkin2021-04-111-7/+155
|
* Implement operators for the rest of operationsAnton Danilkin2021-04-111-129/+204
|
* Implement operators for the mask operationAnton Danilkin2021-04-111-113/+174
|
* Add support for the source and clear operators for the paint operationAnton Danilkin2021-04-111-167/+225
|
* Add a layer of indiraction to calls to the clipperAnton Danilkin2021-04-111-47/+45
|