Commit graph

8877 commits

Author SHA1 Message Date
Andrea Canciani
b4466bc914 quartz: Fix y glyph advance
The advances must be transformed by the "quartz inverse scale",
i.e. (scale_inverse * scale(1,-1)).

Fixes show-glyph-advance.
2011-03-19 16:08:46 +01:00
Andrea Canciani
aaf87a65a8 test: Add show-glyphs-advance
This new test (based on show-glyphs-many) checks that the glyphs
advances are respected along both axes.

9c0d761bfc introduced a bug which
regresses this test in quartz.

Thanks to Jeff Muizelaar for the report!
2011-03-19 16:07:23 +01:00
Andrea Canciani
36e0cad71a path: Fix _cairo_path_fixed_is_rectangle()
__cairo_path_fixed_is_rectangle() is used by the PS and PDF backends
to check if a path is equivalent to a rectangle when stroking. This is
different from being a rectangle when filling, because of the implicit
close_path appended to every subpath when filling.

Fixes stroke-open-box.

See https://bugs.freedesktop.org/show_bug.cgi?id=34560
2011-03-19 15:53:39 +01:00
Andrea Canciani
145e8ab03d test: Add stroke-open-box
Add a new test to check that the stroking of a 3-sided box is not
"optimized" to a 4-sided box.

Test case based on the code by Simon Kellner in
https://bugs.freedesktop.org/show_bug.cgi?id=34560
2011-03-19 15:30:25 +01:00
Chris Wilson
d2f227e585 configure: Test for funlockfile
cairo-trace already depended upon HAVE_FUNLOCKFILE for its
thread-safety.

[This is a candidate for 1.10.]

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-03-15 13:24:59 +00:00
Chris Wilson
60c6f658b1 xcb: Compile fix when using xcb-drm
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-03-15 13:24:51 +00:00
Adrian Johnson
684fff7a49 cff: Fix heap corruption
caused by holding a pointer into a cairo_array after a realloc

https://bugs.freedesktop.org/show_bug.cgi?id=35161
2011-03-13 21:08:54 +10:30
Benjamin Otte
1583d0a724 arf: Fix erroneous return statement.
Introduced in 24ed8b1e60.
2011-02-19 10:42:32 +01:00
Benjamin Otte
24ed8b1e60 arc: Handle radius == 0 the same no matter the arc direction
Commit a0ea0b63fd fixed cairo_arc() but
did not apply the same patch to cairo_arc_negative(). This patch fixes
that oversight.
2011-02-18 19:56:39 +01:00
Andrea Canciani
9d37bd9630 xlib: Fix compilation when gradient functions are not available
It is not correct to rely on the version defined in render.h. The
Xrender.h header is independent and might not define some functions
available in RENDER 0.10.

Their availability must be detected at configure time and the stubs
must be defined only if the functions are not available.

Fixes https://bugs.freedesktop.org/show_bug.cgi?id=31906
2011-02-14 11:32:25 +01:00
Adrian Johnson
a1b36ad521 Type1-subset: Fallback if font contains more than one /Encoding
https://bugzilla.gnome.org/show_bug.cgi?id=641704
2011-02-08 21:45:15 +10:30
Pino Toscano
10ed4f7001 LD_PRELOAD is supported on Hurd
LD_PRELOAD is supported on Hurd. Adding Hurd to the list of supported
systems makes cairo-trace available on them as well.

See http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=608492
2011-01-25 14:51:12 +01:00
Robert O'Callahan
686dbfa496 tee: Do not apply two times the master device transform
cairo_tee_surface_create copies the device transform from 'master' to
the new surface. This is wrong since all the cairo_surface_wrapper
functions apply master's device transform themselves.

Reviewed-by: Benjamin Otte <otte@redhat.com>
2011-01-18 13:58:36 +01:00
Chris Wilson
c84730d889 version: Post release version bump 2010-12-25 23:04:47 +00:00
Chris Wilson
4938e11ffe version: Bump for 1.10.2 release 2010-12-25 13:25:14 +00:00
Chris Wilson
de464ea778 NEWS: Add entry for 1.10.2 2010-12-25 13:24:37 +00:00
Chris Wilson
888eeb187f Add a KNOWN_ISSUES file to track WONTFIX(?) bugs 2010-12-25 10:19:38 +00:00
Koji Otani
a27e3bc6d0 PS: fix embedding of grayscale jpegs
https://bugs.freedesktop.org/show_bug.cgi?id=31632
(cherry picked from commit 653ceb517f)
2010-12-17 02:08:47 +10:30
Andrea Canciani
4aabff8f67 path-bounder: Update current point after curve_to op
Even if the curve_to is completely within the current extents box, the
current point needs to be updated because the shape of following ops
depends on the position of the current point.

