Commit graph

6300 commits

Author SHA1 Message Date
Carl Worth
2297f98786 Increment cairo version to 1.8.11
Following the 1.8.10 release.
2010-02-19 16:30:18 -08:00
Carl Worth
dc7eba7564 Increment cairo version to 1.8.10.
For the 1.8.10 release, of course.
2010-02-19 16:24:49 -08:00
Carl Worth
feadfb7c69 NEWS: Add notes for the 1.8.10 release.
Summarizing all bug fixes (as well as I could).
2010-02-19 16:23:23 -08:00
Carl Worth
6a46fabf7c Fix "make distcheck" to avoid complaints about duplicate getline definition
The _GNU_SOURCE macro needs to be defined first, (so that now included
file includes any C library header (such as stdio.h) without this
definition in place. Without this fix, "make check" in the perf
directory would fail.
2010-02-19 15:59:06 -08:00
Adrian Johnson
e5552dda22 Fix bug in _cairo_ft_index_to_ucs4
Previously it would miss the first character causing the space glyph to
return 0x00A0 instead of 0x0020.
(cherry picked from commit f3b3a5c43f)
2010-02-19 13:33:51 -08:00
Chris Wilson
af10ae114b arc: Just emit a line-to if radius is zero.
In order to be consistent with the semantics of cairo_arc() using a
radius of 0 should simply degenerate into a line-to.

Reported-by: Benjamin Berg
(cherry picked from commit a0ea0b63fd)
2010-02-19 13:33:42 -08:00
Adrian Johnson
546edda521 Type1-subset: Append "cleartomark" operator for binary fonts that don't include it
Type 1 fonts embedded in PDF may omit the fixed-content portion of the
font that contains the "cleartomark" operator.
(cherry picked from commit cee3a6169b)
2010-02-19 13:33:22 -08:00
Adrian Johnson
af5f90df1d PDF: Include Type 1 fixed-content portion in the embedded font
Some fonts may contain additional PostScript code after the
cleartomark.
(cherry picked from commit d962d6bae2)
2010-02-19 13:32:13 -08:00
Adrian Johnson
7169e1f694 Type1-subset: Check for binary eexec data
Type 1 fonts embedded in PDF have the the encrypted portion in binary
but the existing check for binary only works for Type 1 fonts in PFB
format.

Add an additional check based on the first 4 characters of eexec data.
The Type 1 specification gurantees that at least one of the first 4
bytes of ciphertext is not an ASCII Hex character.
(cherry picked from commit ac59c75808)
2010-02-19 13:28:59 -08:00
Adrian Johnson
7f22d9d433 Type 1 subset: Don't add a new line when in binary mode
At the end of the private dictionary a new line is appended so that
the trailing zeros will not exceed 80 columns. In hex mode (used for
PS embedding) extra white space is harmless as it is ignored when
parsing the ascii hex encoded data. But in binary mode (used for PDF
embedding) the new line must not be added as it corrupts the binary
data.

https://bugs.launchpad.net/ubuntu/+source/cups/+bug/419143
(cherry picked from commit a4a59be600)
2009-11-07 14:54:47 +10:30
M Joonas Pihlaja
0a5ec9802a [build] Look for libpng.pc as well when configuring.
The OpenBSD png package installs only libpng.pc and not
any of libpng{13,12,10}.pc.
2009-11-01 17:37:39 +02:00
Benjamin Otte
c4cc224781 [xlib] DO_XCOPYAREA and DO_XTILE optimizations break with Window source
Cairo should include the contents of subwindows when using a Window as a
source but will clip to subwindows when using a Window as a destination.
This can be set using the GC's subwindow_mode.

XCopyArea and XFillRectangle can however only use one GC for both source
and destination. Cairo's mode is set to (the default) ClipByChildren.
This means that copying from a Window is broken, so we only allow the
optimization when we know that the source is a Pixmap.

The performance impact of this change has not been tested. It should be
small, as the code will use XRender otherwise.

If it turns out to be a bigger impact, the optimizations could be
improved by doing a two-step copy process:
1) Copy to an intermediate Pixmap with IncludeInferiors
2) Copy to the destination with ClipByChildren
(potentially omitting one one of the steps if source or destination are
known to be Pixmaps).

references:
commit 0c5d28a4e5
https://bugs.freedesktop.org/show_bug.cgi?id=12996
2009-10-16 18:24:59 +03:00
Chris Wilson
06c2a4d234 [surface] Protect against the user setting a fallback resolution of 0.
Bug 23067 -- using clear drawing operator crashes printing
http://bugs.freedesktop.org/show_bug.cgi?id=23067

Here we were hitting an assert within the paginated surface after creating
a zero sized fallback image, due to the paginated surface being created
with an x fallback resolution of 0 dpi (by
_gtk_printer_create_cairo_surface(), gtk/gtkprinter.c:924).

