Commit graph

773 commits

Author SHA1 Message Date
Carl Worth
ec413ca3a4 Fix for bug #4401 as reported by Tim Mooney:
Don't bother checking for sincos function.
Don't use sincos function since it is apparently buggy on some platforms, (Tru64 at least).
2005-09-12 11:11:48 +00:00
Owen Taylor
d521fa3a75 Handle displays which don't match the local endianness by byteswapping on GetImage/PutImage. (#4321, reported by Sjoerd Simons) 2005-08-31 15:09:43 +00:00
Owen Taylor
44d6afc8a8 Liberalize the ServerVendor check so that we can handle the Mandriva vendor string. (#4298, Frederic Crozat) 2005-08-30 10:50:27 +00:00
Owen Taylor
a4418a63d7 Use a 8xN rather than a 1xN strip for a vertical gradient. This is much more tolerant of slow compositing code, and is worth some extra expense computing the gradient. (#4263, found in test case from Richard Stellingwerff) 2005-08-30 10:42:17 +00:00
Owen Taylor
96342fe7be Make the check for rectangular trapezoids simpler and more accurate. (#4220, found using test case from Richard Stellingwerff)
reviewed by: cworth
2005-08-27 18:54:03 +00:00
Owen Taylor
30e3d538df Make the vendor string check for XFree86 more liberal, to deal with older versions of gentoo that modified it in a different way. (#4231, fix from Billy Biggs) 2005-08-27 18:49:06 +00:00
Owen Taylor
a6acc962f7 Undef MIN/MAX before defining them in case some system header happens to define them. (#4196, Christian Biesinger) 2005-08-27 18:46:34 +00:00
Owen Taylor
3c53414cf3 Fix docs not to talk about %NULL returns. #4271, Duncan Coutts. 2005-08-27 18:40:46 +00:00
Tor Lillqvist
bd510d8b4b Drop PDF and PS backend and FT font API from Win32 DLL entry points for now. 2005-08-24 07:56:45 +00:00
Billy Biggs
985d8571d2 Fix some minor typos in the doc. 2005-08-24 06:09:11 +00:00
Keith Packard
235838d49f Use new device_x_scale/device_y_scale surface fields to set the device coordinate space to the nominal pixels.
Treat more alpha values as translucent (up to 0.999)
Fix emit_image to actually use a temporary image when necessary.
Change PS coordinate space to match cairo (top-down), adjust PS output to use new space.
Find more cases where PS output was not supported and fall back to image surface.
reviewed by: cworth
2005-08-24 01:47:13 +00:00
Keith Packard
5198e71eaf _cairo_surface_show_glyphs may return UNSUPPORTED in which case a call to scaled_font->backend->show_glyphs is needed.
reviewed by: cworth
2005-08-24 01:42:19 +00:00
Keith Packard
e4166936b9 Add device_x_scale and device_y_scale to surface so that the coordinate system seen by the backend can differ from the nominal device coordinate space used by the application.
Useful for printer backends where the device coordinate space should be in pixels while the user visible device space is in points.
There is no API to set these values; the backends using this functionality should do that themselves before the first cairo_t is created.
reviewed by: cworth
2005-08-24 01:39:56 +00:00
Carl Worth
77a0ae7439 Fix cairo_show_text to advance the current point. Add documentation for cairo_show_text.
Add test to verify that the current-point-advancing behavior of cairo_show_text is working.
Remove bug about cairo_show_text not advancing the current point.
2005-08-24 01:13:36 +00:00
Carl Worth
5ac2d216ab Update documentation for most path construction functions. Add discussion of the effects on the current point to all functions. Rephrase the wording of the relative functions. Big rewrite of cairo_arc description. Add discussion of join not caps to cairo_close_path. 2005-08-24 00:19:52 +00:00
Carl Worth
4f44cd809d Minor doc edit. 2005-08-23 23:20:53 +00:00
Billy Biggs
0b616d20dd Add a long description.
Fix a typo.
Document the return value of cairo_scaled_font_reference().
Document the width and height parameters of cairo_xlib_surface_set_drawable().
2005-08-23 21:36:08 +00:00
Billy Biggs
86889a55de Document the rest of the path functions (except the two text ones, which should coordinate with their corresponding non-path versions).
Minor shuffling.
2005-08-23 21:10:39 +00:00
Billy Biggs
326911a749 Update the long description of cairo_matrix_t to match the current sources.
Add cairo_path_data_t.
Some documentation updates and improvements.
2005-08-23 19:52:09 +00:00
Owen Taylor
00af78735e Rip out all the code for doing anything other than linear interpolation between color stops, instead of doing different funky things based on pattern->filter. (#4184) 2005-08-23 14:53:08 +00:00
Owen Taylor
48b3a1cacd Check for AlphaBlend() with GetProcAddress() to support older compilation environments like MSVC 6. (Also fixes this portion of the code to run on Win98 and Win95, but much of the rest of cairo-win32-* won't work in that environment) (#3926, Hans Breuer, Christian Biesinger, based on code originally from Mozilla)
Remove WINVER define, since it was there only for AlphaBlend().
2005-08-23 14:52:38 +00:00
Carl Worth
c4c1c4db96 Remove assert statements that violate two intentional instances of ref_count == 0. 2005-08-23 14:51:51 +00:00
Owen Taylor
a96a4a7ce6 Check for AlphaBlend() with GetProcAddress() to support older compilation environments like MSVC 6. (Also fixes this portion of the code to run on Win98 and Win95, but much of the rest of cairo-win32-* won't work in that environment) (#3926, Hans Breuer, Christian Biesinger, based on code originally from Mozilla)
Remove WINVER define, since it was (hopefully) there only for AlphaBlend().
2005-08-23 14:30:52 +00:00
Owen Taylor
6d8df3957d Call _get_pattern_load_flags() on the resolved pattern, not the input pattern. (Further fix from sunmoon1997) 2005-08-23 14:12:01 +00:00
Carl Worth
f219b83466 if users attempt to twice destroy or re-reference a destroyed object. The condition for detecting this case is a ref_count of 0.
Reviewed by: otaylor Fixes bug #4198
2005-08-23 14:04:28 +00:00
Carl Worth
a0ecb16417 Move CAIRO_CONTENT_VALID and CAIRO_FORMAT_VALID from the public cairo.h to the private cairoint.h where they belong. 2005-08-23 13:57:00 +00:00
Owen Taylor
f229b1abfb when creating the temporary mask, do glyph ADD mask, not (glyph IN source) ADD mask. Set the mask as having component alpha when it's 4-channel.
test/text-antialias-subpixel.c test/Makefile.am: No longer XFAIL.
test/text-antialias-gray.c test/text-antialias-subpixel.c
Don't turn off metrics hinting, it doesn't make sense.
Update.
2005-08-23 13:34:14 +00:00
Carl Worth
0c2aa6e6ab Move comment about missing cleanup of caches on XCloseDisplay from BUGS to a _cairo_xlib_close_display. Also covered in bug #4120. 2005-08-23 08:21:46 +00:00
Carl Worth
256456b708 Fix for bug #4205:
Abstract the cap-addition code from the end of the stroke operation into a new _cairo_stroker_add_caps function.
Call the new _cairo_stroker_add_caps at the beginning of every move_to so that we get caps on every subpath and not just the last one.
2005-08-23 07:44:14 +00:00
Billy Biggs
55a517991e Add libpixman.la to the libcairo_la_DEPENDENCIES line so that changes to pixman get picked up. 2005-08-23 05:54:38 +00:00
Owen Taylor
099060f925 Some fixes for warnings from sparse (Part of #4208, Kjartan Maraas)
Use NULL, not 0.
Fix C99'ism of mixed code and declarations.
2005-08-23 05:18:48 +00:00
Carl Worth
65bfc03e72 Remove discussion of the BAD_NESTING restriction from the documentation of cairo_create. No such restriction exists anymore. 2005-08-23 00:03:09 +00:00
Carl Worth
c0bbf9ac08 Fix for bug #4192:
New function to handle both calling FT_Done_Face on unscaled->face and decrementing font_map->num_open_faces.
Call new _font_map_release_face_lock_held as approporiate.
Assert that (font_map->num_open_faces == 0) when we're done, to help guarantee the bug is fixed.
Don't call FT_Done_Face anymore, instead assert that (unscaled->face == NULL) by the time this function is called.
Prefer TRUE/FALSE as values for cairo_bool_t have_scale.
2005-08-23 00:00:42 +00:00
Owen Taylor
2d9d744f8c Make cairo_ft_unscaled_font_backend static.
Add missing static.
Use NULL, not 0.
Use void in the definition of void functions, not ().
Make non-exported cairo_pattern_nil_* static.
2005-08-22 20:43:23 +00:00
Bertram Felgenhauer
23baafbaa8 remove. 2005-08-22 16:52:40 +00:00
Bertram Felgenhauer
9883104290 correct the calculation of the error bound. 2005-08-22 16:50:30 +00:00
Bertram Felgenhauer
c0905759b0 use new function. strip comment of derivation for major axis length.
use _cairo_matrix_get_affine to retrieve matrix entries.
new function split out of cairo-pen.c. UTF8-ify the comment that explains the calculation.
2005-08-22 16:48:28 +00:00
Bertram Felgenhauer
c7a35fbd31 use correctly transposed version of the matrix and fix up the comments above to use row vector notation. 2005-08-22 16:29:56 +00:00
Tor Lillqvist
46dd21e795 Calculate LT_CURRENT_MINUS_AGE (which forms part of the DLL name on Win32), and AC_SUBST it.
Add target "zips" to create zip file based distribution for Win32.
Produce a cairo.def file for distribution by preprocessing the relevant header files and grepping for declarations of functions that start with cairo_. Works for now, will have to modify later if necessary. Use the .def file when linking on Win32.
2005-08-22 15:49:04 +00:00
Owen Taylor
aa6b2c386b Support artificial bold fonts with FC_EMBOLDEN; patch from Jackey Yang and sunmoon1997.
Check for FT_GlyphSlot_Embolden()
Call FT_GlyphSlot_Embolden for fonts where FC_EMBOLDEN is set but that aren't bold. Add another private flag for this.
2005-08-22 15:19:03 +00:00
Billy Biggs
fdb5e2aa47 Optimize away calls to cairo_paint_with_alpha() if the alpha value given is <= 0.
Add a new macro CAIRO_ALPHA_IS_ZERO.
2005-08-21 21:04:52 +00:00
Billy Biggs
33599bc6b6 Fix for bug #4172:
Use _cairo_fixed_to_double and _cairo_double_to_fixed when converting between double and 16.16 fixed point. These functions round nicely, and solve some inconsistencies in rendering between my PPC and x86 machines. Thanks to Owen Taylor for suggesting the fix.
The above change does affect linear gradients slightly, but it seems worth it. Update the reference images to follow.
2005-08-21 14:10:39 +00:00
Owen Taylor
e3e7046cd7 Remove stray doc sentence that wasn't meant to be committed. 2005-08-21 12:13:17 +00:00
Billy Biggs
17845df95b Fix for bug #4165:
Use pointer comparison for coincident points to ensure a well-defined ordering, and avoid setting discard on both points. This fixes problems with my Mac's implementation of qsort. Final patch by Bertram Felgenhauer.
Update reference images after the change.
2005-08-21 11:41:44 +00:00
Owen Taylor
1ce62becd1 Fix the handling of backend->clone_similar == NULL. (#4161, Christian Biesinger) 2005-08-21 08:53:56 +00:00
Owen Taylor
8e9e40d752 Improve the documentation of internal functions. (Based on a patch from Christian Biesinger, #4162) 2005-08-21 08:24:41 +00:00
Owen Taylor
65f90287bb Recognize gentoo's (and maybe other distro's) modified server vendor string, where extra text is added to the upstream value. (#4068, reported by Doug Goldstein, others. Patch from Mart Raudsepp) 2005-08-21 08:11:24 +00:00
Owen Taylor
af614d2de6 Don't try to transform val->image when it is NULL. (#4163, Mathias Hasselmann) 2005-08-21 08:06:06 +00:00
Owen Taylor
4a7a09b4ab Include Xfree86-4.5 in the blacklist. (Reported by Andrew Benton) 2005-08-20 05:23:52 +00:00
Billy Biggs
b9da101879 Fix for bug #4096:
Improve the performance of png reading by adding special cases for fully transparent and fully opaque alpha, and using the standard optimization for 8-bit division by 255.
Add an INLINE macro for gcc.
2005-08-19 23:05:13 +00:00