Fixes bug-extents.
2010-12-14 21:03:31 +01:00
Andrea Canciani
5996652364 test: Add bug-extents
Add a test for the computation of approximate extents used by most
backends to esimate the region affected by drawing operations.

Based on:
http://lists.cairographics.org/archives/cairo/2010-December/021331.html
2010-12-14 21:03:31 +01:00
Andrea Canciani
f832ff7f22 test: Fix ref images
The corners of the boxes in these ref images were not correct.
2010-12-02 10:28:46 +01:00
Andrea Canciani
ff35af3fd7 image: Fix compositing of unaligned boxes
The input of _fill_unaligned_boxes is (supposed to be) composed only
of disjoint rectangles, that can safely be passed to the rectilinear
span converter, but this function artificially introduces intersecting
rectangles when drawing non-aligned boxes.

Using non-intersecting rectangles is easy and makes the code correct.

Fixes rectilinear-grid.

Reviewed-by: Uli Schlachter <psychon@znc.in>
2010-12-02 10:28:37 +01:00
Andrea Canciani
7b29f1d5d8 test: Add rectilinear-grid
The rectilinear scan converter assumes disjoint rects as input, but
cairo-image passes intersecting rectangles to it.

This test shows that image and any backends passing through it for the
rasterization (fallbacks, vector backends whose renderer is
cairo-based) fail in compute the corners of intersecting rectangles
correctly.
2010-12-02 10:28:08 +01:00
Adrian Johnson
9ec51baa77 PDF: Add missing clipper_reset
(cherry picked from commit 2ae2be36d4)
2010-11-26 22:00:11 +10:30
Markus Stange
841a2df735 Fix type of _cairo_memory_stream_destroy parameter
In 9b9952ab4f
_cairo_memory_stream_destroy was changed to take an unsigned long
instead of unsigned int, and the two callsites in cairo-gl-shaders.c
weren't updated.
2010-11-26 10:02:34 +00:00
Andrea Canciani
b6a97499c7 xcb: Do not return value in void function
Sun Studio Compiler complains:
"cairo-xcb-surface.c", line 585: void function cannot return value
even if the returned value is void.
Some minor code restructuring removes the issue.
2010-11-26 10:02:16 +00:00
Andrea Canciani
e71588c80d test: Add romedalen images copyright information
romedalen.png and romedalen.jpg have been bundled into the test
suite without an explicit copyright notice.
2010-11-26 10:01:38 +00:00
Andrea Canciani
2b3d8de11a Fix degenerate arcs
Make sure that degenerate arcs become a move_to-line_to sequence
instead of just a move_to.

Fixes get-path-extents.
2010-11-26 10:01:19 +00:00
Joerg Sonnenberger
fafca7ace2 LD_PRELOAD is supported on DragonFly. 2010-11-26 10:00:36 +00:00
Erik Zeek
c20d55eb1c Fix build on gentoo
The problem is probably caused by a change in the behavior of autoconf
(2.67).

See http://bugs.gentoo.org/336329
2010-11-26 10:00:21 +00:00
Andrea Canciani
8ef5161da3 configure: Correct reporting of tee backend
Since 9f33f8453b tee is not compiled in
anymore by default. Reporting it as always enabled is misleading.
2010-11-26 10:00:10 +00:00
Andrea Canciani
a6b503961b ps: Fix painting
Painting of some pattern was broken because the paint operation was
implemented as a fill to a rect containing the clip, but this rect was
not transformed as appropriate (using the cairo_to_ps matrix).
PDF simply fills the whole surface rect, so we implement the same
behavior in PS.