Avoid the bug by guarding against bad input to
cairo_surface_set_fallback_resolution() which also allows us to identity
the invalid caller.
2009-08-05 15:18:21 +01:00
Chris Wilson
77b7d6f487 [cairo] Offset the current path when pushing/popping groups.
We need to translate the path in order to compensate for the device offset
applied to the group surface when pushing and popping. (The path is
transformed to device space on creation, and so needs recomputing for the
new device.)
2009-06-19 19:19:51 +01:00
Nis Martensen
158ab5cded [path] Fix missing implicit move-to
When cairo_curve_to happens to start a new subpath (e.g., after a call
to cairo_new_sub_path()), it also needs to update the last_move_point.
Otherwise the new current point after a close_path() will be at an
unexpected position.

Therefore, call _cairo_path_fixed_move_to() explicitly.
2009-06-17 16:45:48 +01:00
Chris Wilson
f10bafdcdd Post release version increment to 1.8.9 2009-06-16 14:09:23 +01:00
Chris Wilson
7dd89ff7a1 Increment version to 1.8.8
Release time!
2009-06-16 13:24:22 +01:00
Chris Wilson
7da47e6647 [test] New smask reference image for xlib.
More font change fallout?
2009-06-16 13:15:01 +01:00
Chris Wilson
9342e432f8 [NEWS] Tweak line break. 2009-06-16 13:13:46 +01:00
Chris Wilson
6bab2dc0a0 [NEWS] Correct date.
It's now been a fortnight since I've started this release process...
2009-06-16 13:12:57 +01:00
Chris Wilson
2450fc4fad [NEWS] Release notes for 1.8.8 2009-06-16 11:52:39 +01:00
Jeff Muizelaar
7a5f7b4a4b Fix compilation on OS X when compiling for 64 bit
OS X doesn't support ATSUI in 64 bit so don't include the cairo ATSUI
API in that case.
2009-06-16 11:48:54 +01:00
Chris Wilson
c21a9eecb0 [win32-font] Non-fatal error from GetGlyphOutlineW(GGO_METRICS)
If GetGlyphOutlineW(GGO_METRICS) fails to retreive the metrics for the
specified glyph it returns GDI_ERROR. Like ft, do not interpret this as a
fatal error but just mark the glyph as empty.

Fixes http://bugs.freedesktop.org/show_bug.cgi?id=20255
Bug 20255 -- cairo_scaled_font_glyph_extents breaks with invalid glyph id
2009-06-10 13:05:18 +01:00
Chris Wilson
2fd0beab2a [ft] Don't call FT_Done_Face() on a face we do not own
_font_map_release_face_lock_held() was being called unconditionally during
_cairo_ft_font_reset_static_data(). This presents two problems. The first
is that we call FT_Done_Face() on an object not owned by cairo, and the
second is that the bookkeeping is then incorrect which will trigger an
assert later.
2009-06-06 16:17:03 +01:00
Chris Wilson
0e38fe1c67 [boilerplate] Read big-endian images from any2ppm 2009-06-03 23:00:42 +01:00
Chris Wilson
3914c8e5b2 [test] fix bad merge in previous commit
Missed the conversion of row from char to int.
2009-06-03 22:52:58 +01:00
Chris Wilson
a52f4cea1f [test] Ensure ppm are in correct byte orientation.
Correct the image conversion failures on big-endian architectures.
2009-06-03 22:48:31 +01:00
Chris Wilson
018275c953 [pattern] Typo in document
Remove extraneous markup from program-listing.

https://bugs.freedesktop.org/show_bug.cgi?id=20441
2009-06-03 20:19:24 +01:00
Chris Wilson
ee90a33169 [cairo] Doc typo.
Fix conflicting sentence as pointed out by
https://bugs.freedesktop.org/show_bug.cgi?id=20183
2009-06-03 10:53:10 +01:00
Chris Wilson
bf6e306013 [image] Doc typo.
Correct parameter reference as pointed out by
https://bugs.freedesktop.org/show_bug.cgi?id=20182
2009-06-03 10:53:01 +01:00
Chris Wilson
234b2d077c [font-options] Doc typo
Remove duplicate 'with' as pointed out by
https://bugs.freedesktop.org/show_bug.cgi?id=20180
2009-06-03 10:52:48 +01:00
Chris Wilson
cbdccac88b [cairo] Update documentation for bug 20154
Several typographical errors were pointed out in
https://bugs.freedesktop.org/show_bug.cgi?id=20154
2009-06-03 10:39:33 +01:00
Adrian Johnson
a278c1bea9 Ensure win32 font index_to_ucs4() sets ucs4 to -1 if lookup fails 2009-06-03 10:22:45 +01:00
Chris Wilson
7f08a2c241 [configure] Replace awk comparator with an aclocal version
As reported in https://bugs.freedesktop.org/show_bug.cgi?id=19283, the
fallback freetype version compare is broken inside the configure script as
the $1-$3 arguments are interpreted as the script is constructed. To avoid
making that awk comparison any more complicated, we import a version compare
from the autoconf archives - such that we have a reusable macro for the
furture.
2009-06-03 09:11:43 +01:00
Chris Wilson
d32470555c [test] Refresh ghostscript reference images
A couple of minor differences with 8.64 vs 8.62
2009-06-03 09:10:51 +01:00
Chris Wilson
d45f99330b [test] Update smask text
Smells like a font change...
2009-06-03 08:42:45 +01:00
Chris Wilson
3ecb25d238 [test] Refresh pdf reference images
Update to reflect current poppler rendering misbehaviour.
2009-06-03 07:59:41 +01:00
Karl Tomlinson
c8f4b2fe80 [ft] Resolve mutual referencing problems with zombie faces
Bug 21706 -- zombie ft_font_face / ft_unscaled_font mutual
             referencing problems
[http://bugs.freedesktop.org/show_bug.cgi?id=21706]

There can be more than one zombie font_face belonging to an unscaled_font,
but only the first is destroyed.  This leaks the client's FT_Face
(and associated font data) as release of the FT_Face depends on release
of the font_face.

(The reason why Firefox ends up with two different font_faces for one
unscaled_font is that load_flags for faces with artificial oblique have
FT_LOAD_NO_BITMAP set.
https://bugzilla.mozilla.org/show_bug.cgi?id=486974)

Also it's possible for _cairo_ft_font_face_create to pull out a zombie
font_face from the unscaled_font, which would crash
_cairo_ft_font_face_scaled_font_create, as that expects non-null
font_face->unscaled (if !font-face->pattern).
2009-06-03 07:17:10 +01:00
Behdad Esfahbod
634298af13 [ft] Fix vertical advance metrics of bitmap fonts (#21985) 2009-06-03 07:16:58 +01:00
Chris Wilson
5c63efe5fd [test] Relax APPROX_EQUALS condition
The bounding box of the text is rounded to the nearest pixel boundaries,
so therefore the test must accept a similar level of imprecision.
2009-06-03 07:08:56 +01:00
Chris Wilson
130ac1f945 [test] Sync with memfault headers.
Update the macros to reflect the current version of memfault.
2009-06-03 07:06:42 +01:00
Chris Wilson
de7270cb1e [cairo] Describe the restrictions upon cairo_set_tolerance()
Truc Troung reported that the behaviour of
cairo_set_tolerance()/cairo_get_tolerance() was inconsistent with the
documentation, i.e. we failed to mention that the tolerance would be
restricted to the smalled fixed-point value.

Add a sentence to the documentation that describes the restriction without
mentioning what that is... Hopefully that is sufficient detail to
accommodate the reporter, without exposing internal implementation details.

Fixes https://bugs.freedesktop.org/show_bug.cgi?id=20095
Bug 20095 - The cairo_set_tolerance() function behavior is inconsistency
with the spec
2009-02-13 10:07:37 +00:00
Chris Wilson
e7d4bc3d86 [png] Correct documentation to avoid reference to NULL
As pointed out by Truc Truong,
cairo_image_surface_create_from_png_stream() cannot return NULL and so the
documentation was incorrect.

Fixes http://bugs.freedesktop.org/show_bug.cgi?id=20075
Bug 20075 There is a misprint in the spec for
cairo_image_surface_create_from_png_stream() function
2009-02-12 10:42:24 +00:00
M Joonas Pihlaja
a5c1cdf2b0 [clip] Fix uninitialised status return in _cairo_clip_intersect_mask() for empty extents.
This fixes the clip-all test case crashing for me.
2009-01-05 14:19:42 +00:00
Jeff Muizelaar
f60da9a379 Fix _compute_transform to check for nearly degenerate matrices
If a matrix was something like [0 .000001 0, .000001 0 0] the old code would
assume that xx and yy were greater than 0 and turn the nearly degenerate matrix
into an actual degenerate one. This caused things to blow up later on. Now we
check that our nearly rectangular matrices are not nearly degenerate, and let
the nearly degenerate ones fall through to the non-rectangular path.

Note: I'm not sure why NEARLY_ZERO(d) is fabs(d) < 1/65536 instead of some
other value.  Hopefully, it's a useful definition.

This problem was found by a test case attached to:
https://bugzilla.mozilla.org/show_bug.cgi?id=467423
2008-12-18 17:07:25 -05:00
Karl Tomlinson
0137b9bd32 [ft] Don't call FT_Done_Face() on faces we did not create 2008-12-17 16:42:20 -05:00
Chris Wilson
9485cd947f Increment version to 1.8.7 after the 1.8.6 release. 2008-12-14 16:35:14 +00:00
Chris Wilson
e2a2eddcfb Increment version to 1.8.6
In preparation for the next stable release.
2008-12-14 14:54:35 +00:00
Chris Wilson
ef7c42a7d3 [NEWS] Add notes for 1.8.6
Add the historical blurb for 1.8.6.
2008-12-14 14:54:35 +00:00
Chris Wilson
ce91e6ac36 [perf] Fix for git-1.6
git-1.6 moved all the subcommands out of the PATH so update our usage.
2008-12-14 14:54:34 +00:00