Fixes clip-group-shapes-circles, clip-stroke, linear-gradient-extend,
linear-gradient-one-stop, radial-gradient-one-stop.
2010-11-24 13:32:40 +01:00
Adrian Johnson
b8347e3353 PS: Fix regression - incorrect EPS bounding box
https://bugs.freedesktop.org/show_bug.cgi?id=24688
(cherry picked from commit bb4055dac6)
2010-11-21 20:34:47 +10:30
Adrian Johnson
cfff4f30a0 PS: Fix regression - missing page content in EPS output
https://bugs.freedesktop.org/show_bug.cgi?id=24688
(cherry picked from commit d3746448d7)
2010-11-21 20:34:35 +10:30
Adrian Johnson
ed87ddddb3 PS/PDF: Fix regression when changing page size to a larger size
https://bugs.freedesktop.org/show_bug.cgi?id=24691
(cherry picked from commit e7c5f47043)
2010-11-21 20:34:18 +10:30
Adrian Johnson
ccff76433e PDF: Restrict ActualText to PDF version >= 1.5
The use of ActualText in a marked content sequence is a PDF 1.5
feature.

A 'use_actual_text' flag linked to the PDF version has already been
implemented in pdf-operators but for some reason this flag had not
been used to control the use of ActualText.
(cherry picked from commit 3afd7cd031)
2010-11-21 20:33:57 +10:30
Adrian Johnson
e0967ff83c Fix type1-fallback bbox
(cherry picked from commit 74873c8224)
2010-11-21 20:29:49 +10:30
Adrian Johnson
1413a44f64 configure.ac.features: s/Meta/Recording/
(cherry picked from commit 8f2f5e5ad4)
2010-11-21 20:28:09 +10:30
Jeff Muizelaar
e9bb70d2de Fix degenerate vertical path bounds.
6b77567b6e made vertical
path bounds with no area return extents of 0,0. This fixes
the problem by not assuming degenerate path bounds are 0,0
2010-11-05 11:40:00 -04:00
Andrea Canciani
91a6fe6423 image: Use correct size for allocation
In 06e9caf861 the type of the variables
was changed, but the type used to compute the allocation size was not.

Fixes a crash in user-font-mask (test-fallback backend).
(cherry picked from commit c7027c9d89)
2010-11-02 08:56:19 +00:00
Benjamin Otte
83259f6ed6 build: Don't build cairo-fdr when the tee surface is off 2010-10-28 13:57:05 +02:00
Adrian Johnson
efc2440526 PDF: Don't use the currently set color after a 'Q' operator
https://bugs.freedesktop.org/show_bug.cgi?id=31140
(cherry picked from commit e23bcfd430)
2010-10-28 21:33:27 +10:30
Adrian Johnson
f47830dbbc Type 1 subset: Fix glyph advance
https://bugs.freedesktop.org/show_bug.cgi?id=31062
(cherry picked from commit 6dc0b19adb)
2010-10-24 11:40:14 +10:30
Adrian Johnson
f747ea81fb PDF: Fix regression in EXTEND_NONE gradients
The test for opaque gradients in _cairo_pdf_surface_add_pdf_pattern()
must be identical to the test in
_cairo_pdf_surface_emit_pattern_stops() other wise the PDF file will
reference a smask that does not exist.

The _cairo_pattern_is_opaque() test is too strict for PDF as PDF can
draw EXTEND_NONE gradients with opaque color stops without requiring a
smask.
(cherry picked from commit 7a17ef3176)
2010-10-24 11:39:55 +10:30
Adrian Johnson
7450a3c8a7 pdf-operators: fix bug that was causing unnecessary repositioning of text
This optimizes the output to increase the maximum amount of text that
is emitted with a single Tj operator.
(cherry picked from commit 165a14b564)
2010-10-01 20:55:28 +09:30
Adrian Johnson
43c93f2b10 Fix font metrics in PDF Type 1 fonts
edcefa87 introduced a bug in the Type 1 font metrics in PDF files.
(cherry picked from commit 3f817dcfd3)
2010-10-01 20:55:14 +09:30
Chris Wilson
66ace8cd33 image: The a8 in-place span compositing is only valid for SOURCE
Fixes test/a8-clear.

Reported-by: Jeremy Moles <jeremy@emperorlinux.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-09-29 13:57:15 +01:00
Chris Wilson
05faebd584 test: Add a8-clear
Reported-by: Jeremy Moles <jeremy@emperorlinux.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-09-29 13:57:04 +01:00
Chris Wilson
ac6fd51fe4 image: Silence a compile warning
cairo-image-surface.c: In function ‘_cairo_image_reset_static_data’:
cairo-image-surface.c:1006: warning: old-style function definition

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-09-29 13:56:58 +01:00
Tim Janik
75e2b7c7b5 cairo: docu fix for cairo_set_source_surface 2010-09-23 15:12:06 +02:00