diff -Nru cairo-1.15.8/aclocal.m4 cairo-1.15.10/aclocal.m4 --- cairo-1.15.8/aclocal.m4 2017-08-29 17:02:10.000000000 +0000 +++ cairo-1.15.10/aclocal.m4 2017-12-11 21:03:09.000000000 +0000 @@ -1214,9 +1214,9 @@ m4_include([build/aclocal.compare.m4]) m4_include([build/aclocal.enable.m4]) m4_include([build/aclocal.float.m4]) -m4_include([build/aclocal.gtk-doc.m4]) m4_include([build/aclocal.makefile.m4]) m4_include([build/aclocal.pkg.m4]) +m4_include([build/gtk-doc.m4]) m4_include([build/libtool.m4]) m4_include([build/ltoptions.m4]) m4_include([build/ltsugar.m4]) diff -Nru cairo-1.15.8/autogen.sh cairo-1.15.10/autogen.sh --- cairo-1.15.8/autogen.sh 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/autogen.sh 2017-12-07 02:13:45.000000000 +0000 @@ -9,7 +9,7 @@ AUTORECONF=`which autoreconf` if test -z $AUTORECONF; then - echo "*** No autoreconf found, please intall it ***" + echo "*** No autoreconf found, please install it ***" exit 1 fi diff -Nru cairo-1.15.8/boilerplate/cairo-boilerplate.c cairo-1.15.10/boilerplate/cairo-boilerplate.c --- cairo-1.15.8/boilerplate/cairo-boilerplate.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/boilerplate/cairo-boilerplate.c 2017-12-07 02:14:36.000000000 +0000 @@ -42,6 +42,7 @@ #undef CAIRO_VERSION_H #include "../cairo-version.h" +#include #include #include #include @@ -976,7 +977,8 @@ cairo_boilerplate_image_surface_create_from_ppm_stream (FILE *file) { char format; - int width, height, stride; + int width, height; + ptrdiff_t stride; int x, y; unsigned char *data; cairo_surface_t *image = NULL; diff -Nru cairo-1.15.8/boilerplate/cairo-boilerplate-constructors.c cairo-1.15.10/boilerplate/cairo-boilerplate-constructors.c --- cairo-1.15.8/boilerplate/cairo-boilerplate-constructors.c 2017-08-29 17:05:45.000000000 +0000 +++ cairo-1.15.10/boilerplate/cairo-boilerplate-constructors.c 2017-12-11 21:03:31.000000000 +0000 @@ -5,17 +5,21 @@ void _cairo_boilerplate_register_all (void); extern void _register_builtin (void); +extern void _register_xlib (void); +extern void _register_xcb (void); extern void _register_script (void); extern void _register_ps (void); +extern void _register_pdf (void); extern void _register_svg (void); -extern void _register_test (void); void _cairo_boilerplate_register_all (void) { _register_builtin (); + _register_xlib (); + _register_xcb (); _register_script (); _register_ps (); + _register_pdf (); _register_svg (); - _register_test (); } diff -Nru cairo-1.15.8/boilerplate/cairo-boilerplate-egl.c cairo-1.15.10/boilerplate/cairo-boilerplate-egl.c --- cairo-1.15.8/boilerplate/cairo-boilerplate-egl.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/boilerplate/cairo-boilerplate-egl.c 2017-12-07 02:14:36.000000000 +0000 @@ -33,10 +33,13 @@ #include "cairo-boilerplate-private.h" #include -#if CAIRO_HAS_GL_SURFACE -#include +#if CAIRO_HAS_GLESV3_SURFACE +#include +#include #elif CAIRO_HAS_GLESV2_SURFACE #include +#elif CAIRO_HAS_GL_SURFACE +#include #endif static const cairo_user_data_key_t gl_closure_key; @@ -85,15 +88,19 @@ EGL_BLUE_SIZE, 8, EGL_ALPHA_SIZE, 8, EGL_SURFACE_TYPE, EGL_PBUFFER_BIT, -#if CAIRO_HAS_GL_SURFACE - EGL_RENDERABLE_TYPE, EGL_OPENGL_BIT, +#if CAIRO_HAS_GLESV3_SURFACE + EGL_RENDERABLE_TYPE, EGL_OPENGL_ES3_BIT_KHR, #elif CAIRO_HAS_GLESV2_SURFACE EGL_RENDERABLE_TYPE, EGL_OPENGL_ES2_BIT, +#elif CAIRO_HAS_GL_SURFACE + EGL_RENDERABLE_TYPE, EGL_OPENGL_BIT, #endif EGL_NONE }; const EGLint ctx_attribs[] = { -#if CAIRO_HAS_GLESV2_SURFACE +#if CAIRO_HAS_GLESV3_SURFACE + EGL_CONTEXT_CLIENT_VERSION, 3, +#elif CAIRO_HAS_GLESV2_SURFACE EGL_CONTEXT_CLIENT_VERSION, 2, #endif EGL_NONE @@ -110,15 +117,22 @@ } eglChooseConfig (gltc->dpy, config_attribs, &config, 1, &numConfigs); +#if CAIRO_HAS_GLESV3_SURFACE && CAIRO_HAS_GLESV2_SURFACE + if (numConfigs == 0) { + /* retry with ES2_BIT */ + config_attribs[11] = ES2_BIT; /* FIXME: Ick */ + eglChooseConfig (gltc->dpy, config_attribs, &config, 1, &numConfigs); + } +#endif if (numConfigs == 0) { free (gltc); return NULL; } -#if CAIRO_HAS_GL_SURFACE - eglBindAPI (EGL_OPENGL_API); -#elif CAIRO_HAS_GLESV2_SURFACE +#if CAIRO_HAS_GLESV3_SURFACE || CAIRO_HAS_GLESV2_SURFACE eglBindAPI (EGL_OPENGL_ES_API); +#elif CAIRO_HAS_GL_SURFACE + eglBindAPI (EGL_OPENGL_API); #endif gltc->ctx = eglCreateContext (gltc->dpy, config, EGL_NO_CONTEXT, diff -Nru cairo-1.15.8/boilerplate/cairo-boilerplate-pdf.c cairo-1.15.10/boilerplate/cairo-boilerplate-pdf.c --- cairo-1.15.8/boilerplate/cairo-boilerplate-pdf.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/boilerplate/cairo-boilerplate-pdf.c 2017-12-07 02:14:36.000000000 +0000 @@ -84,6 +84,7 @@ if (cairo_surface_status (surface)) goto CLEANUP_FILENAME; + cairo_pdf_surface_set_metadata (surface, CAIRO_PDF_METADATA_CREATE_DATE, NULL); cairo_surface_set_fallback_resolution (surface, 72., 72.); if (content == CAIRO_CONTENT_COLOR) { diff -Nru cairo-1.15.8/boilerplate/Makefile.am.features cairo-1.15.10/boilerplate/Makefile.am.features --- cairo-1.15.8/boilerplate/Makefile.am.features 2017-04-24 22:50:27.000000000 +0000 +++ cairo-1.15.10/boilerplate/Makefile.am.features 2017-12-07 02:15:43.000000000 +0000 @@ -243,6 +243,18 @@ enabled_cairo_boilerplate_sources += $(cairo_boilerplate_glesv2_sources) endif +unsupported_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers) +all_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers) +all_cairo_boilerplate_private += $(cairo_boilerplate_glesv3_private) +all_cairo_boilerplate_cxx_sources += $(cairo_boilerplate_glesv3_cxx_sources) +all_cairo_boilerplate_sources += $(cairo_boilerplate_glesv3_sources) +if CAIRO_HAS_GLESV3_SURFACE +enabled_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers) +enabled_cairo_boilerplate_private += $(cairo_boilerplate_glesv3_private) +enabled_cairo_boilerplate_cxx_sources += $(cairo_boilerplate_glesv3_cxx_sources) +enabled_cairo_boilerplate_sources += $(cairo_boilerplate_glesv3_sources) +endif + unsupported_cairo_boilerplate_headers += $(cairo_boilerplate_cogl_headers) all_cairo_boilerplate_headers += $(cairo_boilerplate_cogl_headers) all_cairo_boilerplate_private += $(cairo_boilerplate_cogl_private) diff -Nru cairo-1.15.8/boilerplate/Makefile.in cairo-1.15.10/boilerplate/Makefile.in --- cairo-1.15.8/boilerplate/Makefile.in 2017-08-29 17:02:11.000000000 +0000 +++ cairo-1.15.10/boilerplate/Makefile.in 2017-12-11 21:03:10.000000000 +0000 @@ -175,94 +175,97 @@ @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_74 = $(cairo_boilerplate_glesv2_private) @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_75 = $(cairo_boilerplate_glesv2_cxx_sources) @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_76 = $(cairo_boilerplate_glesv2_sources) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_77 = $(cairo_boilerplate_cogl_headers) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_78 = $(cairo_boilerplate_cogl_private) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_79 = $(cairo_boilerplate_cogl_cxx_sources) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_80 = $(cairo_boilerplate_cogl_sources) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_81 = $(cairo_boilerplate_directfb_headers) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_82 = $(cairo_boilerplate_directfb_private) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_83 = $(cairo_boilerplate_directfb_cxx_sources) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_84 = $(cairo_boilerplate_directfb_sources) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_85 = $(cairo_boilerplate_vg_headers) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_86 = $(cairo_boilerplate_vg_private) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_87 = $(cairo_boilerplate_vg_cxx_sources) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_88 = $(cairo_boilerplate_vg_sources) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_89 = $(cairo_boilerplate_egl_headers) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_90 = $(cairo_boilerplate_egl_private) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_91 = $(cairo_boilerplate_egl_cxx_sources) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_92 = $(cairo_boilerplate_egl_sources) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_93 = $(cairo_boilerplate_glx_headers) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_94 = $(cairo_boilerplate_glx_private) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_95 = $(cairo_boilerplate_glx_cxx_sources) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_96 = $(cairo_boilerplate_glx_sources) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_97 = $(cairo_boilerplate_wgl_headers) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_98 = $(cairo_boilerplate_wgl_private) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_99 = $(cairo_boilerplate_wgl_cxx_sources) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_100 = $(cairo_boilerplate_wgl_sources) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_101 = $(cairo_boilerplate_script_headers) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_102 = $(cairo_boilerplate_script_private) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_103 = $(cairo_boilerplate_script_cxx_sources) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_104 = $(cairo_boilerplate_script_sources) -@CAIRO_HAS_FT_FONT_TRUE@am__append_105 = $(cairo_boilerplate_ft_headers) -@CAIRO_HAS_FT_FONT_TRUE@am__append_106 = $(cairo_boilerplate_ft_private) -@CAIRO_HAS_FT_FONT_TRUE@am__append_107 = $(cairo_boilerplate_ft_cxx_sources) -@CAIRO_HAS_FT_FONT_TRUE@am__append_108 = $(cairo_boilerplate_ft_sources) -@CAIRO_HAS_FC_FONT_TRUE@am__append_109 = $(cairo_boilerplate_fc_headers) -@CAIRO_HAS_FC_FONT_TRUE@am__append_110 = $(cairo_boilerplate_fc_private) -@CAIRO_HAS_FC_FONT_TRUE@am__append_111 = $(cairo_boilerplate_fc_cxx_sources) -@CAIRO_HAS_FC_FONT_TRUE@am__append_112 = $(cairo_boilerplate_fc_sources) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_113 = $(cairo_boilerplate_ps_headers) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_114 = $(cairo_boilerplate_ps_private) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_115 = $(cairo_boilerplate_ps_cxx_sources) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_116 = $(cairo_boilerplate_ps_sources) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_117 = $(cairo_boilerplate_pdf_headers) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_118 = $(cairo_boilerplate_pdf_private) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_119 = $(cairo_boilerplate_pdf_cxx_sources) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_120 = $(cairo_boilerplate_pdf_sources) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_121 = $(cairo_boilerplate_svg_headers) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_122 = $(cairo_boilerplate_svg_private) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_123 = $(cairo_boilerplate_svg_cxx_sources) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_124 = $(cairo_boilerplate_svg_sources) -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_125 = $(cairo_boilerplate_test_surfaces_private) $(cairo_boilerplate_test_surfaces_headers) -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_126 = $(cairo_boilerplate_test_surfaces_cxx_sources) -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_127 = $(cairo_boilerplate_test_surfaces_sources) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_128 = $(cairo_boilerplate_tee_headers) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_129 = $(cairo_boilerplate_tee_private) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_130 = $(cairo_boilerplate_tee_cxx_sources) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_131 = $(cairo_boilerplate_tee_sources) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_132 = $(cairo_boilerplate_xml_headers) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_133 = $(cairo_boilerplate_xml_private) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_134 = $(cairo_boilerplate_xml_cxx_sources) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_135 = $(cairo_boilerplate_xml_sources) -@CAIRO_HAS_PTHREAD_TRUE@am__append_136 = $(cairo_boilerplate_pthread_private) $(cairo_boilerplate_pthread_headers) -@CAIRO_HAS_PTHREAD_TRUE@am__append_137 = $(cairo_boilerplate_pthread_cxx_sources) -@CAIRO_HAS_PTHREAD_TRUE@am__append_138 = $(cairo_boilerplate_pthread_sources) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_139 = $(cairo_boilerplate_gobject_headers) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_140 = $(cairo_boilerplate_gobject_private) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_141 = $(cairo_boilerplate_gobject_cxx_sources) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_142 = $(cairo_boilerplate_gobject_sources) -@CAIRO_HAS_TRACE_TRUE@am__append_143 = $(cairo_boilerplate_trace_private) $(cairo_boilerplate_trace_headers) -@CAIRO_HAS_TRACE_TRUE@am__append_144 = $(cairo_boilerplate_trace_cxx_sources) -@CAIRO_HAS_TRACE_TRUE@am__append_145 = $(cairo_boilerplate_trace_sources) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_146 = $(cairo_boilerplate_interpreter_private) $(cairo_boilerplate_interpreter_headers) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_147 = $(cairo_boilerplate_interpreter_cxx_sources) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_148 = $(cairo_boilerplate_interpreter_sources) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_149 = $(cairo_boilerplate_symbol_lookup_private) $(cairo_boilerplate_symbol_lookup_headers) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_150 = $(cairo_boilerplate_symbol_lookup_cxx_sources) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_151 = $(cairo_boilerplate_symbol_lookup_sources) -@CAIRO_HAS_DL_TRUE@am__append_152 = -ldl -@CAIRO_HAS_WIN32_SURFACE_TRUE@am__append_153 = -lwinspool -@CROSS_COMPILING_FALSE@am__append_154 = check-link$(EXEEXT) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_77 = $(cairo_boilerplate_glesv3_headers) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_78 = $(cairo_boilerplate_glesv3_private) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_79 = $(cairo_boilerplate_glesv3_cxx_sources) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_80 = $(cairo_boilerplate_glesv3_sources) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_81 = $(cairo_boilerplate_cogl_headers) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_82 = $(cairo_boilerplate_cogl_private) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_83 = $(cairo_boilerplate_cogl_cxx_sources) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_84 = $(cairo_boilerplate_cogl_sources) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_85 = $(cairo_boilerplate_directfb_headers) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_86 = $(cairo_boilerplate_directfb_private) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_87 = $(cairo_boilerplate_directfb_cxx_sources) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_88 = $(cairo_boilerplate_directfb_sources) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_89 = $(cairo_boilerplate_vg_headers) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_90 = $(cairo_boilerplate_vg_private) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_91 = $(cairo_boilerplate_vg_cxx_sources) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_92 = $(cairo_boilerplate_vg_sources) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_93 = $(cairo_boilerplate_egl_headers) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_94 = $(cairo_boilerplate_egl_private) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_95 = $(cairo_boilerplate_egl_cxx_sources) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_96 = $(cairo_boilerplate_egl_sources) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_97 = $(cairo_boilerplate_glx_headers) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_98 = $(cairo_boilerplate_glx_private) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_99 = $(cairo_boilerplate_glx_cxx_sources) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_100 = $(cairo_boilerplate_glx_sources) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_101 = $(cairo_boilerplate_wgl_headers) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_102 = $(cairo_boilerplate_wgl_private) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_103 = $(cairo_boilerplate_wgl_cxx_sources) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_104 = $(cairo_boilerplate_wgl_sources) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_105 = $(cairo_boilerplate_script_headers) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_106 = $(cairo_boilerplate_script_private) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_107 = $(cairo_boilerplate_script_cxx_sources) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_108 = $(cairo_boilerplate_script_sources) +@CAIRO_HAS_FT_FONT_TRUE@am__append_109 = $(cairo_boilerplate_ft_headers) +@CAIRO_HAS_FT_FONT_TRUE@am__append_110 = $(cairo_boilerplate_ft_private) +@CAIRO_HAS_FT_FONT_TRUE@am__append_111 = $(cairo_boilerplate_ft_cxx_sources) +@CAIRO_HAS_FT_FONT_TRUE@am__append_112 = $(cairo_boilerplate_ft_sources) +@CAIRO_HAS_FC_FONT_TRUE@am__append_113 = $(cairo_boilerplate_fc_headers) +@CAIRO_HAS_FC_FONT_TRUE@am__append_114 = $(cairo_boilerplate_fc_private) +@CAIRO_HAS_FC_FONT_TRUE@am__append_115 = $(cairo_boilerplate_fc_cxx_sources) +@CAIRO_HAS_FC_FONT_TRUE@am__append_116 = $(cairo_boilerplate_fc_sources) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_117 = $(cairo_boilerplate_ps_headers) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_118 = $(cairo_boilerplate_ps_private) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_119 = $(cairo_boilerplate_ps_cxx_sources) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_120 = $(cairo_boilerplate_ps_sources) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_121 = $(cairo_boilerplate_pdf_headers) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_122 = $(cairo_boilerplate_pdf_private) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_123 = $(cairo_boilerplate_pdf_cxx_sources) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_124 = $(cairo_boilerplate_pdf_sources) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_125 = $(cairo_boilerplate_svg_headers) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_126 = $(cairo_boilerplate_svg_private) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_127 = $(cairo_boilerplate_svg_cxx_sources) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_128 = $(cairo_boilerplate_svg_sources) +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_129 = $(cairo_boilerplate_test_surfaces_private) $(cairo_boilerplate_test_surfaces_headers) +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_130 = $(cairo_boilerplate_test_surfaces_cxx_sources) +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_131 = $(cairo_boilerplate_test_surfaces_sources) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_132 = $(cairo_boilerplate_tee_headers) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_133 = $(cairo_boilerplate_tee_private) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_134 = $(cairo_boilerplate_tee_cxx_sources) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_135 = $(cairo_boilerplate_tee_sources) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_136 = $(cairo_boilerplate_xml_headers) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_137 = $(cairo_boilerplate_xml_private) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_138 = $(cairo_boilerplate_xml_cxx_sources) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_139 = $(cairo_boilerplate_xml_sources) +@CAIRO_HAS_PTHREAD_TRUE@am__append_140 = $(cairo_boilerplate_pthread_private) $(cairo_boilerplate_pthread_headers) +@CAIRO_HAS_PTHREAD_TRUE@am__append_141 = $(cairo_boilerplate_pthread_cxx_sources) +@CAIRO_HAS_PTHREAD_TRUE@am__append_142 = $(cairo_boilerplate_pthread_sources) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_143 = $(cairo_boilerplate_gobject_headers) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_144 = $(cairo_boilerplate_gobject_private) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_145 = $(cairo_boilerplate_gobject_cxx_sources) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_146 = $(cairo_boilerplate_gobject_sources) +@CAIRO_HAS_TRACE_TRUE@am__append_147 = $(cairo_boilerplate_trace_private) $(cairo_boilerplate_trace_headers) +@CAIRO_HAS_TRACE_TRUE@am__append_148 = $(cairo_boilerplate_trace_cxx_sources) +@CAIRO_HAS_TRACE_TRUE@am__append_149 = $(cairo_boilerplate_trace_sources) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_150 = $(cairo_boilerplate_interpreter_private) $(cairo_boilerplate_interpreter_headers) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_151 = $(cairo_boilerplate_interpreter_cxx_sources) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_152 = $(cairo_boilerplate_interpreter_sources) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_153 = $(cairo_boilerplate_symbol_lookup_private) $(cairo_boilerplate_symbol_lookup_headers) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_154 = $(cairo_boilerplate_symbol_lookup_cxx_sources) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_155 = $(cairo_boilerplate_symbol_lookup_sources) +@CAIRO_HAS_DL_TRUE@am__append_156 = -ldl +@CAIRO_HAS_WIN32_SURFACE_TRUE@am__append_157 = -lwinspool +@CROSS_COMPILING_FALSE@am__append_158 = check-link$(EXEEXT) subdir = boilerplate ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/aclocal.cairo.m4 \ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -314,7 +317,7 @@ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) $(am__objects_1) + $(am__objects_1) $(am__objects_1) $(am__objects_1) am__objects_4 = $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ @@ -328,7 +331,7 @@ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) + $(am__objects_1) $(am__objects_1) am__objects_5 = cairo-boilerplate-getopt.lo \ cairo-boilerplate-system.lo cairo-boilerplate.lo am__objects_6 = cairo-boilerplate-xlib.lo @@ -372,14 +375,14 @@ $(am__objects_1) $(am__objects_13) $(am__objects_1) \ $(am__objects_15) $(am__objects_1) $(am__objects_1) \ $(am__objects_17) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) $(am__objects_1) $(am__objects_19) \ - $(am__objects_21) $(am__objects_23) $(am__objects_25) \ - $(am__objects_27) $(am__objects_29) $(am__objects_31) \ - $(am__objects_1) $(am__objects_1) $(am__objects_33) \ - $(am__objects_35) $(am__objects_37) $(am__objects_39) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ + $(am__objects_19) $(am__objects_21) $(am__objects_23) \ + $(am__objects_25) $(am__objects_27) $(am__objects_29) \ + $(am__objects_31) $(am__objects_1) $(am__objects_1) \ + $(am__objects_33) $(am__objects_35) $(am__objects_37) \ + $(am__objects_39) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) + $(am__objects_1) $(am__objects_1) am_libcairoboilerplate_la_OBJECTS = $(am__objects_3) $(am__objects_4) \ $(am__objects_40) cairo-boilerplate-constructors.lo libcairoboilerplate_la_OBJECTS = $(am_libcairoboilerplate_la_OBJECTS) @@ -408,7 +411,8 @@ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) $(am__objects_1) $(am__objects_1) + $(am__objects_1) $(am__objects_1) $(am__objects_1) \ + $(am__objects_1) am_libcairoboilerplate_cxx_la_OBJECTS = $(am__objects_45) libcairoboilerplate_cxx_la_OBJECTS = \ $(am_libcairoboilerplate_cxx_la_OBJECTS) @@ -767,6 +771,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -865,6 +874,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ @@ -931,7 +942,7 @@ make-cairo-boilerplate-constructors.sh EXTRA_LTLIBRARIES = libcairoboilerplate.la $(cxx_boilerplate_lib) MAINTAINERCLEANFILES = Makefile.in -TESTS = $(am__append_154) +TESTS = $(am__append_158) cairo_boilerplate_headers = \ cairo-boilerplate-getopt.h \ cairo-boilerplate-scaled-font.h \ @@ -1005,6 +1016,7 @@ $(cairo_boilerplate_gallium_headers) \ $(cairo_boilerplate_gl_headers) \ $(cairo_boilerplate_glesv2_headers) \ + $(cairo_boilerplate_glesv3_headers) \ $(cairo_boilerplate_cogl_headers) \ $(cairo_boilerplate_directfb_headers) \ $(cairo_boilerplate_vg_headers) \ @@ -1030,6 +1042,7 @@ $(cairo_boilerplate_png_headers) \ $(cairo_boilerplate_gl_headers) \ $(cairo_boilerplate_glesv2_headers) \ + $(cairo_boilerplate_glesv3_headers) \ $(cairo_boilerplate_cogl_headers) \ $(cairo_boilerplate_directfb_headers) \ $(cairo_boilerplate_vg_headers) \ @@ -1070,6 +1083,7 @@ $(cairo_boilerplate_png_private) \ $(cairo_boilerplate_gl_private) \ $(cairo_boilerplate_glesv2_private) \ + $(cairo_boilerplate_glesv3_private) \ $(cairo_boilerplate_cogl_private) \ $(cairo_boilerplate_directfb_private) \ $(cairo_boilerplate_vg_private) \ @@ -1120,6 +1134,7 @@ $(cairo_boilerplate_png_cxx_sources) \ $(cairo_boilerplate_gl_cxx_sources) \ $(cairo_boilerplate_glesv2_cxx_sources) \ + $(cairo_boilerplate_glesv3_cxx_sources) \ $(cairo_boilerplate_cogl_cxx_sources) \ $(cairo_boilerplate_directfb_cxx_sources) \ $(cairo_boilerplate_vg_cxx_sources) \ @@ -1165,6 +1180,7 @@ $(cairo_boilerplate_png_sources) \ $(cairo_boilerplate_gl_sources) \ $(cairo_boilerplate_glesv2_sources) \ + $(cairo_boilerplate_glesv3_sources) \ $(cairo_boilerplate_cogl_sources) \ $(cairo_boilerplate_directfb_sources) \ $(cairo_boilerplate_vg_sources) \ @@ -1201,12 +1217,13 @@ $(am__append_85) $(am__append_89) $(am__append_93) \ $(am__append_97) $(am__append_101) $(am__append_105) \ $(am__append_109) $(am__append_113) $(am__append_117) \ - $(am__append_121) $(cairo_boilerplate_image_headers) \ + $(am__append_121) $(am__append_125) \ + $(cairo_boilerplate_image_headers) \ $(cairo_boilerplate_mime_headers) \ $(cairo_boilerplate_recording_headers) \ - $(cairo_boilerplate_observer_headers) $(am__append_128) \ - $(am__append_132) $(cairo_boilerplate_user_headers) \ - $(am__append_139) + $(cairo_boilerplate_observer_headers) $(am__append_132) \ + $(am__append_136) $(cairo_boilerplate_user_headers) \ + $(am__append_143) enabled_cairo_boilerplate_private = $(cairo_boilerplate_private) \ $(am__append_2) $(am__append_6) $(am__append_10) \ $(am__append_14) $(am__append_18) $(am__append_22) \ @@ -1218,14 +1235,14 @@ $(am__append_86) $(am__append_90) $(am__append_94) \ $(am__append_98) $(am__append_102) $(am__append_106) \ $(am__append_110) $(am__append_114) $(am__append_118) \ - $(am__append_122) $(am__append_125) \ + $(am__append_122) $(am__append_126) $(am__append_129) \ $(cairo_boilerplate_image_private) \ $(cairo_boilerplate_mime_private) \ $(cairo_boilerplate_recording_private) \ - $(cairo_boilerplate_observer_private) $(am__append_129) \ - $(am__append_133) $(cairo_boilerplate_user_private) \ - $(am__append_136) $(am__append_140) $(am__append_143) \ - $(am__append_146) $(am__append_149) + $(cairo_boilerplate_observer_private) $(am__append_133) \ + $(am__append_137) $(cairo_boilerplate_user_private) \ + $(am__append_140) $(am__append_144) $(am__append_147) \ + $(am__append_150) $(am__append_153) enabled_cairo_boilerplate_cxx_sources = \ $(cairo_boilerplate_cxx_sources) $(am__append_3) \ $(am__append_7) $(am__append_11) $(am__append_15) \ @@ -1238,13 +1255,14 @@ $(am__append_91) $(am__append_95) $(am__append_99) \ $(am__append_103) $(am__append_107) $(am__append_111) \ $(am__append_115) $(am__append_119) $(am__append_123) \ - $(am__append_126) $(cairo_boilerplate_image_cxx_sources) \ + $(am__append_127) $(am__append_130) \ + $(cairo_boilerplate_image_cxx_sources) \ $(cairo_boilerplate_mime_cxx_sources) \ $(cairo_boilerplate_recording_cxx_sources) \ - $(cairo_boilerplate_observer_cxx_sources) $(am__append_130) \ - $(am__append_134) $(cairo_boilerplate_user_cxx_sources) \ - $(am__append_137) $(am__append_141) $(am__append_144) \ - $(am__append_147) $(am__append_150) + $(cairo_boilerplate_observer_cxx_sources) $(am__append_134) \ + $(am__append_138) $(cairo_boilerplate_user_cxx_sources) \ + $(am__append_141) $(am__append_145) $(am__append_148) \ + $(am__append_151) $(am__append_154) enabled_cairo_boilerplate_sources = $(cairo_boilerplate_sources) \ $(am__append_4) $(am__append_8) $(am__append_12) \ $(am__append_16) $(am__append_20) $(am__append_24) \ @@ -1256,14 +1274,14 @@ $(am__append_88) $(am__append_92) $(am__append_96) \ $(am__append_100) $(am__append_104) $(am__append_108) \ $(am__append_112) $(am__append_116) $(am__append_120) \ - $(am__append_124) $(am__append_127) \ + $(am__append_124) $(am__append_128) $(am__append_131) \ $(cairo_boilerplate_image_sources) \ $(cairo_boilerplate_mime_sources) \ $(cairo_boilerplate_recording_sources) \ - $(cairo_boilerplate_observer_sources) $(am__append_131) \ - $(am__append_135) $(cairo_boilerplate_user_sources) \ - $(am__append_138) $(am__append_142) $(am__append_145) \ - $(am__append_148) $(am__append_151) + $(cairo_boilerplate_observer_sources) $(am__append_135) \ + $(am__append_139) $(cairo_boilerplate_user_sources) \ + $(am__append_142) $(am__append_146) $(am__append_149) \ + $(am__append_152) $(am__append_155) #MAINTAINERCLEANFILES += $(srcdir)/Makefile.win32.features AM_CPPFLAGS = \ -I$(srcdir) \ @@ -1288,7 +1306,7 @@ libcairoboilerplate_la_LIBADD = $(top_builddir)/src/libcairo.la \ $(cxx_boilerplate_lib) $(CAIRO_LIBS) $(CAIROBOILERPLATE_LIBS) \ - $(NULL) $(am__append_152) $(am__append_153) + $(NULL) $(am__append_156) $(am__append_157) libcairoboilerplate_cxx_la_LIBADD = $(top_builddir)/src/libcairo.la \ $(CAIRO_LIBS) \ $(CAIROBOILERPLATE_LIBS) \ diff -Nru cairo-1.15.8/boilerplate/Makefile.win32.features cairo-1.15.10/boilerplate/Makefile.win32.features --- cairo-1.15.8/boilerplate/Makefile.win32.features 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/boilerplate/Makefile.win32.features 2017-12-07 02:14:36.000000000 +0000 @@ -247,6 +247,18 @@ enabled_cairo_boilerplate_sources += $(cairo_boilerplate_glesv2_sources) endif +unsupported_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers) +all_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers) +all_cairo_boilerplate_private += $(cairo_boilerplate_glesv3_private) +all_cairo_boilerplate_cxx_sources += $(cairo_boilerplate_glesv3_cxx_sources) +all_cairo_boilerplate_sources += $(cairo_boilerplate_glesv3_sources) +ifeq ($(CAIRO_HAS_GLESV3_SURFACE),1) +enabled_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers) +enabled_cairo_boilerplate_private += $(cairo_boilerplate_glesv3_private) +enabled_cairo_boilerplate_cxx_sources += $(cairo_boilerplate_glesv3_cxx_sources) +enabled_cairo_boilerplate_sources += $(cairo_boilerplate_glesv3_sources) +endif + unsupported_cairo_boilerplate_headers += $(cairo_boilerplate_cogl_headers) all_cairo_boilerplate_headers += $(cairo_boilerplate_cogl_headers) all_cairo_boilerplate_private += $(cairo_boilerplate_cogl_private) diff -Nru cairo-1.15.8/build/aclocal.cairo.m4 cairo-1.15.10/build/aclocal.cairo.m4 --- cairo-1.15.8/build/aclocal.cairo.m4 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/build/aclocal.cairo.m4 2017-12-07 02:14:36.000000000 +0000 @@ -165,7 +165,7 @@ int atomic_add(int i) { return __sync_fetch_and_add (&i, 1); } int atomic_cmpxchg(int i, int j, int k) { return __sync_val_compare_and_swap (&i, j, k); } ], [], - cairo_cv_atomic_primitives="Intel" + cairo_cv_atomic_primitives="gcc-legacy" ) AC_TRY_LINK([ @@ -190,9 +190,9 @@ [Enable if your compiler supports the GCC __atomic_* atomic primitives]) fi - if test "x$cairo_cv_atomic_primitives" = xIntel; then - AC_DEFINE(HAVE_INTEL_ATOMIC_PRIMITIVES, 1, - [Enable if your compiler supports the Intel __sync_* atomic primitives]) + if test "x$cairo_cv_atomic_primitives" = xgcc-legacy; then + AC_DEFINE(HAVE_GCC_LEGACY_ATOMICS, 1, + [Enable if your compiler supports the legacy GCC __sync_* atomic primitives]) fi if test "x$cairo_cv_atomic_primitives" = "xlibatomic-ops"; then diff -Nru cairo-1.15.8/build/aclocal.gtk-doc.m4 cairo-1.15.10/build/aclocal.gtk-doc.m4 --- cairo-1.15.8/build/aclocal.gtk-doc.m4 2017-04-24 17:17:20.000000000 +0000 +++ cairo-1.15.10/build/aclocal.gtk-doc.m4 1970-01-01 00:00:00.000000000 +0000 @@ -1,39 +0,0 @@ -dnl -*- mode: autoconf -*- - -# serial 1 - -dnl Usage: -dnl GTK_DOC_CHECK([minimum-gtk-doc-version]) -AC_DEFUN([GTK_DOC_CHECK], -[ - AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first - AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first - dnl for overriding the documentation installation directory - AC_ARG_WITH([html-dir], - AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),, - [with_html_dir='${datadir}/gtk-doc/html']) - HTML_DIR="$with_html_dir" - AC_SUBST([HTML_DIR]) - - dnl enable/disable documentation building - AC_ARG_ENABLE([gtk-doc], - AS_HELP_STRING([--enable-gtk-doc], - [use gtk-doc to build documentation [[default=no]]]),, - [enable_gtk_doc=no]) - - if test x$enable_gtk_doc = xyes; then - ifelse([$1],[], - [PKG_CHECK_EXISTS([gtk-doc],, - AC_MSG_ERROR([gtk-doc not installed and --enable-gtk-doc requested]))], - [PKG_CHECK_EXISTS([gtk-doc >= $1],, - AC_MSG_ERROR([You need to have gtk-doc >= $1 installed to build gtk-doc]))]) - fi - - AC_MSG_CHECKING([whether to build gtk-doc documentation]) - AC_MSG_RESULT($enable_gtk_doc) - - AC_PATH_PROGS(GTKDOC_CHECK,gtkdoc-check,) - - AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes]) - AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"]) -]) diff -Nru cairo-1.15.8/build/configure.ac.features cairo-1.15.10/build/configure.ac.features --- cairo-1.15.8/build/configure.ac.features 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/build/configure.ac.features 2017-12-07 02:14:36.000000000 +0000 @@ -384,6 +384,7 @@ echo " SVG: $use_svg" echo " OpenGL: $use_gl" echo " OpenGL ES 2.0: $use_glesv2" + echo " OpenGL ES 3.0: $use_glesv3" echo " BeOS: $use_beos" echo " DirectFB: $use_directfb" echo " OpenVG: $use_vg" diff -Nru cairo-1.15.8/build/configure.ac.system cairo-1.15.10/build/configure.ac.system --- cairo-1.15.8/build/configure.ac.system 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/build/configure.ac.system 2017-12-07 02:14:36.000000000 +0000 @@ -108,11 +108,13 @@ dnl check for misc headers and functions AC_CHECK_HEADERS([libgen.h byteswap.h signal.h setjmp.h fenv.h sys/wait.h]) -AC_CHECK_FUNCS([ctime_r drand48 flockfile funlockfile getline link strndup]) - -dnl check for win32 headers (this detects mingw as well) -AC_CHECK_HEADERS([windows.h], have_windows=yes, have_windows=no) +AC_CHECK_FUNCS([ctime_r localtime_r gmtime_r drand48 flockfile funlockfile getline link strndup]) +dnl Check if the runtime platform is a native Win32 host. +AC_COMPILE_IFELSE([[ +#ifdef _WIN32 + choke me +#endif]], [have_windows=no], [have_windows=yes]) dnl Possible headers for mkdir AC_CHECK_HEADERS([sys/stat.h io.h]) diff -Nru cairo-1.15.8/build/gtk-doc.m4 cairo-1.15.10/build/gtk-doc.m4 --- cairo-1.15.8/build/gtk-doc.m4 1970-01-01 00:00:00.000000000 +0000 +++ cairo-1.15.10/build/gtk-doc.m4 2016-04-26 18:35:41.000000000 +0000 @@ -0,0 +1,88 @@ +dnl -*- mode: autoconf -*- + +# serial 2 + +dnl Usage: +dnl GTK_DOC_CHECK([minimum-gtk-doc-version]) +AC_DEFUN([GTK_DOC_CHECK], +[ + AC_REQUIRE([PKG_PROG_PKG_CONFIG]) + AC_BEFORE([AC_PROG_LIBTOOL],[$0])dnl setup libtool first + AC_BEFORE([AM_PROG_LIBTOOL],[$0])dnl setup libtool first + + ifelse([$1],[],[gtk_doc_requires="gtk-doc"],[gtk_doc_requires="gtk-doc >= $1"]) + AC_MSG_CHECKING([for gtk-doc]) + PKG_CHECK_EXISTS([$gtk_doc_requires],[have_gtk_doc=yes],[have_gtk_doc=no]) + AC_MSG_RESULT($have_gtk_doc) + + if test "$have_gtk_doc" = "no"; then + AC_MSG_WARN([ + You will not be able to create source packages with 'make dist' + because $gtk_doc_requires is not found.]) + fi + + dnl check for tools we added during development + dnl Use AC_CHECK_PROG to avoid the check target using an absolute path that + dnl may not be writable by the user. Currently, automake requires that the + dnl test name must end in '.test'. + dnl https://bugzilla.gnome.org/show_bug.cgi?id=701638 + AC_CHECK_PROG([GTKDOC_CHECK],[gtkdoc-check],[gtkdoc-check.test]) + AC_PATH_PROG([GTKDOC_CHECK_PATH],[gtkdoc-check]) + AC_PATH_PROGS([GTKDOC_REBASE],[gtkdoc-rebase],[true]) + AC_PATH_PROG([GTKDOC_MKPDF],[gtkdoc-mkpdf]) + + dnl for overriding the documentation installation directory + AC_ARG_WITH([html-dir], + AS_HELP_STRING([--with-html-dir=PATH], [path to installed docs]),, + [with_html_dir='${datadir}/gtk-doc/html']) + HTML_DIR="$with_html_dir" + AC_SUBST([HTML_DIR]) + + dnl enable/disable documentation building + AC_ARG_ENABLE([gtk-doc], + AS_HELP_STRING([--enable-gtk-doc], + [use gtk-doc to build documentation [[default=no]]]),, + [enable_gtk_doc=no]) + + AC_MSG_CHECKING([whether to build gtk-doc documentation]) + AC_MSG_RESULT($enable_gtk_doc) + + if test "x$enable_gtk_doc" = "xyes" && test "$have_gtk_doc" = "no"; then + AC_MSG_ERROR([ + You must have $gtk_doc_requires installed to build documentation for + $PACKAGE_NAME. Please install gtk-doc or disable building the + documentation by adding '--disable-gtk-doc' to '[$]0'.]) + fi + + dnl don't check for glib if we build glib + if test "x$PACKAGE_NAME" != "xglib"; then + dnl don't fail if someone does not have glib + PKG_CHECK_MODULES(GTKDOC_DEPS, glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0,,[:]) + fi + + dnl enable/disable output formats + AC_ARG_ENABLE([gtk-doc-html], + AS_HELP_STRING([--enable-gtk-doc-html], + [build documentation in html format [[default=yes]]]),, + [enable_gtk_doc_html=yes]) + AC_ARG_ENABLE([gtk-doc-pdf], + AS_HELP_STRING([--enable-gtk-doc-pdf], + [build documentation in pdf format [[default=no]]]),, + [enable_gtk_doc_pdf=no]) + + if test -z "$GTKDOC_MKPDF"; then + enable_gtk_doc_pdf=no + fi + + if test -z "$AM_DEFAULT_VERBOSITY"; then + AM_DEFAULT_VERBOSITY=1 + fi + AC_SUBST([AM_DEFAULT_VERBOSITY]) + + AM_CONDITIONAL([HAVE_GTK_DOC], [test x$have_gtk_doc = xyes]) + AM_CONDITIONAL([ENABLE_GTK_DOC], [test x$enable_gtk_doc = xyes]) + AM_CONDITIONAL([GTK_DOC_BUILD_HTML], [test x$enable_gtk_doc_html = xyes]) + AM_CONDITIONAL([GTK_DOC_BUILD_PDF], [test x$enable_gtk_doc_pdf = xyes]) + AM_CONDITIONAL([GTK_DOC_USE_LIBTOOL], [test -n "$LIBTOOL"]) + AM_CONDITIONAL([GTK_DOC_USE_REBASE], [test -n "$GTKDOC_REBASE"]) +]) diff -Nru cairo-1.15.8/build/Makefile.win32.features cairo-1.15.10/build/Makefile.win32.features --- cairo-1.15.8/build/Makefile.win32.features 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/build/Makefile.win32.features 2017-12-07 02:14:36.000000000 +0000 @@ -19,6 +19,7 @@ CAIRO_HAS_PNG_FUNCTIONS=1 CAIRO_HAS_GL_SURFACE=0 CAIRO_HAS_GLESV2_SURFACE=0 +CAIRO_HAS_GLESV3_SURFACE=0 CAIRO_HAS_COGL_SURFACE=0 CAIRO_HAS_DIRECTFB_SURFACE=0 CAIRO_HAS_VG_SURFACE=0 diff -Nru cairo-1.15.8/build/Makefile.win32.features-h cairo-1.15.10/build/Makefile.win32.features-h --- cairo-1.15.8/build/Makefile.win32.features-h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/build/Makefile.win32.features-h 2017-12-07 02:14:36.000000000 +0000 @@ -62,6 +62,9 @@ ifeq ($(CAIRO_HAS_GLESV2_SURFACE),1) @echo "#define CAIRO_HAS_GLESV2_SURFACE 1" >> $(top_srcdir)/src/cairo-features.h endif +ifeq ($(CAIRO_HAS_GLESV3_SURFACE),1) + @echo "#define CAIRO_HAS_GLESV3_SURFACE 1" >> $(top_srcdir)/src/cairo-features.h +endif ifeq ($(CAIRO_HAS_COGL_SURFACE),1) @echo "#define CAIRO_HAS_COGL_SURFACE 1" >> $(top_srcdir)/src/cairo-features.h endif diff -Nru cairo-1.15.8/cairo-version.h cairo-1.15.10/cairo-version.h --- cairo-1.15.8/cairo-version.h 2017-08-29 17:01:02.000000000 +0000 +++ cairo-1.15.10/cairo-version.h 2017-12-11 20:57:24.000000000 +0000 @@ -3,6 +3,6 @@ #define CAIRO_VERSION_MAJOR 1 #define CAIRO_VERSION_MINOR 15 -#define CAIRO_VERSION_MICRO 8 +#define CAIRO_VERSION_MICRO 10 #endif diff -Nru cairo-1.15.8/ChangeLog cairo-1.15.10/ChangeLog --- cairo-1.15.8/ChangeLog 2017-08-29 17:05:46.000000000 +0000 +++ cairo-1.15.10/ChangeLog 2017-12-11 21:03:32.000000000 +0000 @@ -1,5 +1,1189 @@ # Generated by configure. Do not edit. +commit 95c464d5feaae58b6cc0990434ce2498cc315dc6 +Author: Bryce Harrington +AuthorDate: Mon Dec 11 13:02:28 2017 -0800 +Commit: Bryce Harrington +CommitDate: Mon Dec 11 13:02:38 2017 -0800 + + 1.15.10 release + + Signed-off-by: Bryce Harrington + + NEWS | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + cairo-version.h | 2 +- + 2 files changed, 73 insertions(+), 1 deletion(-) + +commit f723ce31920cf5d5fe0ba417bb4b50b62a3ac4e6 +Author: Bryce Harrington +AuthorDate: Thu Dec 7 15:53:16 2017 -0800 +Commit: Bryce Harrington +CommitDate: Thu Dec 7 15:53:16 2017 -0800 + + pattern: Mark a private routine as cairo_private. + + Fixes distcheck PLT error: + + Checking .libs/libcairo.so for local PLT entries + 000000000031f1d0 0000024200000007 R_X86_64_JUMP_SLOT + 0000000000055de0 _cairo_pattern_is_constant_alpha + 0 + + src/cairo-pattern-private.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit c9a78ec9c21900f4418988ffe832b7e611a776c8 +Author: Bryce Harrington +AuthorDate: Thu Dec 7 14:15:17 2017 -0800 +Commit: Bryce Harrington +CommitDate: Thu Dec 7 14:15:17 2017 -0800 + + Fix distcheck errors on use of #ifdef + + Checking that feature conditionals are used with #if only (not #ifdef) + ./cairo-ft.h:#ifdef CAIRO_HAS_FC_FONT + ./cairo-ft.h:#ifdef CAIRO_HAS_FC_FONT + + src/cairo-ft.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 04b4967586ac31763186d9894107b8c8403bcb34 +Author: Bryce Harrington +AuthorDate: Thu Dec 7 14:00:21 2017 -0800 +Commit: Bryce Harrington +CommitDate: Thu Dec 7 14:13:32 2017 -0800 + + Fix various doxygen warnings found by check-doc-syntax.sh + + ./cairo-clip-boxes.c (268): ERROR: copy invalid doc id (should be 'cairo_...:') + ./cairo-clip-boxes.c (274): ERROR: copy bad line: ' */' + ./cairo-clip-boxes.c (274): ERROR: copy documentation comment not closed with **/ + ./cairo-boxes.c (106): ERROR: Computes invalid doc id (should be 'cairo_...:') + ./cairo-boxes.c (114): ERROR: Computes bad line: ' */' + ./cairo-boxes.c (114): ERROR: Computes documentation comment not closed with **/ + ./cairo-boxes.c (279): ERROR: Computes invalid doc id (should be 'cairo_...:') + ./cairo-boxes.c (284): ERROR: Computes bad line: ' */' + ./cairo-boxes.c (284): ERROR: Computes documentation comment not closed with **/ + ./cairo-boxes.c (338): ERROR: Linearize invalid doc id (should be 'cairo_...:') + ./cairo-boxes.c (345): ERROR: Linearize documentation comment not closed with **/ + ./cairo.c (240): ERROR: SECTION:cairo-tag bad line: '' + ./cairo.c (892): ERROR: cairo_set_source_rgb: Duplicate 'Since' field + + src/cairo-boxes.c | 23 +++++++++++++---------- + src/cairo-clip-boxes.c | 11 +++++------ + src/cairo-svg-surface.c | 2 +- + src/cairo.c | 4 +--- + 4 files changed, 20 insertions(+), 20 deletions(-) + +commit dbc1636a9b932fd81ace436a03c1992a6ac1cbcf +Author: Bryce Harrington +AuthorDate: Thu Dec 7 13:25:58 2017 -0800 +Commit: Bryce Harrington +CommitDate: Thu Dec 7 14:13:32 2017 -0800 + + win32: Fix since field version number + + check-doc-syntax.sh expects since numbers to be MAJOR.MINOR without a + patch level number + + src/win32/cairo-win32-display-surface.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit bb0d616c4efe1015d17d41125f235a219ad14322 +Author: Bryce Harrington +AuthorDate: Wed Dec 6 18:27:21 2017 -0800 +Commit: Bryce Harrington +CommitDate: Thu Dec 7 14:13:28 2017 -0800 + + image: Fix include for use of ptrdiff + + Commit 38fbe621 added use of the ptrdiff_t type in a header file, + however `make distcheck` complains: + + In file included from headers-standalone-tmp.c:1:0: + ../../../src/cairo-image-surface-private.h:74:5: error: unknown type name ‘ptrdiff_t’ + ptrdiff_t stride; + ^ + + src/cairo-image-surface-private.h | 1 + + 1 file changed, 1 insertion(+) + +commit 15559b54af473d720da9e03b0e769c54a53505a9 +Author: Antonio Ospite +AuthorDate: Wed Oct 11 18:51:13 2017 +0200 +Commit: Bryce Harrington +CommitDate: Mon Dec 4 13:58:34 2017 -0800 + + svg: add a new function to specify the SVG document unit + + Add a cairo_svg_surface_set_document_unit() function to allow users to + set a unit for the width and height values of the root element. + + In particular this allows to draw in pixels and still have the expected + result when generating SVG output. + + Add also the correspondent getter function. + + Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=90166 + Reviewed-by: Bryce Harrington + + src/cairo-svg-surface.c | 84 +++++++++++++++++++++++++++++++++++++++++++++++-- + src/cairo-svg.h | 47 +++++++++++++++++++++++++++ + 2 files changed, 129 insertions(+), 2 deletions(-) + +commit 84fc0ce91d1a57d20500f710abc0e17de82c67df +Author: Tom Schoonjans +AuthorDate: Thu Nov 2 16:55:22 2017 +0000 +Commit: Adrian Johnson +CommitDate: Sun Nov 26 20:16:43 2017 +1030 + + Use UTF-8 filenames on Windows + + Until now fopen was used on Windows to open files for reading and + writing. This assumed however that the filename would be encoded in the + current codepage, which is a major inconvenience and makes it even + impossible to use filenames that use characters from more than one + codepage. This patch enforces the use of UTF-8 filenames on all + platforms. + + Based on the work of Owen Taylor (https://lists.cairographics.org/archives/cairo/2007-February/009591.html) + + src/cairo-misc.c | 62 +++++++++++++++++++++++++++++++++++++++++++++++ + src/cairo-output-stream.c | 7 +++++- + src/cairo-png.c | 20 +++++++++++---- + src/cairoint.h | 4 +++ + 4 files changed, 87 insertions(+), 6 deletions(-) + +commit e5532f5ad7f5493d703f9a7110b0816b5fa33e54 +Author: Mikhail Fludkov +AuthorDate: Mon Nov 6 13:07:00 2017 +0100 +Commit: Adrian Johnson +CommitDate: Sun Nov 26 13:09:51 2017 +1030 + + Fix code generation when using GCC legacy atomic operations + + https://bugs.freedesktop.org/show_bug.cgi?id=103559 + + build/aclocal.cairo.m4 | 8 ++++---- + src/cairo-atomic-private.h | 9 +-------- + 2 files changed, 5 insertions(+), 12 deletions(-) + +commit f614f588e67daebd123bb6698b56d4b8054616c4 +Author: Adrian Johnson +AuthorDate: Sat Nov 11 16:59:47 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sun Nov 26 13:03:44 2017 +1030 + + Prevent -Wundef warnings in when cairo-ft.h is used without fontconfig + + src/cairo-ft.h | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit a709197121c8e405c2dd99e408ee3046ccf50a6a +Author: Adrian Johnson +AuthorDate: Sun Nov 26 13:03:18 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sun Nov 26 13:03:18 2017 +1030 + + pdf: fix some annotation bugs + + - each annotation was emitted on every page instead of just the page + that contains the annotation + + - the document structure did not correctly link to annotation objects + + - fix some annotation related memory leaks + + src/cairo-pdf-interchange.c | 165 ++++++++++++++++++++++++++++++---------- + src/cairo-pdf-surface-private.h | 14 ++-- + src/cairo-pdf-surface.c | 3 +- + src/cairo-tag-attributes.c | 4 + + 4 files changed, 138 insertions(+), 48 deletions(-) + +commit 17e2abc992b012ac3dceb2f66fba17d312ae6d77 +Author: Adrian Johnson +AuthorDate: Mon Nov 20 05:37:34 2017 +1030 +Commit: Adrian Johnson +CommitDate: Mon Nov 20 05:37:34 2017 +1030 + + ps: fix compile with old versions of MSVC + + https://lists.cairographics.org/archives/cairo/2017-November/028452.html + + src/cairo-ps-surface.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 0c8070f5bc74c124e6393b433a61807a8e4bee5d +Author: Adrian Johnson +AuthorDate: Thu Nov 16 20:16:14 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 16 20:16:14 2017 +1030 + + pdf: fix document structure for non tagged structures + + src/cairo-pdf-interchange.c | 26 ++++++++++++++++++++------ + 1 file changed, 20 insertions(+), 6 deletions(-) + +commit 164be896603ceb419c5bc47c7348781f791f70e4 +Author: Adrian Johnson +AuthorDate: Fri Nov 10 20:10:01 2017 +1030 +Commit: Adrian Johnson +CommitDate: Fri Nov 10 20:10:01 2017 +1030 + + test: update some stale ref images + + test/reference/record-extend-pad.ps.ref.png | Bin 341 -> 0 bytes + ...recording-surface-extend-none.pdf.argb32.ref.png | Bin 3941 -> 3944 bytes + .../recording-surface-extend-none.pdf.rgb24.ref.png | Bin 3775 -> 3773 bytes + ...ording-surface-extend-reflect.pdf.argb32.ref.png | Bin 29897 -> 29999 bytes + ...cording-surface-extend-reflect.pdf.rgb24.ref.png | Bin 29901 -> 29984 bytes + ...cording-surface-extend-repeat.pdf.argb32.ref.png | Bin 26323 -> 26534 bytes + ...ecording-surface-extend-repeat.pdf.rgb24.ref.png | Bin 25867 -> 26017 bytes + test/reference/scale-offset-similar.pdf.ref.png | Bin 9742 -> 9742 bytes + 8 files changed, 0 insertions(+), 0 deletions(-) + +commit 5c7a6ca141363333a5dc9d2eaef055d383f91ef9 +Author: Adrian Johnson +AuthorDate: Fri Nov 10 20:10:01 2017 +1030 +Commit: Adrian Johnson +CommitDate: Fri Nov 10 20:10:01 2017 +1030 + + ps: fix extend-*-similar failures + + src/cairo-ps-surface-private.h | 1 + + src/cairo-ps-surface.c | 39 +++++++++++++++++++++------------------ + 2 files changed, 22 insertions(+), 18 deletions(-) + +commit 9bfa9df2bb8557623df7c561613ea6eaa2a67cdd +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:02:05 2017 +1030 + + ps: fix padded image crash + + src/cairo-ps-surface.c | 8 +++----- + 1 file changed, 3 insertions(+), 5 deletions(-) + +commit f7d6d78f9428c6813e79d5f7c1351c354d44da64 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:02:05 2017 +1030 + + ps: prevent self-copy infinite loop + + src/cairo-ps-surface-private.h | 3 ++- + src/cairo-ps-surface.c | 24 +++++++++++++++++++++++- + 2 files changed, 25 insertions(+), 2 deletions(-) + +commit 71746c37d48a08d56b18d4d82185896ada215194 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:02:05 2017 +1030 + + test: use CAIRO_MIME_TYPE_UNIQUE_ID with record-text-transform + + The PS output from this test is > 100MB due to the duplicated images. + Using CAIRO_MIME_TYPE_UNIQUE_ID reduces the PS output to 650k, runs + considerably faster, and now produces correct output. + + test/cairo-test.c | 5 +++++ + test/record.c | 11 +++++++++++ + .../reference/record-text-transform.ps.argb32.ref.png | Bin 1216 -> 3995 bytes + test/reference/record-text-transform.ps.rgb24.ref.png | Bin 1216 -> 3995 bytes + 4 files changed, 16 insertions(+) + +commit 5ffbaf9e2f7da103da8d015b5f928e25f9433b60 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:02:05 2017 +1030 + + ps: add CAIRO_MIME_TYPE_EPS mime type for embedding EPS files + + doc/public/cairo-sections.txt | 2 + + src/cairo-ps-surface-private.h | 1 + + src/cairo-ps-surface.c | 183 +++++++++++++++++++++++++++++++++++-- + src/cairo-surface.c | 18 ++++ + src/cairo-tag-attributes-private.h | 7 ++ + src/cairo-tag-attributes.c | 47 ++++++++++ + src/cairo.h | 2 + + 7 files changed, 252 insertions(+), 8 deletions(-) + +commit 7d3ba77b6cd20f68cfbda3d8008811265aa030cb +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:01:40 2017 +1030 + + ps: use Reusable streams for forms in Level 3 + + to avoid emitting image data as strings + + src/cairo-ps-surface.c | 57 +++++++++++++++++++++++++++++++++++++++++++------- + test/mime-unique-id.c | 2 +- + 2 files changed, 50 insertions(+), 9 deletions(-) + +commit b1c7a087b5da9a3bfa1e05e2e99861e07723c6f8 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:01:40 2017 +1030 + + ps: use forms for surfaces with UNIQUE_ID mime type + + to ensure the surfaces are emitted only once. + + fixes mime-unique-id PS output + + src/cairo-ps-surface-private.h | 19 +- + src/cairo-ps-surface.c | 665 ++++++++++++++++++++++++++++++++--------- + test/mime-unique-id.c | 4 +- + 3 files changed, 544 insertions(+), 144 deletions(-) + +commit 638d64a702449fee130b103e623c8fa3b8c06e9b +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:01:40 2017 +1030 + + ps: don't acquire image or snapshot in acquire_source_image_from_pattern + + otherwise emit_surface may not see the mime data + + src/cairo-ps-surface.c | 156 +++++++++++++++++++------------------------------ + 1 file changed, 61 insertions(+), 95 deletions(-) + +commit fcc037a76ecd70050e324d0e3f7decd81f2f0a05 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:01:40 2017 +1030 + + ps: use << >> for dictionaries instead of dict begin end + + src/cairo-ps-surface.c | 94 ++++++++++++++++++++++++-------------------------- + 1 file changed, 46 insertions(+), 48 deletions(-) + +commit 632232c3ce465e31929ab026012c731491492d6a +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:01:40 2017 +1030 + + ps: remove unused prolog + + src/cairo-ps-surface.c | 3 --- + 1 file changed, 3 deletions(-) + +commit 9d372ca91a067b00fc1f66f466ab795206f5ef14 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:01:40 2017 +1030 + + ps: emit base85 strings instead of strings of base85 + + When image data is emitted as strings (required when an image is used + in a PaintProc), the base85 encoded data was emitted inside PS strings + (...) and the image filters included an ASCI85Decode filter. + + This has been changed to emit the strings as ASCII85 strings <~...~> + and remove the ASCII85Decode filter since the base85 is decoded when + the string is parsed. + + Also factor out the string data source procedure into the prolog. + + src/cairo-ps-surface.c | 186 +++++++++++++++++++++---------------------------- + 1 file changed, 79 insertions(+), 107 deletions(-) + +commit d5cb45013bf10d97657cea105683bf5ccb21c2d7 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 22:01:40 2017 +1030 + + pdf: fix mime-unique-id jpeg attached to recording test + + - Restructure the emit_surface code so that mime types are checked first. + + - Add a test parameter to emit_surface to test if the surface will be emitted + as an image or recording instead checking the surface type as the attached + mime may override this. + + - Mark surface as not clear when mime is attached to avoid optimizing away + "clear" surfaces that have mime attached. + + - Include entire surface in analysis if mime attached (also fixes bug with + calculating the extents CONTENT_COLOR surfaces) + + src/cairo-analysis-surface.c | 172 +++++++++++++++++++---------------- + src/cairo-pdf-surface.c | 209 +++++++++++++++++++++++++++++-------------- + src/cairo-surface.c | 42 +++++++++ + src/cairoint.h | 3 + + test/mime-unique-id.c | 4 +- + 5 files changed, 286 insertions(+), 144 deletions(-) + +commit bff47b43c4b0501c0255e9ba191904bea13ddf5c +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 20:52:36 2017 +1030 + + pdf: fix mime-unique-id unbounded recording test + + PDF XObjects need to specify the bounding box. Emit unbounded surfaces + when finishing as at this point the extents of all uses of the + unbounded surface are known. + + src/cairo-pdf-surface-private.h | 7 +++- + src/cairo-pdf-surface.c | 85 +++++++++++++++++++++++++++++++---------- + src/cairo-surface.c | 4 +- + 3 files changed, 72 insertions(+), 24 deletions(-) + +commit cf9a07035292f3a1a3d057cfbb9dac1447a11235 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 20:52:36 2017 +1030 + + pdf: fix mime-unique-id bounded recording test + + The embedded bounded recording surface was being clipped to the + extents of its first use. + + src/cairo-pdf-surface.c | 77 ++++++++++++++++++++----------------------------- + 1 file changed, 31 insertions(+), 46 deletions(-) + +commit 5e4707a10d476604614bddcc9ba8b06f6002e6d6 +Author: Adrian Johnson +AuthorDate: Thu Nov 9 20:52:36 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Nov 9 20:52:36 2017 +1030 + + Add mime-unique-id test + + to check that PS/PDF embeds images with CAIRO_MIME_TYPE_UNIQUE_ID only + once. + + test/Makefile.sources | 2 +- + test/mime-unique-id.c | 511 ++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 512 insertions(+), 1 deletion(-) + +commit 38fbe621cf80d560cfc27b54b5417b62cda64c8a +Author: Adrian Johnson +AuthorDate: Thu Oct 20 21:12:30 2016 +1030 +Commit: Bryce Harrington +CommitDate: Tue Nov 7 17:01:49 2017 -0800 + + image: prevent invalid ptr access for > 4GB images + + Image data is often accessed using: + + image->data + y * image->stride + + On 64-bit achitectures if the image data is > 4GB, this computation + will overflow since both y and stride are 32-bit types. + + Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=98165 + Reviewed-by: Bryce Harrington + + boilerplate/cairo-boilerplate.c | 4 +++- + src/cairo-image-compositor.c | 4 ++-- + src/cairo-image-surface-private.h | 2 +- + src/cairo-mesh-pattern-rasterizer.c | 2 +- + src/cairo-png.c | 2 +- + src/cairo-script-surface.c | 3 ++- + 6 files changed, 10 insertions(+), 7 deletions(-) + +commit 35fccff6ec393ccca3d3ced79093ca491ce32df4 +Author: Bryce Harrington +AuthorDate: Mon Nov 6 12:09:53 2017 -0800 +Commit: Bryce Harrington +CommitDate: Mon Nov 6 12:18:37 2017 -0800 + + Un-doxygen disabled cairo_set_opacity + + The cairo_set_opacity() routine has been disabled since 2010. There + appears to be support for it internally in the backend, so it is unclear + why it is not enabled or what might break if it were re-enabled. Given + the lack of bug reports about its omission, it may be vestigal. For + now, just hide the doxygen for it to suppress warnings. It may be worth + deeper review to either re-enable it or remove it entirely. + + Reported-by: Rafał Mużyło (See fdo bugzilla #82741) + Signed-off-by: Bryce Harrington + + src/cairo.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit 8d89fc573eae0bc0234e1b909932e405a776b7e1 +Author: Bryce Harrington +AuthorDate: Mon Nov 6 11:28:58 2017 -0800 +Commit: Bryce Harrington +CommitDate: Mon Nov 6 11:35:24 2017 -0800 + + configure: Check for typeof + + Check via the AC_C_TYPEOF macro if GCC's typeof is available. If it is + available via a different spelling, define typeof to that spelling. + + Patch from and issue reported by Richard Palo. + + Signed-off-by: Bryce Harrington + Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=93027 + + configure.ac | 1 + + 1 file changed, 1 insertion(+) + +commit 3322580f0488ff77f53d86c2b4d3cf59e6dca4c7 +Author: Adrian Johnson +AuthorDate: Tue Oct 24 21:30:45 2017 +1030 +Commit: Adrian Johnson +CommitDate: Tue Oct 24 21:44:08 2017 +1030 + + pdf: remove old comment + + These issues have been fixed. + + src/cairo-pdf-surface.c | 9 --------- + 1 file changed, 9 deletions(-) + +commit 1674d2b8850f9264232e60e82cb5b2827426632c +Author: Adrian Johnson +AuthorDate: Tue Oct 24 21:26:56 2017 +1030 +Commit: Adrian Johnson +CommitDate: Tue Oct 24 21:44:08 2017 +1030 + + pdf: set default create date + + boilerplate/cairo-boilerplate-pdf.c | 1 + + build/configure.ac.system | 2 +- + src/cairo-pdf-interchange.c | 50 +++++++++++++++++++++++++++++++++++++ + src/cairo-pdf-surface.c | 1 - + 4 files changed, 52 insertions(+), 2 deletions(-) + +commit 378e8e2f59a109a40da8e40893652a4c003a4dc7 +Author: Adrian Johnson +AuthorDate: Tue Oct 24 07:01:14 2017 +1030 +Commit: Adrian Johnson +CommitDate: Tue Oct 24 07:01:14 2017 +1030 + + pdf: set ca/CA instead of using an smask when the mask has constant alpha + + src/cairo-pattern-private.h | 5 +++ + src/cairo-pattern.c | 53 +++++++++++++++++++++++++++++ + src/cairo-pdf-surface-private.h | 1 + + src/cairo-pdf-surface.c | 74 ++++++++++++++++++++++++++++++++--------- + 4 files changed, 117 insertions(+), 16 deletions(-) + +commit 5fd0b8710f125bb33c55d75fcc8252996b403e2d +Author: Carlos Garcia Campos +AuthorDate: Wed Oct 18 11:33:25 2017 +0200 +Commit: Adrian Johnson +CommitDate: Sun Oct 22 11:09:02 2017 +1030 + + scaled-font: Fix assert when destroying glyph page + + This happens when _cairo_ft_scaled_glyph_init() returns + CAIRO_INT_STATUS_UNSUPPORTED when called from + _cairo_scaled_glyph_lookup(). In those cases + _cairo_scaled_font_free_last_glyph() is called to release the glyph that + has just been allocated. If there aren't more glyphs, + _cairo_scaled_glyph_page_destroy() is called. The problem is that + _cairo_scaled_glyph_lookup() should always be called with the cache + frozen, and _cairo_scaled_glyph_page_destroy() without the cache + frozen. We can simply thaw/freeze the font before calling + _cairo_scaled_glyph_page_destroy(). + + https://bugs.freedesktop.org/show_bug.cgi?id=103335 + + src/cairo-scaled-font.c | 7 +++++++ + 1 file changed, 7 insertions(+) + +commit 87dfd0c16f4fa798c1f72612a2e070fca8547ad2 +Author: Adrian Johnson +AuthorDate: Sun Oct 22 08:45:45 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sun Oct 22 08:59:58 2017 +1030 + + Allow mime image to be different size to cairo image + + Previously it was assumed the mime image size is the same as the cairo + image surface size. When using the 1 bpp formats (CCITT, JBIG2), + creating a cairo image of the same size will have very large memory + requirements and in some case may exceed the pixman image size + limits. In these cases it is useful to allow the mime image to have a + different resolution to the cairo image and in the PDF/PS output scale + the mime image to be the same physical size as the cairo image. + + In PDF, this is easy as all PDF images are scaled to 1x1 unit and the + CTM is used to scale the image to the required size. The PS surface + has been changed to also scale images to 1x1 and use the CTM to get + the required size. + + src/cairo-pdf-surface.c | 124 ------------------------------------------------ + src/cairo-ps-surface.c | 29 +++++++++-- + 2 files changed, 24 insertions(+), 129 deletions(-) + +commit e1a02b180d804887980c111c1f9780bed44b96a6 +Author: Adrian Johnson +AuthorDate: Sun Oct 22 08:07:49 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sun Oct 22 08:42:36 2017 +1030 + + Add CCITT_FAX mime type for PDF and PS surfaces + + This completes the full set of PDF/PS image filters allowing image + data to be passed though without decompressing then recompresssing in + a less efficient format. + + The difficulty with CCITT_FAX is it needs some decoding parameters + that are not stored inside the image data. This is achieved by using + an additional mime type CCITT_FAX_PARAMS that contains the params in + key=value format. + + doc/public/cairo-sections.txt | 2 + + src/Makefile.sources | 16 +- + src/cairo-pdf-surface-private.h | 2 +- + src/cairo-pdf-surface.c | 263 ++++++++++++++++++++++++--- + src/cairo-ps-surface.c | 200 ++++++++++++++++++-- + src/cairo-surface.c | 21 ++- + src/cairo-tag-attributes-private.h | 15 ++ + src/cairo-tag-attributes.c | 80 ++++++++ + src/cairo.h | 2 + + test/ccitt.g3 | 2 + + test/mime-data.c | 56 +++++- + test/reference/mime-data.base.argb32.ref.png | Bin 243 -> 272 bytes + test/reference/mime-data.base.rgb24.ref.png | Bin 243 -> 272 bytes + test/reference/mime-data.pdf.ref.png | Bin 7563 -> 8205 bytes + test/reference/mime-data.ps.ref.png | Bin 4705 -> 5386 bytes + test/reference/mime-data.ref.png | Bin 243 -> 272 bytes + test/reference/mime-data.script.ref.png | Bin 2130 -> 2175 bytes + test/reference/mime-data.svg.ref.png | Bin 6437 -> 6513 bytes + 18 files changed, 609 insertions(+), 50 deletions(-) + +commit 4ae7f411c865a25b577faea58e5fda6f4e9e1172 +Author: Adrian Johnson +AuthorDate: Sat Oct 21 20:05:56 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sat Oct 21 20:05:56 2017 +1030 + + util/font-view: fix build error + + util/font-view.c | 2 ++ + 1 file changed, 2 insertions(+) + +commit 9ffbf63d3715f81ec92cdba93b60a04a11be130f +Author: Adrian Johnson +AuthorDate: Sat Oct 21 13:05:26 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sat Oct 21 13:08:39 2017 +1030 + + fix warning: inlining failed in call to '_csi_stack_push' + + util/cairo-script/cairo-script-interpreter.c | 11 +++++++++++ + util/cairo-script/cairo-script-private.h | 11 ++--------- + 2 files changed, 13 insertions(+), 9 deletions(-) + +commit b092b63119cbfe3cb4bc786eee81630998996acf +Author: Adrian Johnson +AuthorDate: Sat Oct 21 13:02:42 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sat Oct 21 13:08:30 2017 +1030 + + fix warning: variable X might be clobbered by 'longjmp' + + Move calls to setjmp into separate function to avoid clobbering + local variables. + + src/cairo-bentley-ottmann-rectangular.c | 8 +++++++- + src/cairo-png.c | 17 +++++++++++------ + 2 files changed, 18 insertions(+), 7 deletions(-) + +commit 132794f6832ea83e2f9a72e11b05080d2cdf80f8 +Author: Adrian Johnson +AuthorDate: Mon Oct 16 20:13:48 2017 +1030 +Commit: Adrian Johnson +CommitDate: Mon Oct 16 20:18:49 2017 +1030 + + svg: recording_surface is needed even if not emitted + + src/cairo-svg-surface.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 27990e391070dd43f08450a3d54c90d18e6d85f3 +Author: Adrian Johnson +AuthorDate: Mon Oct 16 19:47:21 2017 +1030 +Commit: Adrian Johnson +CommitDate: Mon Oct 16 20:18:49 2017 +1030 + + fix unused function warnings + + src/cairo-botor-scan-converter.c | 2 ++ + test/any2ppm.c | 2 +- + 2 files changed, 3 insertions(+), 1 deletion(-) + +commit fc929d70054583d0c21f24b18083348e3e7d914c +Author: Adrian Johnson +AuthorDate: Mon Oct 16 19:42:16 2017 +1030 +Commit: Adrian Johnson +CommitDate: Mon Oct 16 19:42:16 2017 +1030 + + ft: prevent unused var warning when freetype < 2.8 + + src/cairo-ft-font.c | 18 +++++++++++------- + 1 file changed, 11 insertions(+), 7 deletions(-) + +commit 1d58e0f81856038d8aa306b97302485a4d2e2ec9 +Author: Adrian Johnson +AuthorDate: Sun Oct 15 19:42:08 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sun Oct 15 19:42:08 2017 +1030 + + svg2png: remove unused headers + + test/svg2png.c | 2 -- + 1 file changed, 2 deletions(-) + +commit 90104809b0e03d28ac1152034fd4f05fc8e97b9a +Author: Mikhail Fludkov +AuthorDate: Fri Oct 6 13:47:51 2017 +0200 +Commit: Adrian Johnson +CommitDate: Sun Oct 15 18:51:04 2017 +1030 + + Surround initialisations with atomic critical section + + Fixes the race condition when one thread uses cairo_mask_compositor_t + pointer returned by _cairo_image_mask_compositor_get, while another one + started but has not finished it's initialisation yet + + Usage: + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; + if (_cairo_atomic_init_once_enter(&once)) { + /* Initialization code */ + _cairo_atomic_init_once_leave(&once); + } + + https://bugs.freedesktop.org/show_bug.cgi?id=103037 + + src/cairo-atomic-private.h | 33 +++++++++++++++++++++++++++++++++ + src/cairo-gl-msaa-compositor.c | 5 ++++- + src/cairo-gl-spans-compositor.c | 5 ++++- + src/cairo-gl-traps-compositor.c | 5 ++++- + src/cairo-image-compositor.c | 19 ++++++++++++++----- + src/cairo-image-mask-compositor.c | 5 ++++- + src/cairo-xlib-core-compositor.c | 5 ++++- + src/cairo-xlib-render-compositor.c | 10 ++++++++-- + src/test-null-compositor-surface.c | 10 ++++++++-- + src/win32/cairo-win32-gdi-compositor.c | 5 ++++- + 10 files changed, 87 insertions(+), 15 deletions(-) + +commit 79e0e25e441a74e3ec207d95bd83437457ba1885 +Author: Adrian Johnson +AuthorDate: Sun Oct 15 07:57:54 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sun Oct 15 07:57:54 2017 +1030 + + svg: source surface hash table does not need to hold the source + + src/cairo-svg-surface-private.h | 1 - + src/cairo-svg-surface.c | 2 -- + 2 files changed, 3 deletions(-) + +commit 965ba86bbf87fb0d8df666cbba7c8823cc393b0b +Author: Adrian Johnson +AuthorDate: Sat Oct 14 19:47:39 2017 +1030 +Commit: Adrian Johnson +CommitDate: Sat Oct 14 20:53:01 2017 +1030 + + svg: use hash table instead of user_data to track emitted surfaces + + Setting a key on the source surface->user_data prevents the surface + from being reused to create another svg file. + + The hash table also supports CAIRO_MIME_TYPE_UNIQUE_ID. + + https://lists.cairographics.org/archives/cairo/2017-October/028406.html + + src/cairo-svg-surface-private.h | 9 ++ + src/cairo-svg-surface.c | 185 ++++++++++++++++++++++++++++++++-------- + 2 files changed, 159 insertions(+), 35 deletions(-) + +commit bb10bd10138a262759b37281135b5199e334f392 +Author: Adrian Johnson +AuthorDate: Fri Oct 13 19:44:45 2017 +1030 +Commit: Adrian Johnson +CommitDate: Fri Oct 13 19:50:24 2017 +1030 + + truetype: limit font name to 127 chars + + Some broken fonts have long strings of garbage in the font name + + https://bugs.freedesktop.org/show_bug.cgi?id=103249 + + src/cairo-truetype-subset.c | 16 ++++++++++++++-- + 1 file changed, 14 insertions(+), 2 deletions(-) + +commit 202a9ed64e3d164307defddb41a9f8cf9e9b751b +Author: Adrian Johnson +AuthorDate: Fri Oct 13 19:27:03 2017 +1030 +Commit: Adrian Johnson +CommitDate: Fri Oct 13 19:33:30 2017 +1030 + + output-stream: allow %s strings larger than 512 chars + + https://bugs.freedesktop.org/show_bug.cgi?id=103249 + + src/cairo-output-stream.c | 10 +++++++--- + 1 file changed, 7 insertions(+), 3 deletions(-) + +commit d5b634da61597aa8e80ba7d5bc39f092e5888515 +Author: Bryce Harrington +AuthorDate: Wed Oct 11 19:13:46 2017 -0700 +Commit: Bryce Harrington +CommitDate: Wed Oct 11 19:13:46 2017 -0700 + + Factor out the ISFINITE() macro + + src/cairo-gstate.c | 6 ------ + src/cairo-matrix.c | 6 ------ + src/cairo-scaled-font.c | 6 ------ + src/cairoint.h | 6 ++++++ + 4 files changed, 6 insertions(+), 18 deletions(-) + +commit 5a9dba9929d9c9046705150f7e3c4783ff34e4dd +Author: Adrian Johnson +AuthorDate: Thu Oct 5 20:50:19 2017 +1030 +Commit: Adrian Johnson +CommitDate: Thu Oct 5 20:50:19 2017 +1030 + + svg: fix painting an unbounded recording surface + + https://lists.cairographics.org/archives/cairo/2017-October/028395.html + + src/cairo-svg-surface-private.h | 1 + + src/cairo-svg-surface.c | 38 +++++++++++++++++++++++++------------- + 2 files changed, 26 insertions(+), 13 deletions(-) + +commit bec8c7508ebc0f69266f9aebe9903539391c519b +Author: Adrian Johnson +AuthorDate: Tue Oct 3 22:18:49 2017 +1030 +Commit: Adrian Johnson +CommitDate: Tue Oct 3 22:27:25 2017 +1030 + + Prevent curved strokes in small ctms from being culled from vector surfaces + + The combination of both curved strokes and ignoring the ctm in the thin + line check caused some fill-strokes in this test case to be culled. + + Modify the thin line check to take the ctm into account and increase + the minimum width to 1 point to prevent curved lines such as tiny dots + from being culled. + + https://bugs.freedesktop.org/show_bug.cgi?id=103071 + + src/cairo-path-bounds.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +commit dccbed7d78d32bd3b912e8810379451dd94e6a1f +Author: Adrian Johnson +AuthorDate: Fri Sep 22 20:24:45 2017 +0930 +Commit: Adrian Johnson +CommitDate: Fri Sep 22 20:25:59 2017 +0930 + + truetype: clarify glyph count variables + + - move num_glyphs_in_face to base struct as it is the number in the font + - move num_glyphs to the subset variables as it is the num glyphs in the subset + - move widths to subset variables as it uses the subset id as the array index + + src/cairo-truetype-subset.c | 54 ++++++++++++++++++++++----------------------- + 1 file changed, 27 insertions(+), 27 deletions(-) + +commit 52cbf42b74785c3c3c2d15effe7bdb416ff9c8b2 +Author: Adrian Johnson +AuthorDate: Fri Sep 22 20:10:10 2017 +0930 +Commit: Adrian Johnson +CommitDate: Fri Sep 22 20:10:10 2017 +0930 + + truetype: reserve space in subset arrays for .notdef + + Subset array sizes are allocated based on the number of glyphs in the + font. In this bug the fonts did not contain the mandatory .notdef + glyph, hence the subset arrays were not large enough. + + https://bugs.freedesktop.org/show_bug.cgi?id=102922 + + src/cairo-truetype-subset.c | 11 ++++++++--- + 1 file changed, 8 insertions(+), 3 deletions(-) + +commit e773dd744e88dc871fdc549132f07760f1be94c7 +Author: Adrian Johnson +AuthorDate: Sun Sep 17 14:15:25 2017 +0930 +Commit: Adrian Johnson +CommitDate: Fri Sep 22 18:17:25 2017 +0930 + + factor out ascii to double code in cff-subset into _cairo_strtod + + src/cairo-cff-subset.c | 27 +++------------------ + src/cairo-misc.c | 60 +++++++++++++++++++++++++++++++++++++++++++++-- + src/cairo-output-stream.c | 2 +- + src/cairo-type1-subset.c | 2 +- + src/cairoint.h | 5 +++- + 5 files changed, 67 insertions(+), 29 deletions(-) + +commit 871c518121452116ee799fe4262421d4c935972e +Author: Aleksander Morgado +AuthorDate: Mon Aug 28 11:23:34 2017 +0200 +Commit: Bryce Harrington +CommitDate: Wed Sep 20 11:44:29 2017 -0700 + + build: fix minor typo in autogen.sh + + Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=102452 + Reviewed-by: Bryce Harrington + + autogen.sh | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 1220e3c6b8f94a00ac7afee15f21e6782655d97c +Author: Adrian Johnson +AuthorDate: Sat Sep 2 19:17:37 2017 +0930 +Commit: Adrian Johnson +CommitDate: Sat Sep 16 10:04:57 2017 +0930 + + replace _BSD_SOURCE with _DEFAULT_SOURCE + + fixes the warning: + + warning: #warning "_BSD_SOURCE and _SVID_SOURCE are deprecated, use _DEFAULT_SOURCE" + + src/cairo-cff-subset.c | 2 +- + src/cairo-ft-font.c | 2 +- + src/cairo-output-stream.c | 2 +- + src/cairo-path-stroke-boxes.c | 2 +- + src/cairo-path-stroke-polygon.c | 2 +- + src/cairo-path-stroke-tristrip.c | 2 +- + src/cairo-path-stroke.c | 2 +- + src/cairo-pdf-surface.c | 2 +- + src/cairo-ps-surface.c | 2 +- + src/cairo-scaled-font-subsets.c | 2 +- + src/cairo-svg-surface.c | 2 +- + src/cairo-toy-font-face.c | 2 +- + src/cairo-truetype-subset.c | 2 +- + src/cairo-type1-fallback.c | 2 +- + src/cairo-type1-subset.c | 2 +- + 15 files changed, 15 insertions(+), 15 deletions(-) + +commit 117a3c27d48107cb9c570fee725105419b1251e3 +Author: Adrian Johnson +AuthorDate: Sat Sep 2 19:09:49 2017 +0930 +Commit: Adrian Johnson +CommitDate: Sat Sep 16 10:04:57 2017 +0930 + + build: use _WIN32 instead of windows.h to check for windows build + + ifdef _WIN32 is the recommended way to check for a windows build [1] + and avoids identifying cygwin as windows. + + based on the patch at [2] + + [1] https://lists.gnu.org/archive/html/autoconf/2012-02/msg00008.html + [2] https://lists.gnu.org/archive/html/autoconf/2012-02/msg00009.html + + build/configure.ac.system | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +commit 8ff3019f51bd40c23d8a0dd5e51ce3fab6442d6e +Author: Bryce Harrington +AuthorDate: Wed Sep 13 12:35:27 2017 -0700 +Commit: Bryce Harrington +CommitDate: Wed Sep 13 15:18:04 2017 -0700 + + gl: Add support for OpenGL ES 3.0 + + This improves the OpenGL ES support to extend it to version 3.0. + A number of new features are available in glesv3 including creation of + multi-sampled renderbuffers. These renderbuffers can be blitted to + single sample textures (but not the other way around). Other features + such as PBO for image uploading, are left as followon work. + + For this preliminary implementation, glesv3 backends always create + renderbuffers, which can be set as single sample or multisample. The + renderbuffer's content is blitted to the texture only when used as a + source or a mask. + + Images uploaded to a texture stay there until the surface is used as a + rendering target, at which point its painted to the renderbuffer. + + This patch is heavily based off of Henry Song's initial GLESv3 patch + 6f7f3795 from his cairogles fork of Cairo, and incorporates subsequent + fixes and pertinent refactorings from his trunk and review feedback from + Uli. + + This implements the *functional* support for glesv3, excluding the + various optimization work to utilize its features. Rendering and + performance should not be expected to improve notably from pure glesv2. + As the GL backend for Cairo remains "experimental", these changes should + likewise be considered as such. + + Signed-off-by: Bryce Harrington + + boilerplate/Makefile.win32.features | 12 +++++ + boilerplate/cairo-boilerplate-egl.c | 30 ++++++++--- + build/Makefile.win32.features | 1 + + build/Makefile.win32.features-h | 3 ++ + build/configure.ac.features | 1 + + configure.ac | 23 ++++++++ + src/Makefile.sources | 4 ++ + src/Makefile.win32.features | 16 ++++++ + src/cairo-gl-composite.c | 103 +++++++++++++++++++++++++++++++++++- + src/cairo-gl-device.c | 91 +++++++++++++++++++++++-------- + src/cairo-gl-dispatch.c | 12 +++++ + src/cairo-gl-gradient-private.h | 9 ++-- + src/cairo-gl-gradient.c | 3 +- + src/cairo-gl-info.c | 4 +- + src/cairo-gl-msaa-compositor.c | 10 +++- + src/cairo-gl-operand.c | 3 +- + src/cairo-gl-private.h | 20 ++++--- + src/cairo-gl-shaders.c | 15 ++++-- + src/cairo-gl-surface.c | 73 ++++++++++++++++++++----- + src/cairo-gl.h | 2 +- + 20 files changed, 370 insertions(+), 65 deletions(-) + +commit d1f941d7ee06340c155158b32bec28fc2e1a4264 +Author: Bryce Harrington +AuthorDate: Thu Oct 20 16:37:28 2016 -0700 +Commit: Bryce Harrington +CommitDate: Wed Sep 13 15:17:55 2017 -0700 + + gl: Make _cairo_gl_ensure_framebuffer a private shared routine + + Signed-off-by: Bryce Harrington + + src/cairo-gl-device.c | 2 +- + src/cairo-gl-private.h | 4 ++++ + 2 files changed, 5 insertions(+), 1 deletion(-) + +commit 4b164bc89872f0cf4e123e1358cc83be8e83a4d3 +Author: Bryce Harrington +AuthorDate: Fri Oct 7 15:26:25 2016 -0700 +Commit: Bryce Harrington +CommitDate: Wed Sep 13 15:17:55 2017 -0700 + + gl: Convert images to rgba or a8 formats when uploading with GLESv2 + + The GLESv2 backend supports only GL_RGBA and GL_ALPHA as supported + texture formats. So, make _cairo_gl_get_image_format_and_type_gles2 + force conversion of other image formats to either of these two as + appropriate when uploading images. + + Patch originally from Henry Song + + Bryce Harrington + + Signed-off-by: Bryce Harrington + + src/cairo-gl-surface.c | 45 +++++++++++++++++++++++++++++++++++++++++ + src/cairo-gl-traps-compositor.c | 30 --------------------------- + 2 files changed, 45 insertions(+), 30 deletions(-) + +commit 99427c3f4f6ce7ce3c95c4caa4d2b8ff7c0093d9 +Author: Behdad Esfahbod +AuthorDate: Tue Sep 12 01:35:15 2017 -0400 +Commit: Behdad Esfahbod +CommitDate: Tue Sep 12 01:35:15 2017 -0400 + + Handle SOURCE and CLEAR operators when painting color glyphs + + In cairo, most operators are composited this way: + + ((src IN mask) OP dst) LERP_clip dst + + but SOURCE and CLEAR operators are composited this way: + + (src OP dst) LERP_(clip IN mask) dst + + (why is this not specified anywhere in the docs or source tree?) + + With color glyphs, we were not special-casing SOURCE and CLEAR. + We do now. + + Fixes https://bugs.freedesktop.org/show_bug.cgi?id=102661 + + src/cairo-surface.c | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +commit 7f6b57a2386c051e4bb6a156cf14904fe061f837 +Author: Behdad Esfahbod +AuthorDate: Mon Sep 11 22:00:00 2017 -0700 +Commit: Behdad Esfahbod +CommitDate: Mon Sep 11 22:00:00 2017 -0700 + + Fix undefined-behavior with integer math + + As reported to me: + + "A calculation on signed integers has undefined behaviour if the result is not + representable in the type. In this case, it's trying to negate int_min, aka + -2^31 but the range of an int is [-2^31, 2^31-1] so it doesn't fit. Instead, + cast to unsigned which has 2's complement wrap-around arithmetic which is what + this particular function expects." + + src/cairo-fixed-private.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 1af18610baaefd2031259fc7aae79b341c57fb91 +Author: Bryce Harrington +AuthorDate: Mon Sep 11 19:49:14 2017 -0700 +Commit: Bryce Harrington +CommitDate: Mon Sep 11 19:56:06 2017 -0700 + + glesv2: Fix regression in gles version detection + + Revert the _cairo_gl_get_flavor() portion of the change from commit + eb523200. This caused GLES to be enabled only if the hardware reported + version 2 exactly; if the hardware supported version 2 and 3 then no ES + support would be enabled. + + src/cairo-gl-info.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit c29db4f0de52727406a8b62f4da9a382084b5a79 +Author: Adrian Johnson +AuthorDate: Sat Sep 2 16:11:43 2017 +0930 +Commit: Adrian Johnson +CommitDate: Sat Sep 2 16:11:43 2017 +0930 + + Remove unused variable + + src/cairo-unicode.c | 2 -- + 1 file changed, 2 deletions(-) + +commit b646f755f3ad12ccd437ea32bffaefe5f6c6be25 +Author: Adrian Johnson +AuthorDate: Sat Sep 2 07:37:36 2017 +0930 +Commit: Adrian Johnson +CommitDate: Sat Sep 2 07:37:36 2017 +0930 + + RELEASING: use correct branch name + + RELEASING | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +commit 934e42fa5e4b74cf7fed022d2ff8a6326908ba3c +Author: Bryce Harrington +AuthorDate: Tue Aug 29 10:18:14 2017 -0700 +Commit: Bryce Harrington +CommitDate: Tue Aug 29 10:18:14 2017 -0700 + + Bump version for new development tree, 1.15.9 + + cairo-version.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + commit 112f0fc73b769c2db69f50601bf094892bd6db10 Author: Bryce Harrington AuthorDate: Sun Aug 27 17:53:40 2017 -0700 diff -Nru cairo-1.15.8/config.h.in cairo-1.15.10/config.h.in --- cairo-1.15.8/config.h.in 2017-08-29 17:05:34.000000000 +0000 +++ cairo-1.15.10/config.h.in 2017-12-11 21:03:19.000000000 +0000 @@ -128,14 +128,18 @@ /* Define to 1 if you have the `funlockfile' function. */ #undef HAVE_FUNLOCKFILE +/* Enable if your compiler supports the legacy GCC __sync_* atomic primitives + */ +#undef HAVE_GCC_LEGACY_ATOMICS + /* Whether you have gcov */ #undef HAVE_GCOV /* Define to 1 if you have the `getline' function. */ #undef HAVE_GETLINE -/* Enable if your compiler supports the Intel __sync_* atomic primitives */ -#undef HAVE_INTEL_ATOMIC_PRIMITIVES +/* Define to 1 if you have the `gmtime_r' function. */ +#undef HAVE_GMTIME_R /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H @@ -155,6 +159,9 @@ /* Define to 1 if you have the `link' function. */ #undef HAVE_LINK +/* Define to 1 if you have the `localtime_r' function. */ +#undef HAVE_LOCALTIME_R + /* Define to 1 if you have the Valgrind lockdep tool */ #undef HAVE_LOCKDEP @@ -243,6 +250,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_TIME_H +/* Define to 1 if typeof works with your compiler. */ +#undef HAVE_TYPEOF + /* Define to 1 if the system has the type `uint128_t'. */ #undef HAVE_UINT128_T @@ -258,9 +268,6 @@ /* Define to 1 if you have the `waitpid' function. */ #undef HAVE_WAITPID -/* Define to 1 if you have the header file. */ -#undef HAVE_WINDOWS_H - /* Define to 1 if you have the header file. */ #undef HAVE_X11_EXTENSIONS_SHMPROTO_H @@ -413,3 +420,6 @@ #ifndef __cplusplus #undef inline #endif + +/* Define to __typeof__ if your compiler spells it that way. */ +#undef typeof diff -Nru cairo-1.15.8/configure cairo-1.15.10/configure --- cairo-1.15.8/configure 2017-08-29 17:02:13.000000000 +0000 +++ cairo-1.15.10/configure 2017-12-11 21:03:11.000000000 +0000 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for cairo 1.15.8. +# Generated by GNU Autoconf 2.69 for cairo 1.15.10. # # Report bugs to . # @@ -591,8 +591,8 @@ # Identity of this package. PACKAGE_NAME='cairo' PACKAGE_TARNAME='cairo' -PACKAGE_VERSION='1.15.8' -PACKAGE_STRING='cairo 1.15.8' +PACKAGE_VERSION='1.15.10' +PACKAGE_STRING='cairo 1.15.10' PACKAGE_BUGREPORT='http://bugs.freedesktop.org/enter_bug.cgi?product=cairo' PACKAGE_URL='http://cairographics.org/' @@ -734,6 +734,10 @@ CAIRO_HAS_COGL_SURFACE_TRUE cogl_LIBS cogl_CFLAGS +CAIRO_HAS_GLESV3_SURFACE_FALSE +CAIRO_HAS_GLESV3_SURFACE_TRUE +glesv3_LIBS +glesv3_CFLAGS CAIRO_HAS_GLESV2_SURFACE_FALSE CAIRO_HAS_GLESV2_SURFACE_TRUE glesv2_LIBS @@ -848,13 +852,26 @@ CAIRO_VERSION_MICRO CAIRO_VERSION_MINOR CAIRO_VERSION_MAJOR +GTK_DOC_USE_REBASE_FALSE +GTK_DOC_USE_REBASE_TRUE GTK_DOC_USE_LIBTOOL_FALSE GTK_DOC_USE_LIBTOOL_TRUE +GTK_DOC_BUILD_PDF_FALSE +GTK_DOC_BUILD_PDF_TRUE +GTK_DOC_BUILD_HTML_FALSE +GTK_DOC_BUILD_HTML_TRUE ENABLE_GTK_DOC_FALSE ENABLE_GTK_DOC_TRUE +HAVE_GTK_DOC_FALSE +HAVE_GTK_DOC_TRUE +GTKDOC_DEPS_LIBS +GTKDOC_DEPS_CFLAGS +HTML_DIR +GTKDOC_MKPDF +GTKDOC_REBASE +GTKDOC_CHECK_PATH GTKDOC_CHECK PKG_CONFIG -HTML_DIR LT_SYS_LIBRARY_PATH OTOOL64 OTOOL @@ -985,6 +1002,8 @@ enable_libtool_lock with_html_dir enable_gtk_doc +enable_gtk_doc_html +enable_gtk_doc_pdf enable_largefile enable_atomic enable_gcov @@ -1012,6 +1031,7 @@ enable_png enable_gl enable_glesv2 +enable_glesv3 enable_cogl enable_directfb enable_vg @@ -1046,6 +1066,8 @@ CPP LT_SYS_LIBRARY_PATH PKG_CONFIG +GTKDOC_DEPS_CFLAGS +GTKDOC_DEPS_LIBS CXX CXXFLAGS CCC @@ -1074,6 +1096,8 @@ gl_LIBS glesv2_CFLAGS glesv2_LIBS +glesv3_CFLAGS +glesv3_LIBS cogl_CFLAGS cogl_LIBS directfb_CFLAGS @@ -1648,7 +1672,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures cairo 1.15.8 to adapt to many kinds of systems. +\`configure' configures cairo 1.15.10 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1723,7 +1747,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of cairo 1.15.8:";; + short | recursive ) echo "Configuration of cairo 1.15.10:";; esac cat <<\_ACEOF @@ -1743,6 +1767,8 @@ optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) --enable-gtk-doc use gtk-doc to build documentation [[default=no]] + --enable-gtk-doc-html build documentation in html format [[default=yes]] + --enable-gtk-doc-pdf build documentation in pdf format [[default=no]] --disable-largefile omit support for large files --disable-atomic disable use of native atomic operations --enable-gcov Enable gcov @@ -1803,6 +1829,9 @@ --enable-glesv2=[no/auto/yes] Enable cairo's OpenGLESv2 surface backend feature [default=no] + --enable-glesv3=[no/auto/yes] + Enable cairo's OpenGLESv3 surface backend feature + [default=no] --enable-cogl=[no/auto/yes] Enable cairo's Cogl surface backend feature [default=no] @@ -1899,6 +1928,10 @@ LT_SYS_LIBRARY_PATH User-defined run-time library search path. PKG_CONFIG path to pkg-config utility + GTKDOC_DEPS_CFLAGS + C compiler flags for GTKDOC_DEPS, overriding pkg-config + GTKDOC_DEPS_LIBS + linker flags for GTKDOC_DEPS, overriding pkg-config CXX C++ compiler command CXXFLAGS C++ compiler flags CXXCPP C++ preprocessor @@ -1936,6 +1969,9 @@ glesv2_CFLAGS C compiler flags for glesv2, overriding pkg-config glesv2_LIBS linker flags for glesv2, overriding pkg-config + glesv3_CFLAGS + C compiler flags for glesv3, overriding pkg-config + glesv3_LIBS linker flags for glesv3, overriding pkg-config cogl_CFLAGS C compiler flags for cogl, overriding pkg-config cogl_LIBS linker flags for cogl, overriding pkg-config directfb_CFLAGS @@ -2043,7 +2079,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -cairo configure 1.15.8 +cairo configure 1.15.10 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2770,7 +2806,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by cairo $as_me 1.15.8, which was +It was created by cairo $as_me 1.15.10, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -4476,6 +4512,60 @@ done + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for typeof syntax and keyword spelling" >&5 +$as_echo_n "checking for typeof syntax and keyword spelling... " >&6; } +if ${ac_cv_c_typeof+:} false; then : + $as_echo_n "(cached) " >&6 +else + ac_cv_c_typeof=no + for ac_kw in typeof __typeof__ no; do + test $ac_kw = no && break + cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +int +main () +{ + + int value; + typedef struct { + char a [1 + + ! (($ac_kw (value)) + (($ac_kw (value)) 0 < ($ac_kw (value)) -1 + ? ($ac_kw (value)) - 1 + : ~ (~ ($ac_kw (value)) 0 + << sizeof ($ac_kw (value)))))]; } + ac__typeof_type_; + return + (! ((void) ((ac__typeof_type_ *) 0), 0)); + + ; + return 0; +} +_ACEOF +if ac_fn_c_try_compile "$LINENO"; then : + ac_cv_c_typeof=$ac_kw +fi +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext + test $ac_cv_c_typeof != no && break + done +fi +{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_typeof" >&5 +$as_echo "$ac_cv_c_typeof" >&6; } + if test $ac_cv_c_typeof != no; then + +$as_echo "#define HAVE_TYPEOF 1" >>confdefs.h + + if test $ac_cv_c_typeof != typeof; then + +cat >>confdefs.h <<_ACEOF +#define typeof $ac_cv_c_typeof +_ACEOF + + fi + fi + + am__api_version='1.15' # Find a good install program. We prefer a C program (faster), @@ -5022,7 +5112,7 @@ # Define the identity of the package. PACKAGE='cairo' - VERSION='1.15.8' + VERSION='1.15.10' # Some tools Automake needs. @@ -13545,54 +13635,121 @@ fi -# Check whether --with-html-dir was given. -if test "${with_html_dir+set}" = set; then : - withval=$with_html_dir; + + gtk_doc_requires="gtk-doc >= 1.15" + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gtk-doc" >&5 +$as_echo_n "checking for gtk-doc... " >&6; } + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\$gtk_doc_requires\""; } >&5 + ($PKG_CONFIG --exists --print-errors "$gtk_doc_requires") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + have_gtk_doc=yes else - with_html_dir='${datadir}/gtk-doc/html' + have_gtk_doc=no fi + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_gtk_doc" >&5 +$as_echo "$have_gtk_doc" >&6; } - HTML_DIR="$with_html_dir" + if test "$have_gtk_doc" = "no"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: + You will not be able to create source packages with 'make dist' + because $gtk_doc_requires is not found." >&5 +$as_echo "$as_me: WARNING: + You will not be able to create source packages with 'make dist' + because $gtk_doc_requires is not found." >&2;} + fi + # Extract the first word of "gtkdoc-check", so it can be a program name with args. +set dummy gtkdoc-check; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_prog_GTKDOC_CHECK+:} false; then : + $as_echo_n "(cached) " >&6 +else + if test -n "$GTKDOC_CHECK"; then + ac_cv_prog_GTKDOC_CHECK="$GTKDOC_CHECK" # Let the user override the test. +else +as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_prog_GTKDOC_CHECK="gtkdoc-check.test" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS - # Check whether --enable-gtk-doc was given. -if test "${enable_gtk_doc+set}" = set; then : - enableval=$enable_gtk_doc; +fi +fi +GTKDOC_CHECK=$ac_cv_prog_GTKDOC_CHECK +if test -n "$GTKDOC_CHECK"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_CHECK" >&5 +$as_echo "$GTKDOC_CHECK" >&6; } else - enable_gtk_doc=no + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } fi - if test x$enable_gtk_doc = xyes; then - if test -n "$PKG_CONFIG" && \ - { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk-doc >= 1.15\""; } >&5 - ($PKG_CONFIG --exists --print-errors "gtk-doc >= 1.15") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; then - : + # Extract the first word of "gtkdoc-check", so it can be a program name with args. +set dummy gtkdoc-check; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GTKDOC_CHECK_PATH+:} false; then : + $as_echo_n "(cached) " >&6 else - as_fn_error $? "You need to have gtk-doc >= 1.15 installed to build gtk-doc" "$LINENO" 5 -fi + case $GTKDOC_CHECK_PATH in + [\\/]* | ?:[\\/]*) + ac_cv_path_GTKDOC_CHECK_PATH="$GTKDOC_CHECK_PATH" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_GTKDOC_CHECK_PATH="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 fi +done + done +IFS=$as_save_IFS - { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build gtk-doc documentation" >&5 -$as_echo_n "checking whether to build gtk-doc documentation... " >&6; } - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_gtk_doc" >&5 -$as_echo "$enable_gtk_doc" >&6; } + ;; +esac +fi +GTKDOC_CHECK_PATH=$ac_cv_path_GTKDOC_CHECK_PATH +if test -n "$GTKDOC_CHECK_PATH"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_CHECK_PATH" >&5 +$as_echo "$GTKDOC_CHECK_PATH" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi - for ac_prog in gtkdoc-check + + for ac_prog in gtkdoc-rebase do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if ${ac_cv_path_GTKDOC_CHECK+:} false; then : +if ${ac_cv_path_GTKDOC_REBASE+:} false; then : $as_echo_n "(cached) " >&6 else - case $GTKDOC_CHECK in + case $GTKDOC_REBASE in [\\/]* | ?:[\\/]*) - ac_cv_path_GTKDOC_CHECK="$GTKDOC_CHECK" # Let the user override the test with a path. + ac_cv_path_GTKDOC_REBASE="$GTKDOC_REBASE" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -13602,7 +13759,7 @@ test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then - ac_cv_path_GTKDOC_CHECK="$as_dir/$ac_word$ac_exec_ext" + ac_cv_path_GTKDOC_REBASE="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi @@ -13613,19 +13770,193 @@ ;; esac fi -GTKDOC_CHECK=$ac_cv_path_GTKDOC_CHECK -if test -n "$GTKDOC_CHECK"; then - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_CHECK" >&5 -$as_echo "$GTKDOC_CHECK" >&6; } +GTKDOC_REBASE=$ac_cv_path_GTKDOC_REBASE +if test -n "$GTKDOC_REBASE"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_REBASE" >&5 +$as_echo "$GTKDOC_REBASE" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi - test -n "$GTKDOC_CHECK" && break + test -n "$GTKDOC_REBASE" && break done +test -n "$GTKDOC_REBASE" || GTKDOC_REBASE="true" + # Extract the first word of "gtkdoc-mkpdf", so it can be a program name with args. +set dummy gtkdoc-mkpdf; ac_word=$2 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 +$as_echo_n "checking for $ac_word... " >&6; } +if ${ac_cv_path_GTKDOC_MKPDF+:} false; then : + $as_echo_n "(cached) " >&6 +else + case $GTKDOC_MKPDF in + [\\/]* | ?:[\\/]*) + ac_cv_path_GTKDOC_MKPDF="$GTKDOC_MKPDF" # Let the user override the test with a path. + ;; + *) + as_save_IFS=$IFS; IFS=$PATH_SEPARATOR +for as_dir in $PATH +do + IFS=$as_save_IFS + test -z "$as_dir" && as_dir=. + for ac_exec_ext in '' $ac_executable_extensions; do + if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then + ac_cv_path_GTKDOC_MKPDF="$as_dir/$ac_word$ac_exec_ext" + $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 + break 2 + fi +done + done +IFS=$as_save_IFS + + ;; +esac +fi +GTKDOC_MKPDF=$ac_cv_path_GTKDOC_MKPDF +if test -n "$GTKDOC_MKPDF"; then + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTKDOC_MKPDF" >&5 +$as_echo "$GTKDOC_MKPDF" >&6; } +else + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } +fi + + + + +# Check whether --with-html-dir was given. +if test "${with_html_dir+set}" = set; then : + withval=$with_html_dir; +else + with_html_dir='${datadir}/gtk-doc/html' +fi + + HTML_DIR="$with_html_dir" + + + # Check whether --enable-gtk-doc was given. +if test "${enable_gtk_doc+set}" = set; then : + enableval=$enable_gtk_doc; +else + enable_gtk_doc=no +fi + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build gtk-doc documentation" >&5 +$as_echo_n "checking whether to build gtk-doc documentation... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_gtk_doc" >&5 +$as_echo "$enable_gtk_doc" >&6; } + + if test "x$enable_gtk_doc" = "xyes" && test "$have_gtk_doc" = "no"; then + as_fn_error $? " + You must have $gtk_doc_requires installed to build documentation for + $PACKAGE_NAME. Please install gtk-doc or disable building the + documentation by adding '--disable-gtk-doc' to '$0'." "$LINENO" 5 + fi + + if test "x$PACKAGE_NAME" != "xglib"; then + +pkg_failed=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTKDOC_DEPS" >&5 +$as_echo_n "checking for GTKDOC_DEPS... " >&6; } + +if test -n "$GTKDOC_DEPS_CFLAGS"; then + pkg_cv_GTKDOC_DEPS_CFLAGS="$GTKDOC_DEPS_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0\""; } >&5 + ($PKG_CONFIG --exists --print-errors "glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + pkg_cv_GTKDOC_DEPS_CFLAGS=`$PKG_CONFIG --cflags "glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$GTKDOC_DEPS_LIBS"; then + pkg_cv_GTKDOC_DEPS_LIBS="$GTKDOC_DEPS_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0\""; } >&5 + ($PKG_CONFIG --exists --print-errors "glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + pkg_cv_GTKDOC_DEPS_LIBS=`$PKG_CONFIG --libs "glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + GTKDOC_DEPS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0" 2>&1` + else + GTKDOC_DEPS_PKG_ERRORS=`$PKG_CONFIG --print-errors "glib-2.0 >= 2.10.0 gobject-2.0 >= 2.10.0" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$GTKDOC_DEPS_PKG_ERRORS" >&5 + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + : +elif test $pkg_failed = untried; then + : +else + GTKDOC_DEPS_CFLAGS=$pkg_cv_GTKDOC_DEPS_CFLAGS + GTKDOC_DEPS_LIBS=$pkg_cv_GTKDOC_DEPS_LIBS + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + : +fi + fi + + # Check whether --enable-gtk-doc-html was given. +if test "${enable_gtk_doc_html+set}" = set; then : + enableval=$enable_gtk_doc_html; +else + enable_gtk_doc_html=yes +fi + + # Check whether --enable-gtk-doc-pdf was given. +if test "${enable_gtk_doc_pdf+set}" = set; then : + enableval=$enable_gtk_doc_pdf; +else + enable_gtk_doc_pdf=no +fi + + + if test -z "$GTKDOC_MKPDF"; then + enable_gtk_doc_pdf=no + fi + + if test -z "$AM_DEFAULT_VERBOSITY"; then + AM_DEFAULT_VERBOSITY=1 + fi + + + if test x$have_gtk_doc = xyes; then + HAVE_GTK_DOC_TRUE= + HAVE_GTK_DOC_FALSE='#' +else + HAVE_GTK_DOC_TRUE='#' + HAVE_GTK_DOC_FALSE= +fi if test x$enable_gtk_doc = xyes; then ENABLE_GTK_DOC_TRUE= @@ -13635,6 +13966,22 @@ ENABLE_GTK_DOC_FALSE= fi + if test x$enable_gtk_doc_html = xyes; then + GTK_DOC_BUILD_HTML_TRUE= + GTK_DOC_BUILD_HTML_FALSE='#' +else + GTK_DOC_BUILD_HTML_TRUE='#' + GTK_DOC_BUILD_HTML_FALSE= +fi + + if test x$enable_gtk_doc_pdf = xyes; then + GTK_DOC_BUILD_PDF_TRUE= + GTK_DOC_BUILD_PDF_FALSE='#' +else + GTK_DOC_BUILD_PDF_TRUE='#' + GTK_DOC_BUILD_PDF_FALSE= +fi + if test -n "$LIBTOOL"; then GTK_DOC_USE_LIBTOOL_TRUE= GTK_DOC_USE_LIBTOOL_FALSE='#' @@ -13643,6 +13990,14 @@ GTK_DOC_USE_LIBTOOL_FALSE= fi + if test -n "$GTKDOC_REBASE"; then + GTK_DOC_USE_REBASE_TRUE= + GTK_DOC_USE_REBASE_FALSE='#' +else + GTK_DOC_USE_REBASE_TRUE='#' + GTK_DOC_USE_REBASE_FALSE= +fi + # Check whether --enable-largefile was given. @@ -13860,10 +14215,10 @@ CAIRO_VERSION_MAJOR=1 CAIRO_VERSION_MINOR=15 -CAIRO_VERSION_MICRO=8 +CAIRO_VERSION_MICRO=10 CAIRO_VERSION_SONUM=2 CAIRO_RELEASE_STATUS=snapshot -CAIRO_LIBTOOL_VERSION_INFO=11510:0:11508 +CAIRO_LIBTOOL_VERSION_INFO=11512:0:11510 @@ -19519,7 +19874,7 @@ } _ACEOF if ac_fn_c_try_link "$LINENO"; then : - cairo_cv_atomic_primitives="Intel" + cairo_cv_atomic_primitives="gcc-legacy" fi rm -f core conftest.err conftest.$ac_objext \ @@ -19573,9 +19928,9 @@ fi - if test "x$cairo_cv_atomic_primitives" = xIntel; then + if test "x$cairo_cv_atomic_primitives" = xgcc-legacy; then -$as_echo "#define HAVE_INTEL_ATOMIC_PRIMITIVES 1" >>confdefs.h +$as_echo "#define HAVE_GCC_LEGACY_ATOMICS 1" >>confdefs.h fi @@ -20296,7 +20651,7 @@ done -for ac_func in ctime_r drand48 flockfile funlockfile getline link strndup +for ac_func in ctime_r localtime_r gmtime_r drand48 flockfile funlockfile getline link strndup do : as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" @@ -20309,21 +20664,19 @@ done -for ac_header in windows.h -do : - ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default" -if test "x$ac_cv_header_windows_h" = xyes; then : - cat >>confdefs.h <<_ACEOF -#define HAVE_WINDOWS_H 1 +cat confdefs.h - <<_ACEOF >conftest.$ac_ext +/* end confdefs.h. */ + +#ifdef _WIN32 + choke me +#endif _ACEOF - have_windows=yes -else +if ac_fn_c_try_compile "$LINENO"; then : have_windows=no +else + have_windows=yes fi - -done - - +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext for ac_header in sys/stat.h io.h do : @@ -28057,6 +28410,352 @@ + # Check whether --enable-glesv3 was given. +if test "${enable_glesv3+set}" = set; then : + enableval=$enable_glesv3; enable_glesv3=$enableval +else + enable_glesv3=no +fi + + case $enable_glesv3 in #( + no) : + use_glesv3="no (disabled, use --enable-glesv3 to enable)" + ;; #( + yes|auto) : + { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cairo's OpenGLESv3 surface backend feature" >&5 +$as_echo_n "checking for cairo's OpenGLESv3 surface backend feature... " >&6; } + echo + + use_glesv3=yes + glesv3_BASE="cairo" +glesv3_REQUIRES="$ac_env_glesv3_REQUIRES_value" +glesv3_CFLAGS="$ac_env_glesv3_CFLAGS_value" +glesv3_NONPKGCONFIG_CFLAGS="$ac_env_glesv3_NONPKGCONFIG_CFLAGS_value" +glesv3_LIBS="$ac_env_glesv3_LIBS_value" +glesv3_NONPKGCONFIG_LIBS="$ac_env_glesv3_NONPKGCONFIG_LIBS_value" +glesv3_NONPKGCONFIG_EXTRA_LIBS="$ac_env_glesv3_NONPKGCONFIG_EXTRA_LIBS_value" + + + + glesv3_REQUIRES="glesv3" + +pkg_failed=no +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for glesv3" >&5 +$as_echo_n "checking for glesv3... " >&6; } + +if test -n "$glesv3_CFLAGS"; then + pkg_cv_glesv3_CFLAGS="$glesv3_CFLAGS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\$glesv3_REQUIRES\""; } >&5 + ($PKG_CONFIG --exists --print-errors "$glesv3_REQUIRES") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + pkg_cv_glesv3_CFLAGS=`$PKG_CONFIG --cflags "$glesv3_REQUIRES" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi +if test -n "$glesv3_LIBS"; then + pkg_cv_glesv3_LIBS="$glesv3_LIBS" + elif test -n "$PKG_CONFIG"; then + if test -n "$PKG_CONFIG" && \ + { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"\$glesv3_REQUIRES\""; } >&5 + ($PKG_CONFIG --exists --print-errors "$glesv3_REQUIRES") 2>&5 + ac_status=$? + $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 + test $ac_status = 0; }; then + pkg_cv_glesv3_LIBS=`$PKG_CONFIG --libs "$glesv3_REQUIRES" 2>/dev/null` +else + pkg_failed=yes +fi + else + pkg_failed=untried +fi + + + +if test $pkg_failed = yes; then + +if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then + _pkg_short_errors_supported=yes +else + _pkg_short_errors_supported=no +fi + if test $_pkg_short_errors_supported = yes; then + glesv3_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$glesv3_REQUIRES" 2>&1` + else + glesv3_PKG_ERRORS=`$PKG_CONFIG --print-errors "$glesv3_REQUIRES" 2>&1` + fi + # Put the nasty error message in config.log where it belongs + echo "$glesv3_PKG_ERRORS" >&5 + + { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 +$as_echo "no" >&6; } + + ac_fn_c_check_header_mongrel "$LINENO" "GLES3/gl3.h" "ac_cv_header_GLES3_gl3_h" "$ac_includes_default" +if test "x$ac_cv_header_GLES3_gl3_h" = xyes; then : + +else + use_glesv3="no (glesv3.pc nor OpenGL ES 3.0 headers not found)" +fi + + + if test "x$use_glesv3" = "xyes"; then + glesv3_NONPKGCONFIG_CFLAGS= + glesv3_NONPKGCONFIG_LIBS="-lGLESv2" + fi +elif test $pkg_failed = untried; then + + ac_fn_c_check_header_mongrel "$LINENO" "GLES3/gl3.h" "ac_cv_header_GLES3_gl3_h" "$ac_includes_default" +if test "x$ac_cv_header_GLES3_gl3_h" = xyes; then : + +else + use_glesv3="no (glesv3.pc nor OpenGL ES 3.0 headers not found)" +fi + + + if test "x$use_glesv3" = "xyes"; then + glesv3_NONPKGCONFIG_CFLAGS= + glesv3_NONPKGCONFIG_LIBS="-lGLESv2" + fi +else + glesv3_CFLAGS=$pkg_cv_glesv3_CFLAGS + glesv3_LIBS=$pkg_cv_glesv3_LIBS + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +$as_echo "yes" >&6; } + : +fi + + if test "x$have_dl" = "xyes" -a "x$have_dlsym" = "xyes"; then + glesv3_LIBS="$glesv3_LIBS -ldl" + fi + + if test "x$use_glesv3" = "xyes" -a "x$use_gl" = "xyes"; then + as_fn_error $? "use either --enable-gl=yes or --enable-glesv3=yes. Not both at the same time." "$LINENO" 5 + fi + + need_egl_functions=yes + + + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cairo's OpenGLESv3 surface backend feature could be enabled" >&5 +$as_echo_n "checking whether cairo's OpenGLESv3 surface backend feature could be enabled... " >&6; } + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_glesv3" >&5 +$as_echo "$use_glesv3" >&6; } + + if test "x$enable_glesv3" = "xyes" -a "x$use_glesv3" != xyes; then : + as_fn_error $? " OpenGLESv3 surface backend feature could not be enabled" "$LINENO" 5 + +fi ;; #( + *) : + as_fn_error $? "invalid argument passed to --enable-glesv3: \`$use_glesv3', should be one of [no/auto/yes]" "$LINENO" 5 + ;; +esac + if test "x$use_glesv3" = "xyes"; then : + CAIRO_REQUIRES="$glesv3_REQUIRES"" ${CAIRO_REQUIRES}" + + CAIRO_CFLAGS="$glesv3_CFLAGS"" ${CAIRO_CFLAGS}" + + CAIRO_NONPKGCONFIG_CFLAGS="$glesv3_NONPKGCONFIG_CFLAGS"" ${CAIRO_NONPKGCONFIG_CFLAGS}" + + CAIRO_LIBS="$glesv3_LIBS"" ${CAIRO_LIBS}" + + CAIRO_NONPKGCONFIG_LIBS="$glesv3_NONPKGCONFIG_LIBS"" ${CAIRO_NONPKGCONFIG_LIBS}" + + +else + unset glesv3_BASE +unset glesv3_REQUIRES +unset glesv3_CFLAGS +unset glesv3_NONPKGCONFIG_CFLAGS +unset glesv3_LIBS +unset glesv3_NONPKGCONFIG_LIBS +unset glesv3_NONPKGCONFIG_EXTRA_LIBS + + +fi + + if test "x$use_glesv3" = xyes; then + CAIRO_HAS_GLESV3_SURFACE_TRUE= + CAIRO_HAS_GLESV3_SURFACE_FALSE='#' +else + CAIRO_HAS_GLESV3_SURFACE_TRUE='#' + CAIRO_HAS_GLESV3_SURFACE_FALSE= +fi + + + cr_make_tmp='CAIRO_HAS_GLESV3_SURFACE=0' + CAIRO_MAKEFILE___WIN32="${CAIRO_MAKEFILE___WIN32} +""$cr_make_tmp" + + + cr_make_tmp='' + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +""$cr_make_tmp" + + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +""$cr_make_tmp" + cr_make_tmp='' + CAIRO_MAKEFILE_cairo_boilerplate_AMAKE="${CAIRO_MAKEFILE_cairo_boilerplate_AMAKE} +""$cr_make_tmp" + + CAIRO_MAKEFILE_cairo_boilerplate_WIN32="${CAIRO_MAKEFILE_cairo_boilerplate_WIN32} +""$cr_make_tmp" + + + + cr_make_tmp='unsupported_cairo_headers += $(cairo_glesv3_headers)' + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +""$cr_make_tmp" + + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +""$cr_make_tmp" + cr_make_tmp='unsupported_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers)' + CAIRO_MAKEFILE_cairo_boilerplate_AMAKE="${CAIRO_MAKEFILE_cairo_boilerplate_AMAKE} +""$cr_make_tmp" + + CAIRO_MAKEFILE_cairo_boilerplate_WIN32="${CAIRO_MAKEFILE_cairo_boilerplate_WIN32} +""$cr_make_tmp" + + + cr_make_tmp='all_cairo_headers += $(cairo_glesv3_headers) +all_cairo_private += $(cairo_glesv3_private) +all_cairo_cxx_sources += $(cairo_glesv3_cxx_sources) +all_cairo_sources += $(cairo_glesv3_sources)' + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +""$cr_make_tmp" + + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +""$cr_make_tmp" + cr_make_tmp='all_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers) +all_cairo_boilerplate_private += $(cairo_boilerplate_glesv3_private) +all_cairo_boilerplate_cxx_sources += $(cairo_boilerplate_glesv3_cxx_sources) +all_cairo_boilerplate_sources += $(cairo_boilerplate_glesv3_sources)' + CAIRO_MAKEFILE_cairo_boilerplate_AMAKE="${CAIRO_MAKEFILE_cairo_boilerplate_AMAKE} +""$cr_make_tmp" + + CAIRO_MAKEFILE_cairo_boilerplate_WIN32="${CAIRO_MAKEFILE_cairo_boilerplate_WIN32} +""$cr_make_tmp" + + + cr_make_tmp='enabled_cairo_headers += $(cairo_glesv3_headers) +enabled_cairo_private += $(cairo_glesv3_private) +enabled_cairo_cxx_sources += $(cairo_glesv3_cxx_sources) +enabled_cairo_sources += $(cairo_glesv3_sources)' + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +"'if CAIRO_HAS_GLESV3_SURFACE' + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +""$cr_make_tmp" + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +"'endif' + + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +"'ifeq ($(CAIRO_HAS_GLESV3_SURFACE),1)' + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +""$cr_make_tmp" + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +"'endif' + cr_make_tmp='enabled_cairo_boilerplate_headers += $(cairo_boilerplate_glesv3_headers) +enabled_cairo_boilerplate_private += $(cairo_boilerplate_glesv3_private) +enabled_cairo_boilerplate_cxx_sources += $(cairo_boilerplate_glesv3_cxx_sources) +enabled_cairo_boilerplate_sources += $(cairo_boilerplate_glesv3_sources)' + CAIRO_MAKEFILE_cairo_boilerplate_AMAKE="${CAIRO_MAKEFILE_cairo_boilerplate_AMAKE} +"'if CAIRO_HAS_GLESV3_SURFACE' + CAIRO_MAKEFILE_cairo_boilerplate_AMAKE="${CAIRO_MAKEFILE_cairo_boilerplate_AMAKE} +""$cr_make_tmp" + CAIRO_MAKEFILE_cairo_boilerplate_AMAKE="${CAIRO_MAKEFILE_cairo_boilerplate_AMAKE} +"'endif' + + CAIRO_MAKEFILE_cairo_boilerplate_WIN32="${CAIRO_MAKEFILE_cairo_boilerplate_WIN32} +"'ifeq ($(CAIRO_HAS_GLESV3_SURFACE),1)' + CAIRO_MAKEFILE_cairo_boilerplate_WIN32="${CAIRO_MAKEFILE_cairo_boilerplate_WIN32} +""$cr_make_tmp" + CAIRO_MAKEFILE_cairo_boilerplate_WIN32="${CAIRO_MAKEFILE_cairo_boilerplate_WIN32} +"'endif' + + + + + if test "x$use_glesv3" = xyes; then : + : + ac_config_files="$ac_config_files src/cairo-glesv3.pc:src/cairo-features.pc.in" + + +fi + if test "x$use_glesv3" = xyes; then : + : + ac_config_files="$ac_config_files cairo-glesv3-uninstalled.pc:src/cairo-features-uninstalled.pc.in" + + +fi + cr_make_tmp='all_cairo_pkgconf += cairo-glesv3.pc' + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +""$cr_make_tmp" + + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +""$cr_make_tmp" + + + cr_make_tmp='enabled_cairo_pkgconf += cairo-glesv3.pc' + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +"'if CAIRO_HAS_GLESV3_SURFACE' + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +""$cr_make_tmp" + CAIRO_MAKEFILE_cairo_AMAKE="${CAIRO_MAKEFILE_cairo_AMAKE} +"'endif' + + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +"'ifeq ($(CAIRO_HAS_GLESV3_SURFACE),1)' + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +""$cr_make_tmp" + CAIRO_MAKEFILE_cairo_WIN32="${CAIRO_MAKEFILE_cairo_WIN32} +"'endif' + + + if test "x$use_glesv3" = xyes; then : + : + CAIRO_FEATURES="${CAIRO_FEATURES} "'CAIRO_HAS_GLESV3_SURFACE' + + +fi + + if test "x$use_glesv3" != xyes; then : + : + CAIRO_NO_FEATURES="${CAIRO_NO_FEATURES} "'CAIRO_HAS_GLESV3_SURFACE' + + + +fi + + cr_make_tmp=' @echo "#define CAIRO_HAS_GLESV3_SURFACE 1" >> $(top_srcdir)/src/cairo-features.h' + CAIRO_MAKEFILE_win32_features_h_WIN32="${CAIRO_MAKEFILE_win32_features_h_WIN32} +"'ifeq ($(CAIRO_HAS_GLESV3_SURFACE),1)' + CAIRO_MAKEFILE_win32_features_h_WIN32="${CAIRO_MAKEFILE_win32_features_h_WIN32} +""$cr_make_tmp" + CAIRO_MAKEFILE_win32_features_h_WIN32="${CAIRO_MAKEFILE_win32_features_h_WIN32} +"'endif' + + + if test "x$use_glesv3" = xyes; then : + : + CAIRO_WARNING_MESSAGE="${CAIRO_WARNING_MESSAGE} + +"'--- The OpenGLESv3 surface backend feature is still under active development +--- and is included in this release only as a preview. It does NOT fully work +--- yet and incompatible changes may yet be made to OpenGLESv3 surface +--- backend specific API.' + + + +fi + + + + + # Check whether --enable-cogl was given. if test "${enable_cogl+set}" = set; then : enableval=$enable_cogl; enable_cogl=$enableval @@ -35721,14 +36420,30 @@ am__EXEEXT_FALSE= fi +if test -z "${HAVE_GTK_DOC_TRUE}" && test -z "${HAVE_GTK_DOC_FALSE}"; then + as_fn_error $? "conditional \"HAVE_GTK_DOC\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi if test -z "${ENABLE_GTK_DOC_TRUE}" && test -z "${ENABLE_GTK_DOC_FALSE}"; then as_fn_error $? "conditional \"ENABLE_GTK_DOC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${GTK_DOC_BUILD_HTML_TRUE}" && test -z "${GTK_DOC_BUILD_HTML_FALSE}"; then + as_fn_error $? "conditional \"GTK_DOC_BUILD_HTML\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi +if test -z "${GTK_DOC_BUILD_PDF_TRUE}" && test -z "${GTK_DOC_BUILD_PDF_FALSE}"; then + as_fn_error $? "conditional \"GTK_DOC_BUILD_PDF\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi if test -z "${GTK_DOC_USE_LIBTOOL_TRUE}" && test -z "${GTK_DOC_USE_LIBTOOL_FALSE}"; then as_fn_error $? "conditional \"GTK_DOC_USE_LIBTOOL\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${GTK_DOC_USE_REBASE_TRUE}" && test -z "${GTK_DOC_USE_REBASE_FALSE}"; then + as_fn_error $? "conditional \"GTK_DOC_USE_REBASE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then as_fn_error $? "conditional \"am__fastdepCXX\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 @@ -35866,6 +36581,10 @@ as_fn_error $? "conditional \"CAIRO_HAS_GLESV2_SURFACE\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi +if test -z "${CAIRO_HAS_GLESV3_SURFACE_TRUE}" && test -z "${CAIRO_HAS_GLESV3_SURFACE_FALSE}"; then + as_fn_error $? "conditional \"CAIRO_HAS_GLESV3_SURFACE\" was never defined. +Usually this means the macro was only invoked conditionally." "$LINENO" 5 +fi if test -z "${CAIRO_HAS_COGL_SURFACE_TRUE}" && test -z "${CAIRO_HAS_COGL_SURFACE_FALSE}"; then as_fn_error $? "conditional \"CAIRO_HAS_COGL_SURFACE\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 @@ -36391,7 +37110,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by cairo $as_me 1.15.8, which was +This file was extended by cairo $as_me 1.15.10, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -36458,7 +37177,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -cairo config.status 1.15.8 +cairo config.status 1.15.10 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" @@ -37239,6 +37958,20 @@ glesv2_NONPKGCONFIG_CFLAGS='$glesv2_NONPKGCONFIG_CFLAGS' SED='$SED' + glesv3_BASE='$glesv3_BASE' + glesv3_REQUIRES='$glesv3_REQUIRES' + glesv3_NONPKGCONFIG_LIBS='$glesv3_NONPKGCONFIG_LIBS' + glesv3_NONPKGCONFIG_EXTRA_LIBS='$glesv3_NONPKGCONFIG_EXTRA_LIBS' + glesv3_NONPKGCONFIG_CFLAGS='$glesv3_NONPKGCONFIG_CFLAGS' + + SED='$SED' + glesv3_BASE='$glesv3_BASE' + glesv3_REQUIRES='$glesv3_REQUIRES' + glesv3_NONPKGCONFIG_LIBS='$glesv3_NONPKGCONFIG_LIBS' + glesv3_NONPKGCONFIG_EXTRA_LIBS='$glesv3_NONPKGCONFIG_EXTRA_LIBS' + glesv3_NONPKGCONFIG_CFLAGS='$glesv3_NONPKGCONFIG_CFLAGS' + + SED='$SED' cogl_BASE='$cogl_BASE' cogl_REQUIRES='$cogl_REQUIRES' cogl_NONPKGCONFIG_LIBS='$cogl_NONPKGCONFIG_LIBS' @@ -37508,6 +38241,8 @@ "cairo-gl-uninstalled.pc") CONFIG_FILES="$CONFIG_FILES cairo-gl-uninstalled.pc:src/cairo-features-uninstalled.pc.in" ;; "src/cairo-glesv2.pc") CONFIG_FILES="$CONFIG_FILES src/cairo-glesv2.pc:src/cairo-features.pc.in" ;; "cairo-glesv2-uninstalled.pc") CONFIG_FILES="$CONFIG_FILES cairo-glesv2-uninstalled.pc:src/cairo-features-uninstalled.pc.in" ;; + "src/cairo-glesv3.pc") CONFIG_FILES="$CONFIG_FILES src/cairo-glesv3.pc:src/cairo-features.pc.in" ;; + "cairo-glesv3-uninstalled.pc") CONFIG_FILES="$CONFIG_FILES cairo-glesv3-uninstalled.pc:src/cairo-features-uninstalled.pc.in" ;; "src/cairo-cogl.pc") CONFIG_FILES="$CONFIG_FILES src/cairo-cogl.pc:src/cairo-features.pc.in" ;; "cairo-cogl-uninstalled.pc") CONFIG_FILES="$CONFIG_FILES cairo-cogl-uninstalled.pc:src/cairo-features-uninstalled.pc.in" ;; "src/cairo-directfb.pc") CONFIG_FILES="$CONFIG_FILES src/cairo-directfb.pc:src/cairo-features.pc.in" ;; @@ -39286,6 +40021,14 @@ $SED " s%@FEATURE_PC@%cairo-glesv2%g; s%@FEATURE_NAME@%OpenGLESv2 surface backend%g; s%@FEATURE_BASE@%$glesv2_BASE%g; s%@FEATURE_REQUIRES@%$glesv2_REQUIRES%g; s%@FEATURE_NONPKGCONFIG_LIBS@%$glesv2_NONPKGCONFIG_LIBS%g; s%@FEATURE_NONPKGCONFIG_EXTRA_LIBS@%$glesv2_NONPKGCONFIG_EXTRA_LIBS%g; s%@FEATURE_NONPKGCONFIG_CFLAGS@%$glesv2_NONPKGCONFIG_CFLAGS%g; " < "cairo-glesv2-uninstalled.pc.tmp" > "cairo-glesv2-uninstalled.pc" && rm -f "cairo-glesv2-uninstalled.pc.tmp" || as_fn_error $? "failed to update cairo-glesv2-uninstalled.pc" "$LINENO" 5 ;; + "src/cairo-glesv3.pc":F) mv "src/cairo-glesv3.pc" "src/cairo-glesv3.pc.tmp" && + $SED " s%@FEATURE_PC@%cairo-glesv3%g; s%@FEATURE_NAME@%OpenGLESv3 surface backend%g; s%@FEATURE_BASE@%$glesv3_BASE%g; s%@FEATURE_REQUIRES@%$glesv3_REQUIRES%g; s%@FEATURE_NONPKGCONFIG_LIBS@%$glesv3_NONPKGCONFIG_LIBS%g; s%@FEATURE_NONPKGCONFIG_EXTRA_LIBS@%$glesv3_NONPKGCONFIG_EXTRA_LIBS%g; s%@FEATURE_NONPKGCONFIG_CFLAGS@%$glesv3_NONPKGCONFIG_CFLAGS%g; " < "src/cairo-glesv3.pc.tmp" > "src/cairo-glesv3.pc" && rm -f "src/cairo-glesv3.pc.tmp" || + as_fn_error $? "failed to update src/cairo-glesv3.pc" "$LINENO" 5 + ;; + "cairo-glesv3-uninstalled.pc":F) mv "cairo-glesv3-uninstalled.pc" "cairo-glesv3-uninstalled.pc.tmp" && + $SED " s%@FEATURE_PC@%cairo-glesv3%g; s%@FEATURE_NAME@%OpenGLESv3 surface backend%g; s%@FEATURE_BASE@%$glesv3_BASE%g; s%@FEATURE_REQUIRES@%$glesv3_REQUIRES%g; s%@FEATURE_NONPKGCONFIG_LIBS@%$glesv3_NONPKGCONFIG_LIBS%g; s%@FEATURE_NONPKGCONFIG_EXTRA_LIBS@%$glesv3_NONPKGCONFIG_EXTRA_LIBS%g; s%@FEATURE_NONPKGCONFIG_CFLAGS@%$glesv3_NONPKGCONFIG_CFLAGS%g; " < "cairo-glesv3-uninstalled.pc.tmp" > "cairo-glesv3-uninstalled.pc" && rm -f "cairo-glesv3-uninstalled.pc.tmp" || + as_fn_error $? "failed to update cairo-glesv3-uninstalled.pc" "$LINENO" 5 + ;; "src/cairo-cogl.pc":F) mv "src/cairo-cogl.pc" "src/cairo-cogl.pc.tmp" && $SED " s%@FEATURE_PC@%cairo-cogl%g; s%@FEATURE_NAME@%Cogl surface backend%g; s%@FEATURE_BASE@%$cogl_BASE%g; s%@FEATURE_REQUIRES@%$cogl_REQUIRES%g; s%@FEATURE_NONPKGCONFIG_LIBS@%$cogl_NONPKGCONFIG_LIBS%g; s%@FEATURE_NONPKGCONFIG_EXTRA_LIBS@%$cogl_NONPKGCONFIG_EXTRA_LIBS%g; s%@FEATURE_NONPKGCONFIG_CFLAGS@%$cogl_NONPKGCONFIG_CFLAGS%g; " < "src/cairo-cogl.pc.tmp" > "src/cairo-cogl.pc" && rm -f "src/cairo-cogl.pc.tmp" || as_fn_error $? "failed to update src/cairo-cogl.pc" "$LINENO" 5 @@ -39471,6 +40214,7 @@ echo " SVG: $use_svg" echo " OpenGL: $use_gl" echo " OpenGL ES 2.0: $use_glesv2" + echo " OpenGL ES 3.0: $use_glesv3" echo " BeOS: $use_beos" echo " DirectFB: $use_directfb" echo " OpenVG: $use_vg" diff -Nru cairo-1.15.8/configure.ac cairo-1.15.10/configure.ac --- cairo-1.15.8/configure.ac 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/configure.ac 2017-12-07 02:14:36.000000000 +0000 @@ -12,6 +12,7 @@ AC_CONFIG_HEADERS(config.h) AC_CHECK_HEADERS([unistd.h sys/ioctl.h]) +AC_C_TYPEOF AM_INIT_AUTOMAKE([1.11 foreign -Wall no-define no-dist-gzip dist-xz]) AM_SILENT_RULES([yes]) @@ -383,6 +384,29 @@ fi need_egl_functions=yes +]) + +dnl =========================================================================== +CAIRO_ENABLE_SURFACE_BACKEND(glesv3, OpenGLESv3, no, [ + glesv3_REQUIRES="glesv3" + PKG_CHECK_MODULES(glesv3, $glesv3_REQUIRES,, [ + dnl Fallback to searching for headers + AC_CHECK_HEADER(GLES3/gl3.h,, [use_glesv3="no (glesv3.pc nor OpenGL ES 3.0 headers not found)"]) + if test "x$use_glesv3" = "xyes"; then + glesv3_NONPKGCONFIG_CFLAGS= + dnl glesv3 is provided by the libGLESv2 library (there is no separate libGLESv3) + glesv3_NONPKGCONFIG_LIBS="-lGLESv2" + fi]) + + if test "x$have_dl" = "xyes" -a "x$have_dlsym" = "xyes"; then + glesv3_LIBS="$glesv3_LIBS -ldl" + fi + + if test "x$use_glesv3" = "xyes" -a "x$use_gl" = "xyes"; then + AC_MSG_ERROR([use either --enable-gl=yes or --enable-glesv3=yes. Not both at the same time.]) + fi + + need_egl_functions=yes ]) dnl =========================================================================== diff -Nru cairo-1.15.8/debian/changelog cairo-1.15.10/debian/changelog --- cairo-1.15.8/debian/changelog 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/changelog 2018-02-25 13:01:14.000000000 +0000 @@ -1,3 +1,23 @@ +cairo (1.15.10-2) unstable; urgency=medium + + * Cherry-pick 0005-Revert-fix-warning-variable-X.patch: + Fix libcairo-perl autopkgtest regression. Thanks Niko Tyni + for identifying the fix. (Closes: #889471) + * Mark libcairo2-dev as Multi-Arch: same (Closes: #689122) and + libcairo2-doc as Multi-Arch: foreign (Closes: #884167) + + -- Jeremy Bicha Sun, 25 Feb 2018 08:01:14 -0500 + +cairo (1.15.10-1) unstable; urgency=medium + + * New upstream snapshot release + * Update Vcs fields for migration to https://salsa.debian.org/ + * debian/libcairo2.symbols: Add new symbols + * Drop 07_CVE-2016-9082.patch: Applied in new release + * Refresh patches + + -- Jeremy Bicha Fri, 02 Feb 2018 14:39:52 -0500 + cairo (1.15.8-3) unstable; urgency=medium * Update Vcs fields and gbp.conf for Debian GNOME team conventions diff -Nru cairo-1.15.8/debian/control cairo-1.15.10/debian/control --- cairo-1.15.8/debian/control 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/control 2018-02-25 13:01:14.000000000 +0000 @@ -27,8 +27,8 @@ zlib1g-dev, liblzo2-dev Standards-Version: 4.1.2 -Vcs-Git: https://anonscm.debian.org/git/pkg-gnome/cairo.git -Vcs-Browser: https://anonscm.debian.org/git/pkg-gnome/cairo.git +Vcs-Browser: https://salsa.debian.org/gnome-team/cairo +Vcs-Git: https://salsa.debian.org/gnome-team/cairo.git Homepage: https://cairographics.org/ Package: libcairo2 @@ -60,6 +60,7 @@ Package: libcairo2-dev Section: libdevel Architecture: any +Multi-Arch: same Depends: libcairo2 (= ${binary:Version}), libcairo-gobject2 (= ${binary:Version}), libcairo-script-interpreter2 (= ${binary:Version}), @@ -89,6 +90,7 @@ Package: libcairo2-doc Section: doc Architecture: all +Multi-Arch: foreign Depends: ${misc:Depends} Recommends: lynx | www-browser Description: Documentation for the Cairo Multi-platform 2D graphics library diff -Nru cairo-1.15.8/debian/control.in cairo-1.15.10/debian/control.in --- cairo-1.15.8/debian/control.in 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/control.in 2018-02-25 13:01:14.000000000 +0000 @@ -23,8 +23,8 @@ zlib1g-dev, liblzo2-dev Standards-Version: 4.1.2 -Vcs-Git: https://anonscm.debian.org/git/pkg-gnome/cairo.git -Vcs-Browser: https://anonscm.debian.org/git/pkg-gnome/cairo.git +Vcs-Browser: https://salsa.debian.org/gnome-team/cairo +Vcs-Git: https://salsa.debian.org/gnome-team/cairo.git Homepage: https://cairographics.org/ Package: libcairo2 @@ -56,6 +56,7 @@ Package: libcairo2-dev Section: libdevel Architecture: any +Multi-Arch: same Depends: libcairo2 (= ${binary:Version}), libcairo-gobject2 (= ${binary:Version}), libcairo-script-interpreter2 (= ${binary:Version}), @@ -85,6 +86,7 @@ Package: libcairo2-doc Section: doc Architecture: all +Multi-Arch: foreign Depends: ${misc:Depends} Recommends: lynx | www-browser Description: Documentation for the Cairo Multi-platform 2D graphics library diff -Nru cairo-1.15.8/debian/libcairo2.symbols cairo-1.15.10/debian/libcairo2.symbols --- cairo-1.15.8/debian/libcairo2.symbols 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/libcairo2.symbols 2018-02-25 13:01:14.000000000 +0000 @@ -344,7 +344,9 @@ cairo_svg_get_versions@Base 1.2.4 cairo_svg_surface_create@Base 1.2.4 cairo_svg_surface_create_for_stream@Base 1.2.4 + cairo_svg_surface_get_document_unit@Base 1.15.10 cairo_svg_surface_restrict_to_version@Base 1.2.4 + cairo_svg_surface_set_document_unit@Base 1.15.10 cairo_svg_version_to_string@Base 1.2.4 cairo_tag_begin@Base 1.15.8 cairo_tag_end@Base 1.15.8 diff -Nru cairo-1.15.8/debian/patches/0005-Revert-fix-warning-variable-X.patch cairo-1.15.10/debian/patches/0005-Revert-fix-warning-variable-X.patch --- cairo-1.15.8/debian/patches/0005-Revert-fix-warning-variable-X.patch 1970-01-01 00:00:00.000000000 +0000 +++ cairo-1.15.10/debian/patches/0005-Revert-fix-warning-variable-X.patch 2018-02-25 13:01:14.000000000 +0000 @@ -0,0 +1,92 @@ +From: Uli Schlachter +Date: Sat, 23 Dec 2017 13:04:59 +0100 +Subject: Revert "fix warning: variable X might be clobbered by 'longjmp'" + +This reverts commit b092b63119cbfe3cb4bc786eee81630998996acf which +introduced a wrapper function around setjmp(). To quote from man setjmp: + + If the function which called setjmp() returns before longjmp() is + called, the behavior is undefined. Some kind of subtle or unsubtle + chaos is sure to result. + +Since after the above commit setjmp() is called from the wrapper +function, the result might or might not work, depending on compiler +settings. If the setjmp() wrapper is not inlined, then the state of the +stack after longjmp() will likely be garbage. +--- + src/cairo-bentley-ottmann-rectangular.c | 8 +------- + src/cairo-png.c | 17 ++++++----------- + 2 files changed, 7 insertions(+), 18 deletions(-) + +diff --git a/src/cairo-bentley-ottmann-rectangular.c b/src/cairo-bentley-ottmann-rectangular.c +index 15688c7..29f902c 100644 +--- a/src/cairo-bentley-ottmann-rectangular.c ++++ b/src/cairo-bentley-ottmann-rectangular.c +@@ -593,12 +593,6 @@ sweep_line_insert (sweep_line_t *sweep, rectangle_t *rectangle) + pqueue_push (sweep, rectangle); + } + +-static int +-sweep_line_setjmp (sweep_line_t *sweep_line) +-{ +- return setjmp (sweep_line->unwind); +-} +- + static cairo_status_t + _cairo_bentley_ottmann_tessellate_rectangular (rectangle_t **rectangles, + int num_rectangles, +@@ -615,7 +609,7 @@ _cairo_bentley_ottmann_tessellate_rectangular (rectangle_t **rectangles, + rectangles, num_rectangles, + fill_rule, + do_traps, container); +- if ((status = sweep_line_setjmp (&sweep_line))) ++ if ((status = setjmp (sweep_line.unwind))) + return status; + + rectangle = rectangle_pop_start (&sweep_line); +diff --git a/src/cairo-png.c b/src/cairo-png.c +index fe23fcf..596b506 100644 +--- a/src/cairo-png.c ++++ b/src/cairo-png.c +@@ -158,14 +158,6 @@ png_simple_warning_callback (png_structp png, + */ + } + +-static int +-png_setjmp (png_struct *png) +-{ +-#ifdef PNG_SETJMP_SUPPORTED +- return setjmp (png_jmpbuf (png)); +-#endif +- return 0; +-} + + /* Starting with libpng-1.2.30, we must explicitly specify an output_flush_fn. + * Otherwise, we will segfault if we are writing to a stream. */ +@@ -237,8 +229,10 @@ write_png (cairo_surface_t *surface, + goto BAIL4; + } + +- if (png_setjmp (png)) ++#ifdef PNG_SETJMP_SUPPORTED ++ if (setjmp (png_jmpbuf (png))) + goto BAIL4; ++#endif + + png_set_write_fn (png, closure, write_func, png_simple_output_flush_fn); + +@@ -584,11 +578,12 @@ read_png (struct png_read_closure_t *png_closure) + png_set_read_fn (png, png_closure, stream_read_func); + + status = CAIRO_STATUS_SUCCESS; +- +- if (png_setjmp (png)) { ++#ifdef PNG_SETJMP_SUPPORTED ++ if (setjmp (png_jmpbuf (png))) { + surface = _cairo_surface_create_in_error (status); + goto BAIL; + } ++#endif + + png_read_info (png, info); + diff -Nru cairo-1.15.8/debian/patches/01_build_perf_utils.patch cairo-1.15.10/debian/patches/01_build_perf_utils.patch --- cairo-1.15.8/debian/patches/01_build_perf_utils.patch 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/patches/01_build_perf_utils.patch 2018-02-25 13:01:14.000000000 +0000 @@ -1,12 +1,31 @@ -Description: Build cairo-perf-utils as part of then normal build process. -Author: Alexandros Frantzis +From: Alexandros Frantzis +Date: Tue, 7 Sep 2010 10:09:10 +0200 +Subject: Build cairo-perf-utils as part of then normal build process. + Bug: https://bugs.freedesktop.org/show_bug.cgi?id=28865 -Last-Update: 2010-08-03 -Index: cairo/configure.ac -=================================================================== ---- cairo.orig/configure.ac 2014-10-21 22:34:06.167497938 +0200 -+++ cairo/configure.ac 2014-10-21 22:34:06.163497880 +0200 -@@ -851,6 +851,11 @@ +--- + build/configure.ac.features | 1 + + configure.ac | 5 +++++ + perf/Makefile.am | 14 ++++++++++++++ + 3 files changed, 20 insertions(+) + +diff --git a/build/configure.ac.features b/build/configure.ac.features +index aa48652..3ae569b 100644 +--- a/build/configure.ac.features ++++ b/build/configure.ac.features +@@ -409,6 +409,7 @@ AC_DEFUN([CAIRO_REPORT], + echo "The following features and utilities:" + echo " cairo-trace: $use_trace" + echo " cairo-script-interpreter: $use_interpreter" ++ echo " cairo-perf-utils: $use_perf_utils" + echo "" + echo "And the following internal features:" + echo " pthread: $use_pthread" +diff --git a/configure.ac b/configure.ac +index d82db45..a8df3b8 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -878,6 +878,11 @@ dnl =========================================================================== PKG_CHECK_MODULES(gtk, "gtk+-2.0",have_gtk=yes, have_gtk=no) AM_CONDITIONAL(HAVE_GTK, test "x$have_gtk" = "xyes") @@ -18,11 +37,11 @@ AC_CONFIG_FILES([ Makefile boilerplate/Makefile -Index: cairo/perf/Makefile.am -=================================================================== ---- cairo.orig/perf/Makefile.am 2014-10-21 22:34:06.167497938 +0200 -+++ cairo/perf/Makefile.am 2014-10-21 22:34:06.163497880 +0200 -@@ -15,11 +15,25 @@ +diff --git a/perf/Makefile.am b/perf/Makefile.am +index 40b35bc..70ed619 100644 +--- a/perf/Makefile.am ++++ b/perf/Makefile.am +@@ -15,11 +15,25 @@ AM_LDFLAGS = $(CAIRO_LDFLAGS) SUBDIRS = micro @@ -48,15 +67,3 @@ EXTRA_PROGRAMS += \ cairo-analyse-trace \ -Index: cairo/build/configure.ac.features -=================================================================== ---- cairo.orig/build/configure.ac.features 2014-10-21 22:34:06.167497938 +0200 -+++ cairo/build/configure.ac.features 2014-10-21 22:34:06.163497880 +0200 -@@ -408,6 +408,7 @@ - echo "The following features and utilities:" - echo " cairo-trace: $use_trace" - echo " cairo-script-interpreter: $use_interpreter" -+ echo " cairo-perf-utils: $use_perf_utils" - echo "" - echo "And the following internal features:" - echo " pthread: $use_pthread" diff -Nru cairo-1.15.8/debian/patches/02_am-maintainer-mode.patch cairo-1.15.10/debian/patches/02_am-maintainer-mode.patch --- cairo-1.15.8/debian/patches/02_am-maintainer-mode.patch 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/patches/02_am-maintainer-mode.patch 2018-02-25 13:01:14.000000000 +0000 @@ -1,9 +1,18 @@ -Index: cairo/configure.ac -=================================================================== ---- cairo.orig/configure.ac 2014-10-21 22:34:11.207571294 +0200 -+++ cairo/configure.ac 2014-10-21 22:34:11.203571237 +0200 -@@ -14,6 +14,7 @@ - AC_CHECK_HEADERS([unistd.h sys/ioctl.h]) +From: =?utf-8?q?Sebastian_Dr=C3=B6ge?= +Date: Tue, 7 Sep 2010 10:09:10 +0200 +Subject: Add AM_MAINTAINER_MODE again to configure.ac + +to prevent build problems +--- + configure.ac | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/configure.ac b/configure.ac +index a8df3b8..90e74ec 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -15,6 +15,7 @@ AC_CHECK_HEADERS([unistd.h sys/ioctl.h]) + AC_C_TYPEOF AM_INIT_AUTOMAKE([1.11 foreign -Wall no-define no-dist-gzip dist-xz]) +AM_MAINTAINER_MODE diff -Nru cairo-1.15.8/debian/patches/03_export-symbols.patch cairo-1.15.10/debian/patches/03_export-symbols.patch --- cairo-1.15.8/debian/patches/03_export-symbols.patch 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/patches/03_export-symbols.patch 2018-02-25 13:01:14.000000000 +0000 @@ -1,8 +1,18 @@ -Index: cairo/src/Makefile.am -=================================================================== ---- cairo.orig/src/Makefile.am 2013-01-18 11:05:30.064627087 +0100 -+++ cairo/src/Makefile.am 2013-01-18 11:05:30.060627087 +0100 -@@ -44,7 +44,7 @@ +From: Emilio Pozuelo Monfort +Date: Sat, 26 Mar 2011 10:11:21 +0000 +Subject: Only export public symbols + +--- + src/Makefile.am | 2 +- + util/cairo-gobject/Makefile.am | 2 +- + util/cairo-script/Makefile.am | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/src/Makefile.am b/src/Makefile.am +index acf0a82..64fa521 100644 +--- a/src/Makefile.am ++++ b/src/Makefile.am +@@ -44,7 +44,7 @@ libcairo_la_SOURCES = \ $(enabled_cairo_private) \ $(enabled_cairo_sources) \ $(NULL) @@ -11,11 +21,11 @@ libcairo_la_LIBADD = $(CAIRO_LIBS) \ $(cairo_cxx_lib) libcairo_la_DEPENDENCIES = $(cairo_def_dependency) $(cairo_cxx_lib) -Index: cairo/util/cairo-gobject/Makefile.am -=================================================================== ---- cairo.orig/util/cairo-gobject/Makefile.am 2013-01-18 11:05:30.064627087 +0100 -+++ cairo/util/cairo-gobject/Makefile.am 2013-01-18 11:05:30.060627087 +0100 -@@ -10,6 +10,6 @@ +diff --git a/util/cairo-gobject/Makefile.am b/util/cairo-gobject/Makefile.am +index 22c1a27..5a15950 100644 +--- a/util/cairo-gobject/Makefile.am ++++ b/util/cairo-gobject/Makefile.am +@@ -10,6 +10,6 @@ libcairo_gobject_la_SOURCES = \ $(NULL) libcairo_gobject_la_CFLAGS = $(CAIRO_CFLAGS) $(GOBJECT_CFLAGS) @@ -23,11 +33,11 @@ +libcairo_gobject_la_LDFLAGS = -version-info $(CAIRO_LIBTOOL_VERSION_INFO) -no-undefined $(export_symbols) -export-symbols-regex \^cairo_.* libcairo_gobject_la_LIBADD = $(top_builddir)/src/libcairo.la $(CAIRO_LIBS) $(GOBJECT_LIBS) -Index: cairo/util/cairo-script/Makefile.am -=================================================================== ---- cairo.orig/util/cairo-script/Makefile.am 2013-01-18 11:05:30.064627087 +0100 -+++ cairo/util/cairo-script/Makefile.am 2013-01-18 11:05:54.468627453 +0100 -@@ -14,7 +14,7 @@ +diff --git a/util/cairo-script/Makefile.am b/util/cairo-script/Makefile.am +index d5c2998..7efa25f 100644 +--- a/util/cairo-script/Makefile.am ++++ b/util/cairo-script/Makefile.am +@@ -14,7 +14,7 @@ libcairo_script_interpreter_la_SOURCES = \ $(libcairo_script_interpreter_headers) \ $(NULL) libcairo_script_interpreter_la_CFLAGS = $(CAIRO_CFLAGS) diff -Nru cairo-1.15.8/debian/patches/06_hurd-map-noreserve.patch cairo-1.15.10/debian/patches/06_hurd-map-noreserve.patch --- cairo-1.15.8/debian/patches/06_hurd-map-noreserve.patch 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/patches/06_hurd-map-noreserve.patch 2018-02-25 13:01:14.000000000 +0000 @@ -1,8 +1,17 @@ -Index: cairo/test/cairo-test-trace.c -=================================================================== ---- cairo.orig/test/cairo-test-trace.c 2015-10-30 09:09:01.835024635 +0100 -+++ cairo/test/cairo-test-trace.c 2015-10-30 09:09:01.831024583 +0100 -@@ -545,7 +545,11 @@ +From: =?utf-8?q?Sebastian_Dr=C3=B6ge?= +Date: Fri, 30 Mar 2012 09:49:05 +0200 +Subject: Hurd has no MAP_NORESERVE so don't use it there + +--- + test/cairo-test-trace.c | 4 ++++ + util/cairo-sphinx/sphinx.c | 4 ++++ + 2 files changed, 8 insertions(+) + +diff --git a/test/cairo-test-trace.c b/test/cairo-test-trace.c +index 5badc43..5c059b4 100644 +--- a/test/cairo-test-trace.c ++++ b/test/cairo-test-trace.c +@@ -545,7 +545,11 @@ spawn_shm (const char *shm_path) base = mmap (NULL, DATA_SIZE, PROT_READ | PROT_WRITE, @@ -14,11 +23,11 @@ fd, 0); close (fd); -Index: cairo/util/cairo-sphinx/sphinx.c -=================================================================== ---- cairo.orig/util/cairo-sphinx/sphinx.c 2015-10-30 09:09:01.835024635 +0100 -+++ cairo/util/cairo-sphinx/sphinx.c 2015-10-30 09:09:01.831024583 +0100 -@@ -1337,7 +1337,11 @@ +diff --git a/util/cairo-sphinx/sphinx.c b/util/cairo-sphinx/sphinx.c +index 238d400..9384edd 100644 +--- a/util/cairo-sphinx/sphinx.c ++++ b/util/cairo-sphinx/sphinx.c +@@ -1337,7 +1337,11 @@ client_shm (const char *shm_path) base = mmap (NULL, DATA_SIZE, PROT_READ | PROT_WRITE, diff -Nru cairo-1.15.8/debian/patches/07_CVE-2016-9082.patch cairo-1.15.10/debian/patches/07_CVE-2016-9082.patch --- cairo-1.15.8/debian/patches/07_CVE-2016-9082.patch 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/patches/07_CVE-2016-9082.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,107 +0,0 @@ -From c812d1c1935cccf096a60ad904e640fdc83bd41c Mon Sep 17 00:00:00 2001 -From: Adrian Johnson -Date: Thu, 20 Oct 2016 21:12:30 +1030 -Subject: [PATCH] image: prevent invalid ptr access for > 4GB images - -Image data is often accessed using: - - image->data + y * image->stride - -On 64-bit achitectures if the image data is > 4GB, this computation -will overflow since both y and stride are 32-bit types. - -https://bugs.freedesktop.org/show_bug.cgi?id=98165 ---- - boilerplate/cairo-boilerplate.c | 4 +++- - src/cairo-image-compositor.c | 4 ++-- - src/cairo-image-surface-private.h | 2 +- - src/cairo-mesh-pattern-rasterizer.c | 2 +- - src/cairo-png.c | 2 +- - src/cairo-script-surface.c | 3 ++- - 6 files changed, 10 insertions(+), 7 deletions(-) - ---- a/boilerplate/cairo-boilerplate.c -+++ b/boilerplate/cairo-boilerplate.c -@@ -42,6 +42,7 @@ - #undef CAIRO_VERSION_H - #include "../cairo-version.h" - -+#include - #include - #include - #include -@@ -976,7 +977,8 @@ cairo_surface_t * - cairo_boilerplate_image_surface_create_from_ppm_stream (FILE *file) - { - char format; -- int width, height, stride; -+ int width, height; -+ ptrdiff_t stride; - int x, y; - unsigned char *data; - cairo_surface_t *image = NULL; ---- a/src/cairo-image-compositor.c -+++ b/src/cairo-image-compositor.c -@@ -1575,7 +1575,7 @@ typedef struct _cairo_image_span_rendere - pixman_image_t *src, *mask; - union { - struct fill { -- int stride; -+ ptrdiff_t stride; - uint8_t *data; - uint32_t pixel; - } fill; -@@ -1594,7 +1594,7 @@ typedef struct _cairo_image_span_rendere - struct finish { - cairo_rectangle_int_t extents; - int src_x, src_y; -- int stride; -+ ptrdiff_t stride; - uint8_t *data; - } mask; - } u; ---- a/src/cairo-image-surface-private.h -+++ b/src/cairo-image-surface-private.h -@@ -71,7 +71,7 @@ struct _cairo_image_surface { - - int width; - int height; -- int stride; -+ ptrdiff_t stride; - int depth; - - unsigned owns_data : 1; ---- a/src/cairo-mesh-pattern-rasterizer.c -+++ b/src/cairo-mesh-pattern-rasterizer.c -@@ -470,7 +470,7 @@ draw_pixel (unsigned char *data, int wid - tg += tg >> 16; - tb += tb >> 16; - -- *((uint32_t*) (data + y*stride + 4*x)) = ((ta << 16) & 0xff000000) | -+ *((uint32_t*) (data + y*(ptrdiff_t)stride + 4*x)) = ((ta << 16) & 0xff000000) | - ((tr >> 8) & 0xff0000) | ((tg >> 16) & 0xff00) | (tb >> 24); - } - } ---- a/src/cairo-png.c -+++ b/src/cairo-png.c -@@ -671,7 +671,7 @@ read_png (struct png_read_closure_t *png - } - - for (i = 0; i < png_height; i++) -- row_pointers[i] = &data[i * stride]; -+ row_pointers[i] = &data[i * (ptrdiff_t)stride]; - - png_read_image (png, row_pointers); - png_read_end (png, info); ---- a/src/cairo-script-surface.c -+++ b/src/cairo-script-surface.c -@@ -1201,7 +1201,8 @@ static cairo_status_t - _write_image_surface (cairo_output_stream_t *output, - const cairo_image_surface_t *image) - { -- int stride, row, width; -+ int row, width; -+ ptrdiff_t stride; - uint8_t row_stack[CAIRO_STACK_BUFFER_SIZE]; - uint8_t *rowdata; - uint8_t *data; diff -Nru cairo-1.15.8/debian/patches/series cairo-1.15.10/debian/patches/series --- cairo-1.15.8/debian/patches/series 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/patches/series 2018-02-25 13:01:14.000000000 +0000 @@ -2,4 +2,4 @@ 02_am-maintainer-mode.patch 03_export-symbols.patch 06_hurd-map-noreserve.patch -07_CVE-2016-9082.patch +0005-Revert-fix-warning-variable-X.patch diff -Nru cairo-1.15.8/debian/rules cairo-1.15.10/debian/rules --- cairo-1.15.8/debian/rules 2017-12-21 18:39:22.000000000 +0000 +++ cairo-1.15.10/debian/rules 2018-02-25 13:01:14.000000000 +0000 @@ -61,6 +61,9 @@ override_dh_auto_clean: rm -rf debian/install/ debian/build/ +override_dh_auto_test: + -dh_auto_test --builddirectory=debian/build/deb + override_dh_strip: dh_strip -plibcairo2-udeb -pcairo-perf-utils dh_strip --remaining-packages --dbgsym-migration="libcairo2-dbg (<< 1.14.8-1~)" diff -Nru cairo-1.15.8/doc/Makefile.in cairo-1.15.10/doc/Makefile.in --- cairo-1.15.8/doc/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/doc/Makefile.in 2017-12-11 21:03:10.000000000 +0000 @@ -96,10 +96,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -463,6 +462,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -561,6 +565,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/doc/public/cairo-sections.txt cairo-1.15.10/doc/public/cairo-sections.txt --- cairo-1.15.8/doc/public/cairo-sections.txt 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/cairo-sections.txt 2017-12-11 21:03:31.000000000 +0000 @@ -242,6 +242,10 @@
cairo-surface CAIRO_HAS_MIME_SURFACE +CAIRO_MIME_TYPE_CCITT_FAX +CAIRO_MIME_TYPE_CCITT_FAX_PARAMS +CAIRO_MIME_TYPE_EPS +CAIRO_MIME_TYPE_EPS_PARAMS CAIRO_MIME_TYPE_JBIG2 CAIRO_MIME_TYPE_JBIG2_GLOBAL CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID diff -Nru cairo-1.15.8/doc/public/html/cairo-cairo-device-t.html cairo-1.15.10/doc/public/html/cairo-cairo-device-t.html --- cairo-1.15.8/doc/public/html/cairo-cairo-device-t.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-cairo-device-t.html 2017-12-11 21:03:31.000000000 +0000 @@ -475,7 +475,7 @@
cairo_destroy_func_t destroy);

Attach user data to device . To remove user data from a surface, -call this function with the key that was used to set it and NULL +call this function with the key that was used to set it and NULL for data .

@@ -528,7 +528,7 @@

Return user data previously attached to device using the specified key. If no user data has been attached with the given -key this function returns NULL.

+key this function returns NULL.

Parameters

@@ -554,7 +554,7 @@

Returns

-

the user data previously attached or NULL.

+

the user data previously attached or NULL.

Since: 1.10

diff -Nru cairo-1.15.8/doc/public/html/cairo-cairo-font-face-t.html cairo-1.15.10/doc/public/html/cairo-cairo-font-face-t.html --- cairo-1.15.8/doc/public/html/cairo-cairo-font-face-t.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-cairo-font-face-t.html 2017-12-11 21:03:31.000000000 +0000 @@ -150,7 +150,7 @@ - @@ -287,7 +287,7 @@ cairo_destroy_func_t destroy);

Attach user data to font_face . To remove user data from a font face, -call this function with the key that was used to set it and NULL +call this function with the key that was used to set it and NULL for data .

@@ -340,7 +340,7 @@

Return user data previously attached to font_face using the specified key. If no user data has been attached with the given key this -function returns NULL.

+function returns NULL.

Parameters

font_face

a cairo_font_face_t, (may be NULL in which case this +

a cairo_font_face_t, (may be NULL in which case this function does nothing).

 
@@ -366,7 +366,7 @@

Returns

-

the user data previously attached or NULL.

+

the user data previously attached or NULL.

Since: 1.0

diff -Nru cairo-1.15.8/doc/public/html/cairo-cairo-font-options-t.html cairo-1.15.10/doc/public/html/cairo-cairo-font-options-t.html --- cairo-1.15.8/doc/public/html/cairo-cairo-font-options-t.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-cairo-font-options-t.html 2017-12-11 21:03:31.000000000 +0000 @@ -398,8 +398,8 @@

Returns

-

TRUE if all fields of the two font options objects match. -Note that this function will return FALSE if either object is in +

TRUE if all fields of the two font options objects match. +Note that this function will return FALSE if either object is in error.

Since: 1.0

diff -Nru cairo-1.15.8/doc/public/html/cairo-cairo-pattern-t.html cairo-1.15.10/doc/public/html/cairo-cairo-pattern-t.html --- cairo-1.15.8/doc/public/html/cairo-cairo-pattern-t.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-cairo-pattern-t.html 2017-12-11 21:03:31.000000000 +0000 @@ -548,7 +548,7 @@ - + @@ -601,27 +601,27 @@ - + - + - + - + - + @@ -769,22 +769,22 @@ - + - + - + - + @@ -857,7 +857,7 @@ - + @@ -957,22 +957,22 @@ - + - + - + - + @@ -1088,32 +1088,32 @@ - + - + - + - + - + - + @@ -1756,7 +1756,7 @@ - + @@ -1863,12 +1863,12 @@ - + - + @@ -1934,22 +1934,22 @@ - + - + - + - + @@ -2345,7 +2345,7 @@ cairo_destroy_func_t destroy);

Attach user data to pattern . To remove user data from a surface, -call this function with the key that was used to set it and NULL +call this function with the key that was used to set it and NULL for data .

@@ -2398,7 +2398,7 @@

Return user data previously attached to pattern using the specified key. If no user data has been attached with the given -key this function returns NULL.

+key this function returns NULL.

Parameters

count

return value for the number of color stops, or NULL

return value for the number of color stops, or NULL

 

offset

return value for the offset of the stop, or NULL

return value for the offset of the stop, or NULL

 

red

return value for red component of color, or NULL

return value for red component of color, or NULL

 

green

return value for green component of color, or NULL

return value for green component of color, or NULL

 

blue

return value for blue component of color, or NULL

return value for blue component of color, or NULL

 

alpha

return value for alpha component of color, or NULL

return value for alpha component of color, or NULL

 

red

return value for red component of color, or NULL

return value for red component of color, or NULL

 

green

return value for green component of color, or NULL

return value for green component of color, or NULL

 

blue

return value for blue component of color, or NULL

return value for blue component of color, or NULL

 

alpha

return value for alpha component of color, or NULL

return value for alpha component of color, or NULL

 

surface

return value for surface of pattern, or NULL

return value for surface of pattern, or NULL

 

x0

return value for the x coordinate of the first point, or NULL

return value for the x coordinate of the first point, or NULL

 

y0

return value for the y coordinate of the first point, or NULL

return value for the y coordinate of the first point, or NULL

 

x1

return value for the x coordinate of the second point, or NULL

return value for the x coordinate of the second point, or NULL

 

y1

return value for the y coordinate of the second point, or NULL

return value for the y coordinate of the second point, or NULL

 

x0

return value for the x coordinate of the center of the first circle, or NULL

return value for the x coordinate of the center of the first circle, or NULL

 

y0

return value for the y coordinate of the center of the first circle, or NULL

return value for the y coordinate of the center of the first circle, or NULL

 

r0

return value for the radius of the first circle, or NULL

return value for the radius of the first circle, or NULL

 

x1

return value for the x coordinate of the center of the second circle, or NULL

return value for the x coordinate of the center of the second circle, or NULL

 

y1

return value for the y coordinate of the center of the second circle, or NULL

return value for the y coordinate of the center of the second circle, or NULL

 

r1

return value for the radius of the second circle, or NULL

return value for the radius of the second circle, or NULL

 

count

return value for the number patches, or NULL

return value for the number patches, or NULL

 

x

return value for the x coordinate of the control point, or NULL

return value for the x coordinate of the control point, or NULL

 

y

return value for the y coordinate of the control point, or NULL

return value for the y coordinate of the control point, or NULL

 

red

return value for red component of color, or NULL

return value for red component of color, or NULL

 

green

return value for green component of color, or NULL

return value for green component of color, or NULL

 

blue

return value for blue component of color, or NULL

return value for blue component of color, or NULL

 

alpha

return value for alpha component of color, or NULL

return value for alpha component of color, or NULL

 
@@ -2424,7 +2424,7 @@

Returns

-

the user data previously attached or NULL.

+

the user data previously attached or NULL.

Since: 1.4

diff -Nru cairo-1.15.8/doc/public/html/cairo-cairo-scaled-font-t.html cairo-1.15.10/doc/public/html/cairo-cairo-scaled-font-t.html --- cairo-1.15.8/doc/public/html/cairo-cairo-scaled-font-t.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-cairo-scaled-font-t.html 2017-12-11 21:03:31.000000000 +0000 @@ -284,7 +284,7 @@ - @@ -504,7 +504,7 @@ mapping, that can be used to render later using scaled_font .

If glyphs - initially points to a non-NULL value, that array is used + initially points to a non-NULL value, that array is used as a glyph buffer, and num_glyphs should point to the number of glyph entries available there. If the provided glyph array is too short for @@ -518,14 +518,14 @@ array using cairo_glyph_free(). This may happen even if the provided array was large enough.

If clusters - is not NULL, num_clusters + is not NULL, num_clusters and cluster_flags - should not be NULL, + should not be NULL, and cluster mapping will be computed. The semantics of how cluster array allocation works is similar to the glyph array. That is, if clusters - initially points to a non-NULL value, that array is used + initially points to a non-NULL value, that array is used as a cluster buffer, and num_clusters should point to the number of cluster entries available there. If the provided cluster array is too short for @@ -540,7 +540,7 @@ array was large enough.

In the simplest case, glyphs and clusters - can point to NULL initially + can point to NULL initially and a suitable array will be allocated. In code:

 cairo_status_t status;
@@ -673,19 +673,19 @@
 
 
- + - + +, or NULL

@@ -943,7 +943,7 @@ cairo_destroy_func_t destroy);

Attach user data to scaled_font . To remove user data from a surface, -call this function with the key that was used to set it and NULL +call this function with the key that was used to set it and NULL for data .

@@ -996,7 +996,7 @@

Return user data previously attached to scaled_font using the specified key. If no user data has been attached with the given -key this function returns NULL.

+key this function returns NULL.

Parameters

scaled_font

a cairo_scaled_font_t, (may be NULL in which case +

a cairo_scaled_font_t, (may be NULL in which case this function does nothing)

 

clusters

pointer to array of cluster mapping information to fill, or NULL

pointer to array of cluster mapping information to fill, or NULL

 

num_clusters

pointer to number of clusters, or NULL

pointer to number of clusters, or NULL

 

cluster_flags

pointer to location to store cluster flags corresponding to the output clusters -, or NULL

 
@@ -1022,7 +1022,7 @@

Returns

-

the user data previously attached or NULL.

+

the user data previously attached or NULL.

Since: 1.4

diff -Nru cairo-1.15.8/doc/public/html/cairo-cairo-surface-t.html cairo-1.15.10/doc/public/html/cairo-cairo-surface-t.html --- cairo-1.15.8/doc/public/html/cairo-cairo-surface-t.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-cairo-surface-t.html 2017-12-11 21:03:31.000000000 +0000 @@ -303,6 +303,22 @@ + + + + + + + + + + + + + + + + @@ -764,7 +780,7 @@

Returns

The device for surface -or NULL if the surface does +or NULL if the surface does not have an associated device.

Since: 1.10

@@ -1247,7 +1263,7 @@ cairo_destroy_func_t destroy);

Attach user data to surface . To remove user data from a surface, -call this function with the key that was used to set it and NULL +call this function with the key that was used to set it and NULL for data .

@@ -1300,7 +1316,7 @@

Return user data previously attached to surface using the specified key. If no user data has been attached with the given key this -function returns NULL.

+function returns NULL.

Parameters

#defineCAIRO_MIME_TYPE_CCITT_FAX
#defineCAIRO_MIME_TYPE_CCITT_FAX_PARAMS
#defineCAIRO_MIME_TYPE_EPS
#defineCAIRO_MIME_TYPE_EPS_PARAMS
#define CAIRO_MIME_TYPE_JBIG2
@@ -1326,7 +1342,7 @@

Returns

-

the user data previously attached or NULL.

+

the user data previously attached or NULL.

Since: 1.0

@@ -1393,7 +1409,7 @@ sophisticated cairo_show_text_glyphs() operations. That is, whether it actually uses the provided text and cluster data to a cairo_show_text_glyphs() call.

-

Note: Even if this function returns FALSE, a +

Note: Even if this function returns FALSE, a cairo_show_text_glyphs() operation targeted at surface will still succeed. It just will @@ -1417,9 +1433,9 @@

Returns

-

TRUE if surface +

TRUE if surface supports -cairo_show_text_glyphs(), FALSE otherwise

+cairo_show_text_glyphs(), FALSE otherwise

Since: 1.8

@@ -1437,7 +1453,7 @@ to surface . To remove the data from a surface, call this function with same mime type -and NULL for data +and NULL for data .

The attached image (or filename) data can later be used by backends which support it (currently: PDF, PS, SVG and Win32 Printing @@ -1448,7 +1464,8 @@

The recognized MIME types are the following: CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_PNG, CAIRO_MIME_TYPE_JP2, CAIRO_MIME_TYPE_URI, CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_JBIG2, -CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID.

+CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, +CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS.

See corresponding backend surface docs for details about which MIME types it can handle. Caution: the associated MIME data will be discarded if you draw on the surface afterwards. Use this function @@ -1526,7 +1543,7 @@ using the specified mime type. If no data has been attached with the given mime type, data - is set NULL.

+ is set NULL.

Parameters

@@ -1594,10 +1611,10 @@

Returns

-

TRUE if surface +

TRUE if surface supports mime_type -, FALSE otherwise

+, FALSE otherwise

Since: 1.12

@@ -1610,7 +1627,7 @@

Returns an image surface that is the most efficient mechanism for modifying the backing store of the target surface. The region retrieved may be limited to the extents - or NULL for the whole surface

+ or NULL for the whole surface

Note, the use of the original surface as a target or source whilst it is mapped is undefined. The result of mapping the surface multiple times is undefined. Calling cairo_surface_destroy() or @@ -1701,6 +1718,42 @@


+

CAIRO_MIME_TYPE_CCITT_FAX

+
#define CAIRO_MIME_TYPE_CCITT_FAX "image/g3fax"
+
+

Group 3 or Group 4 CCITT facsimile encoding (International +Telecommunication Union, Recommendations T.4 and T.6.)

+

Since: 1.16

+
+
+
+

CAIRO_MIME_TYPE_CCITT_FAX_PARAMS

+
#define CAIRO_MIME_TYPE_CCITT_FAX_PARAMS "application/x-cairo.ccitt.params"
+
+

Decode parameters for Group 3 or Group 4 CCITT facsimile encoding. +See CCITT Fax Images.

+

Since: 1.16

+
+
+
+

CAIRO_MIME_TYPE_EPS

+
#define CAIRO_MIME_TYPE_EPS "application/postscript"
+
+

Encapsulated PostScript file. +Encapsulated PostScript File Format Specification

+

Since: 1.16

+
+
+
+

CAIRO_MIME_TYPE_EPS_PARAMS

+
#define CAIRO_MIME_TYPE_EPS_PARAMS "application/x-cairo.eps.params"
+
+

Embedding parameters Encapsulated PostScript data. +See Embedding EPS files.

+

Since: 1.16

+
+
+

CAIRO_MIME_TYPE_JBIG2

#define CAIRO_MIME_TYPE_JBIG2 "application/x-cairo.jbig2"
 
diff -Nru cairo-1.15.8/doc/public/html/cairo-cairo-t.html cairo-1.15.10/doc/public/html/cairo-cairo-t.html --- cairo-1.15.8/doc/public/html/cairo-cairo-t.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-cairo-t.html 2017-12-11 21:03:31.000000000 +0000 @@ -612,7 +612,7 @@

a newly allocated cairo_t with a reference count of 1. The initial reference count should be released with cairo_destroy() when you are done using the cairo_t. -This function never returns NULL. If memory cannot be +This function never returns NULL. If memory cannot be allocated, a special cairo_t object will be returned on which cairo_status() returns CAIRO_STATUS_NO_MEMORY. If you attempt to target a surface which does not support @@ -1422,7 +1422,7 @@ cairo_get_dash (cairo_t *cr, double *dashes, double *offset); -

Gets the current dash array. If not NULL, dashes +

Gets the current dash array. If not NULL, dashes should be big enough to hold at least the number of values returned by cairo_get_dash_count().

@@ -1442,12 +1442,12 @@
- + - + @@ -2162,7 +2162,7 @@
cairo_rectangle_list_t *
 cairo_copy_clip_rectangle_list (cairo_t *cr);

Gets the current clip region as a list of rectangles in user coordinates. -Never returns NULL.

+Never returns NULL.

The status in the list may be CAIRO_STATUS_CLIP_NOT_REPRESENTABLE to indicate that the clip region cannot be represented as a list of user-space rectangles. The status may have other values to indicate @@ -2779,7 +2779,7 @@ cairo_destroy_func_t destroy);

Attach user data to cr . To remove user data from a surface, -call this function with the key that was used to set it and NULL +call this function with the key that was used to set it and NULL for data .

@@ -2832,7 +2832,7 @@

Return user data previously attached to cr using the specified key. If no user data has been attached with the given key this -function returns NULL.

+function returns NULL.

Parameters

dashes

return value for the dash array, or NULL

return value for the dash array, or NULL

 

offset

return value for the current dash offset, or NULL

return value for the current dash offset, or NULL

 
@@ -2858,7 +2858,7 @@

Returns

-

the user data previously attached or NULL.

+

the user data previously attached or NULL.

Since: 1.4

diff -Nru cairo-1.15.8/doc/public/html/cairo.devhelp2 cairo-1.15.10/doc/public/html/cairo.devhelp2 --- cairo-1.15.8/doc/public/html/cairo.devhelp2 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo.devhelp2 2017-12-11 21:03:31.000000000 +0000 @@ -421,6 +421,10 @@ + + + + @@ -494,7 +498,7 @@ - + diff -Nru cairo-1.15.8/doc/public/html/cairo-Error-handling.html cairo-1.15.10/doc/public/html/cairo-Error-handling.html --- cairo-1.15.8/doc/public/html/cairo-Error-handling.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-Error-handling.html 2017-12-11 21:03:31.000000000 +0000 @@ -204,7 +204,7 @@ diff -Nru cairo-1.15.8/doc/public/html/cairo-FreeType-Fonts.html cairo-1.15.10/doc/public/html/cairo-FreeType-Fonts.html --- cairo-1.15.8/doc/public/html/cairo-FreeType-Fonts.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-FreeType-Fonts.html 2017-12-11 21:03:31.000000000 +0000 @@ -339,7 +339,7 @@

Returns

The FT_Face object for font , scaled appropriately, -or NULL if scaled_font +or NULL if scaled_font is in an error state (see cairo_scaled_font_status()) or there is insufficient memory.

diff -Nru cairo-1.15.8/doc/public/html/cairo-Image-Surfaces.html cairo-1.15.10/doc/public/html/cairo-Image-Surfaces.html --- cairo-1.15.8/doc/public/html/cairo-Image-Surfaces.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-Image-Surfaces.html 2017-12-11 21:03:31.000000000 +0000 @@ -341,7 +341,7 @@

Returns

-

a pointer to the image data of this surface or NULL +

a pointer to the image data of this surface or NULL if surface is not an image surface, or if cairo_surface_finish() has been called.

diff -Nru cairo-1.15.8/doc/public/html/cairo-Paths.html cairo-1.15.10/doc/public/html/cairo-Paths.html --- cairo-1.15.8/doc/public/html/cairo-Paths.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-Paths.html 2017-12-11 21:03:31.000000000 +0000 @@ -248,7 +248,7 @@ cairo_path_t. See cairo_path_data_t for hints on how to iterate over the returned data structure.

This function will always return a valid pointer, but the result -will have no data (data==NULL and +will have no data (data==NULL and num_data==0), if either of the following conditions hold:

    @@ -297,7 +297,7 @@ of type CAIRO_PATH_CURVE_TO which will instead be replaced by a series of CAIRO_PATH_LINE_TO elements.

    This function will always return a valid pointer, but the result -will have no data (data==NULL and +will have no data (data==NULL and num_data==0), if either of the following conditions hold:

      @@ -1051,7 +1051,7 @@
- + diff -Nru cairo-1.15.8/doc/public/html/cairo-PDF-Surfaces.html cairo-1.15.10/doc/public/html/cairo-PDF-Surfaces.html --- cairo-1.15.8/doc/public/html/cairo-PDF-Surfaces.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-PDF-Surfaces.html 2017-12-11 21:03:31.000000000 +0000 @@ -159,19 +159,60 @@

The following mime types are supported: CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_JP2, CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_JBIG2, CAIRO_MIME_TYPE_JBIG2_GLOBAL, -CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID.

+CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, +CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS.

+
+

JBIG2 Images

JBIG2 data in PDF must be in the embedded format as described in ISO/IEC 11544. Image specific JBIG2 data must be in CAIRO_MIME_TYPE_JBIG2. Any global segments in the JBIG2 data (segments with page association field set to 0) must be in CAIRO_MIME_TYPE_JBIG2_GLOBAL. The global data may be shared by multiple images. All images sharing the same global data must set -CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID to a unique identifer. At least +CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID to a unique identifier. At least one of the images must provide the global data using CAIRO_MIME_TYPE_JBIG2_GLOBAL. The global data will only be -embedded once but shared by all JBIG2 images with the same +embedded once and shared by all JBIG2 images with the same CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID.

+
+
+

CCITT Fax Images

+

The CAIRO_MIME_TYPE_CCITT_FAX mime data requires a number of decoding +parameters These parameters are specified using CAIRO_MIME_TYPE_CCITT_FAX_PARAMS.

+

CAIRO_MIME_TYPE_CCITT_FAX_PARAMS mime data must contain a string of the form +"param1=value1 param2=value2 ...".

+

Columns +: [required] An integer specifying the width of the image in pixels.

+

Rows +: [required] An integer specifying the height of the image in scan lines.

+

K +: [optional] An integer identifying the encoding scheme used. < 0 +is 2 dimensional Group 4, = 0 is Group3 1 dimensional, > 0 is mixed 1 +and 2 dimensional encoding. Default is 0.

+

EndOfLine +: [optional] If true end-of-line bit patterns are present. Default is false.

+

EncodedByteAlign +: [optional] If true the end of line is padded +with 0 bits so the next line begins on a byte boundary. Default is false.

+

EndOfBlock +: [optional] If true the data contains an end-of-block pattern. Default is true.

+

BlackIs1 +: [optional] If true 1 bits are black pixels. Default is false.

+

DamagedRowsBeforeError +: [optional] An integer specifying the +number of damages rows tolerated before an error occurs. Default is 0.

+

Boolean values may be "true" or "false", or 1 or 0.

+

These parameters are the same as the CCITTFaxDecode parameters in the +PostScript Language Reference +and Portable Document Format (PDF). +Refer to these documents for further details.

+

An example CAIRO_MIME_TYPE_CCITT_FAX_PARAMS string is:

+
+"Columns=10230 Rows=40000 K=1 EndOfLine=true EncodedByteAlign=1 BlackIs1=false"
+
+
+

Functions

@@ -194,7 +235,7 @@
- @@ -247,7 +288,7 @@ - - +

CAIRO_STATUS_NULL_POINTER

-

NULL pointer (Since 1.0)

+

NULL pointer (Since 1.0)

 

utf8

a NUL-terminated string of text encoded in UTF-8, or NULL

a NUL-terminated string of text encoded in UTF-8, or NULL

 

filename

a filename for the PDF output (must be writable), NULL may be +

a filename for the PDF output (must be writable), NULL may be used to specify no output. This will generate a PDF surface that may be queried and used as a source, without generating a temporary file.

write_func

a cairo_write_func_t to accept the output data, may be NULL +

a cairo_write_func_t to accept the output data, may be NULL to indicate a no-op write_func . With a no-op write_func , @@ -361,7 +402,7 @@ cairo_pdf_version_to_string (cairo_pdf_version_t version);

Get the string representation of the given version id. This function -will return NULL if version +will return NULL if version isn't valid. See cairo_pdf_get_versions() for a way to get the list of valid version ids.

diff -Nru cairo-1.15.8/doc/public/html/cairo-PNG-Support.html cairo-1.15.10/doc/public/html/cairo-PNG-Support.html --- cairo-1.15.8/doc/public/html/cairo-PNG-Support.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-PNG-Support.html 2017-12-11 21:03:31.000000000 +0000 @@ -133,7 +133,8 @@

filename

name of PNG file to load

name of PNG file to load. On Windows this filename +is encoded in UTF-8.

 
@@ -276,7 +277,8 @@

filename

-

the name of a file to write to

+

the name of a file to write to; on Windows this filename +is encoded in UTF-8.

  diff -Nru cairo-1.15.8/doc/public/html/cairo-PostScript-Surfaces.html cairo-1.15.10/doc/public/html/cairo-PostScript-Surfaces.html --- cairo-1.15.8/doc/public/html/cairo-PostScript-Surfaces.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-PostScript-Surfaces.html 2017-12-11 21:03:31.000000000 +0000 @@ -152,6 +152,34 @@

Description

The PostScript surface is used to render cairo graphics to Adobe PostScript files and is a multi-page vector surface backend.

+

The following mime types are supported: CAIRO_MIME_TYPE_JPEG, +CAIRO_MIME_TYPE_UNIQUE_ID, +CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, +CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, +CAIRO_MIME_TYPE_EPS, CAIRO_MIME_TYPE_EPS_PARAMS.

+

Source surfaces used by the PostScript surface that have a +CAIRO_MIME_TYPE_UNIQUE_ID mime type will be stored in PostScript +printer memory for the duration of the print +job. CAIRO_MIME_TYPE_UNIQUE_ID should only be used for small +frequently used sources.

+

The CAIRO_MIME_TYPE_CCITT_FAX and CAIRO_MIME_TYPE_CCITT_FAX_PARAMS mime types +are documented in CCITT Fax Images.

+
+

Embedding EPS files

+

Encapsulated PostScript files can be embedded in the PS output by +setting the CAIRO_MIME_TYPE_EPS mime data on a surface to the EPS +data and painting the surface. The EPS will be scaled and +translated to the extents of the surface the EPS data is attached +to.

+

The CAIRO_MIME_TYPE_EPS mime type requires the +CAIRO_MIME_TYPE_EPS_PARAMS mime data to also be provided in order +to specify the embeddding parameters. CAIRO_MIME_TYPE_EPS_PARAMS +mime data must contain a string of the form "bbox=[llx lly urx +ury]" that specifies the bounding box (in PS coordinates) of the +EPS graphics. The parameters are: lower left x, lower left y, upper +right x, upper right y. Normally the bbox data is identical to the +%%BoundingBox data in the EPS file.

+

Functions

@@ -179,7 +207,7 @@

filename

-

a filename for the PS output (must be writable), NULL may be +

a filename for the PS output (must be writable), NULL may be used to specify no output. This will generate a PS surface that may be queried and used as a source, without generating a temporary file.

@@ -236,7 +264,7 @@

write_func

-

a cairo_write_func_t to accept the output data, may be NULL +

a cairo_write_func_t to accept the output data, may be NULL to indicate a no-op write_func . With a no-op write_func , @@ -351,7 +379,7 @@ cairo_ps_level_to_string (cairo_ps_level_t level);

Get the string representation of the given level id. This function -will return NULL if level +will return NULL if level id isn't valid. See cairo_ps_get_levels() for a way to get the list of valid level ids.

@@ -382,7 +410,7 @@ cairo_ps_surface_set_eps (cairo_surface_t *surface, cairo_bool_t eps);

If eps - is TRUE, the PostScript surface will output Encapsulated + is TRUE, the PostScript surface will output Encapsulated PostScript.

This function should only be called before any drawing operations have been performed on the current page. The simplest way to do @@ -405,7 +433,7 @@

eps

-

TRUE to output EPS format PostScript

+

TRUE to output EPS format PostScript

  @@ -436,7 +464,7 @@

Returns

-

TRUE if the surface will output Encapsulated PostScript.

+

TRUE if the surface will output Encapsulated PostScript.

Since: 1.6

diff -Nru cairo-1.15.8/doc/public/html/cairo-Recording-Surfaces.html cairo-1.15.10/doc/public/html/cairo-Recording-Surfaces.html --- cairo-1.15.8/doc/public/html/cairo-Recording-Surfaces.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-Recording-Surfaces.html 2017-12-11 21:03:31.000000000 +0000 @@ -140,7 +140,7 @@

extents

-

the extents to record in pixels, can be NULL to record +

the extents to record in pixels, can be NULL to record unbounded operations.

  @@ -237,8 +237,8 @@

Returns

-

TRUE if the surface is bounded, of recording type, and -not in an error state, otherwise FALSE

+

TRUE if the surface is bounded, of recording type, and +not in an error state, otherwise FALSE

Since: 1.12

diff -Nru cairo-1.15.8/doc/public/html/cairo-Regions.html cairo-1.15.10/doc/public/html/cairo-Regions.html --- cairo-1.15.8/doc/public/html/cairo-Regions.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-Regions.html 2017-12-11 21:03:31.000000000 +0000 @@ -581,8 +581,8 @@

Returns

-

TRUE if region -is empty, FALSE if it isn't.

+

TRUE if region +is empty, FALSE if it isn't.

Since: 1.10

@@ -626,10 +626,10 @@

Returns

-

TRUE if (x +

TRUE if (x , y ) is contained in region -, FALSE if it is not.

+, FALSE if it is not.

Since: 1.10

@@ -685,8 +685,8 @@
cairo_bool_t
 cairo_region_equal (const cairo_region_t *a,
                     const cairo_region_t *b);
-

Compares whether region_a is equivalent to region_b. NULL as an argument -is equal to itself, but not to any non-NULL region.

+

Compares whether region_a is equivalent to region_b. NULL as an argument +is equal to itself, but not to any non-NULL region.

Parameters

@@ -698,12 +698,12 @@ - + - + @@ -711,8 +711,8 @@

Returns

-

TRUE if both regions contained the same coverage, -FALSE if it is not or any region is in an error status.

+

TRUE if both regions contained the same coverage, +FALSE if it is not or any region is in an error status.

Since: 1.10

diff -Nru cairo-1.15.8/doc/public/html/cairo-SVG-Surfaces.html cairo-1.15.10/doc/public/html/cairo-SVG-Surfaces.html --- cairo-1.15.8/doc/public/html/cairo-SVG-Surfaces.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-SVG-Surfaces.html 2017-12-11 21:03:31.000000000 +0000 @@ -129,6 +129,8 @@

If CAIRO_MIME_TYPE_URI is not present, but CAIRO_MIME_TYPE_JPEG or CAIRO_MIME_TYPE_PNG is specified, the corresponding data is Base64-encoded and emitted.

+

If CAIRO_MIME_TYPE_UNIQUE_ID is present, all surfaces with the same +unique identifier will only be embedded once.

Parameters

a

a cairo_region_t or NULL

a cairo_region_t or NULL

 

b

a cairo_region_t or NULL

a cairo_region_t or NULL

 
@@ -140,7 +142,7 @@ - @@ -193,7 +195,7 @@ - - + @@ -610,7 +610,7 @@

the current font face. This object is owned by cairo. To keep a reference to it, you must call cairo_font_face_reference().

-

This function never returns NULL. If memory cannot be allocated, a +

This function never returns NULL. If memory cannot be allocated, a special "nil" cairo_font_face_t object will be returned on which cairo_font_face_status() returns CAIRO_STATUS_NO_MEMORY. Using this nil object will cause its error state to propagate to other @@ -681,7 +681,7 @@

the current scaled font. This object is owned by cairo. To keep a reference to it, you must call cairo_scaled_font_reference().

-

This function never returns NULL. If memory cannot be allocated, a +

This function never returns NULL. If memory cannot be allocated, a special "nil" cairo_scaled_font_t object will be returned on which cairo_scaled_font_status() returns CAIRO_STATUS_NO_MEMORY. Using this nil object will cause its error state to propagate to other @@ -731,7 +731,7 @@

- + @@ -940,7 +940,7 @@ - + @@ -1149,9 +1149,9 @@ needs to allocate an array of glyphs that cairo will free. For all other uses, user can use their own allocation method for glyphs.

-

This function returns NULL if num_glyphs +

This function returns NULL if num_glyphs is not positive, -or if out of memory. That means, the NULL return value +or if out of memory. That means, the NULL return value signals out-of-memory only if num_glyphs was positive.

@@ -1197,7 +1197,7 @@
- +

filename

a filename for the SVG output (must be writable), NULL may be +

a filename for the SVG output (must be writable), NULL may be used to specify no output. This will generate a SVG surface that may be queried and used as a source, without generating a temporary file.

write_func

a cairo_write_func_t to accept the output data, may be NULL +

a cairo_write_func_t to accept the output data, may be NULL to indicate a no-op write_func . With a no-op write_func , @@ -307,7 +309,7 @@ cairo_svg_version_to_string (cairo_svg_version_t version);

Get the string representation of the given version id. This function -will return NULL if version +will return NULL if version isn't valid. See cairo_svg_get_versions() for a way to get the list of valid version ids.

@@ -345,8 +347,35 @@

enum cairo_svg_version_t

-

cairo_svg_version_t is used to describe the version number of the SVG -specification that a generated SVG file will conform to.

+

CAIRO_SVG_UNIT_USER +: User unit, a value in the current coordinate system. + If used in the root element for the initial coordinate systems it + corresponds to pixels. (Since 1.16) +CAIRO_SVG_UNIT_EM +: The size of the element's font. (Since 1.16) +CAIRO_SVG_UNIT_EX +: The x-height of the element’s font. (Since 1.16) +CAIRO_SVG_UNIT_PX +: Pixels (1px = 1/96th of 1in). (Since 1.16) +CAIRO_SVG_UNIT_IN +: Inches (1in = 2.54cm = 96px). (Since 1.16) +CAIRO_SVG_UNIT_CM +: Centimeters (1cm = 96px/2.54). (Since 1.16) +CAIRO_SVG_UNIT_MM +: Millimeters (1mm = 1/10th of 1cm). (Since 1.16) +CAIRO_SVG_UNIT_PT +: Points (1pt = 1/72th of 1in). (Since 1.16) +CAIRO_SVG_UNIT_PC +: Picas (1pc = 1/6th of 1in). (Since 1.16) +CAIRO_SVG_UNIT_PERCENT +: Percent, a value that is some fraction of another + reference value. (Since 1.16)

+

cairo_svg_unit_t is used to describe the units valid for coordinates and +lengths in the SVG specification.

+

See also: +https://www.w3.org/TR/SVG/coords.htmlUnits +https://www.w3.org/TR/SVG/types.htmlDataTypeLength +https://www.w3.org/TR/css-values-3/lengths

Members

@@ -358,22 +387,18 @@ - + - +

CAIRO_SVG_VERSION_1_1

-

The version 1.1 of the SVG specification. (Since 1.2)

-
   

CAIRO_SVG_VERSION_1_2

-

The version 1.2 of the SVG specification. (Since 1.2)

-
   
-

Since: 1.2

+

Since: 1.16

diff -Nru cairo-1.15.8/doc/public/html/cairo-text.html cairo-1.15.10/doc/public/html/cairo-text.html --- cairo-1.15.8/doc/public/html/cairo-text.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-text.html 2017-12-11 21:03:31.000000000 +0000 @@ -576,7 +576,7 @@

font_face

a cairo_font_face_t, or NULL to restore to the default font

a cairo_font_face_t, or NULL to restore to the default font

 

utf8

a NUL-terminated string of text encoded in UTF-8, or NULL

a NUL-terminated string of text encoded in UTF-8, or NULL

 

utf8

a NUL-terminated string of text encoded in UTF-8, or NULL

a NUL-terminated string of text encoded in UTF-8, or NULL

 

glyphs

array of glyphs to free, or NULL

array of glyphs to free, or NULL

 
@@ -1215,9 +1215,9 @@ needs to allocate an array of text clusters that cairo will free. For all other uses, user can use their own allocation method for text clusters.

-

This function returns NULL if num_clusters +

This function returns NULL if num_clusters is not positive, -or if out of memory. That means, the NULL return value +or if out of memory. That means, the NULL return value signals out-of-memory only if num_clusters was positive.

@@ -1263,7 +1263,7 @@

clusters

-

array of text clusters to free, or NULL

+

array of text clusters to free, or NULL

 
diff -Nru cairo-1.15.8/doc/public/html/cairo-User-Fonts.html cairo-1.15.10/doc/public/html/cairo-User-Fonts.html --- cairo-1.15.8/doc/public/html/cairo-User-Fonts.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-User-Fonts.html 2017-12-11 21:03:31.000000000 +0000 @@ -344,7 +344,7 @@ argument is preset to the number of glyph entries available in the glyphs buffer. If the glyphs - buffer is NULL, the value of + buffer is NULL, the value of num_glyphs will be zero. If the provided glyph array is too short for the conversion (or for convenience), a new glyph array may be allocated @@ -360,13 +360,13 @@ The callback should populate the glyph indices and positions (in font space) assuming that the text is to be shown at the origin.

If clusters - is not NULL, num_clusters + is not NULL, num_clusters and cluster_flags are also -non-NULL, and cluster mapping should be computed. The semantics of how +non-NULL, and cluster mapping should be computed. The semantics of how cluster array allocation works is similar to the glyph array. That is, if clusters - initially points to a non-NULL value, that array may be used + initially points to a non-NULL value, that array may be used as a cluster buffer, and num_clusters points to the number of cluster entries available there. If the provided cluster array is too short for @@ -429,7 +429,7 @@

clusters

-

pointer to array of cluster mapping information to fill, or NULL

+

pointer to array of cluster mapping information to fill, or NULL

  @@ -568,7 +568,7 @@

init_func

-

The init callback, or NULL

+

The init callback, or NULL

  @@ -600,7 +600,7 @@

Returns

The init callback of font_face -or NULL if none set or an error has occurred.

+or NULL if none set or an error has occurred.

Since: 1.8

@@ -618,7 +618,7 @@ error will occur. A user font-face is immutable as soon as a scaled-font is created from it.

The render_glyph callback is the only mandatory callback of a user-font. -If the callback is NULL and a glyph is tried to be rendered using +If the callback is NULL and a glyph is tried to be rendered using font_face , a CAIRO_STATUS_USER_FONT_ERROR will occur.

@@ -637,7 +637,7 @@

render_glyph_func

-

The render_glyph callback, or NULL

+

The render_glyph callback, or NULL

  @@ -670,7 +670,7 @@

Returns

The render_glyph callback of font_face -or NULL if none set or an error has occurred.

+or NULL if none set or an error has occurred.

Since: 1.8

@@ -703,7 +703,7 @@

unicode_to_glyph_func

-

The unicode_to_glyph callback, or NULL

+

The unicode_to_glyph callback, or NULL

  @@ -736,7 +736,7 @@

Returns

The unicode_to_glyph callback of font_face -or NULL if none set or an error occurred.

+or NULL if none set or an error occurred.

Since: 1.8

@@ -769,7 +769,7 @@

text_to_glyphs_func

-

The text_to_glyphs callback, or NULL

+

The text_to_glyphs callback, or NULL

  @@ -802,7 +802,7 @@

Returns

The text_to_glyphs callback of font_face -or NULL if none set or an error occurred.

+or NULL if none set or an error occurred.

Since: 1.8

diff -Nru cairo-1.15.8/doc/public/html/cairo-Win32-Fonts.html cairo-1.15.10/doc/public/html/cairo-Win32-Fonts.html --- cairo-1.15.8/doc/public/html/cairo-Win32-Fonts.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-Win32-Fonts.html 2017-12-11 21:03:31.000000000 +0000 @@ -221,7 +221,7 @@

logfont

A LOGFONTW structure specifying the font to use. If font -is NULL then the lfHeight, lfWidth, lfOrientation and lfEscapement +is NULL then the lfHeight, lfWidth, lfOrientation and lfEscapement fields of this structure are ignored. Otherwise lfWidth, lfOrientation and lfEscapement must be zero.

  diff -Nru cairo-1.15.8/doc/public/html/cairo-Win32-Surfaces.html cairo-1.15.10/doc/public/html/cairo-Win32-Surfaces.html --- cairo-1.15.8/doc/public/html/cairo-Win32-Surfaces.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-Win32-Surfaces.html 2017-12-11 21:03:31.000000000 +0000 @@ -278,8 +278,8 @@

cairo_win32_surface_get_dc ()

HDC
 cairo_win32_surface_get_dc (cairo_surface_t *surface);
-

Returns the HDC associated with this surface, or NULL if none. -Also returns NULL if the surface is not a win32 surface.

+

Returns the HDC associated with this surface, or NULL if none. +Also returns NULL if the surface is not a win32 surface.

A call to cairo_surface_flush() is required before using the HDC to ensure that all pending drawing operations are finished and to restore any temporary modification cairo has made to its state. A @@ -302,7 +302,7 @@

Returns

-

HDC or NULL if no HDC available.

+

HDC or NULL if no HDC available.

Since: 1.2

@@ -313,7 +313,7 @@ cairo_win32_surface_get_image (cairo_surface_t *surface);

Returns a cairo_surface_t image surface that refers to the same bits as the DIB of the Win32 surface. If the passed-in win32 surface -is not a DIB surface, NULL is returned.

+is not a DIB surface, NULL is returned.

Parameters

@@ -332,7 +332,7 @@

Returns

a cairo_surface_t (owned by the win32 cairo_surface_t), -or NULL if the win32 surface is not a DIB.

+or NULL if the win32 surface is not a DIB.

Since: 1.4

diff -Nru cairo-1.15.8/doc/public/html/cairo-XLib-Surfaces.html cairo-1.15.10/doc/public/html/cairo-XLib-Surfaces.html --- cairo-1.15.8/doc/public/html/cairo-XLib-Surfaces.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-XLib-Surfaces.html 2017-12-11 21:03:31.000000000 +0000 @@ -502,7 +502,7 @@

Returns

-

the Visual or NULL if there is no appropriate Visual for +

the Visual or NULL if there is no appropriate Visual for surface .

diff -Nru cairo-1.15.8/doc/public/html/cairo-XLib-XRender-Backend.html cairo-1.15.10/doc/public/html/cairo-XLib-XRender-Backend.html --- cairo-1.15.8/doc/public/html/cairo-XLib-XRender-Backend.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/cairo-XLib-XRender-Backend.html 2017-12-11 21:03:31.000000000 +0000 @@ -180,7 +180,7 @@

Returns

the XRenderPictFormat* associated with surface , -or NULL if the surface is not an xlib surface +or NULL if the surface is not an xlib surface or if the X Render extension is not available.

Since: 1.6

diff -Nru cairo-1.15.8/doc/public/html/index-1.10.html cairo-1.15.10/doc/public/html/index-1.10.html --- cairo-1.15.8/doc/public/html/index-1.10.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index-1.10.html 2017-12-11 21:03:31.000000000 +0000 @@ -26,145 +26,145 @@

D

-
cairo_device_acquire, cairo_device_acquire () +
cairo_device_acquire, cairo_device_acquire ()
-
cairo_device_destroy, cairo_device_destroy () +
cairo_device_destroy, cairo_device_destroy ()
-
cairo_device_finish, cairo_device_finish () +
cairo_device_finish, cairo_device_finish ()
-
cairo_device_flush, cairo_device_flush () +
cairo_device_flush, cairo_device_flush ()
-
cairo_device_get_reference_count, cairo_device_get_reference_count () +
cairo_device_get_reference_count, cairo_device_get_reference_count ()
-
cairo_device_get_type, cairo_device_get_type () +
cairo_device_get_type, cairo_device_get_type ()
-
cairo_device_get_user_data, cairo_device_get_user_data () +
cairo_device_get_user_data, cairo_device_get_user_data ()
-
cairo_device_reference, cairo_device_reference () +
cairo_device_reference, cairo_device_reference ()
-
cairo_device_release, cairo_device_release () +
cairo_device_release, cairo_device_release ()
-
cairo_device_set_user_data, cairo_device_set_user_data () +
cairo_device_set_user_data, cairo_device_set_user_data ()
-
cairo_device_status, cairo_device_status () +
cairo_device_status, cairo_device_status ()
-
cairo_device_t, cairo_device_t +
cairo_device_t, cairo_device_t
-
cairo_device_type_t, enum cairo_device_type_t +
cairo_device_type_t, enum cairo_device_type_t

H

-
CAIRO_HAS_FC_FONT, CAIRO_HAS_FC_FONT +
CAIRO_HAS_FC_FONT, CAIRO_HAS_FC_FONT
-
CAIRO_HAS_RECORDING_SURFACE, CAIRO_HAS_RECORDING_SURFACE +
CAIRO_HAS_RECORDING_SURFACE, CAIRO_HAS_RECORDING_SURFACE

I

-
cairo_in_clip, cairo_in_clip () +
cairo_in_clip, cairo_in_clip ()

M

-
CAIRO_MIME_TYPE_JP2, CAIRO_MIME_TYPE_JP2 +
CAIRO_MIME_TYPE_JP2, CAIRO_MIME_TYPE_JP2
-
CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_JPEG +
CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_JPEG
-
CAIRO_MIME_TYPE_PNG, CAIRO_MIME_TYPE_PNG +
CAIRO_MIME_TYPE_PNG, CAIRO_MIME_TYPE_PNG
-
CAIRO_MIME_TYPE_URI, CAIRO_MIME_TYPE_URI +
CAIRO_MIME_TYPE_URI, CAIRO_MIME_TYPE_URI

P

-
cairo_pdf_get_versions, cairo_pdf_get_versions () +
cairo_pdf_get_versions, cairo_pdf_get_versions ()
-
cairo_pdf_surface_restrict_to_version, cairo_pdf_surface_restrict_to_version () +
cairo_pdf_surface_restrict_to_version, cairo_pdf_surface_restrict_to_version ()
-
cairo_pdf_version_t, enum cairo_pdf_version_t +
cairo_pdf_version_t, enum cairo_pdf_version_t
-
cairo_pdf_version_to_string, cairo_pdf_version_to_string () +
cairo_pdf_version_to_string, cairo_pdf_version_to_string ()

R

-
cairo_recording_surface_create, cairo_recording_surface_create () +
cairo_recording_surface_create, cairo_recording_surface_create ()
-
cairo_recording_surface_ink_extents, cairo_recording_surface_ink_extents () +
cairo_recording_surface_ink_extents, cairo_recording_surface_ink_extents ()
-
cairo_rectangle_int_t, cairo_rectangle_int_t +
cairo_rectangle_int_t, cairo_rectangle_int_t
-
cairo_region_contains_point, cairo_region_contains_point () +
cairo_region_contains_point, cairo_region_contains_point ()
-
cairo_region_contains_rectangle, cairo_region_contains_rectangle () +
cairo_region_contains_rectangle, cairo_region_contains_rectangle ()
-
cairo_region_copy, cairo_region_copy () +
cairo_region_copy, cairo_region_copy ()
-
cairo_region_create, cairo_region_create () +
cairo_region_create, cairo_region_create ()
-
cairo_region_create_rectangle, cairo_region_create_rectangle () +
cairo_region_create_rectangle, cairo_region_create_rectangle ()
-
cairo_region_create_rectangles, cairo_region_create_rectangles () +
cairo_region_create_rectangles, cairo_region_create_rectangles ()
-
cairo_region_destroy, cairo_region_destroy () +
cairo_region_destroy, cairo_region_destroy ()
-
cairo_region_equal, cairo_region_equal () +
cairo_region_equal, cairo_region_equal ()
-
cairo_region_get_extents, cairo_region_get_extents () +
cairo_region_get_extents, cairo_region_get_extents ()
-
cairo_region_get_rectangle, cairo_region_get_rectangle () +
cairo_region_get_rectangle, cairo_region_get_rectangle ()
-
cairo_region_intersect, cairo_region_intersect () +
cairo_region_intersect, cairo_region_intersect ()
-
cairo_region_intersect_rectangle, cairo_region_intersect_rectangle () +
cairo_region_intersect_rectangle, cairo_region_intersect_rectangle ()
-
cairo_region_is_empty, cairo_region_is_empty () +
cairo_region_is_empty, cairo_region_is_empty ()
-
cairo_region_num_rectangles, cairo_region_num_rectangles () +
cairo_region_num_rectangles, cairo_region_num_rectangles ()
-
cairo_region_overlap_t, enum cairo_region_overlap_t +
cairo_region_overlap_t, enum cairo_region_overlap_t
-
cairo_region_reference, cairo_region_reference () +
cairo_region_reference, cairo_region_reference ()
-
cairo_region_status, cairo_region_status () +
cairo_region_status, cairo_region_status ()
-
cairo_region_subtract, cairo_region_subtract () +
cairo_region_subtract, cairo_region_subtract ()
-
cairo_region_subtract_rectangle, cairo_region_subtract_rectangle () +
cairo_region_subtract_rectangle, cairo_region_subtract_rectangle ()
-
cairo_region_t, cairo_region_t +
cairo_region_t, cairo_region_t
-
cairo_region_translate, cairo_region_translate () +
cairo_region_translate, cairo_region_translate ()
-
cairo_region_union, cairo_region_union () +
cairo_region_union, cairo_region_union ()
-
cairo_region_union_rectangle, cairo_region_union_rectangle () +
cairo_region_union_rectangle, cairo_region_union_rectangle ()
-
cairo_region_xor, cairo_region_xor () +
cairo_region_xor, cairo_region_xor ()
-
cairo_region_xor_rectangle, cairo_region_xor_rectangle () +
cairo_region_xor_rectangle, cairo_region_xor_rectangle ()

S

-
cairo_surface_create_for_rectangle, cairo_surface_create_for_rectangle () +
cairo_surface_create_for_rectangle, cairo_surface_create_for_rectangle ()
-
cairo_surface_get_device, cairo_surface_get_device () +
cairo_surface_get_device, cairo_surface_get_device ()
-
cairo_surface_get_mime_data, cairo_surface_get_mime_data () +
cairo_surface_get_mime_data, cairo_surface_get_mime_data ()
-
cairo_surface_set_mime_data, cairo_surface_set_mime_data () +
cairo_surface_set_mime_data, cairo_surface_set_mime_data ()
diff -Nru cairo-1.15.8/doc/public/html/index-1.12.html cairo-1.15.10/doc/public/html/index-1.12.html --- cairo-1.15.8/doc/public/html/index-1.12.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index-1.12.html 2017-12-11 21:03:31.000000000 +0000 @@ -26,161 +26,161 @@

F

-
cairo_ft_font_face_get_synthesize, cairo_ft_font_face_get_synthesize () +
cairo_ft_font_face_get_synthesize, cairo_ft_font_face_get_synthesize ()
-
cairo_ft_font_face_set_synthesize, cairo_ft_font_face_set_synthesize () +
cairo_ft_font_face_set_synthesize, cairo_ft_font_face_set_synthesize ()
-
cairo_ft_font_face_unset_synthesize, cairo_ft_font_face_unset_synthesize () +
cairo_ft_font_face_unset_synthesize, cairo_ft_font_face_unset_synthesize ()
-
cairo_ft_synthesize_t, enum cairo_ft_synthesize_t +
cairo_ft_synthesize_t, enum cairo_ft_synthesize_t

H

-
CAIRO_HAS_SCRIPT_SURFACE, CAIRO_HAS_SCRIPT_SURFACE +
CAIRO_HAS_SCRIPT_SURFACE, CAIRO_HAS_SCRIPT_SURFACE
-
CAIRO_HAS_XCB_SURFACE, CAIRO_HAS_XCB_SURFACE +
CAIRO_HAS_XCB_SURFACE, CAIRO_HAS_XCB_SURFACE

M

-
cairo_mesh_pattern_begin_patch, cairo_mesh_pattern_begin_patch () +
cairo_mesh_pattern_begin_patch, cairo_mesh_pattern_begin_patch ()
-
cairo_mesh_pattern_curve_to, cairo_mesh_pattern_curve_to () +
cairo_mesh_pattern_curve_to, cairo_mesh_pattern_curve_to ()
-
cairo_mesh_pattern_end_patch, cairo_mesh_pattern_end_patch () +
cairo_mesh_pattern_end_patch, cairo_mesh_pattern_end_patch ()
-
cairo_mesh_pattern_get_control_point, cairo_mesh_pattern_get_control_point () +
cairo_mesh_pattern_get_control_point, cairo_mesh_pattern_get_control_point ()
-
cairo_mesh_pattern_get_corner_color_rgba, cairo_mesh_pattern_get_corner_color_rgba () +
cairo_mesh_pattern_get_corner_color_rgba, cairo_mesh_pattern_get_corner_color_rgba ()
-
cairo_mesh_pattern_get_patch_count, cairo_mesh_pattern_get_patch_count () +
cairo_mesh_pattern_get_patch_count, cairo_mesh_pattern_get_patch_count ()
-
cairo_mesh_pattern_get_path, cairo_mesh_pattern_get_path () +
cairo_mesh_pattern_get_path, cairo_mesh_pattern_get_path ()
-
cairo_mesh_pattern_line_to, cairo_mesh_pattern_line_to () +
cairo_mesh_pattern_line_to, cairo_mesh_pattern_line_to ()
-
cairo_mesh_pattern_move_to, cairo_mesh_pattern_move_to () +
cairo_mesh_pattern_move_to, cairo_mesh_pattern_move_to ()
-
cairo_mesh_pattern_set_control_point, cairo_mesh_pattern_set_control_point () +
cairo_mesh_pattern_set_control_point, cairo_mesh_pattern_set_control_point ()
-
cairo_mesh_pattern_set_corner_color_rgb, cairo_mesh_pattern_set_corner_color_rgb () +
cairo_mesh_pattern_set_corner_color_rgb, cairo_mesh_pattern_set_corner_color_rgb ()
-
cairo_mesh_pattern_set_corner_color_rgba, cairo_mesh_pattern_set_corner_color_rgba () +
cairo_mesh_pattern_set_corner_color_rgba, cairo_mesh_pattern_set_corner_color_rgba ()
-
CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_UNIQUE_ID +
CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_UNIQUE_ID

P

-
cairo_pattern_create_mesh, cairo_pattern_create_mesh () +
cairo_pattern_create_mesh, cairo_pattern_create_mesh ()
-
cairo_pattern_create_raster_source, cairo_pattern_create_raster_source () +
cairo_pattern_create_raster_source, cairo_pattern_create_raster_source ()

R

-
cairo_raster_source_acquire_func_t, cairo_raster_source_acquire_func_t () +
cairo_raster_source_acquire_func_t, cairo_raster_source_acquire_func_t ()
-
cairo_raster_source_copy_func_t, cairo_raster_source_copy_func_t () +
cairo_raster_source_copy_func_t, cairo_raster_source_copy_func_t ()
-
cairo_raster_source_finish_func_t, cairo_raster_source_finish_func_t () +
cairo_raster_source_finish_func_t, cairo_raster_source_finish_func_t ()
-
cairo_raster_source_pattern_get_acquire, cairo_raster_source_pattern_get_acquire () +
cairo_raster_source_pattern_get_acquire, cairo_raster_source_pattern_get_acquire ()
-
cairo_raster_source_pattern_get_callback_data, cairo_raster_source_pattern_get_callback_data () +
cairo_raster_source_pattern_get_callback_data, cairo_raster_source_pattern_get_callback_data ()
-
cairo_raster_source_pattern_get_copy, cairo_raster_source_pattern_get_copy () +
cairo_raster_source_pattern_get_copy, cairo_raster_source_pattern_get_copy ()
-
cairo_raster_source_pattern_get_finish, cairo_raster_source_pattern_get_finish () +
cairo_raster_source_pattern_get_finish, cairo_raster_source_pattern_get_finish ()
-
cairo_raster_source_pattern_get_snapshot, cairo_raster_source_pattern_get_snapshot () +
cairo_raster_source_pattern_get_snapshot, cairo_raster_source_pattern_get_snapshot ()
-
cairo_raster_source_pattern_set_acquire, cairo_raster_source_pattern_set_acquire () +
cairo_raster_source_pattern_set_acquire, cairo_raster_source_pattern_set_acquire ()
-
cairo_raster_source_pattern_set_callback_data, cairo_raster_source_pattern_set_callback_data () +
cairo_raster_source_pattern_set_callback_data, cairo_raster_source_pattern_set_callback_data ()
-
cairo_raster_source_pattern_set_copy, cairo_raster_source_pattern_set_copy () +
cairo_raster_source_pattern_set_copy, cairo_raster_source_pattern_set_copy ()
-
cairo_raster_source_pattern_set_finish, cairo_raster_source_pattern_set_finish () +
cairo_raster_source_pattern_set_finish, cairo_raster_source_pattern_set_finish ()
-
cairo_raster_source_pattern_set_snapshot, cairo_raster_source_pattern_set_snapshot () +
cairo_raster_source_pattern_set_snapshot, cairo_raster_source_pattern_set_snapshot ()
-
cairo_raster_source_release_func_t, cairo_raster_source_release_func_t () +
cairo_raster_source_release_func_t, cairo_raster_source_release_func_t ()
-
cairo_raster_source_snapshot_func_t, cairo_raster_source_snapshot_func_t () +
cairo_raster_source_snapshot_func_t, cairo_raster_source_snapshot_func_t ()
-
cairo_recording_surface_get_extents, cairo_recording_surface_get_extents () +
cairo_recording_surface_get_extents, cairo_recording_surface_get_extents ()

S

-
cairo_script_create, cairo_script_create () +
cairo_script_create, cairo_script_create ()
-
cairo_script_create_for_stream, cairo_script_create_for_stream () +
cairo_script_create_for_stream, cairo_script_create_for_stream ()
-
cairo_script_from_recording_surface, cairo_script_from_recording_surface () +
cairo_script_from_recording_surface, cairo_script_from_recording_surface ()
-
cairo_script_get_mode, cairo_script_get_mode () +
cairo_script_get_mode, cairo_script_get_mode ()
-
cairo_script_mode_t, enum cairo_script_mode_t +
cairo_script_mode_t, enum cairo_script_mode_t
-
cairo_script_set_mode, cairo_script_set_mode () +
cairo_script_set_mode, cairo_script_set_mode ()
-
cairo_script_surface_create, cairo_script_surface_create () +
cairo_script_surface_create, cairo_script_surface_create ()
-
cairo_script_surface_create_for_target, cairo_script_surface_create_for_target () +
cairo_script_surface_create_for_target, cairo_script_surface_create_for_target ()
-
cairo_script_write_comment, cairo_script_write_comment () +
cairo_script_write_comment, cairo_script_write_comment ()
-
cairo_surface_create_similar_image, cairo_surface_create_similar_image () +
cairo_surface_create_similar_image, cairo_surface_create_similar_image ()
-
cairo_surface_map_to_image, cairo_surface_map_to_image () +
cairo_surface_map_to_image, cairo_surface_map_to_image ()
-
cairo_surface_supports_mime_type, cairo_surface_supports_mime_type () +
cairo_surface_supports_mime_type, cairo_surface_supports_mime_type ()
-
cairo_surface_unmap_image, cairo_surface_unmap_image () +
cairo_surface_unmap_image, cairo_surface_unmap_image ()

X

-
cairo_xcb_device_debug_cap_xrender_version, cairo_xcb_device_debug_cap_xrender_version () +
cairo_xcb_device_debug_cap_xrender_version, cairo_xcb_device_debug_cap_xrender_version ()
-
cairo_xcb_device_debug_cap_xshm_version, cairo_xcb_device_debug_cap_xshm_version () +
cairo_xcb_device_debug_cap_xshm_version, cairo_xcb_device_debug_cap_xshm_version ()
-
cairo_xcb_device_debug_get_precision, cairo_xcb_device_debug_get_precision () +
cairo_xcb_device_debug_get_precision, cairo_xcb_device_debug_get_precision ()
-
cairo_xcb_device_debug_set_precision, cairo_xcb_device_debug_set_precision () +
cairo_xcb_device_debug_set_precision, cairo_xcb_device_debug_set_precision ()
-
cairo_xcb_device_get_connection, cairo_xcb_device_get_connection () +
cairo_xcb_device_get_connection, cairo_xcb_device_get_connection ()
-
cairo_xcb_surface_create, cairo_xcb_surface_create () +
cairo_xcb_surface_create, cairo_xcb_surface_create ()
-
cairo_xcb_surface_create_for_bitmap, cairo_xcb_surface_create_for_bitmap () +
cairo_xcb_surface_create_for_bitmap, cairo_xcb_surface_create_for_bitmap ()
-
cairo_xcb_surface_create_with_xrender_format, cairo_xcb_surface_create_with_xrender_format () +
cairo_xcb_surface_create_with_xrender_format, cairo_xcb_surface_create_with_xrender_format ()
-
cairo_xcb_surface_set_drawable, cairo_xcb_surface_set_drawable () +
cairo_xcb_surface_set_drawable, cairo_xcb_surface_set_drawable ()
-
cairo_xcb_surface_set_size, cairo_xcb_surface_set_size () +
cairo_xcb_surface_set_size, cairo_xcb_surface_set_size ()
-
cairo_xlib_device_debug_cap_xrender_version, cairo_xlib_device_debug_cap_xrender_version () +
cairo_xlib_device_debug_cap_xrender_version, cairo_xlib_device_debug_cap_xrender_version ()
-
cairo_xlib_device_debug_get_precision, cairo_xlib_device_debug_get_precision () +
cairo_xlib_device_debug_get_precision, cairo_xlib_device_debug_get_precision ()
-
cairo_xlib_device_debug_set_precision, cairo_xlib_device_debug_set_precision () +
cairo_xlib_device_debug_set_precision, cairo_xlib_device_debug_set_precision ()
diff -Nru cairo-1.15.8/doc/public/html/index-1.14.html cairo-1.15.10/doc/public/html/index-1.14.html --- cairo-1.15.8/doc/public/html/index-1.14.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index-1.14.html 2017-12-11 21:03:31.000000000 +0000 @@ -26,20 +26,20 @@

M

-
CAIRO_MIME_TYPE_JBIG2, CAIRO_MIME_TYPE_JBIG2 +
CAIRO_MIME_TYPE_JBIG2, CAIRO_MIME_TYPE_JBIG2
-
CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL +
CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL
-
CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID +
CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID

S

-
cairo_surface_get_device_scale, cairo_surface_get_device_scale () +
cairo_surface_get_device_scale, cairo_surface_get_device_scale ()
-
cairo_surface_set_device_scale, cairo_surface_set_device_scale () +
cairo_surface_set_device_scale, cairo_surface_set_device_scale ()
diff -Nru cairo-1.15.8/doc/public/html/index-1.2.html cairo-1.15.10/doc/public/html/index-1.2.html --- cairo-1.15.8/doc/public/html/index-1.2.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index-1.2.html 2017-12-11 21:03:31.000000000 +0000 @@ -26,147 +26,145 @@

F

-
cairo_font_face_get_type, cairo_font_face_get_type () +
cairo_font_face_get_type, cairo_font_face_get_type ()
-
cairo_font_type_t, enum cairo_font_type_t +
cairo_font_type_t, enum cairo_font_type_t

G

-
cairo_get_group_target, cairo_get_group_target () +
cairo_get_group_target, cairo_get_group_target ()

H

-
CAIRO_HAS_PDF_SURFACE, CAIRO_HAS_PDF_SURFACE +
CAIRO_HAS_PDF_SURFACE, CAIRO_HAS_PDF_SURFACE
-
CAIRO_HAS_PS_SURFACE, CAIRO_HAS_PS_SURFACE +
CAIRO_HAS_PS_SURFACE, CAIRO_HAS_PS_SURFACE
-
CAIRO_HAS_SVG_SURFACE, CAIRO_HAS_SVG_SURFACE +
CAIRO_HAS_SVG_SURFACE, CAIRO_HAS_SVG_SURFACE

I

-
cairo_image_surface_get_data, cairo_image_surface_get_data () +
cairo_image_surface_get_data, cairo_image_surface_get_data ()
-
cairo_image_surface_get_format, cairo_image_surface_get_format () +
cairo_image_surface_get_format, cairo_image_surface_get_format ()
-
cairo_image_surface_get_stride, cairo_image_surface_get_stride () +
cairo_image_surface_get_stride, cairo_image_surface_get_stride ()

N

-
cairo_new_sub_path, cairo_new_sub_path () +
cairo_new_sub_path, cairo_new_sub_path ()

P

-
cairo_pattern_get_type, cairo_pattern_get_type () +
cairo_pattern_get_type, cairo_pattern_get_type ()
-
cairo_pattern_type_t, enum cairo_pattern_type_t +
cairo_pattern_type_t, enum cairo_pattern_type_t
-
cairo_pdf_surface_create, cairo_pdf_surface_create () +
cairo_pdf_surface_create, cairo_pdf_surface_create ()
-
cairo_pdf_surface_create_for_stream, cairo_pdf_surface_create_for_stream () +
cairo_pdf_surface_create_for_stream, cairo_pdf_surface_create_for_stream ()
-
cairo_pdf_surface_set_size, cairo_pdf_surface_set_size () +
cairo_pdf_surface_set_size, cairo_pdf_surface_set_size ()
-
cairo_pop_group, cairo_pop_group () +
cairo_pop_group, cairo_pop_group ()
-
cairo_pop_group_to_source, cairo_pop_group_to_source () +
cairo_pop_group_to_source, cairo_pop_group_to_source ()
-
cairo_ps_surface_create, cairo_ps_surface_create () +
cairo_ps_surface_create, cairo_ps_surface_create ()
-
cairo_ps_surface_create_for_stream, cairo_ps_surface_create_for_stream () +
cairo_ps_surface_create_for_stream, cairo_ps_surface_create_for_stream ()
-
cairo_ps_surface_dsc_begin_page_setup, cairo_ps_surface_dsc_begin_page_setup () +
cairo_ps_surface_dsc_begin_page_setup, cairo_ps_surface_dsc_begin_page_setup ()
-
cairo_ps_surface_dsc_begin_setup, cairo_ps_surface_dsc_begin_setup () +
cairo_ps_surface_dsc_begin_setup, cairo_ps_surface_dsc_begin_setup ()
-
cairo_ps_surface_dsc_comment, cairo_ps_surface_dsc_comment () +
cairo_ps_surface_dsc_comment, cairo_ps_surface_dsc_comment ()
-
cairo_ps_surface_set_size, cairo_ps_surface_set_size () +
cairo_ps_surface_set_size, cairo_ps_surface_set_size ()
-
cairo_push_group, cairo_push_group () +
cairo_push_group, cairo_push_group ()
-
cairo_push_group_with_content, cairo_push_group_with_content () +
cairo_push_group_with_content, cairo_push_group_with_content ()

S

-
cairo_scaled_font_get_ctm, cairo_scaled_font_get_ctm () +
cairo_scaled_font_get_ctm, cairo_scaled_font_get_ctm ()
-
cairo_scaled_font_get_font_face, cairo_scaled_font_get_font_face () +
cairo_scaled_font_get_font_face, cairo_scaled_font_get_font_face ()
-
cairo_scaled_font_get_font_matrix, cairo_scaled_font_get_font_matrix () +
cairo_scaled_font_get_font_matrix, cairo_scaled_font_get_font_matrix ()
-
cairo_scaled_font_get_font_options, cairo_scaled_font_get_font_options () +
cairo_scaled_font_get_font_options, cairo_scaled_font_get_font_options ()
-
cairo_scaled_font_get_type, cairo_scaled_font_get_type () +
cairo_scaled_font_get_type, cairo_scaled_font_get_type ()
-
cairo_scaled_font_text_extents, cairo_scaled_font_text_extents () +
cairo_scaled_font_text_extents, cairo_scaled_font_text_extents ()
-
cairo_set_scaled_font, cairo_set_scaled_font () +
cairo_set_scaled_font, cairo_set_scaled_font ()
-
cairo_surface_get_content, cairo_surface_get_content () +
cairo_surface_get_content, cairo_surface_get_content ()
-
cairo_surface_get_device_offset, cairo_surface_get_device_offset () +
cairo_surface_get_device_offset, cairo_surface_get_device_offset ()
-
cairo_surface_get_type, cairo_surface_get_type () +
cairo_surface_get_type, cairo_surface_get_type ()
-
cairo_surface_set_fallback_resolution, cairo_surface_set_fallback_resolution () +
cairo_surface_set_fallback_resolution, cairo_surface_set_fallback_resolution ()
-
cairo_surface_type_t, enum cairo_surface_type_t +
cairo_surface_type_t, enum cairo_surface_type_t
-
cairo_svg_get_versions, cairo_svg_get_versions () +
cairo_svg_get_versions, cairo_svg_get_versions ()
-
cairo_svg_surface_create, cairo_svg_surface_create () +
cairo_svg_surface_create, cairo_svg_surface_create ()
-
cairo_svg_surface_create_for_stream, cairo_svg_surface_create_for_stream () +
cairo_svg_surface_create_for_stream, cairo_svg_surface_create_for_stream ()
-
cairo_svg_surface_restrict_to_version, cairo_svg_surface_restrict_to_version () +
cairo_svg_surface_restrict_to_version, cairo_svg_surface_restrict_to_version ()
-
cairo_svg_version_t, enum cairo_svg_version_t -
-
cairo_svg_version_to_string, cairo_svg_version_to_string () +
cairo_svg_version_to_string, cairo_svg_version_to_string ()

W

-
cairo_win32_font_face_create_for_hfont, cairo_win32_font_face_create_for_hfont () +
cairo_win32_font_face_create_for_hfont, cairo_win32_font_face_create_for_hfont ()
-
cairo_win32_surface_create_with_dib, cairo_win32_surface_create_with_dib () +
cairo_win32_surface_create_with_dib, cairo_win32_surface_create_with_dib ()
-
cairo_win32_surface_get_dc, cairo_win32_surface_get_dc () +
cairo_win32_surface_get_dc, cairo_win32_surface_get_dc ()

X

-
cairo_xlib_surface_get_depth, cairo_xlib_surface_get_depth () +
cairo_xlib_surface_get_depth, cairo_xlib_surface_get_depth ()
-
cairo_xlib_surface_get_display, cairo_xlib_surface_get_display () +
cairo_xlib_surface_get_display, cairo_xlib_surface_get_display ()
-
cairo_xlib_surface_get_drawable, cairo_xlib_surface_get_drawable () +
cairo_xlib_surface_get_drawable, cairo_xlib_surface_get_drawable ()
-
cairo_xlib_surface_get_height, cairo_xlib_surface_get_height () +
cairo_xlib_surface_get_height, cairo_xlib_surface_get_height ()
-
cairo_xlib_surface_get_screen, cairo_xlib_surface_get_screen () +
cairo_xlib_surface_get_screen, cairo_xlib_surface_get_screen ()
-
cairo_xlib_surface_get_visual, cairo_xlib_surface_get_visual () +
cairo_xlib_surface_get_visual, cairo_xlib_surface_get_visual ()
-
cairo_xlib_surface_get_width, cairo_xlib_surface_get_width () +
cairo_xlib_surface_get_width, cairo_xlib_surface_get_width ()
diff -Nru cairo-1.15.8/doc/public/html/index-1.4.html cairo-1.15.10/doc/public/html/index-1.4.html --- cairo-1.15.8/doc/public/html/index-1.4.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index-1.4.html 2017-12-11 21:03:31.000000000 +0000 @@ -26,91 +26,91 @@

C

-
cairo_clip_extents, cairo_clip_extents () +
cairo_clip_extents, cairo_clip_extents ()
-
cairo_copy_clip_rectangle_list, cairo_copy_clip_rectangle_list () +
cairo_copy_clip_rectangle_list, cairo_copy_clip_rectangle_list ()

F

-
cairo_font_face_get_reference_count, cairo_font_face_get_reference_count () +
cairo_font_face_get_reference_count, cairo_font_face_get_reference_count ()

G

-
cairo_get_dash, cairo_get_dash () +
cairo_get_dash, cairo_get_dash ()
-
cairo_get_dash_count, cairo_get_dash_count () +
cairo_get_dash_count, cairo_get_dash_count ()
-
cairo_get_reference_count, cairo_get_reference_count () +
cairo_get_reference_count, cairo_get_reference_count ()
-
cairo_get_scaled_font, cairo_get_scaled_font () +
cairo_get_scaled_font, cairo_get_scaled_font ()
-
cairo_get_user_data, cairo_get_user_data () +
cairo_get_user_data, cairo_get_user_data ()

P

-
cairo_pattern_get_color_stop_count, cairo_pattern_get_color_stop_count () +
cairo_pattern_get_color_stop_count, cairo_pattern_get_color_stop_count ()
-
cairo_pattern_get_color_stop_rgba, cairo_pattern_get_color_stop_rgba () +
cairo_pattern_get_color_stop_rgba, cairo_pattern_get_color_stop_rgba ()
-
cairo_pattern_get_linear_points, cairo_pattern_get_linear_points () +
cairo_pattern_get_linear_points, cairo_pattern_get_linear_points ()
-
cairo_pattern_get_radial_circles, cairo_pattern_get_radial_circles () +
cairo_pattern_get_radial_circles, cairo_pattern_get_radial_circles ()
-
cairo_pattern_get_reference_count, cairo_pattern_get_reference_count () +
cairo_pattern_get_reference_count, cairo_pattern_get_reference_count ()
-
cairo_pattern_get_rgba, cairo_pattern_get_rgba () +
cairo_pattern_get_rgba, cairo_pattern_get_rgba ()
-
cairo_pattern_get_surface, cairo_pattern_get_surface () +
cairo_pattern_get_surface, cairo_pattern_get_surface ()
-
cairo_pattern_get_user_data, cairo_pattern_get_user_data () +
cairo_pattern_get_user_data, cairo_pattern_get_user_data ()
-
cairo_pattern_set_user_data, cairo_pattern_set_user_data () +
cairo_pattern_set_user_data, cairo_pattern_set_user_data ()

R

-
cairo_rectangle_list_destroy, cairo_rectangle_list_destroy () +
cairo_rectangle_list_destroy, cairo_rectangle_list_destroy ()
-
cairo_rectangle_list_t, cairo_rectangle_list_t +
cairo_rectangle_list_t, cairo_rectangle_list_t
-
cairo_rectangle_t, cairo_rectangle_t +
cairo_rectangle_t, cairo_rectangle_t

S

-
cairo_scaled_font_get_reference_count, cairo_scaled_font_get_reference_count () +
cairo_scaled_font_get_reference_count, cairo_scaled_font_get_reference_count ()
-
cairo_scaled_font_get_user_data, cairo_scaled_font_get_user_data () +
cairo_scaled_font_get_user_data, cairo_scaled_font_get_user_data ()
-
cairo_scaled_font_set_user_data, cairo_scaled_font_set_user_data () +
cairo_scaled_font_set_user_data, cairo_scaled_font_set_user_data ()
-
cairo_set_user_data, cairo_set_user_data () +
cairo_set_user_data, cairo_set_user_data ()
-
cairo_surface_get_reference_count, cairo_surface_get_reference_count () +
cairo_surface_get_reference_count, cairo_surface_get_reference_count ()

W

-
cairo_win32_scaled_font_get_device_to_logical, cairo_win32_scaled_font_get_device_to_logical () +
cairo_win32_scaled_font_get_device_to_logical, cairo_win32_scaled_font_get_device_to_logical ()
-
cairo_win32_scaled_font_get_logical_to_device, cairo_win32_scaled_font_get_logical_to_device () +
cairo_win32_scaled_font_get_logical_to_device, cairo_win32_scaled_font_get_logical_to_device ()
-
cairo_win32_surface_create_with_ddb, cairo_win32_surface_create_with_ddb () +
cairo_win32_surface_create_with_ddb, cairo_win32_surface_create_with_ddb ()
-
cairo_win32_surface_get_image, cairo_win32_surface_get_image () +
cairo_win32_surface_get_image, cairo_win32_surface_get_image ()
diff -Nru cairo-1.15.8/doc/public/html/index-1.6.html cairo-1.15.10/doc/public/html/index-1.6.html --- cairo-1.15.8/doc/public/html/index-1.6.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index-1.6.html 2017-12-11 21:03:31.000000000 +0000 @@ -25,77 +25,77 @@

F

-
cairo_format_stride_for_width, cairo_format_stride_for_width () +
cairo_format_stride_for_width, cairo_format_stride_for_width ()

H

-
cairo_has_current_point, cairo_has_current_point () +
cairo_has_current_point, cairo_has_current_point ()
-
CAIRO_HAS_QUARTZ_FONT, CAIRO_HAS_QUARTZ_FONT +
CAIRO_HAS_QUARTZ_FONT, CAIRO_HAS_QUARTZ_FONT
-
CAIRO_HAS_QUARTZ_SURFACE, CAIRO_HAS_QUARTZ_SURFACE +
CAIRO_HAS_QUARTZ_SURFACE, CAIRO_HAS_QUARTZ_SURFACE
-
CAIRO_HAS_XLIB_XRENDER_SURFACE, CAIRO_HAS_XLIB_XRENDER_SURFACE +
CAIRO_HAS_XLIB_XRENDER_SURFACE, CAIRO_HAS_XLIB_XRENDER_SURFACE

P

-
cairo_path_extents, cairo_path_extents () +
cairo_path_extents, cairo_path_extents ()
-
cairo_ps_get_levels, cairo_ps_get_levels () +
cairo_ps_get_levels, cairo_ps_get_levels ()
-
cairo_ps_level_t, enum cairo_ps_level_t +
cairo_ps_level_t, enum cairo_ps_level_t
-
cairo_ps_level_to_string, cairo_ps_level_to_string () +
cairo_ps_level_to_string, cairo_ps_level_to_string ()
-
cairo_ps_surface_get_eps, cairo_ps_surface_get_eps () +
cairo_ps_surface_get_eps, cairo_ps_surface_get_eps ()
-
cairo_ps_surface_restrict_to_level, cairo_ps_surface_restrict_to_level () +
cairo_ps_surface_restrict_to_level, cairo_ps_surface_restrict_to_level ()
-
cairo_ps_surface_set_eps, cairo_ps_surface_set_eps () +
cairo_ps_surface_set_eps, cairo_ps_surface_set_eps ()

Q

-
cairo_quartz_font_face_create_for_atsu_font_id, cairo_quartz_font_face_create_for_atsu_font_id () +
cairo_quartz_font_face_create_for_atsu_font_id, cairo_quartz_font_face_create_for_atsu_font_id ()
-
cairo_quartz_font_face_create_for_cgfont, cairo_quartz_font_face_create_for_cgfont () +
cairo_quartz_font_face_create_for_cgfont, cairo_quartz_font_face_create_for_cgfont ()
-
cairo_quartz_surface_create, cairo_quartz_surface_create () +
cairo_quartz_surface_create, cairo_quartz_surface_create ()
-
cairo_quartz_surface_create_for_cg_context, cairo_quartz_surface_create_for_cg_context () +
cairo_quartz_surface_create_for_cg_context, cairo_quartz_surface_create_for_cg_context ()
-
cairo_quartz_surface_get_cg_context, cairo_quartz_surface_get_cg_context () +
cairo_quartz_surface_get_cg_context, cairo_quartz_surface_get_cg_context ()

S

-
cairo_surface_copy_page, cairo_surface_copy_page () +
cairo_surface_copy_page, cairo_surface_copy_page ()
-
cairo_surface_show_page, cairo_surface_show_page () +
cairo_surface_show_page, cairo_surface_show_page ()

W

-
cairo_win32_font_face_create_for_logfontw_hfont, cairo_win32_font_face_create_for_logfontw_hfont () +
cairo_win32_font_face_create_for_logfontw_hfont, cairo_win32_font_face_create_for_logfontw_hfont ()
-
cairo_win32_printing_surface_create, cairo_win32_printing_surface_create () +
cairo_win32_printing_surface_create, cairo_win32_printing_surface_create ()

X

-
cairo_xlib_surface_get_xrender_format, cairo_xlib_surface_get_xrender_format () +
cairo_xlib_surface_get_xrender_format, cairo_xlib_surface_get_xrender_format ()
diff -Nru cairo-1.15.8/doc/public/html/index-1.8.html cairo-1.15.10/doc/public/html/index-1.8.html --- cairo-1.15.8/doc/public/html/index-1.8.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index-1.8.html 2017-12-11 21:03:31.000000000 +0000 @@ -26,96 +26,96 @@

G

-
cairo_glyph_allocate, cairo_glyph_allocate () +
cairo_glyph_allocate, cairo_glyph_allocate ()
-
cairo_glyph_free, cairo_glyph_free () +
cairo_glyph_free, cairo_glyph_free ()

H

-
CAIRO_HAS_IMAGE_SURFACE, CAIRO_HAS_IMAGE_SURFACE +
CAIRO_HAS_IMAGE_SURFACE, CAIRO_HAS_IMAGE_SURFACE
-
CAIRO_HAS_USER_FONT, CAIRO_HAS_USER_FONT +
CAIRO_HAS_USER_FONT, CAIRO_HAS_USER_FONT
-
CAIRO_HAS_WIN32_FONT, CAIRO_HAS_WIN32_FONT +
CAIRO_HAS_WIN32_FONT, CAIRO_HAS_WIN32_FONT

S

-
cairo_scaled_font_get_scale_matrix, cairo_scaled_font_get_scale_matrix () +
cairo_scaled_font_get_scale_matrix, cairo_scaled_font_get_scale_matrix ()
-
cairo_scaled_font_text_to_glyphs, cairo_scaled_font_text_to_glyphs () +
cairo_scaled_font_text_to_glyphs, cairo_scaled_font_text_to_glyphs ()
-
cairo_show_text_glyphs, cairo_show_text_glyphs () +
cairo_show_text_glyphs, cairo_show_text_glyphs ()
-
cairo_surface_get_fallback_resolution, cairo_surface_get_fallback_resolution () +
cairo_surface_get_fallback_resolution, cairo_surface_get_fallback_resolution ()
-
cairo_surface_has_show_text_glyphs, cairo_surface_has_show_text_glyphs () +
cairo_surface_has_show_text_glyphs, cairo_surface_has_show_text_glyphs ()

T

-
cairo_text_cluster_allocate, cairo_text_cluster_allocate () +
cairo_text_cluster_allocate, cairo_text_cluster_allocate ()
-
cairo_text_cluster_flags_t, enum cairo_text_cluster_flags_t +
cairo_text_cluster_flags_t, enum cairo_text_cluster_flags_t
-
cairo_text_cluster_free, cairo_text_cluster_free () +
cairo_text_cluster_free, cairo_text_cluster_free ()
-
cairo_text_cluster_t, cairo_text_cluster_t +
cairo_text_cluster_t, cairo_text_cluster_t
-
cairo_toy_font_face_create, cairo_toy_font_face_create () +
cairo_toy_font_face_create, cairo_toy_font_face_create ()
-
cairo_toy_font_face_get_family, cairo_toy_font_face_get_family () +
cairo_toy_font_face_get_family, cairo_toy_font_face_get_family ()
-
cairo_toy_font_face_get_slant, cairo_toy_font_face_get_slant () +
cairo_toy_font_face_get_slant, cairo_toy_font_face_get_slant ()
-
cairo_toy_font_face_get_weight, cairo_toy_font_face_get_weight () +
cairo_toy_font_face_get_weight, cairo_toy_font_face_get_weight ()

U

-
cairo_user_font_face_create, cairo_user_font_face_create () +
cairo_user_font_face_create, cairo_user_font_face_create ()
-
cairo_user_font_face_get_init_func, cairo_user_font_face_get_init_func () +
cairo_user_font_face_get_init_func, cairo_user_font_face_get_init_func ()
-
cairo_user_font_face_get_render_glyph_func, cairo_user_font_face_get_render_glyph_func () +
cairo_user_font_face_get_render_glyph_func, cairo_user_font_face_get_render_glyph_func ()
-
cairo_user_font_face_get_text_to_glyphs_func, cairo_user_font_face_get_text_to_glyphs_func () +
cairo_user_font_face_get_text_to_glyphs_func, cairo_user_font_face_get_text_to_glyphs_func ()
-
cairo_user_font_face_get_unicode_to_glyph_func, cairo_user_font_face_get_unicode_to_glyph_func () +
cairo_user_font_face_get_unicode_to_glyph_func, cairo_user_font_face_get_unicode_to_glyph_func ()
-
cairo_user_font_face_set_init_func, cairo_user_font_face_set_init_func () +
cairo_user_font_face_set_init_func, cairo_user_font_face_set_init_func ()
-
cairo_user_font_face_set_render_glyph_func, cairo_user_font_face_set_render_glyph_func () +
cairo_user_font_face_set_render_glyph_func, cairo_user_font_face_set_render_glyph_func ()
-
cairo_user_font_face_set_text_to_glyphs_func, cairo_user_font_face_set_text_to_glyphs_func () +
cairo_user_font_face_set_text_to_glyphs_func, cairo_user_font_face_set_text_to_glyphs_func ()
-
cairo_user_font_face_set_unicode_to_glyph_func, cairo_user_font_face_set_unicode_to_glyph_func () +
cairo_user_font_face_set_unicode_to_glyph_func, cairo_user_font_face_set_unicode_to_glyph_func ()
-
cairo_user_scaled_font_init_func_t, cairo_user_scaled_font_init_func_t () +
cairo_user_scaled_font_init_func_t, cairo_user_scaled_font_init_func_t ()
-
cairo_user_scaled_font_render_glyph_func_t, cairo_user_scaled_font_render_glyph_func_t () +
cairo_user_scaled_font_render_glyph_func_t, cairo_user_scaled_font_render_glyph_func_t ()
-
cairo_user_scaled_font_text_to_glyphs_func_t, cairo_user_scaled_font_text_to_glyphs_func_t () +
cairo_user_scaled_font_text_to_glyphs_func_t, cairo_user_scaled_font_text_to_glyphs_func_t ()
-
cairo_user_scaled_font_unicode_to_glyph_func_t, cairo_user_scaled_font_unicode_to_glyph_func_t () +
cairo_user_scaled_font_unicode_to_glyph_func_t, cairo_user_scaled_font_unicode_to_glyph_func_t ()

V

-
CAIRO_VERSION_STRING, CAIRO_VERSION_STRING +
CAIRO_VERSION_STRING, CAIRO_VERSION_STRING
-
CAIRO_VERSION_STRINGIZE, CAIRO_VERSION_STRINGIZE() +
CAIRO_VERSION_STRINGIZE, CAIRO_VERSION_STRINGIZE()
diff -Nru cairo-1.15.8/doc/public/html/index-all.html cairo-1.15.10/doc/public/html/index-all.html --- cairo-1.15.8/doc/public/html/index-all.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index-all.html 2017-12-11 21:03:31.000000000 +0000 @@ -26,1112 +26,1120 @@

A

-
cairo_antialias_t, enum cairo_antialias_t +
cairo_antialias_t, enum cairo_antialias_t
-
cairo_append_path, cairo_append_path () +
cairo_append_path, cairo_append_path ()
-
cairo_arc, cairo_arc () +
cairo_arc, cairo_arc ()
-
cairo_arc_negative, cairo_arc_negative () +
cairo_arc_negative, cairo_arc_negative ()

B

-
cairo_bool_t, cairo_bool_t +
cairo_bool_t, cairo_bool_t

C

-
cairo_clip, cairo_clip () +
cairo_clip, cairo_clip ()
-
cairo_clip_extents, cairo_clip_extents () +
cairo_clip_extents, cairo_clip_extents ()
-
cairo_clip_preserve, cairo_clip_preserve () +
cairo_clip_preserve, cairo_clip_preserve ()
-
cairo_close_path, cairo_close_path () +
cairo_close_path, cairo_close_path ()
-
cairo_content_t, enum cairo_content_t +
cairo_content_t, enum cairo_content_t
-
cairo_copy_clip_rectangle_list, cairo_copy_clip_rectangle_list () +
cairo_copy_clip_rectangle_list, cairo_copy_clip_rectangle_list ()
-
cairo_copy_page, cairo_copy_page () +
cairo_copy_page, cairo_copy_page ()
-
cairo_copy_path, cairo_copy_path () +
cairo_copy_path, cairo_copy_path ()
-
cairo_copy_path_flat, cairo_copy_path_flat () +
cairo_copy_path_flat, cairo_copy_path_flat ()
-
cairo_create, cairo_create () +
cairo_create, cairo_create ()
-
cairo_curve_to, cairo_curve_to () +
cairo_curve_to, cairo_curve_to ()

D

-
cairo_debug_reset_static_data, cairo_debug_reset_static_data () +
cairo_debug_reset_static_data, cairo_debug_reset_static_data ()
-
cairo_destroy, cairo_destroy () +
cairo_destroy, cairo_destroy ()
-
cairo_destroy_func_t, cairo_destroy_func_t () +
cairo_destroy_func_t, cairo_destroy_func_t ()
-
cairo_device_acquire, cairo_device_acquire () +
cairo_device_acquire, cairo_device_acquire ()
-
cairo_device_destroy, cairo_device_destroy () +
cairo_device_destroy, cairo_device_destroy ()
-
cairo_device_finish, cairo_device_finish () +
cairo_device_finish, cairo_device_finish ()
-
cairo_device_flush, cairo_device_flush () +
cairo_device_flush, cairo_device_flush ()
-
cairo_device_get_reference_count, cairo_device_get_reference_count () +
cairo_device_get_reference_count, cairo_device_get_reference_count ()
-
cairo_device_get_type, cairo_device_get_type () +
cairo_device_get_type, cairo_device_get_type ()
-
cairo_device_get_user_data, cairo_device_get_user_data () +
cairo_device_get_user_data, cairo_device_get_user_data ()
-
cairo_device_observer_elapsed, cairo_device_observer_elapsed () +
cairo_device_observer_elapsed, cairo_device_observer_elapsed ()
-
cairo_device_observer_fill_elapsed, cairo_device_observer_fill_elapsed () +
cairo_device_observer_fill_elapsed, cairo_device_observer_fill_elapsed ()
-
cairo_device_observer_glyphs_elapsed, cairo_device_observer_glyphs_elapsed () +
cairo_device_observer_glyphs_elapsed, cairo_device_observer_glyphs_elapsed ()
-
cairo_device_observer_mask_elapsed, cairo_device_observer_mask_elapsed () +
cairo_device_observer_mask_elapsed, cairo_device_observer_mask_elapsed ()
-
cairo_device_observer_paint_elapsed, cairo_device_observer_paint_elapsed () +
cairo_device_observer_paint_elapsed, cairo_device_observer_paint_elapsed ()
-
cairo_device_observer_print, cairo_device_observer_print () +
cairo_device_observer_print, cairo_device_observer_print ()
-
cairo_device_observer_stroke_elapsed, cairo_device_observer_stroke_elapsed () +
cairo_device_observer_stroke_elapsed, cairo_device_observer_stroke_elapsed ()
-
cairo_device_reference, cairo_device_reference () +
cairo_device_reference, cairo_device_reference ()
-
cairo_device_release, cairo_device_release () +
cairo_device_release, cairo_device_release ()
-
cairo_device_set_user_data, cairo_device_set_user_data () +
cairo_device_set_user_data, cairo_device_set_user_data ()
-
cairo_device_status, cairo_device_status () +
cairo_device_status, cairo_device_status ()
-
cairo_device_t, cairo_device_t +
cairo_device_t, cairo_device_t
-
cairo_device_to_user, cairo_device_to_user () +
cairo_device_to_user, cairo_device_to_user ()
-
cairo_device_to_user_distance, cairo_device_to_user_distance () +
cairo_device_to_user_distance, cairo_device_to_user_distance ()
-
cairo_device_type_t, enum cairo_device_type_t +
cairo_device_type_t, enum cairo_device_type_t

E

-
cairo_extend_t, enum cairo_extend_t +
cairo_extend_t, enum cairo_extend_t

F

-
cairo_fill, cairo_fill () +
cairo_fill, cairo_fill ()
-
cairo_fill_extents, cairo_fill_extents () +
cairo_fill_extents, cairo_fill_extents ()
-
cairo_fill_preserve, cairo_fill_preserve () +
cairo_fill_preserve, cairo_fill_preserve ()
-
cairo_fill_rule_t, enum cairo_fill_rule_t +
cairo_fill_rule_t, enum cairo_fill_rule_t
-
cairo_filter_t, enum cairo_filter_t +
cairo_filter_t, enum cairo_filter_t
-
cairo_font_extents, cairo_font_extents () +
cairo_font_extents, cairo_font_extents ()
-
cairo_font_extents_t, cairo_font_extents_t +
cairo_font_extents_t, cairo_font_extents_t
-
cairo_font_face_destroy, cairo_font_face_destroy () +
cairo_font_face_destroy, cairo_font_face_destroy ()
-
cairo_font_face_get_reference_count, cairo_font_face_get_reference_count () +
cairo_font_face_get_reference_count, cairo_font_face_get_reference_count ()
-
cairo_font_face_get_type, cairo_font_face_get_type () +
cairo_font_face_get_type, cairo_font_face_get_type ()
-
cairo_font_face_get_user_data, cairo_font_face_get_user_data () +
cairo_font_face_get_user_data, cairo_font_face_get_user_data ()
-
cairo_font_face_reference, cairo_font_face_reference () +
cairo_font_face_reference, cairo_font_face_reference ()
-
cairo_font_face_set_user_data, cairo_font_face_set_user_data () +
cairo_font_face_set_user_data, cairo_font_face_set_user_data ()
-
cairo_font_face_status, cairo_font_face_status () +
cairo_font_face_status, cairo_font_face_status ()
-
cairo_font_face_t, cairo_font_face_t +
cairo_font_face_t, cairo_font_face_t
-
cairo_font_options_copy, cairo_font_options_copy () +
cairo_font_options_copy, cairo_font_options_copy ()
-
cairo_font_options_create, cairo_font_options_create () +
cairo_font_options_create, cairo_font_options_create ()
-
cairo_font_options_destroy, cairo_font_options_destroy () +
cairo_font_options_destroy, cairo_font_options_destroy ()
-
cairo_font_options_equal, cairo_font_options_equal () +
cairo_font_options_equal, cairo_font_options_equal ()
-
cairo_font_options_get_antialias, cairo_font_options_get_antialias () +
cairo_font_options_get_antialias, cairo_font_options_get_antialias ()
-
cairo_font_options_get_hint_metrics, cairo_font_options_get_hint_metrics () +
cairo_font_options_get_hint_metrics, cairo_font_options_get_hint_metrics ()
-
cairo_font_options_get_hint_style, cairo_font_options_get_hint_style () +
cairo_font_options_get_hint_style, cairo_font_options_get_hint_style ()
-
cairo_font_options_get_subpixel_order, cairo_font_options_get_subpixel_order () +
cairo_font_options_get_subpixel_order, cairo_font_options_get_subpixel_order ()
-
cairo_font_options_hash, cairo_font_options_hash () +
cairo_font_options_hash, cairo_font_options_hash ()
-
cairo_font_options_merge, cairo_font_options_merge () +
cairo_font_options_merge, cairo_font_options_merge ()
-
cairo_font_options_set_antialias, cairo_font_options_set_antialias () +
cairo_font_options_set_antialias, cairo_font_options_set_antialias ()
-
cairo_font_options_set_hint_metrics, cairo_font_options_set_hint_metrics () +
cairo_font_options_set_hint_metrics, cairo_font_options_set_hint_metrics ()
-
cairo_font_options_set_hint_style, cairo_font_options_set_hint_style () +
cairo_font_options_set_hint_style, cairo_font_options_set_hint_style ()
-
cairo_font_options_set_subpixel_order, cairo_font_options_set_subpixel_order () +
cairo_font_options_set_subpixel_order, cairo_font_options_set_subpixel_order ()
-
cairo_font_options_status, cairo_font_options_status () +
cairo_font_options_status, cairo_font_options_status ()
-
cairo_font_options_t, cairo_font_options_t +
cairo_font_options_t, cairo_font_options_t
-
cairo_font_slant_t, enum cairo_font_slant_t +
cairo_font_slant_t, enum cairo_font_slant_t
-
cairo_font_type_t, enum cairo_font_type_t +
cairo_font_type_t, enum cairo_font_type_t
-
cairo_font_weight_t, enum cairo_font_weight_t +
cairo_font_weight_t, enum cairo_font_weight_t
-
cairo_format_stride_for_width, cairo_format_stride_for_width () +
cairo_format_stride_for_width, cairo_format_stride_for_width ()
-
cairo_format_t, enum cairo_format_t +
cairo_format_t, enum cairo_format_t
-
cairo_ft_font_face_create_for_ft_face, cairo_ft_font_face_create_for_ft_face () +
cairo_ft_font_face_create_for_ft_face, cairo_ft_font_face_create_for_ft_face ()
-
cairo_ft_font_face_create_for_pattern, cairo_ft_font_face_create_for_pattern () +
cairo_ft_font_face_create_for_pattern, cairo_ft_font_face_create_for_pattern ()
-
cairo_ft_font_face_get_synthesize, cairo_ft_font_face_get_synthesize () +
cairo_ft_font_face_get_synthesize, cairo_ft_font_face_get_synthesize ()
-
cairo_ft_font_face_set_synthesize, cairo_ft_font_face_set_synthesize () +
cairo_ft_font_face_set_synthesize, cairo_ft_font_face_set_synthesize ()
-
cairo_ft_font_face_unset_synthesize, cairo_ft_font_face_unset_synthesize () +
cairo_ft_font_face_unset_synthesize, cairo_ft_font_face_unset_synthesize ()
-
cairo_ft_font_options_substitute, cairo_ft_font_options_substitute () +
cairo_ft_font_options_substitute, cairo_ft_font_options_substitute ()
-
cairo_ft_scaled_font_lock_face, cairo_ft_scaled_font_lock_face () +
cairo_ft_scaled_font_lock_face, cairo_ft_scaled_font_lock_face ()
-
cairo_ft_scaled_font_unlock_face, cairo_ft_scaled_font_unlock_face () +
cairo_ft_scaled_font_unlock_face, cairo_ft_scaled_font_unlock_face ()
-
cairo_ft_synthesize_t, enum cairo_ft_synthesize_t +
cairo_ft_synthesize_t, enum cairo_ft_synthesize_t

G

-
cairo_get_antialias, cairo_get_antialias () +
cairo_get_antialias, cairo_get_antialias ()
-
cairo_get_current_point, cairo_get_current_point () +
cairo_get_current_point, cairo_get_current_point ()
-
cairo_get_dash, cairo_get_dash () +
cairo_get_dash, cairo_get_dash ()
-
cairo_get_dash_count, cairo_get_dash_count () +
cairo_get_dash_count, cairo_get_dash_count ()
-
cairo_get_fill_rule, cairo_get_fill_rule () +
cairo_get_fill_rule, cairo_get_fill_rule ()
-
cairo_get_font_face, cairo_get_font_face () +
cairo_get_font_face, cairo_get_font_face ()
-
cairo_get_font_matrix, cairo_get_font_matrix () +
cairo_get_font_matrix, cairo_get_font_matrix ()
-
cairo_get_font_options, cairo_get_font_options () +
cairo_get_font_options, cairo_get_font_options ()
-
cairo_get_group_target, cairo_get_group_target () +
cairo_get_group_target, cairo_get_group_target ()
-
cairo_get_line_cap, cairo_get_line_cap () +
cairo_get_line_cap, cairo_get_line_cap ()
-
cairo_get_line_join, cairo_get_line_join () +
cairo_get_line_join, cairo_get_line_join ()
-
cairo_get_line_width, cairo_get_line_width () +
cairo_get_line_width, cairo_get_line_width ()
-
cairo_get_matrix, cairo_get_matrix () +
cairo_get_matrix, cairo_get_matrix ()
-
cairo_get_miter_limit, cairo_get_miter_limit () +
cairo_get_miter_limit, cairo_get_miter_limit ()
-
cairo_get_operator, cairo_get_operator () +
cairo_get_operator, cairo_get_operator ()
-
cairo_get_reference_count, cairo_get_reference_count () +
cairo_get_reference_count, cairo_get_reference_count ()
-
cairo_get_scaled_font, cairo_get_scaled_font () +
cairo_get_scaled_font, cairo_get_scaled_font ()
-
cairo_get_source, cairo_get_source () +
cairo_get_source, cairo_get_source ()
-
cairo_get_target, cairo_get_target () +
cairo_get_target, cairo_get_target ()
-
cairo_get_tolerance, cairo_get_tolerance () +
cairo_get_tolerance, cairo_get_tolerance ()
-
cairo_get_user_data, cairo_get_user_data () +
cairo_get_user_data, cairo_get_user_data ()
-
cairo_glyph_allocate, cairo_glyph_allocate () +
cairo_glyph_allocate, cairo_glyph_allocate ()
-
cairo_glyph_extents, cairo_glyph_extents () +
cairo_glyph_extents, cairo_glyph_extents ()
-
cairo_glyph_free, cairo_glyph_free () +
cairo_glyph_free, cairo_glyph_free ()
-
cairo_glyph_path, cairo_glyph_path () +
cairo_glyph_path, cairo_glyph_path ()
-
cairo_glyph_t, cairo_glyph_t +
cairo_glyph_t, cairo_glyph_t

H

-
cairo_has_current_point, cairo_has_current_point () +
cairo_has_current_point, cairo_has_current_point ()
-
CAIRO_HAS_FC_FONT, CAIRO_HAS_FC_FONT +
CAIRO_HAS_FC_FONT, CAIRO_HAS_FC_FONT
-
CAIRO_HAS_FT_FONT, CAIRO_HAS_FT_FONT +
CAIRO_HAS_FT_FONT, CAIRO_HAS_FT_FONT
-
CAIRO_HAS_IMAGE_SURFACE, CAIRO_HAS_IMAGE_SURFACE +
CAIRO_HAS_IMAGE_SURFACE, CAIRO_HAS_IMAGE_SURFACE
-
CAIRO_HAS_MIME_SURFACE, CAIRO_HAS_MIME_SURFACE +
CAIRO_HAS_MIME_SURFACE, CAIRO_HAS_MIME_SURFACE
-
CAIRO_HAS_PDF_SURFACE, CAIRO_HAS_PDF_SURFACE +
CAIRO_HAS_PDF_SURFACE, CAIRO_HAS_PDF_SURFACE
-
CAIRO_HAS_PNG_FUNCTIONS, CAIRO_HAS_PNG_FUNCTIONS +
CAIRO_HAS_PNG_FUNCTIONS, CAIRO_HAS_PNG_FUNCTIONS
-
CAIRO_HAS_PS_SURFACE, CAIRO_HAS_PS_SURFACE +
CAIRO_HAS_PS_SURFACE, CAIRO_HAS_PS_SURFACE
-
CAIRO_HAS_QUARTZ_FONT, CAIRO_HAS_QUARTZ_FONT +
CAIRO_HAS_QUARTZ_FONT, CAIRO_HAS_QUARTZ_FONT
-
CAIRO_HAS_QUARTZ_SURFACE, CAIRO_HAS_QUARTZ_SURFACE +
CAIRO_HAS_QUARTZ_SURFACE, CAIRO_HAS_QUARTZ_SURFACE
-
CAIRO_HAS_RECORDING_SURFACE, CAIRO_HAS_RECORDING_SURFACE +
CAIRO_HAS_RECORDING_SURFACE, CAIRO_HAS_RECORDING_SURFACE
-
CAIRO_HAS_SCRIPT_SURFACE, CAIRO_HAS_SCRIPT_SURFACE +
CAIRO_HAS_SCRIPT_SURFACE, CAIRO_HAS_SCRIPT_SURFACE
-
CAIRO_HAS_SVG_SURFACE, CAIRO_HAS_SVG_SURFACE +
CAIRO_HAS_SVG_SURFACE, CAIRO_HAS_SVG_SURFACE
-
CAIRO_HAS_USER_FONT, CAIRO_HAS_USER_FONT +
CAIRO_HAS_USER_FONT, CAIRO_HAS_USER_FONT
-
CAIRO_HAS_WIN32_FONT, CAIRO_HAS_WIN32_FONT +
CAIRO_HAS_WIN32_FONT, CAIRO_HAS_WIN32_FONT
-
CAIRO_HAS_WIN32_SURFACE, CAIRO_HAS_WIN32_SURFACE +
CAIRO_HAS_WIN32_SURFACE, CAIRO_HAS_WIN32_SURFACE
-
CAIRO_HAS_XCB_SHM_FUNCTIONS, CAIRO_HAS_XCB_SHM_FUNCTIONS +
CAIRO_HAS_XCB_SHM_FUNCTIONS, CAIRO_HAS_XCB_SHM_FUNCTIONS
-
CAIRO_HAS_XCB_SURFACE, CAIRO_HAS_XCB_SURFACE +
CAIRO_HAS_XCB_SURFACE, CAIRO_HAS_XCB_SURFACE
-
CAIRO_HAS_XLIB_SURFACE, CAIRO_HAS_XLIB_SURFACE +
CAIRO_HAS_XLIB_SURFACE, CAIRO_HAS_XLIB_SURFACE
-
CAIRO_HAS_XLIB_XRENDER_SURFACE, CAIRO_HAS_XLIB_XRENDER_SURFACE +
CAIRO_HAS_XLIB_XRENDER_SURFACE, CAIRO_HAS_XLIB_XRENDER_SURFACE
-
cairo_hint_metrics_t, enum cairo_hint_metrics_t +
cairo_hint_metrics_t, enum cairo_hint_metrics_t
-
cairo_hint_style_t, enum cairo_hint_style_t +
cairo_hint_style_t, enum cairo_hint_style_t

I

-
cairo_identity_matrix, cairo_identity_matrix () +
cairo_identity_matrix, cairo_identity_matrix ()
-
cairo_image_surface_create, cairo_image_surface_create () +
cairo_image_surface_create, cairo_image_surface_create ()
-
cairo_image_surface_create_for_data, cairo_image_surface_create_for_data () +
cairo_image_surface_create_for_data, cairo_image_surface_create_for_data ()
-
cairo_image_surface_create_from_png, cairo_image_surface_create_from_png () +
cairo_image_surface_create_from_png, cairo_image_surface_create_from_png ()
-
cairo_image_surface_create_from_png_stream, cairo_image_surface_create_from_png_stream () +
cairo_image_surface_create_from_png_stream, cairo_image_surface_create_from_png_stream ()
-
cairo_image_surface_get_data, cairo_image_surface_get_data () +
cairo_image_surface_get_data, cairo_image_surface_get_data ()
-
cairo_image_surface_get_format, cairo_image_surface_get_format () +
cairo_image_surface_get_format, cairo_image_surface_get_format ()
-
cairo_image_surface_get_height, cairo_image_surface_get_height () +
cairo_image_surface_get_height, cairo_image_surface_get_height ()
-
cairo_image_surface_get_stride, cairo_image_surface_get_stride () +
cairo_image_surface_get_stride, cairo_image_surface_get_stride ()
-
cairo_image_surface_get_width, cairo_image_surface_get_width () +
cairo_image_surface_get_width, cairo_image_surface_get_width ()
-
cairo_in_clip, cairo_in_clip () +
cairo_in_clip, cairo_in_clip ()
-
cairo_in_fill, cairo_in_fill () +
cairo_in_fill, cairo_in_fill ()
-
cairo_in_stroke, cairo_in_stroke () +
cairo_in_stroke, cairo_in_stroke ()

L

-
cairo_line_cap_t, enum cairo_line_cap_t +
cairo_line_cap_t, enum cairo_line_cap_t
-
cairo_line_join_t, enum cairo_line_join_t +
cairo_line_join_t, enum cairo_line_join_t
-
cairo_line_to, cairo_line_to () +
cairo_line_to, cairo_line_to ()

M

-
cairo_mask, cairo_mask () +
cairo_mask, cairo_mask ()
-
cairo_mask_surface, cairo_mask_surface () +
cairo_mask_surface, cairo_mask_surface ()
-
cairo_matrix_init, cairo_matrix_init () +
cairo_matrix_init, cairo_matrix_init ()
-
cairo_matrix_init_identity, cairo_matrix_init_identity () +
cairo_matrix_init_identity, cairo_matrix_init_identity ()
-
cairo_matrix_init_rotate, cairo_matrix_init_rotate () +
cairo_matrix_init_rotate, cairo_matrix_init_rotate ()
-
cairo_matrix_init_scale, cairo_matrix_init_scale () +
cairo_matrix_init_scale, cairo_matrix_init_scale ()
-
cairo_matrix_init_translate, cairo_matrix_init_translate () +
cairo_matrix_init_translate, cairo_matrix_init_translate ()
-
cairo_matrix_invert, cairo_matrix_invert () +
cairo_matrix_invert, cairo_matrix_invert ()
-
cairo_matrix_multiply, cairo_matrix_multiply () +
cairo_matrix_multiply, cairo_matrix_multiply ()
-
cairo_matrix_rotate, cairo_matrix_rotate () +
cairo_matrix_rotate, cairo_matrix_rotate ()
-
cairo_matrix_scale, cairo_matrix_scale () +
cairo_matrix_scale, cairo_matrix_scale ()
-
cairo_matrix_t, cairo_matrix_t +
cairo_matrix_t, cairo_matrix_t
-
cairo_matrix_transform_distance, cairo_matrix_transform_distance () +
cairo_matrix_transform_distance, cairo_matrix_transform_distance ()
-
cairo_matrix_transform_point, cairo_matrix_transform_point () +
cairo_matrix_transform_point, cairo_matrix_transform_point ()
-
cairo_matrix_translate, cairo_matrix_translate () +
cairo_matrix_translate, cairo_matrix_translate ()
-
cairo_mesh_pattern_begin_patch, cairo_mesh_pattern_begin_patch () +
cairo_mesh_pattern_begin_patch, cairo_mesh_pattern_begin_patch ()
-
cairo_mesh_pattern_curve_to, cairo_mesh_pattern_curve_to () +
cairo_mesh_pattern_curve_to, cairo_mesh_pattern_curve_to ()
-
cairo_mesh_pattern_end_patch, cairo_mesh_pattern_end_patch () +
cairo_mesh_pattern_end_patch, cairo_mesh_pattern_end_patch ()
-
cairo_mesh_pattern_get_control_point, cairo_mesh_pattern_get_control_point () +
cairo_mesh_pattern_get_control_point, cairo_mesh_pattern_get_control_point ()
-
cairo_mesh_pattern_get_corner_color_rgba, cairo_mesh_pattern_get_corner_color_rgba () +
cairo_mesh_pattern_get_corner_color_rgba, cairo_mesh_pattern_get_corner_color_rgba ()
-
cairo_mesh_pattern_get_patch_count, cairo_mesh_pattern_get_patch_count () +
cairo_mesh_pattern_get_patch_count, cairo_mesh_pattern_get_patch_count ()
-
cairo_mesh_pattern_get_path, cairo_mesh_pattern_get_path () +
cairo_mesh_pattern_get_path, cairo_mesh_pattern_get_path ()
-
cairo_mesh_pattern_line_to, cairo_mesh_pattern_line_to () +
cairo_mesh_pattern_line_to, cairo_mesh_pattern_line_to ()
-
cairo_mesh_pattern_move_to, cairo_mesh_pattern_move_to () +
cairo_mesh_pattern_move_to, cairo_mesh_pattern_move_to ()
-
cairo_mesh_pattern_set_control_point, cairo_mesh_pattern_set_control_point () +
cairo_mesh_pattern_set_control_point, cairo_mesh_pattern_set_control_point ()
-
cairo_mesh_pattern_set_corner_color_rgb, cairo_mesh_pattern_set_corner_color_rgb () +
cairo_mesh_pattern_set_corner_color_rgb, cairo_mesh_pattern_set_corner_color_rgb ()
-
cairo_mesh_pattern_set_corner_color_rgba, cairo_mesh_pattern_set_corner_color_rgba () +
cairo_mesh_pattern_set_corner_color_rgba, cairo_mesh_pattern_set_corner_color_rgba ()
-
CAIRO_MIME_TYPE_JBIG2, CAIRO_MIME_TYPE_JBIG2 +
CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX
-
CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL +
CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS
-
CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID +
CAIRO_MIME_TYPE_EPS, CAIRO_MIME_TYPE_EPS
-
CAIRO_MIME_TYPE_JP2, CAIRO_MIME_TYPE_JP2 +
CAIRO_MIME_TYPE_EPS_PARAMS, CAIRO_MIME_TYPE_EPS_PARAMS
-
CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_JPEG +
CAIRO_MIME_TYPE_JBIG2, CAIRO_MIME_TYPE_JBIG2
-
CAIRO_MIME_TYPE_PNG, CAIRO_MIME_TYPE_PNG +
CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL
-
CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_UNIQUE_ID +
CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID
-
CAIRO_MIME_TYPE_URI, CAIRO_MIME_TYPE_URI +
CAIRO_MIME_TYPE_JP2, CAIRO_MIME_TYPE_JP2
-
cairo_move_to, cairo_move_to () +
CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_JPEG +
+
CAIRO_MIME_TYPE_PNG, CAIRO_MIME_TYPE_PNG +
+
CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_UNIQUE_ID +
+
CAIRO_MIME_TYPE_URI, CAIRO_MIME_TYPE_URI +
+
cairo_move_to, cairo_move_to ()

N

-
cairo_new_path, cairo_new_path () +
cairo_new_path, cairo_new_path ()
-
cairo_new_sub_path, cairo_new_sub_path () +
cairo_new_sub_path, cairo_new_sub_path ()

O

-
cairo_operator_t, enum cairo_operator_t +
cairo_operator_t, enum cairo_operator_t

P

-
cairo_paint, cairo_paint () +
cairo_paint, cairo_paint ()
-
cairo_paint_with_alpha, cairo_paint_with_alpha () +
cairo_paint_with_alpha, cairo_paint_with_alpha ()
-
cairo_path_data_t, union cairo_path_data_t +
cairo_path_data_t, union cairo_path_data_t
-
cairo_path_data_type_t, enum cairo_path_data_type_t +
cairo_path_data_type_t, enum cairo_path_data_type_t
-
cairo_path_destroy, cairo_path_destroy () +
cairo_path_destroy, cairo_path_destroy ()
-
cairo_path_extents, cairo_path_extents () +
cairo_path_extents, cairo_path_extents ()
-
cairo_path_t, cairo_path_t +
cairo_path_t, cairo_path_t
-
cairo_pattern_add_color_stop_rgb, cairo_pattern_add_color_stop_rgb () +
cairo_pattern_add_color_stop_rgb, cairo_pattern_add_color_stop_rgb ()
-
cairo_pattern_add_color_stop_rgba, cairo_pattern_add_color_stop_rgba () +
cairo_pattern_add_color_stop_rgba, cairo_pattern_add_color_stop_rgba ()
-
cairo_pattern_create_for_surface, cairo_pattern_create_for_surface () +
cairo_pattern_create_for_surface, cairo_pattern_create_for_surface ()
-
cairo_pattern_create_linear, cairo_pattern_create_linear () +
cairo_pattern_create_linear, cairo_pattern_create_linear ()
-
cairo_pattern_create_mesh, cairo_pattern_create_mesh () +
cairo_pattern_create_mesh, cairo_pattern_create_mesh ()
-
cairo_pattern_create_radial, cairo_pattern_create_radial () +
cairo_pattern_create_radial, cairo_pattern_create_radial ()
-
cairo_pattern_create_raster_source, cairo_pattern_create_raster_source () +
cairo_pattern_create_raster_source, cairo_pattern_create_raster_source ()
-
cairo_pattern_create_rgb, cairo_pattern_create_rgb () +
cairo_pattern_create_rgb, cairo_pattern_create_rgb ()
-
cairo_pattern_create_rgba, cairo_pattern_create_rgba () +
cairo_pattern_create_rgba, cairo_pattern_create_rgba ()
-
cairo_pattern_destroy, cairo_pattern_destroy () +
cairo_pattern_destroy, cairo_pattern_destroy ()
-
cairo_pattern_get_color_stop_count, cairo_pattern_get_color_stop_count () +
cairo_pattern_get_color_stop_count, cairo_pattern_get_color_stop_count ()
-
cairo_pattern_get_color_stop_rgba, cairo_pattern_get_color_stop_rgba () +
cairo_pattern_get_color_stop_rgba, cairo_pattern_get_color_stop_rgba ()
-
cairo_pattern_get_extend, cairo_pattern_get_extend () +
cairo_pattern_get_extend, cairo_pattern_get_extend ()
-
cairo_pattern_get_filter, cairo_pattern_get_filter () +
cairo_pattern_get_filter, cairo_pattern_get_filter ()
-
cairo_pattern_get_linear_points, cairo_pattern_get_linear_points () +
cairo_pattern_get_linear_points, cairo_pattern_get_linear_points ()
-
cairo_pattern_get_matrix, cairo_pattern_get_matrix () +
cairo_pattern_get_matrix, cairo_pattern_get_matrix ()
-
cairo_pattern_get_radial_circles, cairo_pattern_get_radial_circles () +
cairo_pattern_get_radial_circles, cairo_pattern_get_radial_circles ()
-
cairo_pattern_get_reference_count, cairo_pattern_get_reference_count () +
cairo_pattern_get_reference_count, cairo_pattern_get_reference_count ()
-
cairo_pattern_get_rgba, cairo_pattern_get_rgba () +
cairo_pattern_get_rgba, cairo_pattern_get_rgba ()
-
cairo_pattern_get_surface, cairo_pattern_get_surface () +
cairo_pattern_get_surface, cairo_pattern_get_surface ()
-
cairo_pattern_get_type, cairo_pattern_get_type () +
cairo_pattern_get_type, cairo_pattern_get_type ()
-
cairo_pattern_get_user_data, cairo_pattern_get_user_data () +
cairo_pattern_get_user_data, cairo_pattern_get_user_data ()
-
cairo_pattern_reference, cairo_pattern_reference () +
cairo_pattern_reference, cairo_pattern_reference ()
-
cairo_pattern_set_extend, cairo_pattern_set_extend () +
cairo_pattern_set_extend, cairo_pattern_set_extend ()
-
cairo_pattern_set_filter, cairo_pattern_set_filter () +
cairo_pattern_set_filter, cairo_pattern_set_filter ()
-
cairo_pattern_set_matrix, cairo_pattern_set_matrix () +
cairo_pattern_set_matrix, cairo_pattern_set_matrix ()
-
cairo_pattern_set_user_data, cairo_pattern_set_user_data () +
cairo_pattern_set_user_data, cairo_pattern_set_user_data ()
-
cairo_pattern_status, cairo_pattern_status () +
cairo_pattern_status, cairo_pattern_status ()
-
cairo_pattern_t, cairo_pattern_t +
cairo_pattern_t, cairo_pattern_t
-
cairo_pattern_type_t, enum cairo_pattern_type_t +
cairo_pattern_type_t, enum cairo_pattern_type_t
-
cairo_pdf_get_versions, cairo_pdf_get_versions () +
cairo_pdf_get_versions, cairo_pdf_get_versions ()
-
cairo_pdf_metadata_t, enum cairo_pdf_metadata_t +
cairo_pdf_metadata_t, enum cairo_pdf_metadata_t
-
cairo_pdf_outline_flags_t, enum cairo_pdf_outline_flags_t +
cairo_pdf_outline_flags_t, enum cairo_pdf_outline_flags_t
-
CAIRO_PDF_OUTLINE_ROOT, CAIRO_PDF_OUTLINE_ROOT +
CAIRO_PDF_OUTLINE_ROOT, CAIRO_PDF_OUTLINE_ROOT
-
cairo_pdf_surface_add_outline, cairo_pdf_surface_add_outline () +
cairo_pdf_surface_add_outline, cairo_pdf_surface_add_outline ()
-
cairo_pdf_surface_create, cairo_pdf_surface_create () +
cairo_pdf_surface_create, cairo_pdf_surface_create ()
-
cairo_pdf_surface_create_for_stream, cairo_pdf_surface_create_for_stream () +
cairo_pdf_surface_create_for_stream, cairo_pdf_surface_create_for_stream ()
-
cairo_pdf_surface_restrict_to_version, cairo_pdf_surface_restrict_to_version () +
cairo_pdf_surface_restrict_to_version, cairo_pdf_surface_restrict_to_version ()
-
cairo_pdf_surface_set_metadata, cairo_pdf_surface_set_metadata () +
cairo_pdf_surface_set_metadata, cairo_pdf_surface_set_metadata ()
-
cairo_pdf_surface_set_page_label, cairo_pdf_surface_set_page_label () +
cairo_pdf_surface_set_page_label, cairo_pdf_surface_set_page_label ()
-
cairo_pdf_surface_set_size, cairo_pdf_surface_set_size () +
cairo_pdf_surface_set_size, cairo_pdf_surface_set_size ()
-
cairo_pdf_surface_set_thumbnail_size, cairo_pdf_surface_set_thumbnail_size () +
cairo_pdf_surface_set_thumbnail_size, cairo_pdf_surface_set_thumbnail_size ()
-
cairo_pdf_version_t, enum cairo_pdf_version_t +
cairo_pdf_version_t, enum cairo_pdf_version_t
-
cairo_pdf_version_to_string, cairo_pdf_version_to_string () +
cairo_pdf_version_to_string, cairo_pdf_version_to_string ()
-
cairo_pop_group, cairo_pop_group () +
cairo_pop_group, cairo_pop_group ()
-
cairo_pop_group_to_source, cairo_pop_group_to_source () +
cairo_pop_group_to_source, cairo_pop_group_to_source ()
-
cairo_ps_get_levels, cairo_ps_get_levels () +
cairo_ps_get_levels, cairo_ps_get_levels ()
-
cairo_ps_level_t, enum cairo_ps_level_t +
cairo_ps_level_t, enum cairo_ps_level_t
-
cairo_ps_level_to_string, cairo_ps_level_to_string () +
cairo_ps_level_to_string, cairo_ps_level_to_string ()
-
cairo_ps_surface_create, cairo_ps_surface_create () +
cairo_ps_surface_create, cairo_ps_surface_create ()
-
cairo_ps_surface_create_for_stream, cairo_ps_surface_create_for_stream () +
cairo_ps_surface_create_for_stream, cairo_ps_surface_create_for_stream ()
-
cairo_ps_surface_dsc_begin_page_setup, cairo_ps_surface_dsc_begin_page_setup () +
cairo_ps_surface_dsc_begin_page_setup, cairo_ps_surface_dsc_begin_page_setup ()
-
cairo_ps_surface_dsc_begin_setup, cairo_ps_surface_dsc_begin_setup () +
cairo_ps_surface_dsc_begin_setup, cairo_ps_surface_dsc_begin_setup ()
-
cairo_ps_surface_dsc_comment, cairo_ps_surface_dsc_comment () +
cairo_ps_surface_dsc_comment, cairo_ps_surface_dsc_comment ()
-
cairo_ps_surface_get_eps, cairo_ps_surface_get_eps () +
cairo_ps_surface_get_eps, cairo_ps_surface_get_eps ()
-
cairo_ps_surface_restrict_to_level, cairo_ps_surface_restrict_to_level () +
cairo_ps_surface_restrict_to_level, cairo_ps_surface_restrict_to_level ()
-
cairo_ps_surface_set_eps, cairo_ps_surface_set_eps () +
cairo_ps_surface_set_eps, cairo_ps_surface_set_eps ()
-
cairo_ps_surface_set_size, cairo_ps_surface_set_size () +
cairo_ps_surface_set_size, cairo_ps_surface_set_size ()
-
cairo_push_group, cairo_push_group () +
cairo_push_group, cairo_push_group ()
-
cairo_push_group_with_content, cairo_push_group_with_content () +
cairo_push_group_with_content, cairo_push_group_with_content ()

Q

-
cairo_quartz_font_face_create_for_atsu_font_id, cairo_quartz_font_face_create_for_atsu_font_id () +
cairo_quartz_font_face_create_for_atsu_font_id, cairo_quartz_font_face_create_for_atsu_font_id ()
-
cairo_quartz_font_face_create_for_cgfont, cairo_quartz_font_face_create_for_cgfont () +
cairo_quartz_font_face_create_for_cgfont, cairo_quartz_font_face_create_for_cgfont ()
-
cairo_quartz_surface_create, cairo_quartz_surface_create () +
cairo_quartz_surface_create, cairo_quartz_surface_create ()
-
cairo_quartz_surface_create_for_cg_context, cairo_quartz_surface_create_for_cg_context () +
cairo_quartz_surface_create_for_cg_context, cairo_quartz_surface_create_for_cg_context ()
-
cairo_quartz_surface_get_cg_context, cairo_quartz_surface_get_cg_context () +
cairo_quartz_surface_get_cg_context, cairo_quartz_surface_get_cg_context ()

R

-
cairo_raster_source_acquire_func_t, cairo_raster_source_acquire_func_t () +
cairo_raster_source_acquire_func_t, cairo_raster_source_acquire_func_t ()
-
cairo_raster_source_copy_func_t, cairo_raster_source_copy_func_t () +
cairo_raster_source_copy_func_t, cairo_raster_source_copy_func_t ()
-
cairo_raster_source_finish_func_t, cairo_raster_source_finish_func_t () +
cairo_raster_source_finish_func_t, cairo_raster_source_finish_func_t ()
-
cairo_raster_source_pattern_get_acquire, cairo_raster_source_pattern_get_acquire () +
cairo_raster_source_pattern_get_acquire, cairo_raster_source_pattern_get_acquire ()
-
cairo_raster_source_pattern_get_callback_data, cairo_raster_source_pattern_get_callback_data () +
cairo_raster_source_pattern_get_callback_data, cairo_raster_source_pattern_get_callback_data ()
-
cairo_raster_source_pattern_get_copy, cairo_raster_source_pattern_get_copy () +
cairo_raster_source_pattern_get_copy, cairo_raster_source_pattern_get_copy ()
-
cairo_raster_source_pattern_get_finish, cairo_raster_source_pattern_get_finish () +
cairo_raster_source_pattern_get_finish, cairo_raster_source_pattern_get_finish ()
-
cairo_raster_source_pattern_get_snapshot, cairo_raster_source_pattern_get_snapshot () +
cairo_raster_source_pattern_get_snapshot, cairo_raster_source_pattern_get_snapshot ()
-
cairo_raster_source_pattern_set_acquire, cairo_raster_source_pattern_set_acquire () +
cairo_raster_source_pattern_set_acquire, cairo_raster_source_pattern_set_acquire ()
-
cairo_raster_source_pattern_set_callback_data, cairo_raster_source_pattern_set_callback_data () +
cairo_raster_source_pattern_set_callback_data, cairo_raster_source_pattern_set_callback_data ()
-
cairo_raster_source_pattern_set_copy, cairo_raster_source_pattern_set_copy () +
cairo_raster_source_pattern_set_copy, cairo_raster_source_pattern_set_copy ()
-
cairo_raster_source_pattern_set_finish, cairo_raster_source_pattern_set_finish () +
cairo_raster_source_pattern_set_finish, cairo_raster_source_pattern_set_finish ()
-
cairo_raster_source_pattern_set_snapshot, cairo_raster_source_pattern_set_snapshot () +
cairo_raster_source_pattern_set_snapshot, cairo_raster_source_pattern_set_snapshot ()
-
cairo_raster_source_release_func_t, cairo_raster_source_release_func_t () +
cairo_raster_source_release_func_t, cairo_raster_source_release_func_t ()
-
cairo_raster_source_snapshot_func_t, cairo_raster_source_snapshot_func_t () +
cairo_raster_source_snapshot_func_t, cairo_raster_source_snapshot_func_t ()
-
cairo_read_func_t, cairo_read_func_t () +
cairo_read_func_t, cairo_read_func_t ()
-
cairo_recording_surface_create, cairo_recording_surface_create () +
cairo_recording_surface_create, cairo_recording_surface_create ()
-
cairo_recording_surface_get_extents, cairo_recording_surface_get_extents () +
cairo_recording_surface_get_extents, cairo_recording_surface_get_extents ()
-
cairo_recording_surface_ink_extents, cairo_recording_surface_ink_extents () +
cairo_recording_surface_ink_extents, cairo_recording_surface_ink_extents ()
-
cairo_rectangle, cairo_rectangle () +
cairo_rectangle, cairo_rectangle ()
-
cairo_rectangle_int_t, cairo_rectangle_int_t +
cairo_rectangle_int_t, cairo_rectangle_int_t
-
cairo_rectangle_list_destroy, cairo_rectangle_list_destroy () +
cairo_rectangle_list_destroy, cairo_rectangle_list_destroy ()
-
cairo_rectangle_list_t, cairo_rectangle_list_t +
cairo_rectangle_list_t, cairo_rectangle_list_t
-
cairo_rectangle_t, cairo_rectangle_t +
cairo_rectangle_t, cairo_rectangle_t
-
cairo_reference, cairo_reference () +
cairo_reference, cairo_reference ()
-
cairo_region_contains_point, cairo_region_contains_point () +
cairo_region_contains_point, cairo_region_contains_point ()
-
cairo_region_contains_rectangle, cairo_region_contains_rectangle () +
cairo_region_contains_rectangle, cairo_region_contains_rectangle ()
-
cairo_region_copy, cairo_region_copy () +
cairo_region_copy, cairo_region_copy ()
-
cairo_region_create, cairo_region_create () +
cairo_region_create, cairo_region_create ()
-
cairo_region_create_rectangle, cairo_region_create_rectangle () +
cairo_region_create_rectangle, cairo_region_create_rectangle ()
-
cairo_region_create_rectangles, cairo_region_create_rectangles () +
cairo_region_create_rectangles, cairo_region_create_rectangles ()
-
cairo_region_destroy, cairo_region_destroy () +
cairo_region_destroy, cairo_region_destroy ()
-
cairo_region_equal, cairo_region_equal () +
cairo_region_equal, cairo_region_equal ()
-
cairo_region_get_extents, cairo_region_get_extents () +
cairo_region_get_extents, cairo_region_get_extents ()
-
cairo_region_get_rectangle, cairo_region_get_rectangle () +
cairo_region_get_rectangle, cairo_region_get_rectangle ()
-
cairo_region_intersect, cairo_region_intersect () +
cairo_region_intersect, cairo_region_intersect ()
-
cairo_region_intersect_rectangle, cairo_region_intersect_rectangle () +
cairo_region_intersect_rectangle, cairo_region_intersect_rectangle ()
-
cairo_region_is_empty, cairo_region_is_empty () +
cairo_region_is_empty, cairo_region_is_empty ()
-
cairo_region_num_rectangles, cairo_region_num_rectangles () +
cairo_region_num_rectangles, cairo_region_num_rectangles ()
-
cairo_region_overlap_t, enum cairo_region_overlap_t +
cairo_region_overlap_t, enum cairo_region_overlap_t
-
cairo_region_reference, cairo_region_reference () +
cairo_region_reference, cairo_region_reference ()
-
cairo_region_status, cairo_region_status () +
cairo_region_status, cairo_region_status ()
-
cairo_region_subtract, cairo_region_subtract () +
cairo_region_subtract, cairo_region_subtract ()
-
cairo_region_subtract_rectangle, cairo_region_subtract_rectangle () +
cairo_region_subtract_rectangle, cairo_region_subtract_rectangle ()
-
cairo_region_t, cairo_region_t +
cairo_region_t, cairo_region_t
-
cairo_region_translate, cairo_region_translate () +
cairo_region_translate, cairo_region_translate ()
-
cairo_region_union, cairo_region_union () +
cairo_region_union, cairo_region_union ()
-
cairo_region_union_rectangle, cairo_region_union_rectangle () +
cairo_region_union_rectangle, cairo_region_union_rectangle ()
-
cairo_region_xor, cairo_region_xor () +
cairo_region_xor, cairo_region_xor ()
-
cairo_region_xor_rectangle, cairo_region_xor_rectangle () +
cairo_region_xor_rectangle, cairo_region_xor_rectangle ()
-
cairo_rel_curve_to, cairo_rel_curve_to () +
cairo_rel_curve_to, cairo_rel_curve_to ()
-
cairo_rel_line_to, cairo_rel_line_to () +
cairo_rel_line_to, cairo_rel_line_to ()
-
cairo_rel_move_to, cairo_rel_move_to () +
cairo_rel_move_to, cairo_rel_move_to ()
-
cairo_reset_clip, cairo_reset_clip () +
cairo_reset_clip, cairo_reset_clip ()
-
cairo_restore, cairo_restore () +
cairo_restore, cairo_restore ()
-
cairo_rotate, cairo_rotate () +
cairo_rotate, cairo_rotate ()

S

-
cairo_save, cairo_save () +
cairo_save, cairo_save ()
-
cairo_scale, cairo_scale () +
cairo_scale, cairo_scale ()
-
cairo_scaled_font_create, cairo_scaled_font_create () +
cairo_scaled_font_create, cairo_scaled_font_create ()
-
cairo_scaled_font_destroy, cairo_scaled_font_destroy () +
cairo_scaled_font_destroy, cairo_scaled_font_destroy ()
-
cairo_scaled_font_extents, cairo_scaled_font_extents () +
cairo_scaled_font_extents, cairo_scaled_font_extents ()
-
cairo_scaled_font_get_ctm, cairo_scaled_font_get_ctm () +
cairo_scaled_font_get_ctm, cairo_scaled_font_get_ctm ()
-
cairo_scaled_font_get_font_face, cairo_scaled_font_get_font_face () +
cairo_scaled_font_get_font_face, cairo_scaled_font_get_font_face ()
-
cairo_scaled_font_get_font_matrix, cairo_scaled_font_get_font_matrix () +
cairo_scaled_font_get_font_matrix, cairo_scaled_font_get_font_matrix ()
-
cairo_scaled_font_get_font_options, cairo_scaled_font_get_font_options () +
cairo_scaled_font_get_font_options, cairo_scaled_font_get_font_options ()
-
cairo_scaled_font_get_reference_count, cairo_scaled_font_get_reference_count () +
cairo_scaled_font_get_reference_count, cairo_scaled_font_get_reference_count ()
-
cairo_scaled_font_get_scale_matrix, cairo_scaled_font_get_scale_matrix () +
cairo_scaled_font_get_scale_matrix, cairo_scaled_font_get_scale_matrix ()
-
cairo_scaled_font_get_type, cairo_scaled_font_get_type () +
cairo_scaled_font_get_type, cairo_scaled_font_get_type ()
-
cairo_scaled_font_get_user_data, cairo_scaled_font_get_user_data () +
cairo_scaled_font_get_user_data, cairo_scaled_font_get_user_data ()
-
cairo_scaled_font_glyph_extents, cairo_scaled_font_glyph_extents () +
cairo_scaled_font_glyph_extents, cairo_scaled_font_glyph_extents ()
-
cairo_scaled_font_reference, cairo_scaled_font_reference () +
cairo_scaled_font_reference, cairo_scaled_font_reference ()
-
cairo_scaled_font_set_user_data, cairo_scaled_font_set_user_data () +
cairo_scaled_font_set_user_data, cairo_scaled_font_set_user_data ()
-
cairo_scaled_font_status, cairo_scaled_font_status () +
cairo_scaled_font_status, cairo_scaled_font_status ()
-
cairo_scaled_font_t, cairo_scaled_font_t +
cairo_scaled_font_t, cairo_scaled_font_t
-
cairo_scaled_font_text_extents, cairo_scaled_font_text_extents () +
cairo_scaled_font_text_extents, cairo_scaled_font_text_extents ()
-
cairo_scaled_font_text_to_glyphs, cairo_scaled_font_text_to_glyphs () +
cairo_scaled_font_text_to_glyphs, cairo_scaled_font_text_to_glyphs ()
-
cairo_script_create, cairo_script_create () +
cairo_script_create, cairo_script_create ()
-
cairo_script_create_for_stream, cairo_script_create_for_stream () +
cairo_script_create_for_stream, cairo_script_create_for_stream ()
-
cairo_script_from_recording_surface, cairo_script_from_recording_surface () +
cairo_script_from_recording_surface, cairo_script_from_recording_surface ()
-
cairo_script_get_mode, cairo_script_get_mode () +
cairo_script_get_mode, cairo_script_get_mode ()
-
cairo_script_mode_t, enum cairo_script_mode_t +
cairo_script_mode_t, enum cairo_script_mode_t
-
cairo_script_set_mode, cairo_script_set_mode () +
cairo_script_set_mode, cairo_script_set_mode ()
-
cairo_script_surface_create, cairo_script_surface_create () +
cairo_script_surface_create, cairo_script_surface_create ()
-
cairo_script_surface_create_for_target, cairo_script_surface_create_for_target () +
cairo_script_surface_create_for_target, cairo_script_surface_create_for_target ()
-
cairo_script_write_comment, cairo_script_write_comment () +
cairo_script_write_comment, cairo_script_write_comment ()
-
cairo_select_font_face, cairo_select_font_face () +
cairo_select_font_face, cairo_select_font_face ()
-
cairo_set_antialias, cairo_set_antialias () +
cairo_set_antialias, cairo_set_antialias ()
-
cairo_set_dash, cairo_set_dash () +
cairo_set_dash, cairo_set_dash ()
-
cairo_set_fill_rule, cairo_set_fill_rule () +
cairo_set_fill_rule, cairo_set_fill_rule ()
-
cairo_set_font_face, cairo_set_font_face () +
cairo_set_font_face, cairo_set_font_face ()
-
cairo_set_font_matrix, cairo_set_font_matrix () +
cairo_set_font_matrix, cairo_set_font_matrix ()
-
cairo_set_font_options, cairo_set_font_options () +
cairo_set_font_options, cairo_set_font_options ()
-
cairo_set_font_size, cairo_set_font_size () +
cairo_set_font_size, cairo_set_font_size ()
-
cairo_set_line_cap, cairo_set_line_cap () +
cairo_set_line_cap, cairo_set_line_cap ()
-
cairo_set_line_join, cairo_set_line_join () +
cairo_set_line_join, cairo_set_line_join ()
-
cairo_set_line_width, cairo_set_line_width () +
cairo_set_line_width, cairo_set_line_width ()
-
cairo_set_matrix, cairo_set_matrix () +
cairo_set_matrix, cairo_set_matrix ()
-
cairo_set_miter_limit, cairo_set_miter_limit () +
cairo_set_miter_limit, cairo_set_miter_limit ()
-
cairo_set_operator, cairo_set_operator () +
cairo_set_operator, cairo_set_operator ()
-
cairo_set_scaled_font, cairo_set_scaled_font () +
cairo_set_scaled_font, cairo_set_scaled_font ()
-
cairo_set_source, cairo_set_source () +
cairo_set_source, cairo_set_source ()
-
cairo_set_source_rgb, cairo_set_source_rgb () +
cairo_set_source_rgb, cairo_set_source_rgb ()
-
cairo_set_source_rgba, cairo_set_source_rgba () +
cairo_set_source_rgba, cairo_set_source_rgba ()
-
cairo_set_source_surface, cairo_set_source_surface () +
cairo_set_source_surface, cairo_set_source_surface ()
-
cairo_set_tolerance, cairo_set_tolerance () +
cairo_set_tolerance, cairo_set_tolerance ()
-
cairo_set_user_data, cairo_set_user_data () +
cairo_set_user_data, cairo_set_user_data ()
-
cairo_show_glyphs, cairo_show_glyphs () +
cairo_show_glyphs, cairo_show_glyphs ()
-
cairo_show_page, cairo_show_page () +
cairo_show_page, cairo_show_page ()
-
cairo_show_text, cairo_show_text () +
cairo_show_text, cairo_show_text ()
-
cairo_show_text_glyphs, cairo_show_text_glyphs () +
cairo_show_text_glyphs, cairo_show_text_glyphs ()
-
cairo_status, cairo_status () +
cairo_status, cairo_status ()
-
cairo_status_t, enum cairo_status_t +
cairo_status_t, enum cairo_status_t
-
cairo_status_to_string, cairo_status_to_string () +
cairo_status_to_string, cairo_status_to_string ()
-
cairo_stroke, cairo_stroke () +
cairo_stroke, cairo_stroke ()
-
cairo_stroke_extents, cairo_stroke_extents () +
cairo_stroke_extents, cairo_stroke_extents ()
-
cairo_stroke_preserve, cairo_stroke_preserve () +
cairo_stroke_preserve, cairo_stroke_preserve ()
-
cairo_subpixel_order_t, enum cairo_subpixel_order_t +
cairo_subpixel_order_t, enum cairo_subpixel_order_t
-
cairo_surface_copy_page, cairo_surface_copy_page () +
cairo_surface_copy_page, cairo_surface_copy_page ()
-
cairo_surface_create_for_rectangle, cairo_surface_create_for_rectangle () +
cairo_surface_create_for_rectangle, cairo_surface_create_for_rectangle ()
-
cairo_surface_create_similar, cairo_surface_create_similar () +
cairo_surface_create_similar, cairo_surface_create_similar ()
-
cairo_surface_create_similar_image, cairo_surface_create_similar_image () +
cairo_surface_create_similar_image, cairo_surface_create_similar_image ()
-
cairo_surface_destroy, cairo_surface_destroy () +
cairo_surface_destroy, cairo_surface_destroy ()
-
cairo_surface_finish, cairo_surface_finish () +
cairo_surface_finish, cairo_surface_finish ()
-
cairo_surface_flush, cairo_surface_flush () +
cairo_surface_flush, cairo_surface_flush ()
-
cairo_surface_get_content, cairo_surface_get_content () +
cairo_surface_get_content, cairo_surface_get_content ()
-
cairo_surface_get_device, cairo_surface_get_device () +
cairo_surface_get_device, cairo_surface_get_device ()
-
cairo_surface_get_device_offset, cairo_surface_get_device_offset () +
cairo_surface_get_device_offset, cairo_surface_get_device_offset ()
-
cairo_surface_get_device_scale, cairo_surface_get_device_scale () +
cairo_surface_get_device_scale, cairo_surface_get_device_scale ()
-
cairo_surface_get_fallback_resolution, cairo_surface_get_fallback_resolution () +
cairo_surface_get_fallback_resolution, cairo_surface_get_fallback_resolution ()
-
cairo_surface_get_font_options, cairo_surface_get_font_options () +
cairo_surface_get_font_options, cairo_surface_get_font_options ()
-
cairo_surface_get_mime_data, cairo_surface_get_mime_data () +
cairo_surface_get_mime_data, cairo_surface_get_mime_data ()
-
cairo_surface_get_reference_count, cairo_surface_get_reference_count () +
cairo_surface_get_reference_count, cairo_surface_get_reference_count ()
-
cairo_surface_get_type, cairo_surface_get_type () +
cairo_surface_get_type, cairo_surface_get_type ()
-
cairo_surface_get_user_data, cairo_surface_get_user_data () +
cairo_surface_get_user_data, cairo_surface_get_user_data ()
-
cairo_surface_has_show_text_glyphs, cairo_surface_has_show_text_glyphs () +
cairo_surface_has_show_text_glyphs, cairo_surface_has_show_text_glyphs ()
-
cairo_surface_map_to_image, cairo_surface_map_to_image () +
cairo_surface_map_to_image, cairo_surface_map_to_image ()
-
cairo_surface_mark_dirty, cairo_surface_mark_dirty () +
cairo_surface_mark_dirty, cairo_surface_mark_dirty ()
-
cairo_surface_mark_dirty_rectangle, cairo_surface_mark_dirty_rectangle () +
cairo_surface_mark_dirty_rectangle, cairo_surface_mark_dirty_rectangle ()
-
cairo_surface_reference, cairo_surface_reference () +
cairo_surface_reference, cairo_surface_reference ()
-
cairo_surface_set_device_offset, cairo_surface_set_device_offset () +
cairo_surface_set_device_offset, cairo_surface_set_device_offset ()
-
cairo_surface_set_device_scale, cairo_surface_set_device_scale () +
cairo_surface_set_device_scale, cairo_surface_set_device_scale ()
-
cairo_surface_set_fallback_resolution, cairo_surface_set_fallback_resolution () +
cairo_surface_set_fallback_resolution, cairo_surface_set_fallback_resolution ()
-
cairo_surface_set_mime_data, cairo_surface_set_mime_data () +
cairo_surface_set_mime_data, cairo_surface_set_mime_data ()
-
cairo_surface_set_user_data, cairo_surface_set_user_data () +
cairo_surface_set_user_data, cairo_surface_set_user_data ()
-
cairo_surface_show_page, cairo_surface_show_page () +
cairo_surface_show_page, cairo_surface_show_page ()
-
cairo_surface_status, cairo_surface_status () +
cairo_surface_status, cairo_surface_status ()
-
cairo_surface_supports_mime_type, cairo_surface_supports_mime_type () +
cairo_surface_supports_mime_type, cairo_surface_supports_mime_type ()
-
cairo_surface_t, cairo_surface_t +
cairo_surface_t, cairo_surface_t
-
cairo_surface_type_t, enum cairo_surface_type_t +
cairo_surface_type_t, enum cairo_surface_type_t
-
cairo_surface_unmap_image, cairo_surface_unmap_image () +
cairo_surface_unmap_image, cairo_surface_unmap_image ()
-
cairo_surface_write_to_png, cairo_surface_write_to_png () +
cairo_surface_write_to_png, cairo_surface_write_to_png ()
-
cairo_surface_write_to_png_stream, cairo_surface_write_to_png_stream () +
cairo_surface_write_to_png_stream, cairo_surface_write_to_png_stream ()
-
cairo_svg_get_versions, cairo_svg_get_versions () +
cairo_svg_get_versions, cairo_svg_get_versions ()
-
cairo_svg_surface_create, cairo_svg_surface_create () +
cairo_svg_surface_create, cairo_svg_surface_create ()
-
cairo_svg_surface_create_for_stream, cairo_svg_surface_create_for_stream () +
cairo_svg_surface_create_for_stream, cairo_svg_surface_create_for_stream ()
-
cairo_svg_surface_restrict_to_version, cairo_svg_surface_restrict_to_version () +
cairo_svg_surface_restrict_to_version, cairo_svg_surface_restrict_to_version ()
-
cairo_svg_version_t, enum cairo_svg_version_t +
cairo_svg_version_t, enum cairo_svg_version_t
-
cairo_svg_version_to_string, cairo_svg_version_to_string () +
cairo_svg_version_to_string, cairo_svg_version_to_string ()

T

-
cairo_t, cairo_t +
cairo_t, cairo_t
-
cairo_tag_begin, cairo_tag_begin () +
cairo_tag_begin, cairo_tag_begin ()
-
CAIRO_TAG_DEST, CAIRO_TAG_DEST +
CAIRO_TAG_DEST, CAIRO_TAG_DEST
-
cairo_tag_end, cairo_tag_end () +
cairo_tag_end, cairo_tag_end ()
-
CAIRO_TAG_LINK, CAIRO_TAG_LINK +
CAIRO_TAG_LINK, CAIRO_TAG_LINK
-
cairo_text_cluster_allocate, cairo_text_cluster_allocate () +
cairo_text_cluster_allocate, cairo_text_cluster_allocate ()
-
cairo_text_cluster_flags_t, enum cairo_text_cluster_flags_t +
cairo_text_cluster_flags_t, enum cairo_text_cluster_flags_t
-
cairo_text_cluster_free, cairo_text_cluster_free () +
cairo_text_cluster_free, cairo_text_cluster_free ()
-
cairo_text_cluster_t, cairo_text_cluster_t +
cairo_text_cluster_t, cairo_text_cluster_t
-
cairo_text_extents, cairo_text_extents () +
cairo_text_extents, cairo_text_extents ()
-
cairo_text_extents_t, cairo_text_extents_t +
cairo_text_extents_t, cairo_text_extents_t
-
cairo_text_path, cairo_text_path () +
cairo_text_path, cairo_text_path ()
-
cairo_toy_font_face_create, cairo_toy_font_face_create () +
cairo_toy_font_face_create, cairo_toy_font_face_create ()
-
cairo_toy_font_face_get_family, cairo_toy_font_face_get_family () +
cairo_toy_font_face_get_family, cairo_toy_font_face_get_family ()
-
cairo_toy_font_face_get_slant, cairo_toy_font_face_get_slant () +
cairo_toy_font_face_get_slant, cairo_toy_font_face_get_slant ()
-
cairo_toy_font_face_get_weight, cairo_toy_font_face_get_weight () +
cairo_toy_font_face_get_weight, cairo_toy_font_face_get_weight ()
-
cairo_transform, cairo_transform () +
cairo_transform, cairo_transform ()
-
cairo_translate, cairo_translate () +
cairo_translate, cairo_translate ()

U

-
cairo_user_data_key_t, cairo_user_data_key_t +
cairo_user_data_key_t, cairo_user_data_key_t
-
cairo_user_font_face_create, cairo_user_font_face_create () +
cairo_user_font_face_create, cairo_user_font_face_create ()
-
cairo_user_font_face_get_init_func, cairo_user_font_face_get_init_func () +
cairo_user_font_face_get_init_func, cairo_user_font_face_get_init_func ()
-
cairo_user_font_face_get_render_glyph_func, cairo_user_font_face_get_render_glyph_func () +
cairo_user_font_face_get_render_glyph_func, cairo_user_font_face_get_render_glyph_func ()
-
cairo_user_font_face_get_text_to_glyphs_func, cairo_user_font_face_get_text_to_glyphs_func () +
cairo_user_font_face_get_text_to_glyphs_func, cairo_user_font_face_get_text_to_glyphs_func ()
-
cairo_user_font_face_get_unicode_to_glyph_func, cairo_user_font_face_get_unicode_to_glyph_func () +
cairo_user_font_face_get_unicode_to_glyph_func, cairo_user_font_face_get_unicode_to_glyph_func ()
-
cairo_user_font_face_set_init_func, cairo_user_font_face_set_init_func () +
cairo_user_font_face_set_init_func, cairo_user_font_face_set_init_func ()
-
cairo_user_font_face_set_render_glyph_func, cairo_user_font_face_set_render_glyph_func () +
cairo_user_font_face_set_render_glyph_func, cairo_user_font_face_set_render_glyph_func ()
-
cairo_user_font_face_set_text_to_glyphs_func, cairo_user_font_face_set_text_to_glyphs_func () +
cairo_user_font_face_set_text_to_glyphs_func, cairo_user_font_face_set_text_to_glyphs_func ()
-
cairo_user_font_face_set_unicode_to_glyph_func, cairo_user_font_face_set_unicode_to_glyph_func () +
cairo_user_font_face_set_unicode_to_glyph_func, cairo_user_font_face_set_unicode_to_glyph_func ()
-
cairo_user_scaled_font_init_func_t, cairo_user_scaled_font_init_func_t () +
cairo_user_scaled_font_init_func_t, cairo_user_scaled_font_init_func_t ()
-
cairo_user_scaled_font_render_glyph_func_t, cairo_user_scaled_font_render_glyph_func_t () +
cairo_user_scaled_font_render_glyph_func_t, cairo_user_scaled_font_render_glyph_func_t ()
-
cairo_user_scaled_font_text_to_glyphs_func_t, cairo_user_scaled_font_text_to_glyphs_func_t () +
cairo_user_scaled_font_text_to_glyphs_func_t, cairo_user_scaled_font_text_to_glyphs_func_t ()
-
cairo_user_scaled_font_unicode_to_glyph_func_t, cairo_user_scaled_font_unicode_to_glyph_func_t () +
cairo_user_scaled_font_unicode_to_glyph_func_t, cairo_user_scaled_font_unicode_to_glyph_func_t ()
-
cairo_user_to_device, cairo_user_to_device () +
cairo_user_to_device, cairo_user_to_device ()
-
cairo_user_to_device_distance, cairo_user_to_device_distance () +
cairo_user_to_device_distance, cairo_user_to_device_distance ()

V

-
cairo_version, cairo_version () +
cairo_version, cairo_version ()
-
CAIRO_VERSION, CAIRO_VERSION +
CAIRO_VERSION, CAIRO_VERSION
-
CAIRO_VERSION_ENCODE, CAIRO_VERSION_ENCODE() +
CAIRO_VERSION_ENCODE, CAIRO_VERSION_ENCODE()
-
CAIRO_VERSION_MAJOR, CAIRO_VERSION_MAJOR +
CAIRO_VERSION_MAJOR, CAIRO_VERSION_MAJOR
-
CAIRO_VERSION_MICRO, CAIRO_VERSION_MICRO +
CAIRO_VERSION_MICRO, CAIRO_VERSION_MICRO
-
CAIRO_VERSION_MINOR, CAIRO_VERSION_MINOR +
CAIRO_VERSION_MINOR, CAIRO_VERSION_MINOR
-
cairo_version_string, cairo_version_string () +
cairo_version_string, cairo_version_string ()
-
CAIRO_VERSION_STRING, CAIRO_VERSION_STRING +
CAIRO_VERSION_STRING, CAIRO_VERSION_STRING
-
CAIRO_VERSION_STRINGIZE, CAIRO_VERSION_STRINGIZE() +
CAIRO_VERSION_STRINGIZE, CAIRO_VERSION_STRINGIZE()

W

-
cairo_win32_font_face_create_for_hfont, cairo_win32_font_face_create_for_hfont () +
cairo_win32_font_face_create_for_hfont, cairo_win32_font_face_create_for_hfont ()
-
cairo_win32_font_face_create_for_logfontw, cairo_win32_font_face_create_for_logfontw () +
cairo_win32_font_face_create_for_logfontw, cairo_win32_font_face_create_for_logfontw ()
-
cairo_win32_font_face_create_for_logfontw_hfont, cairo_win32_font_face_create_for_logfontw_hfont () +
cairo_win32_font_face_create_for_logfontw_hfont, cairo_win32_font_face_create_for_logfontw_hfont ()
-
cairo_win32_printing_surface_create, cairo_win32_printing_surface_create () +
cairo_win32_printing_surface_create, cairo_win32_printing_surface_create ()
-
cairo_win32_scaled_font_done_font, cairo_win32_scaled_font_done_font () +
cairo_win32_scaled_font_done_font, cairo_win32_scaled_font_done_font ()
-
cairo_win32_scaled_font_get_device_to_logical, cairo_win32_scaled_font_get_device_to_logical () +
cairo_win32_scaled_font_get_device_to_logical, cairo_win32_scaled_font_get_device_to_logical ()
-
cairo_win32_scaled_font_get_logical_to_device, cairo_win32_scaled_font_get_logical_to_device () +
cairo_win32_scaled_font_get_logical_to_device, cairo_win32_scaled_font_get_logical_to_device ()
-
cairo_win32_scaled_font_get_metrics_factor, cairo_win32_scaled_font_get_metrics_factor () +
cairo_win32_scaled_font_get_metrics_factor, cairo_win32_scaled_font_get_metrics_factor ()
-
cairo_win32_scaled_font_select_font, cairo_win32_scaled_font_select_font () +
cairo_win32_scaled_font_select_font, cairo_win32_scaled_font_select_font ()
-
cairo_win32_surface_create, cairo_win32_surface_create () +
cairo_win32_surface_create, cairo_win32_surface_create ()
-
cairo_win32_surface_create_with_ddb, cairo_win32_surface_create_with_ddb () +
cairo_win32_surface_create_with_ddb, cairo_win32_surface_create_with_ddb ()
-
cairo_win32_surface_create_with_dib, cairo_win32_surface_create_with_dib () +
cairo_win32_surface_create_with_dib, cairo_win32_surface_create_with_dib ()
-
cairo_win32_surface_get_dc, cairo_win32_surface_get_dc () +
cairo_win32_surface_get_dc, cairo_win32_surface_get_dc ()
-
cairo_win32_surface_get_image, cairo_win32_surface_get_image () +
cairo_win32_surface_get_image, cairo_win32_surface_get_image ()
-
cairo_write_func_t, cairo_write_func_t () +
cairo_write_func_t, cairo_write_func_t ()

X

-
cairo_xcb_device_debug_cap_xrender_version, cairo_xcb_device_debug_cap_xrender_version () +
cairo_xcb_device_debug_cap_xrender_version, cairo_xcb_device_debug_cap_xrender_version ()
-
cairo_xcb_device_debug_cap_xshm_version, cairo_xcb_device_debug_cap_xshm_version () +
cairo_xcb_device_debug_cap_xshm_version, cairo_xcb_device_debug_cap_xshm_version ()
-
cairo_xcb_device_debug_get_precision, cairo_xcb_device_debug_get_precision () +
cairo_xcb_device_debug_get_precision, cairo_xcb_device_debug_get_precision ()
-
cairo_xcb_device_debug_set_precision, cairo_xcb_device_debug_set_precision () +
cairo_xcb_device_debug_set_precision, cairo_xcb_device_debug_set_precision ()
-
cairo_xcb_device_get_connection, cairo_xcb_device_get_connection () +
cairo_xcb_device_get_connection, cairo_xcb_device_get_connection ()
-
cairo_xcb_surface_create, cairo_xcb_surface_create () +
cairo_xcb_surface_create, cairo_xcb_surface_create ()
-
cairo_xcb_surface_create_for_bitmap, cairo_xcb_surface_create_for_bitmap () +
cairo_xcb_surface_create_for_bitmap, cairo_xcb_surface_create_for_bitmap ()
-
cairo_xcb_surface_create_with_xrender_format, cairo_xcb_surface_create_with_xrender_format () +
cairo_xcb_surface_create_with_xrender_format, cairo_xcb_surface_create_with_xrender_format ()
-
cairo_xcb_surface_set_drawable, cairo_xcb_surface_set_drawable () +
cairo_xcb_surface_set_drawable, cairo_xcb_surface_set_drawable ()
-
cairo_xcb_surface_set_size, cairo_xcb_surface_set_size () +
cairo_xcb_surface_set_size, cairo_xcb_surface_set_size ()
-
cairo_xlib_device_debug_cap_xrender_version, cairo_xlib_device_debug_cap_xrender_version () +
cairo_xlib_device_debug_cap_xrender_version, cairo_xlib_device_debug_cap_xrender_version ()
-
cairo_xlib_device_debug_get_precision, cairo_xlib_device_debug_get_precision () +
cairo_xlib_device_debug_get_precision, cairo_xlib_device_debug_get_precision ()
-
cairo_xlib_device_debug_set_precision, cairo_xlib_device_debug_set_precision () +
cairo_xlib_device_debug_set_precision, cairo_xlib_device_debug_set_precision ()
-
cairo_xlib_surface_create, cairo_xlib_surface_create () +
cairo_xlib_surface_create, cairo_xlib_surface_create ()
-
cairo_xlib_surface_create_for_bitmap, cairo_xlib_surface_create_for_bitmap () +
cairo_xlib_surface_create_for_bitmap, cairo_xlib_surface_create_for_bitmap ()
-
cairo_xlib_surface_create_with_xrender_format, cairo_xlib_surface_create_with_xrender_format () +
cairo_xlib_surface_create_with_xrender_format, cairo_xlib_surface_create_with_xrender_format ()
-
cairo_xlib_surface_get_depth, cairo_xlib_surface_get_depth () +
cairo_xlib_surface_get_depth, cairo_xlib_surface_get_depth ()
-
cairo_xlib_surface_get_display, cairo_xlib_surface_get_display () +
cairo_xlib_surface_get_display, cairo_xlib_surface_get_display ()
-
cairo_xlib_surface_get_drawable, cairo_xlib_surface_get_drawable () +
cairo_xlib_surface_get_drawable, cairo_xlib_surface_get_drawable ()
-
cairo_xlib_surface_get_height, cairo_xlib_surface_get_height () +
cairo_xlib_surface_get_height, cairo_xlib_surface_get_height ()
-
cairo_xlib_surface_get_screen, cairo_xlib_surface_get_screen () +
cairo_xlib_surface_get_screen, cairo_xlib_surface_get_screen ()
-
cairo_xlib_surface_get_visual, cairo_xlib_surface_get_visual () +
cairo_xlib_surface_get_visual, cairo_xlib_surface_get_visual ()
-
cairo_xlib_surface_get_width, cairo_xlib_surface_get_width () +
cairo_xlib_surface_get_width, cairo_xlib_surface_get_width ()
-
cairo_xlib_surface_get_xrender_format, cairo_xlib_surface_get_xrender_format () +
cairo_xlib_surface_get_xrender_format, cairo_xlib_surface_get_xrender_format ()
-
cairo_xlib_surface_set_drawable, cairo_xlib_surface_set_drawable () +
cairo_xlib_surface_set_drawable, cairo_xlib_surface_set_drawable ()
-
cairo_xlib_surface_set_size, cairo_xlib_surface_set_size () +
cairo_xlib_surface_set_size, cairo_xlib_surface_set_size ()
diff -Nru cairo-1.15.8/doc/public/html/index.html cairo-1.15.10/doc/public/html/index.html --- cairo-1.15.8/doc/public/html/index.html 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/html/index.html 2017-12-11 21:03:31.000000000 +0000 @@ -14,7 +14,7 @@
-

for Cairo 1.15.8 +

for Cairo 1.15.10


diff -Nru cairo-1.15.8/doc/public/Makefile.in cairo-1.15.10/doc/public/Makefile.in --- cairo-1.15.8/doc/public/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/doc/public/Makefile.in 2017-12-11 21:03:10.000000000 +0000 @@ -257,107 +257,111 @@ @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_93 = $(cairo_glesv2_cxx_sources) @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_94 = $(cairo_glesv2_sources) @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_95 = cairo-glesv2.pc -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_96 = $(cairo_cogl_headers) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_97 = $(cairo_cogl_private) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_98 = $(cairo_cogl_cxx_sources) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_99 = $(cairo_cogl_sources) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_100 = cairo-cogl.pc -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_101 = $(cairo_directfb_headers) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_102 = $(cairo_directfb_private) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_103 = $(cairo_directfb_cxx_sources) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_104 = $(cairo_directfb_sources) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_105 = cairo-directfb.pc -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_106 = $(cairo_vg_headers) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_107 = $(cairo_vg_private) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_108 = $(cairo_vg_cxx_sources) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_109 = $(cairo_vg_sources) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_110 = cairo-vg.pc -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_111 = $(cairo_egl_headers) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_112 = $(cairo_egl_private) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_113 = $(cairo_egl_cxx_sources) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_114 = $(cairo_egl_sources) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_115 = cairo-egl.pc -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_116 = $(cairo_glx_headers) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_117 = $(cairo_glx_private) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_118 = $(cairo_glx_cxx_sources) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_119 = $(cairo_glx_sources) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_120 = cairo-glx.pc -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_121 = $(cairo_wgl_headers) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_122 = $(cairo_wgl_private) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_123 = $(cairo_wgl_cxx_sources) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_124 = $(cairo_wgl_sources) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_125 = cairo-wgl.pc -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_126 = $(cairo_script_headers) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_127 = $(cairo_script_private) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_128 = $(cairo_script_cxx_sources) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_129 = $(cairo_script_sources) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_130 = cairo-script.pc -@CAIRO_HAS_FT_FONT_TRUE@am__append_131 = $(cairo_ft_headers) -@CAIRO_HAS_FT_FONT_TRUE@am__append_132 = $(cairo_ft_private) -@CAIRO_HAS_FT_FONT_TRUE@am__append_133 = $(cairo_ft_cxx_sources) -@CAIRO_HAS_FT_FONT_TRUE@am__append_134 = $(cairo_ft_sources) -@CAIRO_HAS_FT_FONT_TRUE@am__append_135 = cairo-ft.pc -@CAIRO_HAS_FC_FONT_TRUE@am__append_136 = $(cairo_fc_headers) -@CAIRO_HAS_FC_FONT_TRUE@am__append_137 = $(cairo_fc_private) -@CAIRO_HAS_FC_FONT_TRUE@am__append_138 = $(cairo_fc_cxx_sources) -@CAIRO_HAS_FC_FONT_TRUE@am__append_139 = $(cairo_fc_sources) -@CAIRO_HAS_FC_FONT_TRUE@am__append_140 = cairo-fc.pc -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_141 = $(cairo_ps_headers) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_142 = $(cairo_ps_private) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_143 = $(cairo_ps_cxx_sources) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_144 = $(cairo_ps_sources) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_145 = cairo-ps.pc -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_146 = $(cairo_pdf_headers) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_147 = $(cairo_pdf_private) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_148 = $(cairo_pdf_cxx_sources) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_149 = $(cairo_pdf_sources) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_150 = cairo-pdf.pc -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_151 = $(cairo_svg_headers) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_152 = $(cairo_svg_private) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_153 = $(cairo_svg_cxx_sources) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_154 = $(cairo_svg_sources) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_155 = cairo-svg.pc -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_156 = $(cairo_test_surfaces_private) $(cairo_test_surfaces_headers) -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_157 = $(cairo_test_surfaces_cxx_sources) -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_158 = $(cairo_test_surfaces_sources) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_159 = $(cairo_tee_headers) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_160 = $(cairo_tee_private) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_161 = $(cairo_tee_cxx_sources) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_162 = $(cairo_tee_sources) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_163 = cairo-tee.pc -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_164 = $(cairo_xml_headers) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_165 = $(cairo_xml_private) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_166 = $(cairo_xml_cxx_sources) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_167 = $(cairo_xml_sources) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_168 = cairo-xml.pc -@CAIRO_HAS_PTHREAD_TRUE@am__append_169 = $(cairo_pthread_private) $(cairo_pthread_headers) -@CAIRO_HAS_PTHREAD_TRUE@am__append_170 = $(cairo_pthread_cxx_sources) -@CAIRO_HAS_PTHREAD_TRUE@am__append_171 = $(cairo_pthread_sources) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_172 = $(cairo_gobject_headers) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_173 = $(cairo_gobject_private) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_174 = $(cairo_gobject_cxx_sources) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_175 = $(cairo_gobject_sources) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_176 = cairo-gobject.pc -@CAIRO_HAS_TRACE_TRUE@am__append_177 = $(cairo_trace_private) $(cairo_trace_headers) -@CAIRO_HAS_TRACE_TRUE@am__append_178 = $(cairo_trace_cxx_sources) -@CAIRO_HAS_TRACE_TRUE@am__append_179 = $(cairo_trace_sources) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_180 = $(cairo_interpreter_private) $(cairo_interpreter_headers) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_181 = $(cairo_interpreter_cxx_sources) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_182 = $(cairo_interpreter_sources) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_183 = $(cairo_symbol_lookup_private) $(cairo_symbol_lookup_headers) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_184 = $(cairo_symbol_lookup_cxx_sources) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_185 = $(cairo_symbol_lookup_sources) -@ENABLE_GTK_DOC_TRUE@am__append_186 = check-doc-coverage.sh +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_96 = $(cairo_glesv3_headers) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_97 = $(cairo_glesv3_private) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_98 = $(cairo_glesv3_cxx_sources) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_99 = $(cairo_glesv3_sources) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_100 = cairo-glesv3.pc +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_101 = $(cairo_cogl_headers) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_102 = $(cairo_cogl_private) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_103 = $(cairo_cogl_cxx_sources) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_104 = $(cairo_cogl_sources) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_105 = cairo-cogl.pc +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_106 = $(cairo_directfb_headers) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_107 = $(cairo_directfb_private) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_108 = $(cairo_directfb_cxx_sources) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_109 = $(cairo_directfb_sources) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_110 = cairo-directfb.pc +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_111 = $(cairo_vg_headers) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_112 = $(cairo_vg_private) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_113 = $(cairo_vg_cxx_sources) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_114 = $(cairo_vg_sources) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_115 = cairo-vg.pc +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_116 = $(cairo_egl_headers) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_117 = $(cairo_egl_private) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_118 = $(cairo_egl_cxx_sources) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_119 = $(cairo_egl_sources) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_120 = cairo-egl.pc +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_121 = $(cairo_glx_headers) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_122 = $(cairo_glx_private) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_123 = $(cairo_glx_cxx_sources) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_124 = $(cairo_glx_sources) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_125 = cairo-glx.pc +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_126 = $(cairo_wgl_headers) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_127 = $(cairo_wgl_private) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_128 = $(cairo_wgl_cxx_sources) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_129 = $(cairo_wgl_sources) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_130 = cairo-wgl.pc +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_131 = $(cairo_script_headers) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_132 = $(cairo_script_private) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_133 = $(cairo_script_cxx_sources) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_134 = $(cairo_script_sources) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_135 = cairo-script.pc +@CAIRO_HAS_FT_FONT_TRUE@am__append_136 = $(cairo_ft_headers) +@CAIRO_HAS_FT_FONT_TRUE@am__append_137 = $(cairo_ft_private) +@CAIRO_HAS_FT_FONT_TRUE@am__append_138 = $(cairo_ft_cxx_sources) +@CAIRO_HAS_FT_FONT_TRUE@am__append_139 = $(cairo_ft_sources) +@CAIRO_HAS_FT_FONT_TRUE@am__append_140 = cairo-ft.pc +@CAIRO_HAS_FC_FONT_TRUE@am__append_141 = $(cairo_fc_headers) +@CAIRO_HAS_FC_FONT_TRUE@am__append_142 = $(cairo_fc_private) +@CAIRO_HAS_FC_FONT_TRUE@am__append_143 = $(cairo_fc_cxx_sources) +@CAIRO_HAS_FC_FONT_TRUE@am__append_144 = $(cairo_fc_sources) +@CAIRO_HAS_FC_FONT_TRUE@am__append_145 = cairo-fc.pc +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_146 = $(cairo_ps_headers) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_147 = $(cairo_ps_private) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_148 = $(cairo_ps_cxx_sources) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_149 = $(cairo_ps_sources) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_150 = cairo-ps.pc +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_151 = $(cairo_pdf_headers) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_152 = $(cairo_pdf_private) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_153 = $(cairo_pdf_cxx_sources) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_154 = $(cairo_pdf_sources) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_155 = cairo-pdf.pc +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_156 = $(cairo_svg_headers) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_157 = $(cairo_svg_private) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_158 = $(cairo_svg_cxx_sources) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_159 = $(cairo_svg_sources) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_160 = cairo-svg.pc +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_161 = $(cairo_test_surfaces_private) $(cairo_test_surfaces_headers) +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_162 = $(cairo_test_surfaces_cxx_sources) +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_163 = $(cairo_test_surfaces_sources) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_164 = $(cairo_tee_headers) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_165 = $(cairo_tee_private) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_166 = $(cairo_tee_cxx_sources) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_167 = $(cairo_tee_sources) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_168 = cairo-tee.pc +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_169 = $(cairo_xml_headers) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_170 = $(cairo_xml_private) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_171 = $(cairo_xml_cxx_sources) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_172 = $(cairo_xml_sources) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_173 = cairo-xml.pc +@CAIRO_HAS_PTHREAD_TRUE@am__append_174 = $(cairo_pthread_private) $(cairo_pthread_headers) +@CAIRO_HAS_PTHREAD_TRUE@am__append_175 = $(cairo_pthread_cxx_sources) +@CAIRO_HAS_PTHREAD_TRUE@am__append_176 = $(cairo_pthread_sources) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_177 = $(cairo_gobject_headers) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_178 = $(cairo_gobject_private) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_179 = $(cairo_gobject_cxx_sources) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_180 = $(cairo_gobject_sources) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_181 = cairo-gobject.pc +@CAIRO_HAS_TRACE_TRUE@am__append_182 = $(cairo_trace_private) $(cairo_trace_headers) +@CAIRO_HAS_TRACE_TRUE@am__append_183 = $(cairo_trace_cxx_sources) +@CAIRO_HAS_TRACE_TRUE@am__append_184 = $(cairo_trace_sources) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_185 = $(cairo_interpreter_private) $(cairo_interpreter_headers) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_186 = $(cairo_interpreter_cxx_sources) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_187 = $(cairo_interpreter_sources) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_188 = $(cairo_symbol_lookup_private) $(cairo_symbol_lookup_headers) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_189 = $(cairo_symbol_lookup_cxx_sources) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_190 = $(cairo_symbol_lookup_sources) +@ENABLE_GTK_DOC_TRUE@am__append_191 = check-doc-coverage.sh subdir = doc/public ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/aclocal.cairo.m4 \ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -667,6 +671,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -765,6 +774,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ @@ -833,7 +844,7 @@ check-doc-coverage.sh check-doc-syntax.sh EXTRA_LTLIBRARIES = MAINTAINERCLEANFILES = Makefile.in -TESTS = $(am__append_186) check-doc-syntax.sh +TESTS = $(am__append_191) check-doc-syntax.sh cairo_headers = cairo.h cairo-deprecated.h cairo_private = cairoint.h cairo-analysis-surface-private.h \ cairo-arc-private.h cairo-array-private.h \ @@ -946,16 +957,26 @@ cairo_egl_sources = cairo-egl-context.c cairo_glx_sources = cairo-glx-context.c cairo_wgl_sources = cairo-wgl-context.c -_cairo_pdf_operators_private = cairo-pdf-operators-private.h cairo-pdf-shading-private.h -_cairo_pdf_operators_sources = cairo-pdf-operators.c cairo-pdf-shading.c +_cairo_pdf_operators_private = \ + cairo-pdf-operators-private.h \ + cairo-pdf-shading-private.h \ + cairo-tag-attributes-private.h \ + $(NULL) + +_cairo_pdf_operators_sources = \ + cairo-pdf-operators.c \ + cairo-pdf-shading.c \ + cairo-tag-attributes.c \ + $(NULL) + cairo_png_sources = cairo-png.c cairo_ps_headers = cairo-ps.h cairo_ps_private = cairo-ps-surface-private.h cairo_ps_sources = cairo-ps-surface.c _cairo_deflate_stream_sources = cairo-deflate-stream.c cairo_pdf_headers = cairo-pdf.h -cairo_pdf_private = cairo-pdf-surface-private.h cairo-tag-stack-private.h cairo-tag-attributes-private.h -cairo_pdf_sources = cairo-pdf-surface.c cairo-pdf-interchange.c cairo-tag-stack.c cairo-tag-attributes.c +cairo_pdf_private = cairo-pdf-surface-private.h cairo-tag-stack-private.h +cairo_pdf_sources = cairo-pdf-surface.c cairo-pdf-interchange.c cairo-tag-stack.c cairo_svg_headers = cairo-svg.h cairo_svg_private = cairo-svg-surface-private.h cairo_svg_sources = cairo-svg-surface.c @@ -1076,6 +1097,9 @@ cairo_glesv2_headers = $(cairo_gl_headers) cairo_glesv2_private = $(cairo_gl_private) cairo_glesv2_sources = $(cairo_gl_sources) +cairo_glesv3_headers = $(cairo_gl_headers) +cairo_glesv3_private = $(cairo_gl_private) +cairo_glesv3_sources = $(cairo_gl_sources) cairo_directfb_headers = cairo-directfb.h cairo_directfb_sources = cairo-directfb-surface.c cairo_drm_headers = cairo-drm.h @@ -1149,9 +1173,9 @@ $(cairo_skia_headers) $(cairo_os2_headers) \ $(cairo_beos_headers) $(cairo_drm_headers) \ $(cairo_gallium_headers) $(cairo_gl_headers) \ - $(cairo_glesv2_headers) $(cairo_cogl_headers) \ - $(cairo_directfb_headers) $(cairo_vg_headers) \ - $(cairo_tee_headers) $(cairo_xml_headers) + $(cairo_glesv2_headers) $(cairo_glesv3_headers) \ + $(cairo_cogl_headers) $(cairo_directfb_headers) \ + $(cairo_vg_headers) $(cairo_tee_headers) $(cairo_xml_headers) all_cairo_headers = $(cairo_headers) $(cairo_xlib_headers) \ $(cairo_xlib_xrender_headers) $(cairo_xcb_headers) \ $(cairo_xlib_xcb_headers) $(cairo_xcb_shm_headers) \ @@ -1162,15 +1186,16 @@ $(cairo_beos_headers) $(cairo_drm_headers) \ $(cairo_gallium_headers) $(cairo_png_headers) \ $(cairo_gl_headers) $(cairo_glesv2_headers) \ - $(cairo_cogl_headers) $(cairo_directfb_headers) \ - $(cairo_vg_headers) $(cairo_egl_headers) $(cairo_glx_headers) \ - $(cairo_wgl_headers) $(cairo_script_headers) \ - $(cairo_ft_headers) $(cairo_fc_headers) $(cairo_ps_headers) \ - $(cairo_pdf_headers) $(cairo_svg_headers) \ - $(cairo_image_headers) $(cairo_mime_headers) \ - $(cairo_recording_headers) $(cairo_observer_headers) \ - $(cairo_tee_headers) $(cairo_xml_headers) \ - $(cairo_user_headers) $(cairo_gobject_headers) + $(cairo_glesv3_headers) $(cairo_cogl_headers) \ + $(cairo_directfb_headers) $(cairo_vg_headers) \ + $(cairo_egl_headers) $(cairo_glx_headers) $(cairo_wgl_headers) \ + $(cairo_script_headers) $(cairo_ft_headers) \ + $(cairo_fc_headers) $(cairo_ps_headers) $(cairo_pdf_headers) \ + $(cairo_svg_headers) $(cairo_image_headers) \ + $(cairo_mime_headers) $(cairo_recording_headers) \ + $(cairo_observer_headers) $(cairo_tee_headers) \ + $(cairo_xml_headers) $(cairo_user_headers) \ + $(cairo_gobject_headers) all_cairo_private = $(cairo_private) $(cairo_xlib_private) \ $(cairo_xlib_xrender_private) $(cairo_xcb_private) \ $(cairo_xlib_xcb_private) $(cairo_xcb_shm_private) \ @@ -1181,20 +1206,21 @@ $(cairo_beos_private) $(cairo_drm_private) \ $(cairo_gallium_private) $(cairo_png_private) \ $(cairo_gl_private) $(cairo_glesv2_private) \ - $(cairo_cogl_private) $(cairo_directfb_private) \ - $(cairo_vg_private) $(cairo_egl_private) $(cairo_glx_private) \ - $(cairo_wgl_private) $(cairo_script_private) \ - $(cairo_ft_private) $(cairo_fc_private) $(cairo_ps_private) \ - $(cairo_pdf_private) $(cairo_svg_private) \ - $(cairo_test_surfaces_private) $(cairo_test_surfaces_headers) \ - $(cairo_image_private) $(cairo_mime_private) \ - $(cairo_recording_private) $(cairo_observer_private) \ - $(cairo_tee_private) $(cairo_xml_private) \ - $(cairo_user_private) $(cairo_pthread_private) \ - $(cairo_pthread_headers) $(cairo_gobject_private) \ - $(cairo_trace_private) $(cairo_trace_headers) \ - $(cairo_interpreter_private) $(cairo_interpreter_headers) \ - $(cairo_symbol_lookup_private) $(cairo_symbol_lookup_headers) + $(cairo_glesv3_private) $(cairo_cogl_private) \ + $(cairo_directfb_private) $(cairo_vg_private) \ + $(cairo_egl_private) $(cairo_glx_private) $(cairo_wgl_private) \ + $(cairo_script_private) $(cairo_ft_private) \ + $(cairo_fc_private) $(cairo_ps_private) $(cairo_pdf_private) \ + $(cairo_svg_private) $(cairo_test_surfaces_private) \ + $(cairo_test_surfaces_headers) $(cairo_image_private) \ + $(cairo_mime_private) $(cairo_recording_private) \ + $(cairo_observer_private) $(cairo_tee_private) \ + $(cairo_xml_private) $(cairo_user_private) \ + $(cairo_pthread_private) $(cairo_pthread_headers) \ + $(cairo_gobject_private) $(cairo_trace_private) \ + $(cairo_trace_headers) $(cairo_interpreter_private) \ + $(cairo_interpreter_headers) $(cairo_symbol_lookup_private) \ + $(cairo_symbol_lookup_headers) all_cairo_cxx_sources = $(cairo_cxx_sources) $(cairo_xlib_cxx_sources) \ $(cairo_xlib_xrender_cxx_sources) $(cairo_xcb_cxx_sources) \ $(cairo_xlib_xcb_cxx_sources) $(cairo_xcb_shm_cxx_sources) \ @@ -1205,19 +1231,19 @@ $(cairo_os2_cxx_sources) $(cairo_beos_cxx_sources) \ $(cairo_drm_cxx_sources) $(cairo_gallium_cxx_sources) \ $(cairo_png_cxx_sources) $(cairo_gl_cxx_sources) \ - $(cairo_glesv2_cxx_sources) $(cairo_cogl_cxx_sources) \ - $(cairo_directfb_cxx_sources) $(cairo_vg_cxx_sources) \ - $(cairo_egl_cxx_sources) $(cairo_glx_cxx_sources) \ - $(cairo_wgl_cxx_sources) $(cairo_script_cxx_sources) \ - $(cairo_ft_cxx_sources) $(cairo_fc_cxx_sources) \ - $(cairo_ps_cxx_sources) $(cairo_pdf_cxx_sources) \ - $(cairo_svg_cxx_sources) $(cairo_test_surfaces_cxx_sources) \ - $(cairo_image_cxx_sources) $(cairo_mime_cxx_sources) \ - $(cairo_recording_cxx_sources) $(cairo_observer_cxx_sources) \ - $(cairo_tee_cxx_sources) $(cairo_xml_cxx_sources) \ - $(cairo_user_cxx_sources) $(cairo_pthread_cxx_sources) \ - $(cairo_gobject_cxx_sources) $(cairo_trace_cxx_sources) \ - $(cairo_interpreter_cxx_sources) \ + $(cairo_glesv2_cxx_sources) $(cairo_glesv3_cxx_sources) \ + $(cairo_cogl_cxx_sources) $(cairo_directfb_cxx_sources) \ + $(cairo_vg_cxx_sources) $(cairo_egl_cxx_sources) \ + $(cairo_glx_cxx_sources) $(cairo_wgl_cxx_sources) \ + $(cairo_script_cxx_sources) $(cairo_ft_cxx_sources) \ + $(cairo_fc_cxx_sources) $(cairo_ps_cxx_sources) \ + $(cairo_pdf_cxx_sources) $(cairo_svg_cxx_sources) \ + $(cairo_test_surfaces_cxx_sources) $(cairo_image_cxx_sources) \ + $(cairo_mime_cxx_sources) $(cairo_recording_cxx_sources) \ + $(cairo_observer_cxx_sources) $(cairo_tee_cxx_sources) \ + $(cairo_xml_cxx_sources) $(cairo_user_cxx_sources) \ + $(cairo_pthread_cxx_sources) $(cairo_gobject_cxx_sources) \ + $(cairo_trace_cxx_sources) $(cairo_interpreter_cxx_sources) \ $(cairo_symbol_lookup_cxx_sources) all_cairo_sources = $(cairo_sources) $(cairo_xlib_sources) \ $(cairo_xlib_xrender_sources) $(cairo_xcb_sources) \ @@ -1229,18 +1255,18 @@ $(cairo_beos_sources) $(cairo_drm_sources) \ $(cairo_gallium_sources) $(cairo_png_sources) \ $(cairo_gl_sources) $(cairo_glesv2_sources) \ - $(cairo_cogl_sources) $(cairo_directfb_sources) \ - $(cairo_vg_sources) $(cairo_egl_sources) $(cairo_glx_sources) \ - $(cairo_wgl_sources) $(cairo_script_sources) \ - $(cairo_ft_sources) $(cairo_fc_sources) $(cairo_ps_sources) \ - $(cairo_pdf_sources) $(cairo_svg_sources) \ - $(cairo_test_surfaces_sources) $(cairo_image_sources) \ - $(cairo_mime_sources) $(cairo_recording_sources) \ - $(cairo_observer_sources) $(cairo_tee_sources) \ - $(cairo_xml_sources) $(cairo_user_sources) \ - $(cairo_pthread_sources) $(cairo_gobject_sources) \ - $(cairo_trace_sources) $(cairo_interpreter_sources) \ - $(cairo_symbol_lookup_sources) + $(cairo_glesv3_sources) $(cairo_cogl_sources) \ + $(cairo_directfb_sources) $(cairo_vg_sources) \ + $(cairo_egl_sources) $(cairo_glx_sources) $(cairo_wgl_sources) \ + $(cairo_script_sources) $(cairo_ft_sources) \ + $(cairo_fc_sources) $(cairo_ps_sources) $(cairo_pdf_sources) \ + $(cairo_svg_sources) $(cairo_test_surfaces_sources) \ + $(cairo_image_sources) $(cairo_mime_sources) \ + $(cairo_recording_sources) $(cairo_observer_sources) \ + $(cairo_tee_sources) $(cairo_xml_sources) \ + $(cairo_user_sources) $(cairo_pthread_sources) \ + $(cairo_gobject_sources) $(cairo_trace_sources) \ + $(cairo_interpreter_sources) $(cairo_symbol_lookup_sources) enabled_cairo_headers = $(cairo_headers) $(am__append_1) \ $(am__append_6) $(am__append_11) $(am__append_16) \ $(am__append_21) $(am__append_26) $(am__append_31) \ @@ -1252,10 +1278,10 @@ $(am__append_111) $(am__append_116) $(am__append_121) \ $(am__append_126) $(am__append_131) $(am__append_136) \ $(am__append_141) $(am__append_146) $(am__append_151) \ - $(cairo_image_headers) $(cairo_mime_headers) \ + $(am__append_156) $(cairo_image_headers) $(cairo_mime_headers) \ $(cairo_recording_headers) $(cairo_observer_headers) \ - $(am__append_159) $(am__append_164) $(cairo_user_headers) \ - $(am__append_172) + $(am__append_164) $(am__append_169) $(cairo_user_headers) \ + $(am__append_177) enabled_cairo_private = $(cairo_private) $(am__append_2) \ $(am__append_7) $(am__append_12) $(am__append_17) \ $(am__append_22) $(am__append_27) $(am__append_32) \ @@ -1267,11 +1293,11 @@ $(am__append_112) $(am__append_117) $(am__append_122) \ $(am__append_127) $(am__append_132) $(am__append_137) \ $(am__append_142) $(am__append_147) $(am__append_152) \ - $(am__append_156) $(cairo_image_private) $(cairo_mime_private) \ - $(cairo_recording_private) $(cairo_observer_private) \ - $(am__append_160) $(am__append_165) $(cairo_user_private) \ - $(am__append_169) $(am__append_173) $(am__append_177) \ - $(am__append_180) $(am__append_183) + $(am__append_157) $(am__append_161) $(cairo_image_private) \ + $(cairo_mime_private) $(cairo_recording_private) \ + $(cairo_observer_private) $(am__append_165) $(am__append_170) \ + $(cairo_user_private) $(am__append_174) $(am__append_178) \ + $(am__append_182) $(am__append_185) $(am__append_188) enabled_cairo_cxx_sources = $(cairo_cxx_sources) $(am__append_3) \ $(am__append_8) $(am__append_13) $(am__append_18) \ $(am__append_23) $(am__append_28) $(am__append_33) \ @@ -1283,12 +1309,12 @@ $(am__append_113) $(am__append_118) $(am__append_123) \ $(am__append_128) $(am__append_133) $(am__append_138) \ $(am__append_143) $(am__append_148) $(am__append_153) \ - $(am__append_157) $(cairo_image_cxx_sources) \ + $(am__append_158) $(am__append_162) $(cairo_image_cxx_sources) \ $(cairo_mime_cxx_sources) $(cairo_recording_cxx_sources) \ - $(cairo_observer_cxx_sources) $(am__append_161) \ - $(am__append_166) $(cairo_user_cxx_sources) $(am__append_170) \ - $(am__append_174) $(am__append_178) $(am__append_181) \ - $(am__append_184) + $(cairo_observer_cxx_sources) $(am__append_166) \ + $(am__append_171) $(cairo_user_cxx_sources) $(am__append_175) \ + $(am__append_179) $(am__append_183) $(am__append_186) \ + $(am__append_189) enabled_cairo_sources = $(cairo_sources) $(am__append_4) \ $(am__append_9) $(am__append_14) $(am__append_19) \ $(am__append_24) $(am__append_29) $(am__append_34) \ @@ -1300,21 +1326,21 @@ $(am__append_114) $(am__append_119) $(am__append_124) \ $(am__append_129) $(am__append_134) $(am__append_139) \ $(am__append_144) $(am__append_149) $(am__append_154) \ - $(am__append_158) $(cairo_image_sources) $(cairo_mime_sources) \ - $(cairo_recording_sources) $(cairo_observer_sources) \ - $(am__append_162) $(am__append_167) $(cairo_user_sources) \ - $(am__append_171) $(am__append_175) $(am__append_179) \ - $(am__append_182) $(am__append_185) + $(am__append_159) $(am__append_163) $(cairo_image_sources) \ + $(cairo_mime_sources) $(cairo_recording_sources) \ + $(cairo_observer_sources) $(am__append_167) $(am__append_172) \ + $(cairo_user_sources) $(am__append_176) $(am__append_180) \ + $(am__append_184) $(am__append_187) $(am__append_190) all_cairo_pkgconf = cairo.pc cairo-xlib.pc cairo-xlib-xrender.pc \ cairo-xcb.pc cairo-xlib-xcb.pc cairo-xcb-shm.pc cairo-qt.pc \ cairo-quartz.pc cairo-quartz-font.pc cairo-quartz-image.pc \ cairo-win32.pc cairo-win32-font.pc cairo-skia.pc cairo-os2.pc \ cairo-beos.pc cairo-drm.pc cairo-gallium.pc cairo-png.pc \ - cairo-gl.pc cairo-glesv2.pc cairo-cogl.pc cairo-directfb.pc \ - cairo-vg.pc cairo-egl.pc cairo-glx.pc cairo-wgl.pc \ - cairo-script.pc cairo-ft.pc cairo-fc.pc cairo-ps.pc \ - cairo-pdf.pc cairo-svg.pc cairo-tee.pc cairo-xml.pc \ - cairo-gobject.pc + cairo-gl.pc cairo-glesv2.pc cairo-glesv3.pc cairo-cogl.pc \ + cairo-directfb.pc cairo-vg.pc cairo-egl.pc cairo-glx.pc \ + cairo-wgl.pc cairo-script.pc cairo-ft.pc cairo-fc.pc \ + cairo-ps.pc cairo-pdf.pc cairo-svg.pc cairo-tee.pc \ + cairo-xml.pc cairo-gobject.pc enabled_cairo_pkgconf = cairo.pc $(am__append_5) $(am__append_10) \ $(am__append_15) $(am__append_20) $(am__append_25) \ $(am__append_30) $(am__append_35) $(am__append_40) \ @@ -1325,8 +1351,8 @@ $(am__append_105) $(am__append_110) $(am__append_115) \ $(am__append_120) $(am__append_125) $(am__append_130) \ $(am__append_135) $(am__append_140) $(am__append_145) \ - $(am__append_150) $(am__append_155) $(am__append_163) \ - $(am__append_168) $(am__append_176) + $(am__append_150) $(am__append_155) $(am__append_160) \ + $(am__append_168) $(am__append_173) $(am__append_181) # The name of the module. DOC_MODULE = cairo diff -Nru cairo-1.15.8/doc/public/tmpl/cairo-surface.sgml cairo-1.15.10/doc/public/tmpl/cairo-surface.sgml --- cairo-1.15.8/doc/public/tmpl/cairo-surface.sgml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/tmpl/cairo-surface.sgml 2017-12-11 21:03:31.000000000 +0000 @@ -27,6 +27,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -Nru cairo-1.15.8/doc/public/tmpl/cairo-tag.sgml cairo-1.15.10/doc/public/tmpl/cairo-tag.sgml --- cairo-1.15.8/doc/public/tmpl/cairo-tag.sgml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/tmpl/cairo-tag.sgml 2017-12-11 21:03:31.000000000 +0000 @@ -9,11 +9,13 @@ + + diff -Nru cairo-1.15.8/doc/public/tmpl/cairo-unused.sgml cairo-1.15.10/doc/public/tmpl/cairo-unused.sgml --- cairo-1.15.8/doc/public/tmpl/cairo-unused.sgml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/tmpl/cairo-unused.sgml 2017-12-11 21:03:31.000000000 +0000 @@ -1,24 +0,0 @@ - - - - - -@base: -@original: -@target: -@matrix: -@canvas: -@paint: -@path: -@source: -@source_image: -@source_extra: - - - - - - -@image: -@bitmap: - diff -Nru cairo-1.15.8/doc/public/version.xml cairo-1.15.10/doc/public/version.xml --- cairo-1.15.8/doc/public/version.xml 2017-08-29 17:05:35.000000000 +0000 +++ cairo-1.15.10/doc/public/version.xml 2017-12-11 21:03:20.000000000 +0000 @@ -1 +1 @@ -1.15.8 +1.15.10 diff -Nru cairo-1.15.8/doc/public/xml/api-index-1.16.xml cairo-1.15.10/doc/public/xml/api-index-1.16.xml --- cairo-1.15.8/doc/public/xml/api-index-1.16.xml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/xml/api-index-1.16.xml 2017-12-11 21:03:31.000000000 +0000 @@ -4,6 +4,12 @@ ]> +M +CAIRO_MIME_TYPE_CCITT_FAX, macro in cairo_surface_t +CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, macro in cairo_surface_t +CAIRO_MIME_TYPE_EPS, macro in cairo_surface_t +CAIRO_MIME_TYPE_EPS_PARAMS, macro in cairo_surface_t + P cairo_pdf_metadata_t, enum in PDF Surfaces cairo_pdf_outline_flags_t, enum in PDF Surfaces @@ -13,6 +19,9 @@ cairo_pdf_surface_set_page_label, function in PDF Surfaces cairo_pdf_surface_set_thumbnail_size, function in PDF Surfaces +S +cairo_svg_version_t, enum in SVG Surfaces + T cairo_tag_begin, function in Tags and Links CAIRO_TAG_DEST, macro in Tags and Links diff -Nru cairo-1.15.8/doc/public/xml/api-index-1.2.xml cairo-1.15.10/doc/public/xml/api-index-1.2.xml --- cairo-1.15.8/doc/public/xml/api-index-1.2.xml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/xml/api-index-1.2.xml 2017-12-11 21:03:31.000000000 +0000 @@ -58,7 +58,6 @@ cairo_svg_surface_create, function in SVG Surfaces cairo_svg_surface_create_for_stream, function in SVG Surfaces cairo_svg_surface_restrict_to_version, function in SVG Surfaces -cairo_svg_version_t, enum in SVG Surfaces cairo_svg_version_to_string, function in SVG Surfaces W diff -Nru cairo-1.15.8/doc/public/xml/api-index-full.xml cairo-1.15.10/doc/public/xml/api-index-full.xml --- cairo-1.15.8/doc/public/xml/api-index-full.xml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/xml/api-index-full.xml 2017-12-11 21:03:31.000000000 +0000 @@ -205,6 +205,10 @@ cairo_mesh_pattern_set_control_point, function in cairo_pattern_t cairo_mesh_pattern_set_corner_color_rgb, function in cairo_pattern_t cairo_mesh_pattern_set_corner_color_rgba, function in cairo_pattern_t +CAIRO_MIME_TYPE_CCITT_FAX, macro in cairo_surface_t +CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, macro in cairo_surface_t +CAIRO_MIME_TYPE_EPS, macro in cairo_surface_t +CAIRO_MIME_TYPE_EPS_PARAMS, macro in cairo_surface_t CAIRO_MIME_TYPE_JBIG2, macro in cairo_surface_t CAIRO_MIME_TYPE_JBIG2_GLOBAL, macro in cairo_surface_t CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, macro in cairo_surface_t diff -Nru cairo-1.15.8/doc/public/xml/cairo-pdf.xml cairo-1.15.10/doc/public/xml/cairo-pdf.xml --- cairo-1.15.8/doc/public/xml/cairo-pdf.xml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/xml/cairo-pdf.xml 2017-12-11 21:03:31.000000000 +0000 @@ -72,18 +72,54 @@ The following mime types are supported: CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_JP2, CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_JBIG2, CAIRO_MIME_TYPE_JBIG2_GLOBAL, -CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID. -JBIG2 data in PDF must be in the embedded format as described in +CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, +CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS. +JBIG2 ImagesJBIG2 data in PDF must be in the embedded format as described in ISO/IEC 11544. Image specific JBIG2 data must be in CAIRO_MIME_TYPE_JBIG2. Any global segments in the JBIG2 data (segments with page association field set to 0) must be in CAIRO_MIME_TYPE_JBIG2_GLOBAL. The global data may be shared by multiple images. All images sharing the same global data must set -CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID to a unique identifer. At least +CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID to a unique identifier. At least one of the images must provide the global data using CAIRO_MIME_TYPE_JBIG2_GLOBAL. The global data will only be -embedded once but shared by all JBIG2 images with the same +embedded once and shared by all JBIG2 images with the same CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID. + +CCITT Fax ImagesThe CAIRO_MIME_TYPE_CCITT_FAX mime data requires a number of decoding +parameters These parameters are specified using CAIRO_MIME_TYPE_CCITT_FAX_PARAMS. +CAIRO_MIME_TYPE_CCITT_FAX_PARAMS mime data must contain a string of the form +"param1=value1 param2=value2 ...". +Columns +: [required] An integer specifying the width of the image in pixels. +Rows +: [required] An integer specifying the height of the image in scan lines. +K +: [optional] An integer identifying the encoding scheme used. < 0 +is 2 dimensional Group 4, = 0 is Group3 1 dimensional, > 0 is mixed 1 +and 2 dimensional encoding. Default is 0. +EndOfLine +: [optional] If true end-of-line bit patterns are present. Default is false. +EncodedByteAlign +: [optional] If true the end of line is padded +with 0 bits so the next line begins on a byte boundary. Default is false. +EndOfBlock +: [optional] If true the data contains an end-of-block pattern. Default is true. +BlackIs1 +: [optional] If true 1 bits are black pixels. Default is false. +DamagedRowsBeforeError +: [optional] An integer specifying the +number of damages rows tolerated before an error occurs. Default is 0. +Boolean values may be "true" or "false", or 1 or 0. +These parameters are the same as the CCITTFaxDecode parameters in the +PostScript Language Reference +and Portable Document Format (PDF). +Refer to these documents for further details. +An example CAIRO_MIME_TYPE_CCITT_FAX_PARAMS string is: + +"Columns=10230 Rows=40000 K=1 EndOfLine=true EncodedByteAlign=1 BlackIs1=false" + + diff -Nru cairo-1.15.8/doc/public/xml/cairo-png.xml cairo-1.15.10/doc/public/xml/cairo-png.xml --- cairo-1.15.8/doc/public/xml/cairo-png.xml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/xml/cairo-png.xml 2017-12-11 21:03:31.000000000 +0000 @@ -84,7 +84,8 @@ filename -name of PNG file to load +name of PNG file to load. On Windows this filename +is encoded in UTF-8. @@ -199,7 +200,8 @@ a cairo_surface_t with pixel contents filename -the name of a file to write to +the name of a file to write to; on Windows this filename +is encoded in UTF-8. diff -Nru cairo-1.15.8/doc/public/xml/cairo-ps.xml cairo-1.15.10/doc/public/xml/cairo-ps.xml --- cairo-1.15.8/doc/public/xml/cairo-ps.xml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/xml/cairo-ps.xml 2017-12-11 21:03:31.000000000 +0000 @@ -68,6 +68,32 @@ Description The PostScript surface is used to render cairo graphics to Adobe PostScript files and is a multi-page vector surface backend. +The following mime types are supported: CAIRO_MIME_TYPE_JPEG, +CAIRO_MIME_TYPE_UNIQUE_ID, +CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, +CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, +CAIRO_MIME_TYPE_EPS, CAIRO_MIME_TYPE_EPS_PARAMS. +Source surfaces used by the PostScript surface that have a +CAIRO_MIME_TYPE_UNIQUE_ID mime type will be stored in PostScript +printer memory for the duration of the print +job. CAIRO_MIME_TYPE_UNIQUE_ID should only be used for small +frequently used sources. +The CAIRO_MIME_TYPE_CCITT_FAX and CAIRO_MIME_TYPE_CCITT_FAX_PARAMS mime types +are documented in CCITT Fax Images. +Embedding EPS filesEncapsulated PostScript files can be embedded in the PS output by +setting the CAIRO_MIME_TYPE_EPS mime data on a surface to the EPS +data and painting the surface. The EPS will be scaled and +translated to the extents of the surface the EPS data is attached +to. +The CAIRO_MIME_TYPE_EPS mime type requires the +CAIRO_MIME_TYPE_EPS_PARAMS mime data to also be provided in order +to specify the embeddding parameters. CAIRO_MIME_TYPE_EPS_PARAMS +mime data must contain a string of the form "bbox=[llx lly urx +ury]" that specifies the bounding box (in PS coordinates) of the +EPS graphics. The parameters are: lower left x, lower left y, upper +right x, upper right y. Normally the bbox data is identical to the +%%BoundingBox data in the EPS file. + diff -Nru cairo-1.15.8/doc/public/xml/cairo-surface.xml cairo-1.15.10/doc/public/xml/cairo-surface.xml --- cairo-1.15.8/doc/public/xml/cairo-surface.xml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/xml/cairo-surface.xml 2017-12-11 21:03:31.000000000 +0000 @@ -96,6 +96,10 @@ #defineCAIRO_HAS_MIME_SURFACE +#defineCAIRO_MIME_TYPE_CCITT_FAX +#defineCAIRO_MIME_TYPE_CCITT_FAX_PARAMS +#defineCAIRO_MIME_TYPE_EPS +#defineCAIRO_MIME_TYPE_EPS_PARAMS #defineCAIRO_MIME_TYPE_JBIG2 #defineCAIRO_MIME_TYPE_JBIG2_GLOBAL #defineCAIRO_MIME_TYPE_JBIG2_GLOBAL_ID @@ -1012,7 +1016,8 @@ The recognized MIME types are the following: CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_PNG, CAIRO_MIME_TYPE_JP2, CAIRO_MIME_TYPE_URI, CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_JBIG2, -CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID. +CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, +CAIRO_MIME_TYPE_CCITT_FAX, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS. See corresponding backend surface docs for details about which MIME types it can handle. Caution: the associated MIME data will be discarded if you draw on the surface afterwards. Use this function @@ -1210,6 +1215,38 @@ + +CAIRO_MIME_TYPE_CCITT_FAX +CAIRO_MIME_TYPE_CCITT_FAX +#define CAIRO_MIME_TYPE_CCITT_FAX "image/g3fax" + +Group 3 or Group 4 CCITT facsimile encoding (International +Telecommunication Union, Recommendations T.4 and T.6.) +Since: 1.16 + +CAIRO_MIME_TYPE_CCITT_FAX_PARAMS +CAIRO_MIME_TYPE_CCITT_FAX_PARAMS +#define CAIRO_MIME_TYPE_CCITT_FAX_PARAMS "application/x-cairo.ccitt.params" + +Decode parameters for Group 3 or Group 4 CCITT facsimile encoding. +See CCITT Fax Images. +Since: 1.16 + +CAIRO_MIME_TYPE_EPS +CAIRO_MIME_TYPE_EPS +#define CAIRO_MIME_TYPE_EPS "application/postscript" + +Encapsulated PostScript file. +Encapsulated PostScript File Format Specification +Since: 1.16 + +CAIRO_MIME_TYPE_EPS_PARAMS +CAIRO_MIME_TYPE_EPS_PARAMS +#define CAIRO_MIME_TYPE_EPS_PARAMS "application/x-cairo.eps.params" + +Embedding parameters Encapsulated PostScript data. +See Embedding EPS files. +Since: 1.16 CAIRO_MIME_TYPE_JBIG2 CAIRO_MIME_TYPE_JBIG2 diff -Nru cairo-1.15.8/doc/public/xml/cairo-svg.xml cairo-1.15.10/doc/public/xml/cairo-svg.xml --- cairo-1.15.8/doc/public/xml/cairo-svg.xml 2017-08-29 17:05:44.000000000 +0000 +++ cairo-1.15.10/doc/public/xml/cairo-svg.xml 2017-12-11 21:03:31.000000000 +0000 @@ -83,6 +83,8 @@ If CAIRO_MIME_TYPE_URI is not present, but CAIRO_MIME_TYPE_JPEG or CAIRO_MIME_TYPE_PNG is specified, the corresponding data is Base64-encoded and emitted. +If CAIRO_MIME_TYPE_UNIQUE_ID is present, all surfaces with the same +unique identifier will only be embedded once. Parameters @@ -252,11 +254,38 @@ Defined if the SVG surface backend is available. This macro can be used to conditionally compile backend-specific code. Since: 1.2 - + enum cairo_svg_version_t -cairo_svg_version_t -cairo_svg_version_t is used to describe the version number of the SVG -specification that a generated SVG file will conform to. +cairo_svg_version_t +CAIRO_SVG_UNIT_USER +: User unit, a value in the current coordinate system. + If used in the root element for the initial coordinate systems it + corresponds to pixels. (Since 1.16) +CAIRO_SVG_UNIT_EM +: The size of the element's font. (Since 1.16) +CAIRO_SVG_UNIT_EX +: The x-height of the element’s font. (Since 1.16) +CAIRO_SVG_UNIT_PX +: Pixels (1px = 1/96th of 1in). (Since 1.16) +CAIRO_SVG_UNIT_IN +: Inches (1in = 2.54cm = 96px). (Since 1.16) +CAIRO_SVG_UNIT_CM +: Centimeters (1cm = 96px/2.54). (Since 1.16) +CAIRO_SVG_UNIT_MM +: Millimeters (1mm = 1/10th of 1cm). (Since 1.16) +CAIRO_SVG_UNIT_PT +: Points (1pt = 1/72th of 1in). (Since 1.16) +CAIRO_SVG_UNIT_PC +: Picas (1pc = 1/6th of 1in). (Since 1.16) +CAIRO_SVG_UNIT_PERCENT +: Percent, a value that is some fraction of another + reference value. (Since 1.16) +cairo_svg_unit_t is used to describe the units valid for coordinates and +lengths in the SVG specification. +See also: +https://www.w3.org/TR/SVG/coords.htmlUnits +https://www.w3.org/TR/SVG/types.htmlDataTypeLength +https://www.w3.org/TR/css-values-3/lengths Members @@ -266,17 +295,15 @@ CAIRO_SVG_VERSION_1_1 -The version 1.1 of the SVG specification. (Since 1.2) - + CAIRO_SVG_VERSION_1_2 -The version 1.2 of the SVG specification. (Since 1.2) - + -Since: 1.2 +Since: 1.16 diff -Nru cairo-1.15.8/Makefile.in cairo-1.15.10/Makefile.in --- cairo-1.15.8/Makefile.in 2017-08-29 17:02:11.000000000 +0000 +++ cairo-1.15.10/Makefile.in 2017-12-11 21:03:10.000000000 +0000 @@ -114,10 +114,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -150,14 +149,15 @@ cairo-os2-uninstalled.pc cairo-beos-uninstalled.pc \ cairo-drm-uninstalled.pc cairo-gallium-uninstalled.pc \ cairo-png-uninstalled.pc cairo-gl-uninstalled.pc \ - cairo-glesv2-uninstalled.pc cairo-cogl-uninstalled.pc \ - cairo-directfb-uninstalled.pc cairo-vg-uninstalled.pc \ - cairo-egl-uninstalled.pc cairo-glx-uninstalled.pc \ - cairo-wgl-uninstalled.pc cairo-script-uninstalled.pc \ - cairo-ft-uninstalled.pc cairo-fc-uninstalled.pc \ - cairo-ps-uninstalled.pc cairo-pdf-uninstalled.pc \ - cairo-svg-uninstalled.pc cairo-tee-uninstalled.pc \ - cairo-xml-uninstalled.pc cairo-gobject-uninstalled.pc + cairo-glesv2-uninstalled.pc cairo-glesv3-uninstalled.pc \ + cairo-cogl-uninstalled.pc cairo-directfb-uninstalled.pc \ + cairo-vg-uninstalled.pc cairo-egl-uninstalled.pc \ + cairo-glx-uninstalled.pc cairo-wgl-uninstalled.pc \ + cairo-script-uninstalled.pc cairo-ft-uninstalled.pc \ + cairo-fc-uninstalled.pc cairo-ps-uninstalled.pc \ + cairo-pdf-uninstalled.pc cairo-svg-uninstalled.pc \ + cairo-tee-uninstalled.pc cairo-xml-uninstalled.pc \ + cairo-gobject-uninstalled.pc CONFIG_CLEAN_VPATH_FILES = AM_V_P = $(am__v_P_@AM_V@) am__v_P_ = $(am__v_P_@AM_DEFAULT_V@) @@ -530,6 +530,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -628,6 +633,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ @@ -846,6 +853,8 @@ cd $(top_builddir) && $(SHELL) ./config.status $@ cairo-glesv2-uninstalled.pc: $(top_builddir)/config.status $(top_srcdir)/src/cairo-features-uninstalled.pc.in cd $(top_builddir) && $(SHELL) ./config.status $@ +cairo-glesv3-uninstalled.pc: $(top_builddir)/config.status $(top_srcdir)/src/cairo-features-uninstalled.pc.in + cd $(top_builddir) && $(SHELL) ./config.status $@ cairo-cogl-uninstalled.pc: $(top_builddir)/config.status $(top_srcdir)/src/cairo-features-uninstalled.pc.in cd $(top_builddir) && $(SHELL) ./config.status $@ cairo-directfb-uninstalled.pc: $(top_builddir)/config.status $(top_srcdir)/src/cairo-features-uninstalled.pc.in diff -Nru cairo-1.15.8/NEWS cairo-1.15.10/NEWS --- cairo-1.15.8/NEWS 2017-08-29 17:01:02.000000000 +0000 +++ cairo-1.15.10/NEWS 2017-12-08 18:24:52.000000000 +0000 @@ -1,3 +1,75 @@ +Release 1.15.10 (2017-12-07 Bryce Harrington ) +======================================================================== +This release adds GLESv3 support to the cairo_gl backend, adds +tracking of SVG units in generated svg documents, and cleans up numerous +test failures and related issues in the PDF and Postscript backends. + +For a complete log of changes, please see + + http://cairographics.org/releases/ChangeLog.1.15.10 + +Features and Enhancements +------------------------- +* Add support for OpenGL ES 3.0 to the gl backend. +* Use Reusable streams for forms in Level 3 Postscript. +* Add CAIRO_MIME_TYPE_EPS mime type for embedding EPS files. +* Add CCITT_FAX mime type for PDF and PS surfaces +* svg: add a new function to specify the SVG document unit + (Bug #90166) +* Use UTF-8 filenames on Windows + +API Changes +----------- +* cairo_svg_surface_set_document_unit() and + cairo_svg_surface_get_document_unit() + +Dependency Changes +------------------ +None + +Performance Optimizations +------------------------- +None + +Bug Fixes +--------- +* Fix regression in gles version detection +* Fix undefined-behavior with integer math. +* Handle SOURCE and CLEAR operators when painting color glyphs. + (Bug #102661) +* Convert images to rgba or a8 formats when uploading with GLESv2 +* Use _WIN32 instead of windows.h to check for windows build. +* Fix sigabrt printing documents with fonts lacking the mandatory .nodef + glyph. + (Bug #102922) +* Prevent curved strokes in small ctms from being culled from vector + surfaces + (Bug #103071) +* Fix painting an unbounded recording surface with the SVG backend. +* Fix falling back to system font with PDFs using certain embedded + fonts, due to truncated font names. + (Bug #103249) +* Fix handling of truetype fonts with excessively long font names + (Bug #103249) +* Fix race conditions with cairo_mask_compositor_t + (Bug #103037) +* Fix build error with util/font-view +* Fix assertion hit with PDFs using Type 4 fonts rendered with user + fonts, due to error when destroying glyph page. + (Bug #103335) +* Set default creation date for PDFs +* Prevent invalid ptr access for > 4GB images. + (Bug #98165) +* Prevent self-copy infinite loop in Postscript surface. +* Fix padded image crash in Postscript surface. +* Fix annotation bugs in PDFs and related memory leaks +* Fix test failures and other assorted issues in ps and pdf code. +* Fix code generation when using GCC legacy atomic operations + (Bug #103559) +* Fix various compilation warnings and errors. +* Fix various distcheck errors with private symbols, doxygen formatting, + etc. + Release 1.15.8 (2017-08-29 Bryce Harrington ) ======================================================================== This small snapshot provides new colored emoji glyph support, and a diff -Nru cairo-1.15.8/perf/Makefile.in cairo-1.15.10/perf/Makefile.in --- cairo-1.15.8/perf/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/perf/Makefile.in 2017-12-11 21:03:10.000000000 +0000 @@ -103,10 +103,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -565,6 +564,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -663,6 +667,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/perf/micro/Makefile.in cairo-1.15.10/perf/micro/Makefile.in --- cairo-1.15.8/perf/micro/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/perf/micro/Makefile.in 2017-12-11 21:03:10.000000000 +0000 @@ -97,10 +97,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -466,6 +465,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -564,6 +568,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/RELEASING cairo-1.15.10/RELEASING --- cairo-1.15.8/RELEASING 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/RELEASING 2017-12-07 02:14:36.000000000 +0000 @@ -173,7 +173,7 @@ previous versions, remove manual-${THIS_RELEASE} and release/cairo-${THIS_RELEASE}. -8) Update trunk (or the stable branch) version number. +8) Update master (or the stable branch) version number. For Micro releases (X.Y.Z), increment cairo_version_micro to the next larger (odd) number in cairo-version.h, commit, and push. diff -Nru cairo-1.15.8/src/cairo-analysis-surface.c cairo-1.15.10/src/cairo-analysis-surface.c --- cairo-1.15.8/src/cairo-analysis-surface.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-analysis-surface.c 2017-12-07 02:14:36.000000000 +0000 @@ -138,81 +138,6 @@ } static cairo_int_status_t -_analyze_recording_surface_pattern (cairo_analysis_surface_t *surface, - const cairo_pattern_t *pattern, - cairo_rectangle_int_t *extents) -{ - const cairo_surface_pattern_t *surface_pattern; - cairo_analysis_surface_t *tmp; - cairo_surface_t *source, *proxy; - cairo_matrix_t p2d; - cairo_status_t status, analysis_status; - cairo_bool_t surface_is_unbounded; - cairo_bool_t unused; - - assert (pattern->type == CAIRO_PATTERN_TYPE_SURFACE); - surface_pattern = (const cairo_surface_pattern_t *) pattern; - assert (surface_pattern->surface->type == CAIRO_SURFACE_TYPE_RECORDING); - source = surface_pattern->surface; - - proxy = _cairo_surface_has_snapshot (source, &proxy_backend); - if (proxy != NULL) { - /* nothing untoward found so far */ - return CAIRO_STATUS_SUCCESS; - } - - tmp = (cairo_analysis_surface_t *) - _cairo_analysis_surface_create (surface->target); - if (unlikely (tmp->base.status)) - return tmp->base.status; - proxy = attach_proxy (source, &tmp->base); - - p2d = pattern->matrix; - status = cairo_matrix_invert (&p2d); - assert (status == CAIRO_STATUS_SUCCESS); - _cairo_analysis_surface_set_ctm (&tmp->base, &p2d); - - source = _cairo_surface_get_source (source, NULL); - surface_is_unbounded = (pattern->extend == CAIRO_EXTEND_REPEAT - || pattern->extend == CAIRO_EXTEND_REFLECT); - status = _cairo_recording_surface_replay_and_create_regions (source, - &pattern->matrix, - &tmp->base, - surface_is_unbounded); - if (tmp->has_supported) { - surface->has_supported = TRUE; - unused = cairo_region_union (&surface->supported_region, &tmp->supported_region); - } - - if (tmp->has_unsupported) { - surface->has_unsupported = TRUE; - unused = cairo_region_union (&surface->fallback_region, &tmp->fallback_region); - } - - analysis_status = tmp->has_unsupported ? CAIRO_INT_STATUS_IMAGE_FALLBACK : CAIRO_INT_STATUS_SUCCESS; - - if (pattern->extend != CAIRO_EXTEND_NONE) { - _cairo_unbounded_rectangle_init (extents); - } else if (source->content & CAIRO_CONTENT_ALPHA) { - status = cairo_matrix_invert (&tmp->ctm); - _cairo_matrix_transform_bounding_box_fixed (&tmp->ctm, - &tmp->page_bbox, NULL); - _cairo_box_round_to_rectangle (&tmp->page_bbox, extents); - } else { - /* black background fills entire extents */ - _cairo_surface_get_extents (source, extents); - } - - detach_proxy (proxy); - cairo_surface_destroy (&tmp->base); - - if (unlikely (status)) - return status; - - return analysis_status; -} - -static cairo_int_status_t _add_operation (cairo_analysis_surface_t *surface, cairo_rectangle_int_t *rect, cairo_int_status_t backend_status) @@ -329,6 +254,103 @@ return status; } +static cairo_int_status_t +_analyze_recording_surface_pattern (cairo_analysis_surface_t *surface, + const cairo_pattern_t *pattern, + cairo_rectangle_int_t *extents) +{ + const cairo_surface_pattern_t *surface_pattern; + cairo_analysis_surface_t *tmp; + cairo_surface_t *source, *proxy; + cairo_matrix_t p2d; + cairo_int_status_t status, analysis_status; + cairo_bool_t surface_is_unbounded; + cairo_bool_t unused; + + assert (pattern->type == CAIRO_PATTERN_TYPE_SURFACE); + surface_pattern = (const cairo_surface_pattern_t *) pattern; + assert (surface_pattern->surface->type == CAIRO_SURFACE_TYPE_RECORDING); + source = surface_pattern->surface; + + proxy = _cairo_surface_has_snapshot (source, &proxy_backend); + if (proxy != NULL) { + /* nothing untoward found so far */ + return CAIRO_STATUS_SUCCESS; + } + + tmp = (cairo_analysis_surface_t *) + _cairo_analysis_surface_create (surface->target); + if (unlikely (tmp->base.status)) { + status =tmp->base.status; + goto cleanup1; + } + proxy = attach_proxy (source, &tmp->base); + + p2d = pattern->matrix; + status = cairo_matrix_invert (&p2d); + assert (status == CAIRO_INT_STATUS_SUCCESS); + _cairo_analysis_surface_set_ctm (&tmp->base, &p2d); + + + source = _cairo_surface_get_source (source, NULL); + surface_is_unbounded = (pattern->extend == CAIRO_EXTEND_REPEAT + || pattern->extend == CAIRO_EXTEND_REFLECT); + status = _cairo_recording_surface_replay_and_create_regions (source, + &pattern->matrix, + &tmp->base, + surface_is_unbounded); + if (unlikely (status)) + goto cleanup2; + + /* black background or mime data fills entire extents */ + if (!(source->content & CAIRO_CONTENT_ALPHA) || _cairo_surface_has_mime_image (source)) { + cairo_rectangle_int_t rect; + + if (_cairo_surface_get_extents (source, &rect)) { + cairo_box_t bbox; + + _cairo_box_from_rectangle (&bbox, &rect); + _cairo_matrix_transform_bounding_box_fixed (&p2d, &bbox, NULL); + _cairo_box_round_to_rectangle (&bbox, &rect); + status = _add_operation (tmp, &rect, CAIRO_INT_STATUS_SUCCESS); + if (status == CAIRO_INT_STATUS_IMAGE_FALLBACK) + status = CAIRO_INT_STATUS_SUCCESS; + if (unlikely (status)) + goto cleanup2; + } + } + + if (tmp->has_supported) { + surface->has_supported = TRUE; + unused = cairo_region_union (&surface->supported_region, &tmp->supported_region); + } + + if (tmp->has_unsupported) { + surface->has_unsupported = TRUE; + unused = cairo_region_union (&surface->fallback_region, &tmp->fallback_region); + } + + analysis_status = tmp->has_unsupported ? CAIRO_INT_STATUS_IMAGE_FALLBACK : CAIRO_INT_STATUS_SUCCESS; + if (pattern->extend != CAIRO_EXTEND_NONE) { + _cairo_unbounded_rectangle_init (extents); + } else { + status = cairo_matrix_invert (&tmp->ctm); + _cairo_matrix_transform_bounding_box_fixed (&tmp->ctm, + &tmp->page_bbox, NULL); + _cairo_box_round_to_rectangle (&tmp->page_bbox, extents); + } + + cleanup2: + detach_proxy (proxy); + cleanup1: + cairo_surface_destroy (&tmp->base); + + if (unlikely (status)) + return status; + + return analysis_status; +} + static cairo_status_t _cairo_analysis_surface_finish (void *abstract_surface) { diff -Nru cairo-1.15.8/src/cairo-atomic-private.h cairo-1.15.10/src/cairo-atomic-private.h --- cairo-1.15.8/src/cairo-atomic-private.h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-atomic-private.h 2017-12-07 02:14:36.000000000 +0000 @@ -45,6 +45,8 @@ #include "config.h" #endif +#include + /* The autoconf on OpenBSD 4.5 produces the malformed constant name * SIZEOF_VOID__ rather than SIZEOF_VOID_P. Work around that here. */ #if !defined(SIZEOF_VOID_P) && defined(SIZEOF_VOID__) @@ -155,13 +157,12 @@ #endif -#if HAVE_INTEL_ATOMIC_PRIMITIVES +#if HAVE_GCC_LEGACY_ATOMICS #define HAS_ATOMIC_OPS 1 typedef int cairo_atomic_int_t; -#ifdef ATOMIC_OP_NEEDS_MEMORY_BARRIER static cairo_always_inline cairo_atomic_int_t _cairo_atomic_int_get (cairo_atomic_int_t *x) { @@ -187,12 +188,6 @@ __sync_synchronize (); return *x; } -#else -# define _cairo_atomic_int_get(x) (*x) -# define _cairo_atomic_int_get_relaxed(x) (*x) -# define _cairo_atomic_int_set_relaxed(x, val) (*x) = (val) -# define _cairo_atomic_ptr_get(x) (*x) -#endif # define _cairo_atomic_int_inc(x) ((void) __sync_fetch_and_add(x, 1)) # define _cairo_atomic_int_dec(x) ((void) __sync_fetch_and_add(x, -1)) @@ -393,6 +388,37 @@ (void) ret__; \ } while (0) +typedef cairo_atomic_int_t cairo_atomic_once_t; + +#define CAIRO_ATOMIC_ONCE_UNINITIALIZED (0) +#define CAIRO_ATOMIC_ONCE_INITIALIZING (1) +#define CAIRO_ATOMIC_ONCE_INITIALIZED (2) +#define CAIRO_ATOMIC_ONCE_INIT CAIRO_ATOMIC_ONCE_UNINITIALIZED + +static cairo_always_inline cairo_bool_t +_cairo_atomic_init_once_enter(cairo_atomic_once_t *once) +{ + if (likely(_cairo_atomic_int_get(once) == CAIRO_ATOMIC_ONCE_INITIALIZED)) + return 0; + + if (_cairo_atomic_int_cmpxchg(once, + CAIRO_ATOMIC_ONCE_UNINITIALIZED, + CAIRO_ATOMIC_ONCE_INITIALIZING)) + return 1; + + while (_cairo_atomic_int_get(once) != CAIRO_ATOMIC_ONCE_INITIALIZED) {} + return 0; +} + +static cairo_always_inline void +_cairo_atomic_init_once_leave(cairo_atomic_once_t *once) +{ + if (unlikely(!_cairo_atomic_int_cmpxchg(once, + CAIRO_ATOMIC_ONCE_INITIALIZING, + CAIRO_ATOMIC_ONCE_INITIALIZED))) + assert (0 && "incorrect use of _cairo_atomic_init_once API (once != CAIRO_ATOMIC_ONCE_INITIALIZING)"); +} + CAIRO_END_DECLS #endif diff -Nru cairo-1.15.8/src/cairo-bentley-ottmann-rectangular.c cairo-1.15.10/src/cairo-bentley-ottmann-rectangular.c --- cairo-1.15.8/src/cairo-bentley-ottmann-rectangular.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-bentley-ottmann-rectangular.c 2017-12-07 02:14:36.000000000 +0000 @@ -593,6 +593,12 @@ pqueue_push (sweep, rectangle); } +static int +sweep_line_setjmp (sweep_line_t *sweep_line) +{ + return setjmp (sweep_line->unwind); +} + static cairo_status_t _cairo_bentley_ottmann_tessellate_rectangular (rectangle_t **rectangles, int num_rectangles, @@ -609,7 +615,7 @@ rectangles, num_rectangles, fill_rule, do_traps, container); - if ((status = setjmp (sweep_line.unwind))) + if ((status = sweep_line_setjmp (&sweep_line))) return status; rectangle = rectangle_pop_start (&sweep_line); diff -Nru cairo-1.15.8/src/cairo-botor-scan-converter.c cairo-1.15.10/src/cairo-botor-scan-converter.c --- cairo-1.15.8/src/cairo-botor-scan-converter.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-botor-scan-converter.c 2017-12-07 02:14:36.000000000 +0000 @@ -2128,6 +2128,7 @@ return CAIRO_STATUS_SUCCESS; } +#if 0 static cairo_status_t _cairo_botor_scan_converter_add_edge (void *converter, const cairo_point_t *p1, @@ -2146,6 +2147,7 @@ return botor_add_edge (self, &edge); } +#endif cairo_status_t _cairo_botor_scan_converter_add_polygon (cairo_botor_scan_converter_t *converter, diff -Nru cairo-1.15.8/src/cairo-boxes.c cairo-1.15.10/src/cairo-boxes.c --- cairo-1.15.8/src/cairo-boxes.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-boxes.c 2017-12-07 22:13:32.000000000 +0000 @@ -102,7 +102,8 @@ boxes->is_pixel_aligned = n == num_boxes; } -/** +/** _cairo_boxes_limit: + * * Computes the minimum bounding box of the given list of boxes and assign * it to the given boxes set. It also assigns that list as the list of * limiting boxes in the box set. @@ -275,12 +276,13 @@ return boxes->status; } -/** +/** _cairo_boxes_extents: + * * Computes the minimum bounding box of the given box set and stores * it in the given box. * - * @param boxes the box set whose minimum bounding is computed - * @param box return buffer for the computed result + * @param boxes The box set whose minimum bounding is computed. + * @param box Return buffer for the computed result. */ void _cairo_boxes_extents (const cairo_boxes_t *boxes, @@ -334,15 +336,16 @@ boxes->is_pixel_aligned = TRUE; } -/** +/** _cairo_boxes_to_array: + * * Linearize a box set of possibly multiple chunks into one big chunk * and returns an array of boxes * - * @param boxes the box set to be converted - * @param num_boxes return buffer for the number of boxes (array count) - * @return pointer to the newly allocated array of boxes - * (the number o elements is given in num_boxes) - * */ + * @param boxes The box set to be converted. + * @param num_boxes Return buffer for the number of boxes (array count). + * @return Pointer to the newly allocated array of boxes + * (the number o elements is given in num_boxes). + */ cairo_box_t * _cairo_boxes_to_array (const cairo_boxes_t *boxes, int *num_boxes) diff -Nru cairo-1.15.8/src/cairo.c cairo-1.15.10/src/cairo.c --- cairo-1.15.8/src/cairo.c 2017-08-29 16:58:07.000000000 +0000 +++ cairo-1.15.10/src/cairo.c 2017-12-07 22:13:32.000000000 +0000 @@ -237,7 +237,7 @@ * * * # Destination Tags # {#dest} - + * * A destination is specified by enclosing the destination drawing * operations with the %CAIRO_TAG_DEST tag. * @@ -844,7 +844,7 @@ #if 0 -/** +/* * cairo_set_opacity: * @cr: a #cairo_t * @opacity: the level of opacity to use when compositing @@ -854,9 +854,7 @@ * using the alpha value. * * The default opacity is 1. - * - * Since: TBD - **/ + */ void cairo_set_opacity (cairo_t *cr, double opacity) { diff -Nru cairo-1.15.8/src/cairo-cff-subset.c cairo-1.15.10/src/cairo-cff-subset.c --- cairo-1.15.8/src/cairo-cff-subset.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-cff-subset.c 2017-12-07 02:14:36.000000000 +0000 @@ -41,7 +41,7 @@ * http://www.adobe.com/content/dam/Adobe/en/devnet/font/pdfs/5177.Type2.pdf */ -#define _BSD_SOURCE /* for snprintf(), strdup() */ +#define _DEFAULT_SOURCE /* for snprintf(), strdup() */ #include "cairoint.h" #include "cairo-array-private.h" @@ -295,20 +295,11 @@ static unsigned char * decode_real (unsigned char *p, double *real) { - const char *decimal_point; - int decimal_point_len; - int n; char buffer[100]; - char buffer2[200]; - char *q; char *buf = buffer; char *buf_end = buffer + sizeof (buffer); - - decimal_point = cairo_get_locale_decimal_point (); - decimal_point_len = strlen (decimal_point); - - assert (decimal_point_len != 0); - assert (sizeof(buffer) + decimal_point_len < sizeof(buffer2)); + char *end; + int n; p++; while (buf + 2 < buf_end) { @@ -324,19 +315,7 @@ }; *buf = 0; - buf = buffer; - if (strchr (buffer, '.')) { - q = strchr (buffer, '.'); - strncpy (buffer2, buffer, q - buffer); - buf = buffer2 + (q - buffer); - strncpy (buf, decimal_point, decimal_point_len); - buf += decimal_point_len; - strcpy (buf, q + 1); - buf = buffer2; - } - - if (sscanf(buf, "%lf", real) != 1) - *real = 0.0; + *real = _cairo_strtod (buffer, &end); return p; } diff -Nru cairo-1.15.8/src/cairo-clip-boxes.c cairo-1.15.10/src/cairo-clip-boxes.c --- cairo-1.15.8/src/cairo-clip-boxes.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-clip-boxes.c 2017-12-07 22:13:32.000000000 +0000 @@ -264,13 +264,12 @@ return _cairo_clip_intersect_rectangle_box (clip, &r, box); } -/** - * copy a box set to an clip +/* Copy a box set to a clip * - * @param box the box set to copy from - * @param clip the clip to copy to (return buffer) - * @result zero if the allocation failed - the clip will be set to all-clipped - * otherwise non-zero + * @param boxes The box set to copy from. + * @param clip The clip to copy to (return buffer). + * @returns Zero if the allocation failed (the clip will be set to + * all-clipped), otherwise non-zero. */ static cairo_bool_t _cairo_boxes_copy_to_clip (const cairo_boxes_t *boxes, cairo_clip_t *clip) diff -Nru cairo-1.15.8/src/cairo-fixed-private.h cairo-1.15.10/src/cairo-fixed-private.h --- cairo-1.15.8/src/cairo-fixed-private.h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-fixed-private.h 2017-12-07 02:13:45.000000000 +0000 @@ -223,7 +223,7 @@ if (f > 0) return ((f - 1)>>CAIRO_FIXED_FRAC_BITS) + 1; else - return - (-f >> CAIRO_FIXED_FRAC_BITS); + return - ((cairo_fixed_t)(-(cairo_fixed_unsigned_t)f) >> CAIRO_FIXED_FRAC_BITS); } /* A bunch of explicit 16.16 operators; we need these diff -Nru cairo-1.15.8/src/cairo-ft-font.c cairo-1.15.10/src/cairo-ft-font.c --- cairo-1.15.8/src/cairo-ft-font.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-ft-font.c 2017-12-07 02:14:36.000000000 +0000 @@ -38,7 +38,7 @@ * Carl Worth */ -#define _BSD_SOURCE /* for strdup() */ +#define _DEFAULT_SOURCE /* for strdup() */ #include "cairoint.h" #include "cairo-error-private.h" @@ -2658,7 +2658,7 @@ if (face->face_flags & FT_FACE_FLAG_MULTIPLE_MASTERS) { FT_MM_Var *mm_var = NULL; FT_Fixed *coords = NULL; - int num_axis, i; + int num_axis; /* If this is an MM or variable font we can't assume the current outlines * are the same as the font tables */ @@ -2682,12 +2682,16 @@ * current design coordinates are the default coordinates. In this case * the current outlines match the font tables. */ - FT_Get_Var_Design_Coordinates (face, num_axis, coords); - *is_synthetic = FALSE; - for (i = 0; i < num_axis; i++) { - if (coords[i] != mm_var->axis[i].def) { - *is_synthetic = TRUE; - break; + { + int i; + + FT_Get_Var_Design_Coordinates (face, num_axis, coords); + *is_synthetic = FALSE; + for (i = 0; i < num_axis; i++) { + if (coords[i] != mm_var->axis[i].def) { + *is_synthetic = TRUE; + break; + } } } #endif diff -Nru cairo-1.15.8/src/cairo-gl-composite.c cairo-1.15.10/src/cairo-gl-composite.c --- cairo-1.15.8/src/cairo-gl-composite.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-composite.c 2017-12-07 02:14:36.000000000 +0000 @@ -52,6 +52,93 @@ #include "cairo-error-private.h" #include "cairo-image-surface-private.h" +/* FIXME: Copy of same routine in cairo-gl-msaa-compositor.c */ +static cairo_int_status_t +_draw_int_rect (cairo_gl_context_t *ctx, + cairo_gl_composite_t *setup, + cairo_rectangle_int_t *rect) +{ + cairo_box_t box; + cairo_point_t quad[4]; + + _cairo_box_from_rectangle (&box, rect); + quad[0].x = box.p1.x; + quad[0].y = box.p1.y; + quad[1].x = box.p1.x; + quad[1].y = box.p2.y; + quad[2].x = box.p2.x; + quad[2].y = box.p2.y; + quad[3].x = box.p2.x; + quad[3].y = box.p1.y; + + return _cairo_gl_composite_emit_quad_as_tristrip (ctx, setup, quad); +} + +static cairo_int_status_t +_blit_texture_to_renderbuffer (cairo_gl_surface_t *surface) +{ + cairo_gl_context_t *ctx = NULL; + cairo_gl_composite_t setup; + cairo_surface_pattern_t pattern; + cairo_rectangle_int_t extents; + cairo_int_status_t status; + + /* FIXME: This only permits blit when glesv3 is enabled. But note that + glesv2 with the ANGLE extension should also be able to support this feature, + so once the ANGLE support code is in place this check can be relaxed. */ + if (((cairo_gl_context_t *)surface->base.device)->gl_flavor != CAIRO_GL_FLAVOR_ES3) + return CAIRO_INT_STATUS_SUCCESS; + + if (! surface->content_in_texture) + return CAIRO_INT_STATUS_SUCCESS; + + memset (&setup, 0, sizeof (cairo_gl_composite_t)); + + status = _cairo_gl_composite_set_operator (&setup, + CAIRO_OPERATOR_SOURCE, + FALSE); + + if (status) + return status; + + setup.dst = surface; + setup.clip_region = surface->clip_region; + + _cairo_pattern_init_for_surface (&pattern, &surface->base); + status = _cairo_gl_composite_set_source (&setup, &pattern.base, + NULL, NULL, FALSE); + _cairo_pattern_fini (&pattern.base); + + if (unlikely (status)) + goto FAIL; + + _cairo_gl_composite_set_multisample (&setup); + + status = _cairo_gl_composite_begin (&setup, &ctx); + + if (unlikely (status)) + goto FAIL; + + extents.x = extents.y = 0; + extents.width = surface->width; + extents.height = surface->height; + + status = _draw_int_rect (ctx, &setup, &extents); + + if (status == CAIRO_INT_STATUS_SUCCESS) + surface->content_in_texture = FALSE; + +FAIL: + _cairo_gl_composite_fini (&setup); + + if (ctx) { + _cairo_gl_composite_flush (ctx); + status = _cairo_gl_context_release (ctx, status); + } + + return status; +} + cairo_int_status_t _cairo_gl_composite_set_source (cairo_gl_composite_t *setup, const cairo_pattern_t *pattern, @@ -68,8 +155,13 @@ _cairo_gl_composite_set_source_operand (cairo_gl_composite_t *setup, const cairo_gl_operand_t *source) { + cairo_int_status_t status; + _cairo_gl_operand_destroy (&setup->src); _cairo_gl_operand_copy (&setup->src, source); + + if (source->type == CAIRO_GL_OPERAND_TEXTURE) + status = _cairo_gl_surface_resolve_multisampling (source->texture.surface); } void @@ -99,9 +191,13 @@ _cairo_gl_composite_set_mask_operand (cairo_gl_composite_t *setup, const cairo_gl_operand_t *mask) { + cairo_int_status_t status; _cairo_gl_operand_destroy (&setup->mask); - if (mask) + if (mask) { _cairo_gl_operand_copy (&setup->mask, mask); + if (mask->type == CAIRO_GL_OPERAND_TEXTURE) + status = _cairo_gl_surface_resolve_multisampling (mask->texture.surface); + } } void @@ -174,7 +270,8 @@ switch (extend) { case CAIRO_EXTEND_NONE: - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3 || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) wrap_mode = GL_CLAMP_TO_EDGE; else wrap_mode = GL_CLAMP_TO_BORDER; @@ -1178,6 +1275,8 @@ { cairo_status_t status; + status = _blit_texture_to_renderbuffer (dst); + memset (setup, 0, sizeof (cairo_gl_composite_t)); status = _cairo_gl_composite_set_operator (setup, op, diff -Nru cairo-1.15.8/src/cairo-gl-device.c cairo-1.15.10/src/cairo-gl-device.c --- cairo-1.15.8/src/cairo-gl-device.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-device.c 2017-12-07 02:14:36.000000000 +0000 @@ -171,7 +171,8 @@ if (gl_flavor == CAIRO_GL_FLAVOR_DESKTOP) return TRUE; - assert (gl_flavor == CAIRO_GL_FLAVOR_ES2); + assert (gl_flavor == CAIRO_GL_FLAVOR_ES3 || + gl_flavor == CAIRO_GL_FLAVOR_ES2); /* For OpenGL ES we have to look for the specific extension and BGRA only * matches cairo's integer packed bytes on little-endian machines. */ @@ -190,7 +191,8 @@ int n; cairo_bool_t is_desktop = gl_flavor == CAIRO_GL_FLAVOR_DESKTOP; - cairo_bool_t is_gles = gl_flavor == CAIRO_GL_FLAVOR_ES2; + cairo_bool_t is_gles = (gl_flavor == CAIRO_GL_FLAVOR_ES3 || + gl_flavor == CAIRO_GL_FLAVOR_ES2); _cairo_device_init (&ctx->base, &_cairo_gl_device_backend); @@ -263,25 +265,31 @@ } #endif -#if CAIRO_HAS_GLESV2_SURFACE && defined(GL_MAX_SAMPLES_EXT) +#if CAIRO_HAS_GLESV3_SURFACE + if (is_gles && ctx->has_packed_depth_stencil) { + glGetIntegerv(GL_MAX_SAMPLES, &ctx->num_samples); + } + +#elif CAIRO_HAS_GLESV2_SURFACE && defined(GL_MAX_SAMPLES_EXT) if (is_gles && ctx->has_packed_depth_stencil && _cairo_gl_has_extension ("GL_EXT_multisampled_render_to_texture")) { glGetIntegerv(GL_MAX_SAMPLES_EXT, &ctx->num_samples); } -#endif -#if CAIRO_HAS_GLESV2_SURFACE && defined(GL_MAX_SAMPLES_IMG) if (is_gles && ctx->has_packed_depth_stencil && _cairo_gl_has_extension ("GL_IMG_multisampled_render_to_texture")) { glGetIntegerv(GL_MAX_SAMPLES_IMG, &ctx->num_samples); } #endif - ctx->supports_msaa = ctx->num_samples > 1; + /* we always use renderbuffer for rendering in glesv3 */ + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) + ctx->supports_msaa = TRUE; + else + ctx->supports_msaa = ctx->num_samples > 1; if (ctx->num_samples > MAX_MSAA_SAMPLES) ctx->num_samples = MAX_MSAA_SAMPLES; - ctx->current_operator = -1; ctx->gl_flavor = gl_flavor; @@ -349,13 +357,15 @@ return GL_DEPTH_STENCIL; #endif -#if CAIRO_HAS_GLESV2_SURFACE +#if CAIRO_HAS_GLESV2_SURFACE && !CAIRO_HAS_GLESV3_SURFACE if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP) return GL_DEPTH24_STENCIL8_OES; #endif #if CAIRO_HAS_GL_SURFACE return GL_DEPTH_STENCIL; +#elif CAIRO_HAS_GLESV3_SURFACE + return GL_DEPTH24_STENCIL8; #elif CAIRO_HAS_GLESV2_SURFACE return GL_DEPTH24_STENCIL8_OES; #endif @@ -381,7 +391,7 @@ } #endif -static void +void _cairo_gl_ensure_framebuffer (cairo_gl_context_t *ctx, cairo_gl_surface_t *surface) { @@ -436,13 +446,14 @@ str, status); } } -#if CAIRO_HAS_GL_SURFACE +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV3_SURFACE static void _cairo_gl_ensure_multisampling (cairo_gl_context_t *ctx, cairo_gl_surface_t *surface) { assert (surface->supports_msaa); - assert (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP); + assert (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3); if (surface->msaa_fb) return; @@ -460,7 +471,11 @@ this information. */ ctx->dispatch.RenderbufferStorageMultisample (GL_RENDERBUFFER, ctx->num_samples, +#if CAIRO_HAS_GLESV3_SURFACE + GL_RGBA8, +#else GL_RGBA, +#endif surface->width, surface->height); ctx->dispatch.FramebufferRenderbuffer (GL_FRAMEBUFFER, @@ -472,6 +487,11 @@ glDisable (GL_SCISSOR_TEST); glClearColor (0, 0, 0, 0); glClear (GL_COLOR_BUFFER_BIT); + + /* for glesv3 with multisample renderbuffer, we always render to + this renderbuffer */ + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) + surface->msaa_active = TRUE; } #endif @@ -484,8 +504,9 @@ return TRUE; _cairo_gl_ensure_framebuffer (ctx, surface); -#if CAIRO_HAS_GL_SURFACE - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP) +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV3_SURFACE + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) _cairo_gl_ensure_multisampling (ctx, surface); #endif @@ -499,8 +520,9 @@ surface->width, surface->height); -#if CAIRO_HAS_GL_SURFACE - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP) { +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV3_SURFACE + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) { dispatch->FramebufferRenderbuffer (GL_FRAMEBUFFER, GL_DEPTH_STENCIL_ATTACHMENT, GL_RENDERBUFFER, @@ -615,7 +637,7 @@ #undef M } -#if CAIRO_HAS_GL_SURFACE +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV3_SURFACE static void bind_multisample_framebuffer (cairo_gl_context_t *ctx, cairo_gl_surface_t *surface) @@ -624,14 +646,19 @@ cairo_bool_t scissor_test_enabled; assert (surface->supports_msaa); - assert (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP); + assert (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3); _cairo_gl_ensure_framebuffer (ctx, surface); _cairo_gl_ensure_multisampling (ctx, surface); if (surface->msaa_active) { +#if CAIRO_HAS_GL_SURFACE glEnable (GL_MULTISAMPLE); +#endif ctx->dispatch.BindFramebuffer (GL_FRAMEBUFFER, surface->msaa_fb); + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) + surface->content_in_texture = FALSE; return; } @@ -642,7 +669,9 @@ glDisable (GL_STENCIL_TEST); glDisable (GL_SCISSOR_TEST); +#if CAIRO_HAS_GL_SURFACE glEnable (GL_MULTISAMPLE); +#endif /* The last time we drew to the surface, we were not using multisampling, so we need to blit from the non-multisampling framebuffer into the @@ -651,17 +680,24 @@ ctx->dispatch.BindFramebuffer (GL_READ_FRAMEBUFFER, surface->fb); ctx->dispatch.BlitFramebuffer (0, 0, surface->width, surface->height, 0, 0, surface->width, surface->height, - GL_COLOR_BUFFER_BIT, GL_NEAREST); + GL_COLOR_BUFFER_BIT +#if CAIRO_HAS_GL_SURFACE + | GL_STENCIL_BUFFER_BIT +#endif + , + GL_NEAREST); ctx->dispatch.BindFramebuffer (GL_FRAMEBUFFER, surface->msaa_fb); if (stencil_test_enabled) glEnable (GL_STENCIL_TEST); if (scissor_test_enabled) glEnable (GL_SCISSOR_TEST); + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) + surface->content_in_texture = FALSE; } #endif -#if CAIRO_HAS_GL_SURFACE +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV3_SURFACE static void bind_singlesample_framebuffer (cairo_gl_context_t *ctx, cairo_gl_surface_t *surface) @@ -669,11 +705,15 @@ cairo_bool_t stencil_test_enabled; cairo_bool_t scissor_test_enabled; - assert (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP); + assert (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3); _cairo_gl_ensure_framebuffer (ctx, surface); if (! surface->msaa_active) { +#if CAIRO_HAS_GL_SURFACE glDisable (GL_MULTISAMPLE); +#endif + ctx->dispatch.BindFramebuffer (GL_FRAMEBUFFER, surface->fb); return; } @@ -685,7 +725,9 @@ glDisable (GL_STENCIL_TEST); glDisable (GL_SCISSOR_TEST); +#if CAIRO_HAS_GL_SURFACE glDisable (GL_MULTISAMPLE); +#endif /* The last time we drew to the surface, we were using multisampling, so we need to blit from the multisampling framebuffer into the @@ -718,7 +760,7 @@ return; } -#if CAIRO_HAS_GL_SURFACE +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV3_SURFACE if (multisampling) bind_multisample_framebuffer (ctx, surface); else @@ -737,7 +779,8 @@ #endif } - surface->msaa_active = multisampling; + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP) + surface->msaa_active = multisampling; } void @@ -751,9 +794,13 @@ * we create an OpenGL ES surface, so we can never switch modes. */ if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) multisampling = surface->msaa_active; + /* For GLESV3, we always use renderbuffer for drawing */ + else if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) + multisampling = TRUE; changing_surface = ctx->current_target != surface || surface->needs_update; - changing_sampling = surface->msaa_active != multisampling; + changing_sampling = (surface->msaa_active != multisampling || + surface->content_in_texture); if (! changing_surface && ! changing_sampling) return; diff -Nru cairo-1.15.8/src/cairo-gl-dispatch.c cairo-1.15.10/src/cairo-gl-dispatch.c --- cairo-1.15.8/src/cairo-gl-dispatch.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-dispatch.c 2017-12-07 02:14:36.000000000 +0000 @@ -124,6 +124,10 @@ else return CAIRO_STATUS_DEVICE_ERROR; } + else if (gl_flavor == CAIRO_GL_FLAVOR_ES3) + { + dispatch_name = CAIRO_GL_DISPATCH_NAME_CORE; + } else if (gl_flavor == CAIRO_GL_FLAVOR_ES2 && gl_version >= CAIRO_GL_VERSION_ENCODE (2, 0)) { @@ -156,6 +160,10 @@ else return CAIRO_STATUS_DEVICE_ERROR; } + else if (gl_flavor == CAIRO_GL_FLAVOR_ES3) + { + dispatch_name = CAIRO_GL_DISPATCH_NAME_CORE; + } else if (gl_flavor == CAIRO_GL_FLAVOR_ES2 && gl_version >= CAIRO_GL_VERSION_ENCODE (2, 0)) { @@ -189,6 +197,10 @@ else return CAIRO_STATUS_DEVICE_ERROR; } + else if (gl_flavor == CAIRO_GL_FLAVOR_ES3) + { + dispatch_name = CAIRO_GL_DISPATCH_NAME_CORE; + } else if (gl_flavor == CAIRO_GL_FLAVOR_ES2 && gl_version >= CAIRO_GL_VERSION_ENCODE (2, 0)) { diff -Nru cairo-1.15.8/src/cairo-gl-gradient.c cairo-1.15.10/src/cairo-gl-gradient.c --- cairo-1.15.8/src/cairo-gl-gradient.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-gradient.c 2017-12-07 02:14:36.000000000 +0000 @@ -282,7 +282,8 @@ * In OpenGL ES 2.0 no format conversion is allowed i.e. 'internalFormat' * must match 'format' in glTexImage2D. */ - if (_cairo_gl_get_flavor () == CAIRO_GL_FLAVOR_ES2) + if (_cairo_gl_get_flavor () == CAIRO_GL_FLAVOR_ES3 || + _cairo_gl_get_flavor () == CAIRO_GL_FLAVOR_ES2) internal_format = GL_BGRA; else internal_format = GL_RGBA; diff -Nru cairo-1.15.8/src/cairo-gl-gradient-private.h cairo-1.15.10/src/cairo-gl-gradient-private.h --- cairo-1.15.8/src/cairo-gl-gradient-private.h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-gradient-private.h 2017-12-07 02:14:36.000000000 +0000 @@ -51,12 +51,15 @@ #include "cairo-gl.h" -#if CAIRO_HAS_GL_SURFACE -#include -#include +#if CAIRO_HAS_GLESV3_SURFACE +#include +#include #elif CAIRO_HAS_GLESV2_SURFACE #include #include +#elif CAIRO_HAS_GL_SURFACE +#include +#include #endif #define CAIRO_GL_GRADIENT_CACHE_SIZE 4096 diff -Nru cairo-1.15.8/src/cairo-gl.h cairo-1.15.10/src/cairo-gl.h --- cairo-1.15.8/src/cairo-gl.h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl.h 2017-12-07 02:14:36.000000000 +0000 @@ -62,7 +62,7 @@ #include "cairo.h" -#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV2_SURFACE +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV2_SURFACE || CAIRO_HAS_GLESV3_SURFACE CAIRO_BEGIN_DECLS diff -Nru cairo-1.15.8/src/cairo-gl-info.c cairo-1.15.10/src/cairo-gl-info.c --- cairo-1.15.8/src/cairo-gl-info.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-info.c 2017-12-07 02:14:36.000000000 +0000 @@ -65,6 +65,8 @@ if (version == NULL) flavor = CAIRO_GL_FLAVOR_NONE; + else if (strstr (version, "OpenGL ES 3") != NULL) + flavor = CAIRO_GL_FLAVOR_ES3; else if (strstr (version, "OpenGL ES 2") != NULL) flavor = CAIRO_GL_FLAVOR_ES2; else diff -Nru cairo-1.15.8/src/cairo-gl-msaa-compositor.c cairo-1.15.10/src/cairo-gl-msaa-compositor.c --- cairo-1.15.8/src/cairo-gl-msaa-compositor.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-msaa-compositor.c 2017-12-07 02:14:36.000000000 +0000 @@ -273,6 +273,8 @@ can_use_msaa_compositor (cairo_gl_surface_t *surface, cairo_antialias_t antialias) { + cairo_gl_flavor_t gl_flavor = ((cairo_gl_context_t *) surface->base.device)->gl_flavor; + query_surface_capabilities (surface); if (! surface->supports_stencil) return FALSE; @@ -280,8 +282,10 @@ /* Multisampling OpenGL ES surfaces only maintain one multisampling framebuffer and thus must use the spans compositor to do non-antialiased rendering. */ - if (((cairo_gl_context_t *) surface->base.device)->gl_flavor == CAIRO_GL_FLAVOR_ES2 + if ((gl_flavor == CAIRO_GL_FLAVOR_ES3 || + gl_flavor == CAIRO_GL_FLAVOR_ES2) && surface->supports_msaa + && surface->num_samples > 1 && antialias == CAIRO_ANTIALIAS_NONE) return FALSE; @@ -378,6 +382,9 @@ FALSE); if (unlikely (status)) goto finish; + + _cairo_gl_context_set_destination (ctx, dst, setup.multisample); + status = _cairo_gl_set_operands_and_operator (&setup, ctx); if (unlikely (status)) goto finish; @@ -634,6 +641,7 @@ glGetIntegerv(GL_STENCIL_BITS, &stencil_bits); surface->supports_stencil = stencil_bits > 0; surface->supports_msaa = samples > 1; + surface->num_samples = samples; status = _cairo_gl_context_release (ctx, status); } @@ -936,10 +944,13 @@ const cairo_compositor_t * _cairo_gl_msaa_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_compositor_t compositor; - if (compositor.delegate == NULL) + if (_cairo_atomic_init_once_enter(&once)) { _cairo_gl_msaa_compositor_init (&compositor, _cairo_gl_span_compositor_get ()); + _cairo_atomic_init_once_leave(&once); + } return &compositor; } diff -Nru cairo-1.15.8/src/cairo-gl-operand.c cairo-1.15.10/src/cairo-gl-operand.c --- cairo-1.15.8/src/cairo-gl-operand.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-operand.c 2017-12-07 02:14:36.000000000 +0000 @@ -658,7 +658,8 @@ * with CAIRO_EXTEND_NONE). When bilinear filtering is enabled, * these shaders need the texture dimensions for their calculations. */ - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2 && + if ((ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3 || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) && _cairo_gl_operand_get_extend (operand) == CAIRO_EXTEND_NONE && _cairo_gl_operand_get_gl_filter (operand) == GL_LINEAR) { diff -Nru cairo-1.15.8/src/cairo-gl-private.h cairo-1.15.10/src/cairo-gl-private.h --- cairo-1.15.8/src/cairo-gl-private.h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-private.h 2017-12-07 02:14:36.000000000 +0000 @@ -60,12 +60,15 @@ #include -#if CAIRO_HAS_GL_SURFACE -#include -#include +#if CAIRO_HAS_GLESV3_SURFACE +#include +#include #elif CAIRO_HAS_GLESV2_SURFACE #include #include +#elif CAIRO_HAS_GL_SURFACE +#include +#include #endif #include "cairo-gl-ext-def-private.h" @@ -99,11 +102,12 @@ typedef struct _cairo_gl_surface cairo_gl_surface_t; -/* GL flavor */ +/* GL flavor is the type of GL supported by the underlying platform. */ typedef enum cairo_gl_flavor { CAIRO_GL_FLAVOR_NONE = 0, CAIRO_GL_FLAVOR_DESKTOP = 1, - CAIRO_GL_FLAVOR_ES2 = 2 + CAIRO_GL_FLAVOR_ES2 = 2, + CAIRO_GL_FLAVOR_ES3 = 3 } cairo_gl_flavor_t; /* Indices for vertex attributes used by BindAttribLocation, etc. */ @@ -169,7 +173,7 @@ GLuint fb; /* GL framebuffer object wrapping our data. */ GLuint depth_stencil; /* GL renderbuffer object for holding stencil buffer clip. */ -#if CAIRO_HAS_GL_SURFACE +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV3_SURFACE GLuint msaa_rb; /* The ARB MSAA path uses a renderbuffer. */ GLuint msaa_fb; #endif @@ -178,8 +182,12 @@ cairo_bool_t stencil_and_msaa_caps_initialized; cairo_bool_t supports_stencil; /* Stencil support for for non-texture surfaces. */ cairo_bool_t supports_msaa; + GLint num_samples; cairo_bool_t msaa_active; /* Whether the multisampling framebuffer is active or not. */ + cairo_bool_t content_in_texture; /* whether we just uploaded image + to texture, used for certain + gles2 extensions and glesv3 */ cairo_clip_t *clip_on_stencil_buffer; int owns_tex; @@ -801,6 +809,10 @@ cairo_composite_glyphs_info_t *info, cairo_clip_t *clip); +cairo_private void +_cairo_gl_ensure_framebuffer (cairo_gl_context_t *ctx, + cairo_gl_surface_t *surface); + cairo_private cairo_surface_t * _cairo_gl_surface_create_scratch (cairo_gl_context_t *ctx, cairo_content_t content, diff -Nru cairo-1.15.8/src/cairo-gl-shaders.c cairo-1.15.10/src/cairo-gl-shaders.c --- cairo-1.15.8/src/cairo-gl-shaders.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-shaders.c 2017-12-07 02:14:36.000000000 +0000 @@ -398,7 +398,8 @@ "vec4 get_%s()\n" "{\n", rectstr, namestr, namestr, namestr, namestr); - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2 && + if ((ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3 || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) && _cairo_gl_shader_needs_border_fade (op)) { _cairo_output_stream_printf (stream, @@ -425,7 +426,8 @@ "vec4 get_%s()\n" "{\n", namestr, namestr, rectstr, namestr, namestr); - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2 && + if ((ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3 || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) && _cairo_gl_shader_needs_border_fade (op)) { _cairo_output_stream_printf (stream, @@ -462,7 +464,8 @@ " float is_valid = step (-%s_radius_0, t * %s_circle_d.z);\n", namestr, namestr, rectstr, namestr, namestr, namestr, namestr, namestr, namestr, namestr, namestr, namestr); - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2 && + if ((ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3 || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) && _cairo_gl_shader_needs_border_fade (op)) { _cairo_output_stream_printf (stream, @@ -507,7 +510,8 @@ " float upper_t = mix (t.y, t.x, is_valid.x);\n", namestr, namestr, rectstr, namestr, namestr, namestr, namestr, namestr, namestr, namestr, namestr, namestr, namestr); - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2 && + if ((ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3 || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) && _cairo_gl_shader_needs_border_fade (op)) { _cairo_output_stream_printf (stream, @@ -674,7 +678,8 @@ _cairo_gl_shader_emit_wrap (ctx, stream, src, CAIRO_GL_TEX_SOURCE); _cairo_gl_shader_emit_wrap (ctx, stream, mask, CAIRO_GL_TEX_MASK); - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) { + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3 || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES2) { if (_cairo_gl_shader_needs_border_fade (src)) _cairo_gl_shader_emit_border_fade (stream, src, CAIRO_GL_TEX_SOURCE); if (_cairo_gl_shader_needs_border_fade (mask)) diff -Nru cairo-1.15.8/src/cairo-gl-spans-compositor.c cairo-1.15.10/src/cairo-gl-spans-compositor.c --- cairo-1.15.8/src/cairo-gl-spans-compositor.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-spans-compositor.c 2017-12-07 02:14:36.000000000 +0000 @@ -528,10 +528,11 @@ const cairo_compositor_t * _cairo_gl_span_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_spans_compositor_t spans; static cairo_compositor_t shape; - if (spans.base.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { /* The fallback to traps here is essentially just for glyphs... */ _cairo_shape_mask_compositor_init (&shape, _cairo_gl_traps_compositor_get()); @@ -547,6 +548,8 @@ //spans.check_span_renderer = check_span_renderer; spans.renderer_init = _cairo_gl_span_renderer_init; spans.renderer_fini = _cairo_gl_span_renderer_fini; + + _cairo_atomic_init_once_leave(&once); } return &spans.base; diff -Nru cairo-1.15.8/src/cairo-gl-surface.c cairo-1.15.10/src/cairo-gl-surface.c --- cairo-1.15.8/src/cairo-gl-surface.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-surface.c 2017-12-07 02:14:36.000000000 +0000 @@ -395,6 +395,7 @@ surface->width = width; surface->height = height; surface->needs_update = FALSE; + surface->content_in_texture = FALSE; _cairo_gl_surface_embedded_operand_init (surface); } @@ -433,6 +434,7 @@ _cairo_gl_surface_init (&ctx->base, surface, content, width, height); surface->supports_msaa = ctx->supports_msaa; + surface->num_samples = ctx->num_samples; surface->supports_stencil = TRUE; /* Create the texture used to store the surface's data. */ @@ -868,12 +870,54 @@ cairo_image_surface_t *clone = NULL; cairo_gl_context_t *ctx; int cpp; + cairo_image_surface_t *rgba_clone = NULL; cairo_int_status_t status = CAIRO_INT_STATUS_SUCCESS; status = _cairo_gl_context_acquire (dst->base.device, &ctx); if (unlikely (status)) return status; + if (_cairo_gl_get_flavor () == CAIRO_GL_FLAVOR_ES3 || + _cairo_gl_get_flavor () == CAIRO_GL_FLAVOR_ES2) { + pixman_format_code_t pixman_format; + cairo_surface_pattern_t pattern; + cairo_bool_t require_conversion = FALSE; + pixman_format = _cairo_is_little_endian () ? PIXMAN_a8b8g8r8 : PIXMAN_r8g8b8a8; + + if (src->base.content != CAIRO_CONTENT_ALPHA) { + if (src->pixman_format != pixman_format) + require_conversion = TRUE; + } + else if (dst->base.content != CAIRO_CONTENT_ALPHA) { + require_conversion = TRUE; + } + else if (src->pixman_format != PIXMAN_a8) { + pixman_format = PIXMAN_a8; + require_conversion = TRUE; + } + + if (require_conversion) { + rgba_clone = (cairo_image_surface_t *) + _cairo_image_surface_create_with_pixman_format (NULL, + pixman_format, + src->width, + src->height, + 0); + if (unlikely (rgba_clone->base.status)) + goto FAIL; + + _cairo_pattern_init_for_surface (&pattern, &src->base); + status = _cairo_surface_paint (&rgba_clone->base, + CAIRO_OPERATOR_SOURCE, + &pattern.base, NULL); + _cairo_pattern_fini (&pattern.base); + if (unlikely (status)) + goto FAIL; + + src = rgba_clone; + } + } + if (! _cairo_gl_get_image_format_and_type (ctx->gl_flavor, src->pixman_format, &internal_format, @@ -938,10 +982,19 @@ else { glPixelStorei (GL_UNPACK_ALIGNMENT, 4); - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP) + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) glPixelStorei (GL_UNPACK_ROW_LENGTH, src->stride / cpp); } + /* we must resolve the renderbuffer to texture before we + upload image */ + status = _cairo_gl_surface_resolve_multisampling (dst); + if (unlikely (status)) { + free (data_start_gles2); + goto FAIL; + } + _cairo_gl_context_activate (ctx, CAIRO_GL_TEX_TEMP); glBindTexture (ctx->tex_target, dst->tex); glTexParameteri (ctx->tex_target, GL_TEXTURE_MIN_FILTER, GL_NEAREST); @@ -961,6 +1014,8 @@ dst_x, dst_y, width, height); } + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) + dst->content_in_texture = TRUE; } else { cairo_surface_t *tmp; @@ -1000,6 +1055,8 @@ } cairo_surface_destroy (tmp); + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) + dst->content_in_texture = TRUE; } FAIL: @@ -1008,6 +1065,9 @@ if (clone) cairo_surface_destroy (&clone->base); + if (rgba_clone) + cairo_surface_destroy (&rgba_clone->base); + return status; } @@ -1047,7 +1107,7 @@ if (surface->msaa_depth_stencil) ctx->dispatch.DeleteRenderbuffers (1, &surface->msaa_depth_stencil); -#if CAIRO_HAS_GL_SURFACE +#if CAIRO_HAS_GL_SURFACE || CAIRO_HAS_GLESV3_SURFACE if (surface->msaa_fb) ctx->dispatch.DeleteFramebuffers (1, &surface->msaa_fb); if (surface->msaa_rb) @@ -1099,7 +1159,8 @@ return NULL; } - if (_cairo_gl_surface_flavor (surface) == CAIRO_GL_FLAVOR_ES2) { + if (_cairo_gl_surface_flavor (surface) == CAIRO_GL_FLAVOR_ES3 || + _cairo_gl_surface_flavor (surface) == CAIRO_GL_FLAVOR_ES2) { /* If only RGBA is supported, we must download data in a compatible * format. This means that pixman will convert the data on the CPU when * interacting with other image surfaces. For ALPHA, GLES2 does not @@ -1148,13 +1209,29 @@ * fall back instead. */ _cairo_gl_composite_flush (ctx); - _cairo_gl_context_set_destination (ctx, surface, FALSE); + + if (ctx->gl_flavor != CAIRO_GL_FLAVOR_ES3) { + _cairo_gl_context_set_destination (ctx, surface, FALSE); + } else { + if (surface->content_in_texture) { + _cairo_gl_ensure_framebuffer (ctx, surface); + ctx->dispatch.BindFramebuffer (GL_FRAMEBUFFER, surface->fb); + } else { + status = _cairo_gl_surface_resolve_multisampling (surface); + if (unlikely (status)) { + status = _cairo_gl_context_release (ctx, status); + cairo_surface_destroy (&image->base); + return _cairo_image_surface_create_in_error (status); + } + } + } flipped = ! _cairo_gl_surface_is_texture (surface); mesa_invert = flipped && ctx->has_mesa_pack_invert; glPixelStorei (GL_PACK_ALIGNMENT, 4); - if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP) + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_DESKTOP || + ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) glPixelStorei (GL_PACK_ROW_LENGTH, image->stride / cpp); if (mesa_invert) glPixelStorei (GL_PACK_INVERT_MESA, 1); @@ -1321,6 +1398,9 @@ /* GLES surfaces do not need explicit resolution. */ if (((cairo_gl_context_t *) surface->base.device)->gl_flavor == CAIRO_GL_FLAVOR_ES2) return CAIRO_INT_STATUS_SUCCESS; + else if (((cairo_gl_context_t *) surface->base.device)->gl_flavor == CAIRO_GL_FLAVOR_ES3 && + surface->content_in_texture) + return CAIRO_INT_STATUS_SUCCESS; if (! _cairo_gl_surface_is_texture (surface)) return CAIRO_INT_STATUS_SUCCESS; @@ -1329,10 +1409,20 @@ if (unlikely (status)) return status; - ctx->current_target = surface; +#if CAIRO_HAS_GLESV3_SURFACE + _cairo_gl_composite_flush (ctx); + ctx->current_target = NULL; + _cairo_gl_context_bind_framebuffer (ctx, surface, FALSE); + if (ctx->gl_flavor == CAIRO_GL_FLAVOR_ES3) + surface->content_in_texture = TRUE; -#if CAIRO_HAS_GL_SURFACE +#elif CAIRO_HAS_GL_SURFACE + ctx->current_target = surface; _cairo_gl_context_bind_framebuffer (ctx, surface, FALSE); + +#else + ctx->current_target = surface; + #endif status = _cairo_gl_context_release (ctx, status); diff -Nru cairo-1.15.8/src/cairo-gl-traps-compositor.c cairo-1.15.10/src/cairo-gl-traps-compositor.c --- cairo-1.15.8/src/cairo-gl-traps-compositor.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gl-traps-compositor.c 2017-12-07 02:14:36.000000000 +0000 @@ -303,36 +303,6 @@ return image->status; } - /* GLES2 only supports RGB/RGBA when uploading */ - if (_cairo_gl_get_flavor () == CAIRO_GL_FLAVOR_ES2) { - cairo_surface_pattern_t pattern; - cairo_surface_t *rgba_image; - - /* XXX perform this fixup inside _cairo_gl_draw_image() */ - - rgba_image = - _cairo_image_surface_create_with_pixman_format (NULL, - _cairo_is_little_endian () ? PIXMAN_a8b8g8r8 : PIXMAN_r8g8b8a8, - extents->width, - extents->height, - 0); - if (unlikely (rgba_image->status)) - return rgba_image->status; - - _cairo_pattern_init_for_surface (&pattern, image); - status = _cairo_surface_paint (rgba_image, CAIRO_OPERATOR_SOURCE, - &pattern.base, NULL); - _cairo_pattern_fini (&pattern.base); - - cairo_surface_destroy (image); - image = rgba_image; - - if (unlikely (status)) { - cairo_surface_destroy (image); - return status; - } - } - mask = _cairo_surface_create_scratch (_dst, CAIRO_CONTENT_COLOR_ALPHA, extents->width, @@ -530,9 +500,10 @@ const cairo_compositor_t * _cairo_gl_traps_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_traps_compositor_t compositor; - if (compositor.base.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { _cairo_traps_compositor_init (&compositor, &_cairo_fallback_compositor); compositor.acquire = acquire; compositor.release = release; @@ -552,6 +523,8 @@ compositor.composite_tristrip = composite_tristrip; compositor.check_composite_glyphs = _cairo_gl_check_composite_glyphs; compositor.composite_glyphs = _cairo_gl_composite_glyphs; + + _cairo_atomic_init_once_leave(&once); } return &compositor.base; diff -Nru cairo-1.15.8/src/cairo-gstate.c cairo-1.15.10/src/cairo-gstate.c --- cairo-1.15.8/src/cairo-gstate.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-gstate.c 2017-12-07 02:14:36.000000000 +0000 @@ -45,12 +45,6 @@ #include "cairo-pattern-private.h" #include "cairo-traps-private.h" -#if _XOPEN_SOURCE >= 600 || defined (_ISOC99_SOURCE) -#define ISFINITE(x) isfinite (x) -#else -#define ISFINITE(x) ((x) * (x) >= 0.) /* check for NaNs */ -#endif - static cairo_status_t _cairo_gstate_init_copy (cairo_gstate_t *gstate, cairo_gstate_t *other); diff -Nru cairo-1.15.8/src/cairo.h cairo-1.15.10/src/cairo.h --- cairo-1.15.8/src/cairo.h 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo.h 2017-12-07 02:14:36.000000000 +0000 @@ -2453,6 +2453,10 @@ #define CAIRO_MIME_TYPE_JBIG2 "application/x-cairo.jbig2" #define CAIRO_MIME_TYPE_JBIG2_GLOBAL "application/x-cairo.jbig2-global" #define CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID "application/x-cairo.jbig2-global-id" +#define CAIRO_MIME_TYPE_CCITT_FAX "image/g3fax" +#define CAIRO_MIME_TYPE_CCITT_FAX_PARAMS "application/x-cairo.ccitt.params" +#define CAIRO_MIME_TYPE_EPS "application/postscript" +#define CAIRO_MIME_TYPE_EPS_PARAMS "application/x-cairo.eps.params" cairo_public void cairo_surface_get_mime_data (cairo_surface_t *surface, diff -Nru cairo-1.15.8/src/cairo-image-compositor.c cairo-1.15.10/src/cairo-image-compositor.c --- cairo-1.15.8/src/cairo-image-compositor.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-image-compositor.c 2017-12-07 02:14:36.000000000 +0000 @@ -1244,11 +1244,12 @@ const cairo_compositor_t * _cairo_image_traps_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_traps_compositor_t compositor; - if (compositor.base.delegate == NULL) { - _cairo_traps_compositor_init (&compositor, - &__cairo_no_compositor); + if (_cairo_atomic_init_once_enter(&once)) { + _cairo_traps_compositor_init(&compositor, + &__cairo_no_compositor); compositor.acquire = acquire; compositor.release = release; compositor.set_clip_region = set_clip_region; @@ -1269,6 +1270,8 @@ #endif compositor.check_composite_glyphs = check_composite_glyphs; compositor.composite_glyphs = composite_glyphs; + + _cairo_atomic_init_once_leave(&once); } return &compositor.base; @@ -1277,9 +1280,10 @@ const cairo_compositor_t * _cairo_image_mask_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_mask_compositor_t compositor; - if (compositor.base.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { _cairo_mask_compositor_init (&compositor, _cairo_image_traps_compositor_get ()); compositor.acquire = acquire; @@ -1296,6 +1300,8 @@ compositor.composite_boxes = composite_boxes; compositor.check_composite_glyphs = check_composite_glyphs; compositor.composite_glyphs = composite_glyphs; + + _cairo_atomic_init_once_leave(&once); } return &compositor.base; @@ -1575,7 +1581,7 @@ pixman_image_t *src, *mask; union { struct fill { - int stride; + ptrdiff_t stride; uint8_t *data; uint32_t pixel; } fill; @@ -1594,7 +1600,7 @@ struct finish { cairo_rectangle_int_t extents; int src_x, src_y; - int stride; + ptrdiff_t stride; uint8_t *data; } mask; } u; @@ -3105,10 +3111,11 @@ const cairo_compositor_t * _cairo_image_spans_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_spans_compositor_t spans; static cairo_compositor_t shape; - if (spans.base.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { _cairo_shape_mask_compositor_init (&shape, _cairo_image_traps_compositor_get()); shape.glyphs = NULL; @@ -3131,6 +3138,8 @@ //spans.check_span_renderer = check_span_renderer; spans.renderer_init = span_renderer_init; spans.renderer_fini = span_renderer_fini; + + _cairo_atomic_init_once_leave(&once); } return &spans.base; diff -Nru cairo-1.15.8/src/cairo-image-surface-private.h cairo-1.15.10/src/cairo-image-surface-private.h --- cairo-1.15.8/src/cairo-image-surface-private.h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-image-surface-private.h 2017-12-07 22:13:28.000000000 +0000 @@ -40,6 +40,7 @@ #include "cairo-surface-private.h" +#include #include CAIRO_BEGIN_DECLS @@ -71,7 +72,7 @@ int width; int height; - int stride; + ptrdiff_t stride; int depth; unsigned owns_data : 1; diff -Nru cairo-1.15.8/src/cairoint.h cairo-1.15.10/src/cairoint.h --- cairo-1.15.8/src/cairoint.h 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairoint.h 2017-12-07 02:14:36.000000000 +0000 @@ -107,6 +107,12 @@ #undef MAX #define MAX(a, b) ((a) > (b) ? (a) : (b)) +#if _XOPEN_SOURCE >= 600 || defined (_ISOC99_SOURCE) +#define ISFINITE(x) isfinite (x) +#else +#define ISFINITE(x) ((x) * (x) >= 0.) /* check for NaNs */ +#endif + #ifndef FALSE #define FALSE 0 #endif @@ -913,7 +919,10 @@ _cairo_intern_string_reset_static_data (void); cairo_private const char * -cairo_get_locale_decimal_point (void); +_cairo_get_locale_decimal_point (void); + +cairo_private double +_cairo_strtod (const char *nptr, char **endptr); /* cairo-path-fixed.c */ cairo_private cairo_path_fixed_t * @@ -1327,6 +1336,9 @@ /* cairo-surface.c */ +cairo_private cairo_bool_t +_cairo_surface_has_mime_image (cairo_surface_t *surface); + cairo_private cairo_status_t _cairo_surface_copy_mime_data (cairo_surface_t *dst, cairo_surface_t *src); @@ -1910,6 +1922,10 @@ cairo_private void _cairo_observers_notify (cairo_list_t *observers, void *arg); +/* Open a file with a UTF-8 filename */ +cairo_private cairo_status_t +_cairo_fopen (const char *filename, const char *mode, FILE **file_out); + /* Avoid unnecessary PLT entries. */ slim_hidden_proto (cairo_clip_preserve); slim_hidden_proto (cairo_close_path); diff -Nru cairo-1.15.8/src/cairo-matrix.c cairo-1.15.10/src/cairo-matrix.c --- cairo-1.15.8/src/cairo-matrix.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-matrix.c 2017-12-07 02:14:36.000000000 +0000 @@ -40,12 +40,6 @@ #define PIXMAN_MAX_INT ((pixman_fixed_1 >> 1) - pixman_fixed_e) /* need to ensure deltas also fit */ -#if _XOPEN_SOURCE >= 600 || defined (_ISOC99_SOURCE) -#define ISFINITE(x) isfinite (x) -#else -#define ISFINITE(x) ((x) * (x) >= 0.) /* check for NaNs */ -#endif - /** * SECTION:cairo-matrix * @Title: cairo_matrix_t diff -Nru cairo-1.15.8/src/cairo-mesh-pattern-rasterizer.c cairo-1.15.10/src/cairo-mesh-pattern-rasterizer.c --- cairo-1.15.8/src/cairo-mesh-pattern-rasterizer.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-mesh-pattern-rasterizer.c 2017-12-07 02:14:36.000000000 +0000 @@ -470,7 +470,7 @@ tg += tg >> 16; tb += tb >> 16; - *((uint32_t*) (data + y*stride + 4*x)) = ((ta << 16) & 0xff000000) | + *((uint32_t*) (data + y*(ptrdiff_t)stride + 4*x)) = ((ta << 16) & 0xff000000) | ((tr >> 8) & 0xff0000) | ((tg >> 16) & 0xff00) | (tb >> 24); } } diff -Nru cairo-1.15.8/src/cairo-misc.c cairo-1.15.10/src/cairo-misc.c --- cairo-1.15.8/src/cairo-misc.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-misc.c 2017-12-07 02:14:36.000000000 +0000 @@ -41,6 +41,9 @@ #include "cairoint.h" #include "cairo-error-private.h" +#include +#include + COMPILE_TIME_ASSERT ((int)CAIRO_STATUS_LAST_STATUS < (int)CAIRO_INT_STATUS_UNSUPPORTED); COMPILE_TIME_ASSERT (CAIRO_INT_STATUS_LAST_STATUS <= 127); @@ -771,7 +774,7 @@ # include const char * -cairo_get_locale_decimal_point (void) +_cairo_get_locale_decimal_point (void) { struct lconv *locale_data = localeconv (); return locale_data->decimal_point; @@ -780,12 +783,127 @@ #else /* Android's Bionic libc doesn't provide decimal_point */ const char * -cairo_get_locale_decimal_point (void) +_cairo_get_locale_decimal_point (void) { return "."; } #endif +/* strtod replacement that ignores locale and only accepts decimal points */ +double +_cairo_strtod (const char *nptr, char **endptr) +{ + const char *decimal_point; + int decimal_point_len; + const char *p; + char buf[100]; + char *bufptr; + char *bufend = buf + sizeof(buf) - 1; + double value; + char *end; + int delta; + cairo_bool_t have_dp; + + decimal_point = _cairo_get_locale_decimal_point (); + decimal_point_len = strlen (decimal_point); + assert (decimal_point_len != 0); + + p = nptr; + bufptr = buf; + delta = 0; + have_dp = FALSE; + while (*p && _cairo_isspace (*p)) { + p++; + delta++; + } + + while (*p && (bufptr + decimal_point_len < bufend)) { + if (_cairo_isdigit (*p)) { + *bufptr++ = *p; + } else if (*p == '.') { + if (have_dp) + break; + strncpy (bufptr, decimal_point, decimal_point_len); + bufptr += decimal_point_len; + delta -= decimal_point_len - 1; + have_dp = TRUE; + } else { + break; + } + p++; + } + *bufptr = 0; + + value = strtod (buf, &end); + if (endptr) { + if (end == buf) + *endptr = (char*)(nptr); + else + *endptr = (char*)(nptr + (end - buf) + delta); + } + + return value; +} + +/** + * _cairo_fopen: + * @filename: filename to open + * @mode: mode string with which to open the file + * @file_out: reference to file handle + * + * Exactly like the C library function, but possibly doing encoding + * conversion on the filename. On all platforms, the filename is + * passed directly to the system, but on Windows, the filename is + * interpreted as UTF-8, rather than in a codepage that would depend + * on system settings. + * + * Return value: CAIRO_STATUS_SUCCESS when the filename was converted + * successfully to the native encoding, or the error reported by + * _cairo_utf8_to_utf16 otherwise. To check if the file handle could + * be obtained, dereference file_out and compare its value against + * NULL + **/ +cairo_status_t +_cairo_fopen (const char *filename, const char *mode, FILE **file_out) +{ + FILE *result; +#ifdef _WIN32 /* also defined on x86_64 */ + uint16_t *filename_w; + uint16_t *mode_w; + cairo_status_t status; + + *file_out = NULL; + + if (filename == NULL || mode == NULL) { + errno = EINVAL; + return CAIRO_STATUS_SUCCESS; + } + + if ((status = _cairo_utf8_to_utf16 (filename, -1, &filename_w, NULL)) != CAIRO_STATUS_SUCCESS) { + errno = EINVAL; + return status; + } + + if ((status = _cairo_utf8_to_utf16 (mode, -1, &mode_w, NULL)) != CAIRO_STATUS_SUCCESS) { + free (filename_w); + errno = EINVAL; + return status; + } + + result = _wfopen(filename_w, mode_w); + + free (filename_w); + free (mode_w); + +#else /* Use fopen directly */ + result = fopen (filename, mode); +#endif + + *file_out = result; + + return CAIRO_STATUS_SUCCESS; +} + #ifdef _WIN32 #define WIN32_LEAN_AND_MEAN diff -Nru cairo-1.15.8/src/cairo-output-stream.c cairo-1.15.10/src/cairo-output-stream.c --- cairo-1.15.8/src/cairo-output-stream.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-output-stream.c 2017-12-07 02:14:36.000000000 +0000 @@ -33,7 +33,7 @@ * Kristian Høgsberg */ -#define _BSD_SOURCE /* for snprintf() */ +#define _DEFAULT_SOURCE /* for snprintf() */ #include "cairoint.h" #include "cairo-output-stream-private.h" @@ -312,7 +312,7 @@ if (d == 0.0) d = 0.0; - decimal_point = cairo_get_locale_decimal_point (); + decimal_point = _cairo_get_locale_decimal_point (); decimal_point_len = strlen (decimal_point); assert (decimal_point_len != 0); @@ -490,9 +490,13 @@ single_fmt, va_arg (ap, long int)); } break; - case 's': - snprintf (buffer, sizeof buffer, - single_fmt, va_arg (ap, const char *)); + case 's': { + /* Write out strings as they may be larger than the buffer. */ + const char *s = va_arg (ap, const char *); + int len = strlen(s); + _cairo_output_stream_write (stream, s, len); + buffer[0] = 0; + } break; case 'f': _cairo_dtostr (buffer, sizeof buffer, va_arg (ap, double), FALSE); @@ -653,11 +657,16 @@ { stdio_stream_t *stream; FILE *file; + cairo_status_t status; if (filename == NULL) return _cairo_null_stream_create (); - file = fopen (filename, "wb"); + status = _cairo_fopen (filename, "wb", &file); + + if (status != CAIRO_STATUS_SUCCESS) + return _cairo_output_stream_create_in_error (status); + if (file == NULL) { switch (errno) { case ENOMEM: diff -Nru cairo-1.15.8/src/cairo-path-bounds.c cairo-1.15.10/src/cairo-path-bounds.c --- cairo-1.15.8/src/cairo-path-bounds.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-path-bounds.c 2017-12-07 02:14:36.000000000 +0000 @@ -200,8 +200,8 @@ cairo_stroke_style_t style; /* When calculating extents for vector surfaces, ensure lines thinner - * than the fixed point resolution are not optimized away. */ - double min_line_width = _cairo_fixed_to_double (CAIRO_FIXED_EPSILON*2); + * than one point are not optimized away. */ + double min_line_width = _cairo_matrix_transformed_circle_major_axis (ctm_inverse, 1.0); if (stroke_style->line_width < min_line_width) { style = *stroke_style; diff -Nru cairo-1.15.8/src/cairo-path-stroke-boxes.c cairo-1.15.10/src/cairo-path-stroke-boxes.c --- cairo-1.15.8/src/cairo-path-stroke-boxes.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-path-stroke-boxes.c 2017-12-07 02:13:45.000000000 +0000 @@ -36,7 +36,7 @@ * Chris Wilson */ -#define _BSD_SOURCE /* for hypot() */ +#define _DEFAULT_SOURCE /* for hypot() */ #include "cairoint.h" #include "cairo-box-inline.h" diff -Nru cairo-1.15.8/src/cairo-path-stroke.c cairo-1.15.10/src/cairo-path-stroke.c --- cairo-1.15.8/src/cairo-path-stroke.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-path-stroke.c 2017-12-07 02:13:45.000000000 +0000 @@ -36,7 +36,7 @@ * Chris Wilson */ -#define _BSD_SOURCE /* for hypot() */ +#define _DEFAULT_SOURCE /* for hypot() */ #include "cairoint.h" #include "cairo-box-inline.h" diff -Nru cairo-1.15.8/src/cairo-path-stroke-polygon.c cairo-1.15.10/src/cairo-path-stroke-polygon.c --- cairo-1.15.8/src/cairo-path-stroke-polygon.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-path-stroke-polygon.c 2017-12-07 02:13:45.000000000 +0000 @@ -37,7 +37,7 @@ * Chris Wilson */ -#define _BSD_SOURCE /* for hypot() */ +#define _DEFAULT_SOURCE /* for hypot() */ #include "cairoint.h" #include "cairo-box-inline.h" diff -Nru cairo-1.15.8/src/cairo-path-stroke-tristrip.c cairo-1.15.10/src/cairo-path-stroke-tristrip.c --- cairo-1.15.8/src/cairo-path-stroke-tristrip.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-path-stroke-tristrip.c 2017-12-07 02:13:45.000000000 +0000 @@ -37,7 +37,7 @@ * Chris Wilson */ -#define _BSD_SOURCE /* for hypot() */ +#define _DEFAULT_SOURCE /* for hypot() */ #include "cairoint.h" #include "cairo-box-inline.h" diff -Nru cairo-1.15.8/src/cairo-pattern.c cairo-1.15.10/src/cairo-pattern.c --- cairo-1.15.8/src/cairo-pattern.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-pattern.c 2017-12-07 02:14:36.000000000 +0000 @@ -3134,6 +3134,59 @@ return TRUE; } +/** + * _cairo_pattern_is_constant_alpha: + * + * Convenience function to determine whether a pattern has constant + * alpha within the given extents. In this case the alpha argument is + * initialized to the alpha within the extents. + * + * Return value: %TRUE if the pattern has constant alpha. + **/ +cairo_bool_t +_cairo_pattern_is_constant_alpha (const cairo_pattern_t *abstract_pattern, + const cairo_rectangle_int_t *extents, + double *alpha) +{ + const cairo_pattern_union_t *pattern; + cairo_color_t color; + + if (_cairo_pattern_is_clear (abstract_pattern)) { + *alpha = 0.0; + return TRUE; + } + + if (_cairo_pattern_is_opaque (abstract_pattern, extents)) { + *alpha = 1.0; + return TRUE; + } + + pattern = (cairo_pattern_union_t *) abstract_pattern; + switch (pattern->base.type) { + case CAIRO_PATTERN_TYPE_SOLID: + *alpha = pattern->solid.color.alpha; + return TRUE; + + case CAIRO_PATTERN_TYPE_LINEAR: + case CAIRO_PATTERN_TYPE_RADIAL: + if (_cairo_gradient_pattern_is_solid (&pattern->gradient.base, extents, &color)) { + *alpha = color.alpha; + return TRUE; + } else { + return FALSE; + } + + /* TODO: need to test these as well */ + case CAIRO_PATTERN_TYPE_SURFACE: + case CAIRO_PATTERN_TYPE_RASTER_SOURCE: + case CAIRO_PATTERN_TYPE_MESH: + return FALSE; + } + + ASSERT_NOT_REACHED; + return FALSE; +} + static cairo_bool_t _mesh_is_clear (const cairo_mesh_pattern_t *mesh) { diff -Nru cairo-1.15.8/src/cairo-pattern-private.h cairo-1.15.10/src/cairo-pattern-private.h --- cairo-1.15.8/src/cairo-pattern-private.h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-pattern-private.h 2017-12-07 23:22:14.000000000 +0000 @@ -256,6 +256,11 @@ const cairo_rectangle_int_t *extents, cairo_color_t *color); +cairo_private cairo_bool_t +_cairo_pattern_is_constant_alpha (const cairo_pattern_t *abstract_pattern, + const cairo_rectangle_int_t *extents, + double *alpha); + cairo_private void _cairo_gradient_pattern_fit_to_range (const cairo_gradient_pattern_t *gradient, double max_value, diff -Nru cairo-1.15.8/src/cairo-pdf-interchange.c cairo-1.15.10/src/cairo-pdf-interchange.c --- cairo-1.15.8/src/cairo-pdf-interchange.c 2017-08-29 16:58:07.000000000 +0000 +++ cairo-1.15.10/src/cairo-pdf-interchange.c 2017-12-07 02:14:36.000000000 +0000 @@ -43,6 +43,7 @@ * - page labels */ +#define _DEFAULT_SOURCE /* for localtime_r(), gmtime_r(), snprintf(), strdup() */ #include "cairoint.h" #include "cairo-pdf.h" @@ -52,6 +53,15 @@ #include "cairo-error-private.h" #include "cairo-output-stream-private.h" +#include + +#ifndef HAVE_LOCALTIME_R +#define localtime_r(T, BUF) (*(BUF) = *localtime (T)) +#endif +#ifndef HAVE_GMTIME_R +#define gmtime_r(T, BUF) (*(BUF) = *gmtime (T)) +#endif + static void write_rect_to_pdf_quad_points (cairo_output_stream_t *stream, const cairo_rectangle_t *rect, @@ -102,8 +112,9 @@ node->parent = parent; cairo_list_init (&node->children); _cairo_array_init (&node->mcid, sizeof(struct page_mcid)); - memset (&node->annot, 0, sizeof(node->annot)); - cairo_list_init (&node->children); + node->annot_res.id = 0; + node->extents.valid = FALSE; + cairo_list_init (&node->extents.link); cairo_list_add_tail (&node->link, &parent->children); @@ -157,6 +168,59 @@ } static cairo_int_status_t +add_annotation (cairo_pdf_surface_t *surface, + cairo_pdf_struct_tree_node_t *node, + const char *name, + const char *attributes) +{ + cairo_int_status_t status = CAIRO_STATUS_SUCCESS; + cairo_pdf_interchange_t *ic = &surface->interchange; + cairo_pdf_annotation_t *annot; + + annot = malloc (sizeof(cairo_pdf_annotation_t)); + if (unlikely (annot == NULL)) + return _cairo_error (CAIRO_STATUS_NO_MEMORY); + + status = _cairo_tag_parse_link_attributes (attributes, &annot->link_attrs); + if (unlikely (status)) { + free (annot); + return status; + } + + annot->node = node; + + status = _cairo_array_append (&ic->annots, &annot); + + return status; +} + +static void +free_annotation (cairo_pdf_annotation_t *annot) +{ + _cairo_array_fini (&annot->link_attrs.rects); + free (annot->link_attrs.dest); + free (annot->link_attrs.uri); + free (annot->link_attrs.file); + free (annot); +} + +static void +cairo_pdf_interchange_clear_annotations (cairo_pdf_surface_t *surface) +{ + cairo_pdf_interchange_t *ic = &surface->interchange; + int num_elems, i; + + num_elems = _cairo_array_num_elements (&ic->annots); + for (i = 0; i < num_elems; i++) { + cairo_pdf_annotation_t * annot; + + _cairo_array_copy_element (&ic->annots, i, &annot); + free_annotation (annot); + } + _cairo_array_truncate (&ic->annots, 0); +} + +static cairo_int_status_t cairo_pdf_interchange_write_node_object (cairo_pdf_surface_t *surface, cairo_pdf_struct_tree_node_t *node) { @@ -176,12 +240,16 @@ node->parent->res.id); if (! cairo_list_is_empty (&node->children)) { - if (cairo_list_is_singular (&node->children)) { + if (cairo_list_is_singular (&node->children) && node->annot_res.id == 0) { child = cairo_list_first_entry (&node->children, cairo_pdf_struct_tree_node_t, link); _cairo_output_stream_printf (surface->output, " /K %d 0 R\n", child->res.id); } else { _cairo_output_stream_printf (surface->output, " /K [ "); - + if (node->annot_res.id != 0) { + _cairo_output_stream_printf (surface->output, + "<< /Type /OBJR /Obj %d 0 R >> ", + node->annot_res.id); + } cairo_list_foreach_entry (child, cairo_pdf_struct_tree_node_t, &node->children, link) { @@ -197,14 +265,14 @@ page_res = _cairo_array_index (&surface->pages, first_page - 1); _cairo_output_stream_printf (surface->output, " /Pg %d 0 R\n", page_res->id); - if (num_mcid == 1 && node->annot.res.id == 0) { + if (num_mcid == 1 && node->annot_res.id == 0) { _cairo_output_stream_printf (surface->output, " /K %d\n", mcid_elem->mcid); } else { _cairo_output_stream_printf (surface->output, " /K [ "); - if (node->annot.res.id != 0) { + if (node->annot_res.id != 0) { _cairo_output_stream_printf (surface->output, - "%d 0 R ", - node->annot.res.id); + "<< /Type /OBJR /Obj %d 0 R >> ", + node->annot_res.id); } for (i = 0; i < num_mcid; i++) { mcid_elem = _cairo_array_index (&node->mcid, i); @@ -405,43 +473,43 @@ } static cairo_int_status_t -cairo_pdf_interchange_write_annot (cairo_pdf_surface_t *surface, - cairo_pdf_struct_tree_node_t *node) +cairo_pdf_interchange_write_annot (cairo_pdf_surface_t *surface, + cairo_pdf_annotation_t *annot) { - cairo_pdf_resource_t res; cairo_int_status_t status = CAIRO_STATUS_SUCCESS; cairo_pdf_interchange_t *ic = &surface->interchange; + cairo_pdf_struct_tree_node_t *node = annot->node; int sp; int i, num_rects; double height; - num_rects = _cairo_array_num_elements (&node->annot.link_attrs.rects); + num_rects = _cairo_array_num_elements (&annot->link_attrs.rects); if (strcmp (node->name, CAIRO_TAG_LINK) == 0 && - node->annot.link_attrs.link_type != TAG_LINK_EMPTY && - (node->annot.extents.valid || num_rects > 0)) + annot->link_attrs.link_type != TAG_LINK_EMPTY && + (node->extents.valid || num_rects > 0)) { - res = _cairo_pdf_surface_new_object (surface); - - status = _cairo_array_append (&ic->parent_tree, &res); + status = _cairo_array_append (&ic->parent_tree, &node->res); if (unlikely (status)) return status; sp = _cairo_array_num_elements (&ic->parent_tree) - 1; - status = _cairo_array_append (&surface->page_annots, &res); + node->annot_res = _cairo_pdf_surface_new_object (surface); + + status = _cairo_array_append (&surface->page_annots, &node->annot_res); if (unlikely (status)) return status; - _cairo_pdf_surface_update_object (surface, res); + _cairo_pdf_surface_update_object (surface, node->annot_res); _cairo_output_stream_printf (surface->output, "%d 0 obj\n" "<< /Type /Annot\n" " /Subtype /Link\n" " /StructParent %d\n", - res.id, + node->annot_res.id, sp); - _cairo_array_copy_element (&surface->page_heights, node->annot.src_page - 1, &height); + height = surface->height; if (num_rects > 0) { cairo_rectangle_int_t bbox_rect; @@ -451,7 +519,7 @@ cairo_rectangle_t rectf; cairo_rectangle_int_t recti; - _cairo_array_copy_element (&node->annot.link_attrs.rects, i, &rectf); + _cairo_array_copy_element (&annot->link_attrs.rects, i, &rectf); _cairo_rectangle_int_from_double (&recti, &rectf); if (i == 0) bbox_rect = recti; @@ -469,11 +537,11 @@ } else { _cairo_output_stream_printf (surface->output, " /Rect [ "); - write_rect_int_to_pdf_bbox (surface->output, &node->annot.extents.extents, height); + write_rect_int_to_pdf_bbox (surface->output, &node->extents.extents, height); _cairo_output_stream_printf (surface->output, " ]\n"); } - status = cairo_pdf_interchange_write_link_action (surface, &node->annot.link_attrs); + status = cairo_pdf_interchange_write_link_action (surface, &annot->link_attrs); if (unlikely (status)) return status; @@ -533,13 +601,27 @@ _cairo_output_stream_printf (surface->output, "%d 0 obj\n" "<< /Type /StructTreeRoot\n" - " /ParentTree %d 0 R\n" - " /K [ %d 0 R ]\n" - ">>\n" - "endobj\n", + " /ParentTree %d 0 R\n", surface->struct_tree_root.id, - ic->parent_tree_res.id, - child->res.id); + ic->parent_tree_res.id); + + if (cairo_list_is_singular (&ic->struct_root->children)) { + child = cairo_list_first_entry (&ic->struct_root->children, cairo_pdf_struct_tree_node_t, link); + _cairo_output_stream_printf (surface->output, " /K [ %d 0 R ]\n", child->res.id); + } else { + _cairo_output_stream_printf (surface->output, " /K [ "); + + cairo_list_foreach_entry (child, cairo_pdf_struct_tree_node_t, + &ic->struct_root->children, link) + { + _cairo_output_stream_printf (surface->output, "%d 0 R ", child->res.id); + } + _cairo_output_stream_printf (surface->output, "]\n"); + } + + _cairo_output_stream_printf (surface->output, + ">>\n" + "endobj\n"); return CAIRO_STATUS_SUCCESS; } @@ -548,13 +630,20 @@ cairo_pdf_interchange_write_page_annots (cairo_pdf_surface_t *surface) { cairo_pdf_interchange_t *ic = &surface->interchange; + int num_elems, i; + cairo_int_status_t status = CAIRO_STATUS_SUCCESS; - _cairo_array_truncate (&surface->page_annots, 0); - ic->annot_page = _cairo_array_num_elements (&surface->pages); + num_elems = _cairo_array_num_elements (&ic->annots); + for (i = 0; i < num_elems; i++) { + cairo_pdf_annotation_t * annot; - cairo_pdf_interchange_walk_struct_tree (surface, ic->struct_root, cairo_pdf_interchange_write_annot); + _cairo_array_copy_element (&ic->annots, i, &annot); + status = cairo_pdf_interchange_write_annot (surface, annot); + if (unlikely (status)) + return status; + } - return CAIRO_STATUS_SUCCESS; + return status; } static cairo_int_status_t @@ -652,6 +741,7 @@ for (i = 1; i < num_elems; i++) { _cairo_array_copy_element (&ic->outline, i, &outline); _cairo_pdf_surface_update_object (surface, outline->res); + status = _cairo_utf8_to_pdf_string (outline->name, &name); if (unlikely (status)) return status; @@ -663,6 +753,7 @@ outline->res.id, name, outline->parent->res.id); + free (name); if (outline->prev) { _cairo_output_stream_printf (surface->output, @@ -1006,12 +1097,11 @@ _cairo_tag_stack_set_top_data (&ic->analysis_tag_stack, ic->current_node); if (tag_type & TAG_TYPE_LINK) { - status = _cairo_tag_parse_link_attributes (attributes, &ic->current_node->annot.link_attrs); + status = add_annotation (surface, ic->current_node, name, attributes); if (unlikely (status)) return status; - ic->current_node->annot.src_page = _cairo_array_num_elements (&surface->pages);; - cairo_list_add_tail (&ic->current_node->annot.extents.link, &ic->extents_list); + cairo_list_add_tail (&ic->current_node->extents.link, &ic->extents_list); } } else if (surface->paginated_mode == CAIRO_PAGINATED_MODE_RENDER) { @@ -1119,7 +1209,7 @@ if (tag_type & TAG_TYPE_LINK) { cairo_list_foreach_entry_safe (tag, next, struct tag_extents, &ic->extents_list, link) { - if (tag == &node->annot.extents) { + if (tag == &node->extents) { cairo_list_del (&tag->link); break; } @@ -1270,6 +1360,8 @@ if (unlikely (status)) return status; + cairo_pdf_interchange_clear_annotations (surface); + return cairo_pdf_interchange_write_page_parent_elems (surface); } @@ -1312,6 +1404,45 @@ return status; } +static void +_cairo_pdf_interchange_set_create_date (cairo_pdf_surface_t *surface) +{ + time_t utc, local, offset; + struct tm tm_local, tm_utc; + char buf[50]; + int buf_size; + char *p; + cairo_pdf_interchange_t *ic = &surface->interchange; + + utc = time (NULL); + localtime_r (&utc, &tm_local); + strftime (buf, sizeof(buf), "(D:%Y%m%d%H%M%S", &tm_local); + + /* strftime "%z" is non standard and does not work on windows (it prints zone name, not offset). + * Calculate time zone offset by comparing local and utc time_t values for the same time. + */ + gmtime_r (&utc, &tm_utc); + tm_utc.tm_isdst = tm_local.tm_isdst; + local = mktime (&tm_utc); + offset = difftime (utc, local); + + if (offset == 0) { + strcat (buf, "Z"); + } else { + if (offset > 0) { + strcat (buf, "+"); + } else { + strcat (buf, "-"); + offset = -offset; + } + p = buf + strlen (buf); + buf_size = sizeof (buf) - strlen (buf); + snprintf (p, buf_size, "%02d'%02d", (int)(offset/3600), (int)(offset%3600)/60); + } + strcat (buf, ")"); + ic->docinfo.create_date = strdup (buf); +} + cairo_int_status_t _cairo_pdf_interchange_init (cairo_pdf_surface_t *surface) { @@ -1333,6 +1464,7 @@ ic->end_page_node = NULL; _cairo_array_init (&ic->parent_tree, sizeof(cairo_pdf_resource_t)); _cairo_array_init (&ic->mcid_to_tree, sizeof(cairo_pdf_struct_tree_node_t *)); + _cairo_array_init (&ic->annots, sizeof(cairo_pdf_annotation_t *)); ic->parent_tree_res.id = 0; cairo_list_init (&ic->extents_list); ic->named_dests = _cairo_hash_table_create (_named_dest_equal); @@ -1349,34 +1481,49 @@ return _cairo_error (CAIRO_STATUS_NO_MEMORY); memset (&ic->docinfo, 0, sizeof (ic->docinfo)); + _cairo_pdf_interchange_set_create_date (surface); status = _cairo_array_append (&ic->outline, &outline_root); return status; } +static void +_cairo_pdf_interchange_free_outlines (cairo_pdf_surface_t *surface) +{ + cairo_pdf_interchange_t *ic = &surface->interchange; + int num_elems, i; + + num_elems = _cairo_array_num_elements (&ic->outline); + for (i = 0; i < num_elems; i++) { + cairo_pdf_outline_entry_t *outline; + + _cairo_array_copy_element (&ic->outline, i, &outline); + free (outline->name); + free (outline->link_attrs.dest); + free (outline->link_attrs.uri); + free (outline->link_attrs.file); + free (outline); + } + _cairo_array_fini (&ic->outline); +} + cairo_int_status_t _cairo_pdf_interchange_fini (cairo_pdf_surface_t *surface) { cairo_pdf_interchange_t *ic = &surface->interchange; - unsigned i; _cairo_tag_stack_fini (&ic->analysis_tag_stack); _cairo_tag_stack_fini (&ic->render_tag_stack); _cairo_array_fini (&ic->push_data); free_node (ic->struct_root); _cairo_array_fini (&ic->mcid_to_tree); + cairo_pdf_interchange_clear_annotations (surface); + _cairo_array_fini (&ic->annots); _cairo_array_fini (&ic->parent_tree); _cairo_hash_table_foreach (ic->named_dests, _named_dest_pluck, ic->named_dests); _cairo_hash_table_destroy (ic->named_dests); free (ic->sorted_dests); - - for (i = 0; i < _cairo_array_num_elements (&ic->outline); i++) { - cairo_pdf_outline_entry_t *outline; - - _cairo_array_copy_element (&ic->outline, i, &outline); - free (outline); - } - _cairo_array_fini (&ic->outline); + _cairo_pdf_interchange_free_outlines (surface); free (ic->docinfo.title); free (ic->docinfo.author); free (ic->docinfo.subject); diff -Nru cairo-1.15.8/src/cairo-pdf-surface.c cairo-1.15.10/src/cairo-pdf-surface.c --- cairo-1.15.8/src/cairo-pdf-surface.c 2017-08-29 16:58:07.000000000 +0000 +++ cairo-1.15.10/src/cairo-pdf-surface.c 2017-12-07 02:14:36.000000000 +0000 @@ -39,7 +39,7 @@ * Adrian Johnson */ -#define _BSD_SOURCE /* for snprintf() */ +#define _DEFAULT_SOURCE /* for snprintf() */ #include "cairoint.h" #include "cairo-pdf.h" @@ -63,18 +63,8 @@ #include "cairo-surface-subsurface-private.h" #include "cairo-type3-glyph-surface-private.h" -#include #include -/* Issues: - * - * - We embed an image in the stream each time it's composited. We - * could add generation counters to surfaces and remember the stream - * ID for a particular generation for a particular surface. - * - * - Backend specific meta data. - */ - /* * Page Structure of the Generated PDF: * @@ -134,19 +124,62 @@ * The following mime types are supported: %CAIRO_MIME_TYPE_JPEG, * %CAIRO_MIME_TYPE_JP2, %CAIRO_MIME_TYPE_UNIQUE_ID, * %CAIRO_MIME_TYPE_JBIG2, %CAIRO_MIME_TYPE_JBIG2_GLOBAL, - * %CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID. + * %CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, + * %CAIRO_MIME_TYPE_CCITT_FAX, %CAIRO_MIME_TYPE_CCITT_FAX_PARAMS. * + * # JBIG2 Images # * JBIG2 data in PDF must be in the embedded format as described in * ISO/IEC 11544. Image specific JBIG2 data must be in * %CAIRO_MIME_TYPE_JBIG2. Any global segments in the JBIG2 data * (segments with page association field set to 0) must be in * %CAIRO_MIME_TYPE_JBIG2_GLOBAL. The global data may be shared by * multiple images. All images sharing the same global data must set - * %CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID to a unique identifer. At least + * %CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID to a unique identifier. At least * one of the images must provide the global data using * %CAIRO_MIME_TYPE_JBIG2_GLOBAL. The global data will only be - * embedded once but shared by all JBIG2 images with the same + * embedded once and shared by all JBIG2 images with the same * %CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID. + * + * # CCITT Fax Images # {#ccitt} + * The %CAIRO_MIME_TYPE_CCITT_FAX mime data requires a number of decoding + * parameters These parameters are specified using %CAIRO_MIME_TYPE_CCITT_FAX_PARAMS. + * + * %CAIRO_MIME_TYPE_CCITT_FAX_PARAMS mime data must contain a string of the form + * "param1=value1 param2=value2 ...". + * + * @Columns: [required] An integer specifying the width of the image in pixels. + * + * @Rows: [required] An integer specifying the height of the image in scan lines. + * + * @K: [optional] An integer identifying the encoding scheme used. < 0 + * is 2 dimensional Group 4, = 0 is Group3 1 dimensional, > 0 is mixed 1 + * and 2 dimensional encoding. Default is 0. + * + * @EndOfLine: [optional] If true end-of-line bit patterns are present. Default is false. + * + * @EncodedByteAlign: [optional] If true the end of line is padded + * with 0 bits so the next line begins on a byte boundary. Default is false. + * + * @EndOfBlock: [optional] If true the data contains an end-of-block pattern. Default is true. + * + * @BlackIs1: [optional] If true 1 bits are black pixels. Default is false. + * + * @DamagedRowsBeforeError: [optional] An integer specifying the + * number of damages rows tolerated before an error occurs. Default is 0. + * + * Boolean values may be "true" or "false", or 1 or 0. + * + * These parameters are the same as the CCITTFaxDecode parameters in the + * [PostScript Language Reference](https://www.adobe.com/products/postscript/pdfs/PLRM.pdf) + * and [Portable Document Format (PDF)](https://www.adobe.com/content/dam/Adobe/en/devnet/pdf/pdfs/PDF32000_2008.pdf). + * Refer to these documents for further details. + * + * An example %CAIRO_MIME_TYPE_CCITT_FAX_PARAMS string is: + * + * + * "Columns=10230 Rows=40000 K=1 EndOfLine=true EncodedByteAlign=1 BlackIs1=false" + * + * **/ static cairo_bool_t @@ -184,6 +217,8 @@ CAIRO_MIME_TYPE_JBIG2, CAIRO_MIME_TYPE_JBIG2_GLOBAL, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, + CAIRO_MIME_TYPE_CCITT_FAX, + CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, NULL }; @@ -233,6 +268,12 @@ _cairo_pdf_surface_close_stream (cairo_pdf_surface_t *surface); static cairo_int_status_t +_cairo_pdf_surface_emit_surface (cairo_pdf_surface_t *surface, + cairo_pdf_source_surface_t *source, + cairo_bool_t test, + cairo_bool_t *is_image); + +static cairo_int_status_t _cairo_pdf_surface_write_page (cairo_pdf_surface_t *surface); static void @@ -245,6 +286,10 @@ _cairo_pdf_surface_write_xref (cairo_pdf_surface_t *surface); static cairo_int_status_t +_cairo_pdf_surface_write_patterns_and_smask_groups (cairo_pdf_surface_t *surface, + cairo_bool_t finish); + +static cairo_int_status_t _cairo_pdf_surface_write_page (cairo_pdf_surface_t *surface); static cairo_int_status_t @@ -386,6 +431,7 @@ _cairo_array_init (&surface->page_patterns, sizeof (cairo_pdf_pattern_t)); _cairo_array_init (&surface->page_surfaces, sizeof (cairo_pdf_source_surface_t)); + _cairo_array_init (&surface->doc_surfaces, sizeof (cairo_pdf_source_surface_t)); _cairo_array_init (&surface->jbig2_global, sizeof (cairo_pdf_jbig2_global_t)); _cairo_array_init (&surface->page_heights, sizeof (double)); surface->all_surfaces = _cairo_hash_table_create (_cairo_pdf_source_surface_equal); @@ -458,6 +504,9 @@ surface->thumbnail_height = 0; surface->thumbnail_image = NULL; + if (getenv ("CAIRO_DEBUG_PDF") != NULL) + surface->compress_content = FALSE; + surface->paginated_surface = _cairo_paginated_surface_create ( &surface->base, CAIRO_CONTENT_COLOR_ALPHA, @@ -1358,57 +1407,12 @@ } static cairo_int_status_t -_get_jbig2_image_info (cairo_surface_t *source, - cairo_image_info_t *info, - const unsigned char **mime_data, - unsigned long *mime_data_length) -{ - cairo_surface_get_mime_data (source, CAIRO_MIME_TYPE_JBIG2, - mime_data, mime_data_length); - if (*mime_data == NULL) - return CAIRO_INT_STATUS_UNSUPPORTED; - - return _cairo_image_info_get_jbig2_info (info, *mime_data, *mime_data_length); -} - -static cairo_int_status_t -_get_jpx_image_info (cairo_surface_t *source, - cairo_image_info_t *info, - const unsigned char **mime_data, - unsigned long *mime_data_length) -{ - cairo_surface_get_mime_data (source, CAIRO_MIME_TYPE_JP2, - mime_data, mime_data_length); - if (*mime_data == NULL) - return CAIRO_INT_STATUS_UNSUPPORTED; - - return _cairo_image_info_get_jpx_info (info, *mime_data, *mime_data_length); -} - -static cairo_int_status_t -_get_jpeg_image_info (cairo_surface_t *source, - cairo_image_info_t *info, - const unsigned char **mime_data, - unsigned long *mime_data_length) -{ - cairo_surface_get_mime_data (source, CAIRO_MIME_TYPE_JPEG, - mime_data, mime_data_length); - if (*mime_data == NULL) - return CAIRO_INT_STATUS_UNSUPPORTED; - - return _cairo_image_info_get_jpeg_info (info, *mime_data, *mime_data_length); -} - -static cairo_int_status_t _get_source_surface_extents (cairo_surface_t *source, cairo_rectangle_int_t *extents, cairo_bool_t *bounded, cairo_bool_t *subsurface) { cairo_int_status_t status; - cairo_image_info_t info; - const unsigned char *mime_data; - unsigned long mime_data_length; *bounded = TRUE; *subsurface = FALSE; @@ -1426,48 +1430,22 @@ } else { cairo_box_t box; - if (! _cairo_surface_get_extents (source, extents)) { - status = _cairo_recording_surface_get_ink_bbox ((cairo_recording_surface_t *)source, - &box, NULL); - if (unlikely (status)) { - cairo_surface_destroy (free_me); - return status; - } - _cairo_box_round_to_rectangle (&box, extents); + *bounded = _cairo_surface_get_extents (source, extents); + if (! *bounded) { + status = _cairo_recording_surface_get_ink_bbox ((cairo_recording_surface_t *)source, + &box, NULL); + if (unlikely (status)) { + cairo_surface_destroy (free_me); + return status; + } + _cairo_box_round_to_rectangle (&box, extents); } } cairo_surface_destroy (free_me); - - return CAIRO_STATUS_SUCCESS; - } - - extents->x = 0; - extents->y = 0; - - status = _get_jbig2_image_info (source, &info, &mime_data, &mime_data_length); - if (status != CAIRO_INT_STATUS_UNSUPPORTED) { - extents->width = info.width; - extents->height = info.height; - return status; - } - - status = _get_jpx_image_info (source, &info, &mime_data, &mime_data_length); - if (status != CAIRO_INT_STATUS_UNSUPPORTED) { - extents->width = info.width; - extents->height = info.height; - return status; - } - - status = _get_jpeg_image_info (source, &info, &mime_data, &mime_data_length); - if (status != CAIRO_INT_STATUS_UNSUPPORTED) { - extents->width = info.width; - extents->height = info.height; - return status; + } else { + *bounded = _cairo_surface_get_extents (source, extents); } - if (! _cairo_surface_get_extents (source, extents)) - return CAIRO_INT_STATUS_UNSUPPORTED; - return CAIRO_STATUS_SUCCESS; } @@ -1480,6 +1458,7 @@ * @filter: [in] filter type of the source pattern * @stencil_mask: [in] if true, the surface will be written to the PDF as an /ImageMask * @smask: [in] if true, only the alpha channel will be written (images only) + * @need_transp_group: [in] if true and an XObject is used, make it a Transparency group * @extents: [in] extents of the operation that is using this source * @smask_res: [in] if not NULL, the image written will specify this resource as the smask for * the image (images only) @@ -1506,6 +1485,7 @@ cairo_filter_t filter, cairo_bool_t stencil_mask, cairo_bool_t smask, + cairo_bool_t need_transp_group, const cairo_rectangle_int_t *extents, cairo_pdf_resource_t *smask_res, cairo_pdf_source_surface_entry_t **pdf_source, @@ -1624,6 +1604,7 @@ surface_entry->interpolate = interpolate; surface_entry->stencil_mask = stencil_mask; surface_entry->smask = smask; + surface_entry->need_transp_group = need_transp_group; surface_entry->unique_id_length = unique_id_length; surface_entry->unique_id = unique_id; if (smask_res) @@ -1671,10 +1652,21 @@ goto fail3; } - status = _cairo_array_append (&surface->page_surfaces, &src_surface); + /* Test if surface will be emitted as image or recording */ + status = _cairo_pdf_surface_emit_surface (surface, &src_surface, TRUE, &surface_entry->emit_image); if (unlikely (status)) goto fail3; + if (surface_entry->bounded) { + status = _cairo_array_append (&surface->page_surfaces, &src_surface); + if (unlikely (status)) + goto fail3; + } else { + status = _cairo_array_append (&surface->doc_surfaces, &src_surface); + if (unlikely (status)) + goto fail3; + } + status = _cairo_hash_table_insert (surface->all_surfaces, &surface_entry->base); if (unlikely(status)) @@ -1782,11 +1774,10 @@ return CAIRO_INT_STATUS_SUCCESS; } -/* Get BBox in PDF coordinates from extents in cairo coordinates */ +/* Get BBox from extents */ static void -_get_bbox_from_extents (double surface_height, - const cairo_rectangle_int_t *extents, - cairo_box_double_t *bbox) +_get_bbox_from_extents (const cairo_rectangle_int_t *extents, + cairo_box_double_t *bbox) { bbox->p1.x = extents->x; bbox->p1.y = extents->y; @@ -2220,6 +2211,11 @@ cairo_pdf_jbig2_global_t *global; char *label; + _cairo_pdf_surface_clear (surface); + + /* Emit unbounded surfaces */ + _cairo_pdf_surface_write_patterns_and_smask_groups (surface, TRUE); + status = surface->base.status; if (status == CAIRO_STATUS_SUCCESS) status = _cairo_pdf_surface_emit_font_subsets (surface); @@ -2284,7 +2280,6 @@ if (status == CAIRO_STATUS_SUCCESS) status = status2; - _cairo_pdf_surface_clear (surface); _cairo_pdf_group_resources_fini (&surface->resources); _cairo_array_fini (&surface->objects); @@ -2293,6 +2288,7 @@ _cairo_array_fini (&surface->alpha_linear_functions); _cairo_array_fini (&surface->page_patterns); _cairo_array_fini (&surface->page_surfaces); + _cairo_array_fini (&surface->doc_surfaces); _cairo_hash_table_foreach (surface->all_surfaces, _cairo_pdf_source_surface_entry_pluck, surface->all_surfaces); @@ -2324,8 +2320,6 @@ } _cairo_array_fini (&surface->page_labels); - _cairo_array_truncate (&surface->page_surfaces, 0); - _cairo_surface_clipper_reset (&surface->clipper); return _cairo_pdf_interchange_fini (surface); @@ -2491,6 +2485,7 @@ source->filter, FALSE, /* stencil mask */ FALSE, /* smask */ + FALSE, /* need_transp_group */ extents, NULL, /* smask_res */ pdf_source, @@ -2906,7 +2901,8 @@ static cairo_int_status_t _cairo_pdf_surface_emit_jbig2_image (cairo_pdf_surface_t *surface, cairo_surface_t *source, - cairo_pdf_source_surface_entry_t *surface_entry) + cairo_pdf_source_surface_entry_t *surface_entry, + cairo_bool_t test) { cairo_int_status_t status; const unsigned char *mime_data; @@ -2929,6 +2925,10 @@ if (status) return status; + /* At this point we know emitting jbig2 will succeed. */ + if (test) + return CAIRO_STATUS_SUCCESS; + cairo_surface_get_mime_data (source, CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, &global_id, &global_id_length); if (global_id && global_id_length > 0) { @@ -3014,7 +3014,8 @@ static cairo_int_status_t _cairo_pdf_surface_emit_jpx_image (cairo_pdf_surface_t *surface, cairo_surface_t *source, - cairo_pdf_source_surface_entry_t *surface_entry) + cairo_pdf_source_surface_entry_t *surface_entry, + cairo_bool_t test) { cairo_int_status_t status; const unsigned char *mime_data; @@ -3045,6 +3046,10 @@ else smask_buf[0] = 0; + /* At this point we know emitting jpx will succeed. */ + if (test) + return CAIRO_STATUS_SUCCESS; + if (surface_entry->stencil_mask) { status = _cairo_pdf_surface_open_stream (surface, &surface_entry->surface_res, @@ -3089,7 +3094,8 @@ static cairo_int_status_t _cairo_pdf_surface_emit_jpeg_image (cairo_pdf_surface_t *surface, cairo_surface_t *source, - cairo_pdf_source_surface_entry_t *surface_entry) + cairo_pdf_source_surface_entry_t *surface_entry, + cairo_bool_t test) { cairo_int_status_t status; const unsigned char *mime_data; @@ -3129,6 +3135,10 @@ return CAIRO_INT_STATUS_UNSUPPORTED; } + /* At this point we know emitting jpeg will succeed. */ + if (test) + return CAIRO_STATUS_SUCCESS; + if (surface_entry->smask_res.id) snprintf(smask_buf, sizeof(smask_buf), " /SMask %d 0 R\n", surface_entry->smask_res.id); else @@ -3182,45 +3192,113 @@ } static cairo_int_status_t -_cairo_pdf_surface_emit_image_surface (cairo_pdf_surface_t *surface, - cairo_pdf_source_surface_t *source) +_cairo_pdf_surface_emit_ccitt_image (cairo_pdf_surface_t *surface, + cairo_surface_t *source, + cairo_pdf_source_surface_entry_t *surface_entry, + cairo_bool_t test) { - cairo_image_surface_t *image; - void *image_extra; - cairo_int_status_t status; + cairo_status_t status; + const unsigned char *ccitt_data; + unsigned long ccitt_data_len; + const unsigned char *ccitt_params_string; + unsigned long ccitt_params_string_len; + char *params, *p, *end; + cairo_ccitt_params_t ccitt_params; + char buf[300]; - if (source->type == CAIRO_PATTERN_TYPE_SURFACE) { - status = _cairo_pdf_surface_emit_jbig2_image (surface, source->surface, source->hash_entry); - if (status != CAIRO_INT_STATUS_UNSUPPORTED) - return status; + cairo_surface_get_mime_data (source, CAIRO_MIME_TYPE_CCITT_FAX, + &ccitt_data, &ccitt_data_len); + if (unlikely (source->status)) + return source->status; + if (ccitt_data == NULL) + return CAIRO_INT_STATUS_UNSUPPORTED; - status = _cairo_pdf_surface_emit_jpx_image (surface, source->surface, source->hash_entry); - if (status != CAIRO_INT_STATUS_UNSUPPORTED) - return status; + cairo_surface_get_mime_data (source, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, + &ccitt_params_string, &ccitt_params_string_len); + if (unlikely (source->status)) + return source->status; + if (ccitt_params_string == NULL) + return CAIRO_INT_STATUS_UNSUPPORTED; - status = _cairo_pdf_surface_emit_jpeg_image (surface, source->surface, source->hash_entry); - if (status != CAIRO_INT_STATUS_UNSUPPORTED) - return status; + /* ensure params_string is null terminated */ + params = malloc (ccitt_params_string_len + 1); + memcpy (params, ccitt_params_string, ccitt_params_string_len); + params[ccitt_params_string_len] = 0; + status = _cairo_tag_parse_ccitt_params (params, &ccitt_params); + if (unlikely(status)) + return source->status; + + free (params); + + /* At this point we know emitting jbig2 will succeed. */ + if (test) + return CAIRO_STATUS_SUCCESS; + + p = buf; + *p = 0; + end = buf + sizeof(buf) - 1; + p += snprintf (p, end - p, "/Columns %d /Rows %d /K %d", + ccitt_params.columns, + ccitt_params.rows, + ccitt_params.k); + if (ccitt_params.end_of_line) + p += snprintf (p, end - p, " /EndOfLine true"); + + if (ccitt_params.encoded_byte_align) + p += snprintf (p, end - p, " /EncodedByteAlign true"); + + if (!ccitt_params.end_of_block) + p += snprintf (p, end - p, " /EndOfBlock false"); + + if (ccitt_params.black_is_1) + p += snprintf (p, end - p, " /BlackIs1 true"); + + if (ccitt_params.damaged_rows_before_error > 0) { + p += snprintf (p, end - p, " /DamagedRowsBeforeError %d", + ccitt_params.damaged_rows_before_error); } - if (source->type == CAIRO_PATTERN_TYPE_SURFACE) { - status = _cairo_surface_acquire_source_image (source->surface, &image, &image_extra); + if (surface_entry->stencil_mask) { + status = _cairo_pdf_surface_open_stream (surface, + &surface_entry->surface_res, + FALSE, + " /Type /XObject\n" + " /Subtype /Image\n" + " /ImageMask true\n" + " /Width %d\n" + " /Height %d\n" + " /Interpolate %s\n" + " /BitsPerComponent 1\n" + " /Decode [1 0]\n" + " /Filter /CCITTFaxDecode\n" + " /DecodeParms << %s >> ", + ccitt_params.columns, + ccitt_params.rows, + surface_entry->interpolate ? "true" : "false", + buf); } else { - status = _cairo_pdf_surface_acquire_source_image_from_pattern (surface, source->raster_pattern, - &image, &image_extra); + status = _cairo_pdf_surface_open_stream (surface, + &surface_entry->surface_res, + FALSE, + " /Type /XObject\n" + " /Subtype /Image\n" + " /Width %d\n" + " /Height %d\n" + " /ColorSpace /DeviceGray\n" + " /BitsPerComponent 1\n" + " /Interpolate %s\n" + " /Filter /CCITTFaxDecode\n" + " /DecodeParms << %s >> ", + ccitt_params.columns, + ccitt_params.rows, + surface_entry->interpolate ? "true" : "false", + buf); } if (unlikely (status)) return status; - status = _cairo_pdf_surface_emit_image (surface, - image, - source->hash_entry); - - if (source->type == CAIRO_PATTERN_TYPE_SURFACE) - _cairo_surface_release_source_image (source->surface, image, image_extra); - else - _cairo_pdf_surface_release_source_image_from_pattern (surface, source->raster_pattern, - image, image_extra); + _cairo_output_stream_write (surface->output, ccitt_data, ccitt_data_len); + status = _cairo_pdf_surface_close_stream (surface); return status; } @@ -3229,7 +3307,6 @@ _cairo_pdf_surface_emit_recording_surface (cairo_pdf_surface_t *surface, cairo_pdf_source_surface_t *pdf_source) { - double old_width, old_height; cairo_rectangle_int_t old_surface_extents; cairo_bool_t old_surface_bounded; cairo_paginated_mode_t old_paginated_mode; @@ -3241,16 +3318,18 @@ cairo_surface_t *free_me = NULL; cairo_surface_t *source; const cairo_rectangle_int_t *extents; - int width; - int height; cairo_bool_t is_subsurface; cairo_bool_t transparency_group; cairo_recording_surface_t *recording; assert (pdf_source->type == CAIRO_PATTERN_TYPE_SURFACE); - extents = &pdf_source->hash_entry->required_extents; - width = pdf_source->hash_entry->extents.width; - height = pdf_source->hash_entry->extents.height; + + if (pdf_source->hash_entry->bounded) { + extents = &pdf_source->hash_entry->extents; + } else { + extents = &pdf_source->hash_entry->required_extents; + } + is_subsurface = FALSE; source = pdf_source->surface; if (_cairo_surface_is_snapshot (source)) @@ -3261,16 +3340,12 @@ source = sub->target; extents = &sub->extents; - width = extents->width; - height = extents->height; is_subsurface = TRUE; } assert (source->type == CAIRO_SURFACE_TYPE_RECORDING); recording = (cairo_recording_surface_t *) source; - old_width = surface->width; - old_height = surface->height; old_in_xobject = surface->in_xobject; old_surface_extents = surface->surface_extents; old_surface_bounded = surface->surface_bounded; @@ -3283,7 +3358,7 @@ _cairo_pdf_operators_reset (&surface->pdf_operators); surface->in_xobject = TRUE; surface->surface_extents = *extents; - surface->surface_bounded = FALSE; + surface->surface_bounded = TRUE; /* Patterns are emitted after fallback images. The paginated mode * needs to be set to _RENDER while the recording surface is replayed @@ -3291,24 +3366,24 @@ */ surface->paginated_mode = CAIRO_PAGINATED_MODE_RENDER; _cairo_pdf_group_resources_clear (&surface->resources); - if (is_subsurface) { - bbox.p1.x = extents->x; - bbox.p1.y = extents->y; - bbox.p2.x = extents->x + extents->width; - bbox.p2.y = extents->y + extents->height; - } else { - _get_bbox_from_extents (height, extents, &bbox); - } + _get_bbox_from_extents (extents, &bbox); /* We can optimize away the transparency group allowing the viewer - * to replay the group in place when all operators are OVER and the - * recording contains only opaque and/or clear alpha. + * to replay the group in place when: + * - ca/CA when painting this groups is 1.0 (need_transp_group is FALSE), + * - all operators are OVER, and + * - the recording contains only opaque and/or clear alpha. */ - transparency_group = !(pdf_source->hash_entry->operator == CAIRO_OPERATOR_OVER && + transparency_group = pdf_source->hash_entry->need_transp_group || + !(pdf_source->hash_entry->operator == CAIRO_OPERATOR_OVER && _cairo_recording_surface_has_only_bilevel_alpha (recording) && _cairo_recording_surface_has_only_op_over (recording)); - status = _cairo_pdf_surface_open_content_stream (surface, &bbox, &pdf_source->hash_entry->surface_res, - TRUE, transparency_group); + + status = _cairo_pdf_surface_open_content_stream (surface, + &bbox, + &pdf_source->hash_entry->surface_res, + TRUE, + transparency_group); if (unlikely (status)) goto err; @@ -3318,10 +3393,12 @@ goto err; _cairo_output_stream_printf (surface->output, - "q /a%d gs 0 0 0 rg 0 0 %f %f re f Q\n", + "q /a%d gs 0 0 0 rg %d %d %d %d re f Q\n", alpha, - surface->width, - surface->height); + extents->x, + extents->y, + extents->width, + extents->height); } status = _cairo_recording_surface_replay_region (source, @@ -3347,15 +3424,107 @@ return status; } +/** + * _cairo_pdf_surface_emit_surface: + * @surface: [in] the pdf surface + * @source: [in] #cairo_pdf_source_surface_t containing the surface to write + * @test: [in] if true, test what type of surface will be emitted. + * @is_image: [out] if @test is true, returns TRUE if the surface will be emitted + * as an Image XObject. + * + * If @test is FALSE, emit @src_surface as an XObject. + * If @test is TRUE, don't emit anything. Set @is_image based on the output that would be emitted. + **/ static cairo_int_status_t _cairo_pdf_surface_emit_surface (cairo_pdf_surface_t *surface, - cairo_pdf_source_surface_t *src_surface) + cairo_pdf_source_surface_t *source, + cairo_bool_t test, + cairo_bool_t *is_image) { - if (src_surface->type == CAIRO_PATTERN_TYPE_SURFACE && - src_surface->surface->type == CAIRO_SURFACE_TYPE_RECORDING) - return _cairo_pdf_surface_emit_recording_surface (surface, src_surface); + cairo_image_surface_t *image; + void *image_extra; + cairo_int_status_t status; + + /* Try all the supported mime types and recording type, falling through + * each option if unsupported */ + if (source->type == CAIRO_PATTERN_TYPE_SURFACE) { + status = _cairo_pdf_surface_emit_jbig2_image (surface, + source->surface, + source->hash_entry, + test); + if (status != CAIRO_INT_STATUS_UNSUPPORTED) { + *is_image = TRUE; + return status; + } + + status = _cairo_pdf_surface_emit_jpx_image (surface, + source->surface, + source->hash_entry, + test); + if (status != CAIRO_INT_STATUS_UNSUPPORTED) { + *is_image = TRUE; + return status; + } + + status = _cairo_pdf_surface_emit_jpeg_image (surface, + source->surface, + source->hash_entry, + test); + if (status != CAIRO_INT_STATUS_UNSUPPORTED) { + *is_image = TRUE; + return status; + } + + status = _cairo_pdf_surface_emit_ccitt_image (surface, + source->surface, + source->hash_entry, + test); + if (status != CAIRO_INT_STATUS_UNSUPPORTED) { + *is_image = TRUE; + return status; + } + + if (source->surface->type == CAIRO_SURFACE_TYPE_RECORDING) { + if (test) { + *is_image = FALSE; + return CAIRO_INT_STATUS_SUCCESS; + } else { + return _cairo_pdf_surface_emit_recording_surface (surface, source); + } + } + } - return _cairo_pdf_surface_emit_image_surface (surface, src_surface); + /* The only option left is to emit as an image surface */ + + if (source->type == CAIRO_PATTERN_TYPE_SURFACE) { + status = _cairo_surface_acquire_source_image (source->surface, &image, &image_extra); + } else { + status = _cairo_pdf_surface_acquire_source_image_from_pattern (surface, + source->raster_pattern, + &image, + &image_extra); + } + if (unlikely (status)) + return status; + + if (test) { + *is_image = TRUE; + } else { + status = _cairo_pdf_surface_emit_image (surface, + image, + source->hash_entry); + } + + if (source->type == CAIRO_PATTERN_TYPE_SURFACE) { + _cairo_surface_release_source_image (source->surface, image, image_extra); + } else { + _cairo_pdf_surface_release_source_image_from_pattern (surface, + source->raster_pattern, + image, + image_extra); + } + + return status; } static cairo_int_status_t @@ -3394,6 +3563,7 @@ pattern->filter, FALSE, /* stencil mask */ FALSE, /* smask */ + FALSE, /* need_transp_group */ &pdf_pattern->extents, NULL, /* smask_res */ &pdf_source, @@ -3501,13 +3671,12 @@ cairo_matrix_multiply (&pdf_p2d, &cairo_p2d, &mat); cairo_matrix_translate (&pdf_p2d, x_offset, y_offset); - if (((cairo_surface_pattern_t *)pattern)->surface->type != CAIRO_SURFACE_TYPE_RECORDING) - { + if (pdf_source->emit_image) { cairo_matrix_translate (&pdf_p2d, 0.0, pdf_source->extents.height); cairo_matrix_scale (&pdf_p2d, 1.0, -1.0); } - _get_bbox_from_extents (pattern_extents.height, &pattern_extents, &bbox); + _get_bbox_from_extents (&pattern_extents, &bbox); _cairo_pdf_surface_update_object (surface, pdf_pattern->pattern_res); status = _cairo_pdf_surface_open_stream (surface, &pdf_pattern->pattern_res, @@ -3530,17 +3699,17 @@ if (unlikely (status)) return status; - if (((cairo_surface_pattern_t *) pattern)->surface->type == CAIRO_SURFACE_TYPE_RECORDING) { + if (pdf_source->emit_image) { snprintf(draw_surface, sizeof (draw_surface), - "/x%d Do", + "q %d 0 0 %d 0 0 cm /x%d Do Q", + pdf_source->extents.width, + pdf_source->extents.height, pdf_source->surface_res.id); } else { snprintf(draw_surface, sizeof (draw_surface), - "q %d 0 0 %d 0 0 cm /x%d Do Q", - pdf_source->extents.width, - pdf_source->extents.height, + "/x%d Do", pdf_source->surface_res.id); } @@ -4037,7 +4206,7 @@ * coordinates. The color and alpha shading patterns painted * in the XObject below contain the cairo pattern to pdf page * matrix in the /Matrix entry of the pattern. */ - _get_bbox_from_extents (pdf_pattern->height, &pdf_pattern->extents, &box); + _get_bbox_from_extents (&pdf_pattern->extents, &box); x1 = box.p1.x; y1 = box.p1.y; x2 = box.p2.x; @@ -4535,12 +4704,13 @@ cairo_operator_t op, const cairo_pattern_t *source, const cairo_rectangle_int_t *extents, + double alpha, cairo_pdf_resource_t *smask_res, cairo_bool_t stencil_mask) { cairo_matrix_t cairo_p2d, pdf_p2d; cairo_int_status_t status; - int alpha; + int alpha_id; double x_offset; double y_offset; cairo_pdf_source_surface_entry_t *pdf_source; @@ -4564,6 +4734,7 @@ source->filter, stencil_mask, FALSE, /* smask */ + alpha != 1.0, /* need_transp_group */ extents, smask_res, &pdf_source, @@ -4582,12 +4753,21 @@ pdf_p2d = surface->cairo_to_pdf; cairo_matrix_multiply (&pdf_p2d, &cairo_p2d, &pdf_p2d); cairo_matrix_translate (&pdf_p2d, x_offset, y_offset); - if (!(source->type == CAIRO_PATTERN_TYPE_SURFACE && - ((cairo_surface_pattern_t *)source)->surface->type == CAIRO_SURFACE_TYPE_RECORDING)) - { - cairo_matrix_translate (&pdf_p2d, 0.0, pdf_source->extents.height); + if (pdf_source->emit_image) { + int width, height; + + if (pdf_source->bounded) { + width = pdf_source->extents.width; + height = pdf_source->extents.height; + } else { + /* We can't scale an image to an unbounded surface size so just set the size to 1 */ + width = 1; + height = 1; + } + + cairo_matrix_translate (&pdf_p2d, 0.0, height); cairo_matrix_scale (&pdf_p2d, 1.0, -1.0); - cairo_matrix_scale (&pdf_p2d, pdf_source->extents.width, pdf_source->extents.height); + cairo_matrix_scale (&pdf_p2d, width, height); } status = _cairo_pdf_operators_flush (&surface->pdf_operators); @@ -4599,7 +4779,7 @@ _cairo_output_stream_printf (surface->output, " cm\n"); } - status = _cairo_pdf_surface_add_alpha (surface, 1.0, &alpha); + status = _cairo_pdf_surface_add_alpha (surface, alpha, &alpha_id); if (unlikely (status)) return status; @@ -4610,7 +4790,7 @@ } else { _cairo_output_stream_printf (surface->output, "/a%d gs /x%d Do\n", - alpha, + alpha_id, pdf_source->surface_res.id); } @@ -4621,12 +4801,13 @@ _cairo_pdf_surface_paint_gradient (cairo_pdf_surface_t *surface, cairo_operator_t op, const cairo_pattern_t *source, - const cairo_rectangle_int_t *extents) + const cairo_rectangle_int_t *extents, + double alpha) { cairo_pdf_resource_t shading_res, gstate_res; cairo_matrix_t pat_to_pdf; cairo_int_status_t status; - int alpha; + int alpha_id; status = _cairo_pdf_surface_add_pdf_shading (surface, source, op, extents, @@ -4665,13 +4846,13 @@ gstate_res.id, shading_res.id); } else { - status = _cairo_pdf_surface_add_alpha (surface, 1.0, &alpha); + status = _cairo_pdf_surface_add_alpha (surface, alpha, &alpha_id); if (unlikely (status)) return status; _cairo_output_stream_printf (surface->output, "/a%d gs /sh%d sh\n", - alpha, + alpha_id, shading_res.id); } @@ -4683,6 +4864,7 @@ cairo_operator_t op, const cairo_pattern_t *source, const cairo_rectangle_int_t *extents, + double alpha, cairo_bool_t mask) { switch (source->type) { @@ -4692,6 +4874,7 @@ op, source, extents, + alpha, NULL, mask); case CAIRO_PATTERN_TYPE_LINEAR: @@ -4700,7 +4883,8 @@ return _cairo_pdf_surface_paint_gradient (surface, op, source, - extents); + extents, + alpha); case CAIRO_PATTERN_TYPE_SOLID: default: @@ -6338,7 +6522,7 @@ cairo_box_double_t bbox; /* Create mask group */ - _get_bbox_from_extents (group->height, &group->extents, &bbox); + _get_bbox_from_extents (&group->extents, &bbox); status = _cairo_pdf_surface_open_group (surface, &bbox, NULL); if (unlikely (status)) return status; @@ -6349,7 +6533,8 @@ CAIRO_OPERATOR_OVER, group->mask, &group->extents, - FALSE); + 1.0, /* alpha */ + FALSE); /* mask */ if (unlikely (status)) return status; @@ -6425,7 +6610,8 @@ CAIRO_OPERATOR_OVER, group->source, &group->extents, - FALSE); + 1.0, /* alpha */ + FALSE); /* mask */ if (unlikely (status)) return status; @@ -6546,7 +6732,7 @@ goto RESTORE_SIZE; } - _get_bbox_from_extents (group->height, &group->extents, &bbox); + _get_bbox_from_extents (&group->extents, &bbox); status = _cairo_pdf_surface_open_group (surface, &bbox, &group->group_res); if (unlikely (status)) return status; @@ -6609,13 +6795,15 @@ } static cairo_int_status_t -_cairo_pdf_surface_write_patterns_and_smask_groups (cairo_pdf_surface_t *surface) +_cairo_pdf_surface_write_patterns_and_smask_groups (cairo_pdf_surface_t *surface, + cairo_bool_t finish) { cairo_pdf_pattern_t pattern; cairo_pdf_smask_group_t *group; cairo_pdf_source_surface_t src_surface; - unsigned int pattern_index, group_index, surface_index; + unsigned int pattern_index, group_index, surface_index, doc_surface_index; cairo_int_status_t status; + cairo_bool_t is_image; /* Writing out PDF_MASK groups will cause additional smask groups * to be appended to surface->smask_groups. Additional patterns @@ -6627,9 +6815,11 @@ pattern_index = 0; group_index = 0; surface_index = 0; + doc_surface_index = 0; while ((pattern_index < _cairo_array_num_elements (&surface->page_patterns)) || (group_index < _cairo_array_num_elements (&surface->smask_groups)) || - (surface_index < _cairo_array_num_elements (&surface->page_surfaces))) + (surface_index < _cairo_array_num_elements (&surface->page_surfaces)) || + (finish && (doc_surface_index < _cairo_array_num_elements (&surface->doc_surfaces)))) { for (; group_index < _cairo_array_num_elements (&surface->smask_groups); group_index++) { _cairo_array_copy_element (&surface->smask_groups, group_index, &group); @@ -6647,10 +6837,19 @@ for (; surface_index < _cairo_array_num_elements (&surface->page_surfaces); surface_index++) { _cairo_array_copy_element (&surface->page_surfaces, surface_index, &src_surface); - status = _cairo_pdf_surface_emit_surface (surface, &src_surface); + status = _cairo_pdf_surface_emit_surface (surface, &src_surface, FALSE, &is_image); if (unlikely (status)) return status; } + + if (finish) { + for (; doc_surface_index < _cairo_array_num_elements (&surface->doc_surfaces); doc_surface_index++) { + _cairo_array_copy_element (&surface->doc_surfaces, doc_surface_index, &src_surface); + status = _cairo_pdf_surface_emit_surface (surface, &src_surface, FALSE, &is_image); + if (unlikely (status)) + return status; + } + } } return CAIRO_STATUS_SUCCESS; @@ -6677,7 +6876,7 @@ extents.y = 0; extents.width = ceil (surface->width); extents.height = ceil (surface->height); - _get_bbox_from_extents (surface->height, &extents, &bbox); + _get_bbox_from_extents (&extents, &bbox); status = _cairo_pdf_surface_open_knockout_group (surface, &bbox); if (unlikely (status)) return status; @@ -6735,7 +6934,7 @@ _cairo_pdf_surface_update_object (surface, *page); _cairo_output_stream_printf (surface->output, "%d 0 obj\n" - "<< /Type /Page\n" + "<< /Type /Page %% %d\n" " /Parent %d 0 R\n" " /MediaBox [ 0 0 %f %f ]\n" " /Contents %d 0 R\n" @@ -6747,6 +6946,7 @@ " >>\n" " /Resources %d 0 R\n", page->id, + page_num, surface->pages_resource.id, surface->width, surface->height, @@ -6782,7 +6982,7 @@ ">>\n" "endobj\n"); - status = _cairo_pdf_surface_write_patterns_and_smask_groups (surface); + status = _cairo_pdf_surface_write_patterns_and_smask_groups (surface, FALSE); if (unlikely (status)) return status; @@ -6791,7 +6991,7 @@ static cairo_int_status_t _cairo_pdf_surface_analyze_surface_pattern_transparency (cairo_pdf_surface_t *surface, - cairo_surface_pattern_t *pattern) + cairo_surface_pattern_t *pattern) { cairo_image_surface_t *image; void *image_extra; @@ -7175,6 +7375,7 @@ source->filter, FALSE, /* stencil mask */ TRUE, /* smask */ + FALSE, /* need_transp_group */ extents, NULL, /* smask_res */ &pdf_source, @@ -7191,6 +7392,7 @@ _cairo_output_stream_printf (surface->output, "q\n"); status = _cairo_pdf_surface_paint_surface_pattern (surface, op, source, extents, + 1.0, /* alpha */ need_smask ? &pdf_source->surface_res : NULL, FALSE); if (unlikely (status)) @@ -7254,7 +7456,7 @@ return status; _cairo_output_stream_printf (surface->output, "q\n"); - status = _cairo_pdf_surface_paint_surface_pattern (surface, op, mask, extents, NULL, TRUE); + status = _cairo_pdf_surface_paint_surface_pattern (surface, op, mask, extents, 1.0, NULL, TRUE); if (unlikely (status)) return status; @@ -7337,7 +7539,8 @@ op, source, &extents.bounded, - FALSE); + 1.0, /* alpha */ + FALSE); /* mask */ if (unlikely (status)) goto cleanup; @@ -7425,6 +7628,7 @@ cairo_int_status_t status; cairo_rectangle_int_t r; cairo_box_t box; + double alpha; status = _cairo_composite_rectangles_init_for_mask (&extents, &surface->base, @@ -7505,6 +7709,26 @@ if (status != CAIRO_INT_STATUS_UNSUPPORTED) goto cleanup; + /* Check if we can set ca/CA instead of an smask. We could handle + * other source patterns as well but for now this is the easiest, + * and most common, case to handle. */ + if (_cairo_pattern_is_constant_alpha (mask, &extents.bounded, &alpha) && + _can_paint_pattern (source)) { + _cairo_output_stream_printf (surface->output, "q\n"); + status = _cairo_pdf_surface_paint_pattern (surface, + op, + source, + &extents.bounded, + alpha, + FALSE); /* mask */ + if (unlikely (status)) + goto cleanup; + + _cairo_output_stream_printf (surface->output, "Q\n"); + _cairo_composite_rectangles_fini (&extents); + return _cairo_output_stream_get_status (surface->output); + } + group = _cairo_pdf_surface_create_smask_group (surface, &extents.bounded); if (unlikely (group == NULL)) { status = _cairo_error (CAIRO_STATUS_NO_MEMORY); @@ -7782,7 +8006,8 @@ op, source, &extents.bounded, - FALSE); + 1.0, /* alpha */ + FALSE); /* mask */ if (unlikely (status)) goto cleanup; diff -Nru cairo-1.15.8/src/cairo-pdf-surface-private.h cairo-1.15.10/src/cairo-pdf-surface-private.h --- cairo-1.15.8/src/cairo-pdf-surface-private.h 2017-08-29 16:58:07.000000000 +0000 +++ cairo-1.15.10/src/cairo-pdf-surface-private.h 2017-12-07 02:14:36.000000000 +0000 @@ -76,15 +76,18 @@ cairo_bool_t interpolate; cairo_bool_t stencil_mask; cairo_bool_t smask; + cairo_bool_t need_transp_group; cairo_pdf_resource_t surface_res; cairo_pdf_resource_t smask_res; - /* Extents of the source surface. If bounded is false, - * extents is the ink extents. */ + /* True if surface will be emitted as an Image XObject. */ + cairo_bool_t emit_image; + + /* Extents of the source surface. */ cairo_bool_t bounded; cairo_rectangle_int_t extents; - /* Union of source extents requried for all operations using this source */ + /* Union of source extents required for all operations using this source */ cairo_rectangle_int_t required_extents; } cairo_pdf_source_surface_entry_t; @@ -175,15 +178,16 @@ struct _cairo_pdf_struct_tree_node *parent; cairo_list_t children; cairo_array_t mcid; /* array of struct page_mcid */ - struct { - struct tag_extents extents; - cairo_pdf_resource_t res; - cairo_link_attrs_t link_attrs; - int src_page; /* page number containing the link */ - } annot; + cairo_pdf_resource_t annot_res; /* 0 if no annot */ + struct tag_extents extents; cairo_list_t link; } cairo_pdf_struct_tree_node_t; +typedef struct _cairo_pdf_annotation { + cairo_pdf_struct_tree_node_t *node; /* node containing the annotation */ + cairo_link_attrs_t link_attrs; +} cairo_pdf_annotation_t; + typedef struct _cairo_pdf_named_dest { cairo_hash_entry_t base; struct tag_extents extents; @@ -225,6 +229,7 @@ cairo_pdf_struct_tree_node_t *end_page_node; cairo_array_t parent_tree; /* parent tree resources */ cairo_array_t mcid_to_tree; /* mcid to tree node mapping for current page */ + cairo_array_t annots; /* array of pointers to cairo_pdf_annotation_t */ cairo_pdf_resource_t parent_tree_res; cairo_list_t extents_list; cairo_hash_table_t *named_dests; @@ -261,6 +266,7 @@ cairo_array_t alpha_linear_functions; cairo_array_t page_patterns; cairo_array_t page_surfaces; + cairo_array_t doc_surfaces; cairo_hash_table_t *all_surfaces; cairo_array_t smask_groups; cairo_array_t knockout_group; diff -Nru cairo-1.15.8/src/cairo-png.c cairo-1.15.10/src/cairo-png.c --- cairo-1.15.8/src/cairo-png.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-png.c 2017-12-07 02:14:36.000000000 +0000 @@ -158,6 +158,14 @@ */ } +static int +png_setjmp (png_struct *png) +{ +#ifdef PNG_SETJMP_SUPPORTED + return setjmp (png_jmpbuf (png)); +#endif + return 0; +} /* Starting with libpng-1.2.30, we must explicitly specify an output_flush_fn. * Otherwise, we will segfault if we are writing to a stream. */ @@ -229,10 +237,8 @@ goto BAIL4; } -#ifdef PNG_SETJMP_SUPPORTED - if (setjmp (png_jmpbuf (png))) + if (png_setjmp (png)) goto BAIL4; -#endif png_set_write_fn (png, closure, write_func, png_simple_output_flush_fn); @@ -339,7 +345,8 @@ /** * cairo_surface_write_to_png: * @surface: a #cairo_surface_t with pixel contents - * @filename: the name of a file to write to + * @filename: the name of a file to write to; on Windows this filename + * is encoded in UTF-8. * * Writes the contents of @surface to a new file @filename as a PNG * image. @@ -367,7 +374,11 @@ if (surface->finished) return _cairo_error (CAIRO_STATUS_SURFACE_FINISHED); - fp = fopen (filename, "wb"); + status = _cairo_fopen (filename, "wb", &fp); + + if (status != CAIRO_STATUS_SUCCESS) + return _cairo_error (status); + if (fp == NULL) { switch (errno) { case ENOMEM: @@ -573,12 +584,11 @@ png_set_read_fn (png, png_closure, stream_read_func); status = CAIRO_STATUS_SUCCESS; -#ifdef PNG_SETJMP_SUPPORTED - if (setjmp (png_jmpbuf (png))) { + + if (png_setjmp (png)) { surface = _cairo_surface_create_in_error (status); goto BAIL; } -#endif png_read_info (png, info); @@ -673,7 +683,7 @@ } for (i = 0; i < png_height; i++) - row_pointers[i] = &data[i * stride]; + row_pointers[i] = &data[i * (ptrdiff_t)stride]; png_read_image (png, row_pointers); png_read_end (png, info); @@ -733,7 +743,8 @@ /** * cairo_image_surface_create_from_png: - * @filename: name of PNG file to load + * @filename: name of PNG file to load. On Windows this filename + * is encoded in UTF-8. * * Creates a new image surface and initializes the contents to the * given PNG file. @@ -759,10 +770,14 @@ { struct png_read_closure_t png_closure; cairo_surface_t *surface; + cairo_status_t status; + + status = _cairo_fopen (filename, "rb", (FILE **) &png_closure.closure); + + if (status != CAIRO_STATUS_SUCCESS) + return _cairo_surface_create_in_error (status); - png_closure.closure = fopen (filename, "rb"); if (png_closure.closure == NULL) { - cairo_status_t status; switch (errno) { case ENOMEM: status = _cairo_error (CAIRO_STATUS_NO_MEMORY); diff -Nru cairo-1.15.8/src/cairo-ps-surface.c cairo-1.15.10/src/cairo-ps-surface.c --- cairo-1.15.8/src/cairo-ps-surface.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-ps-surface.c 2017-12-07 02:14:36.000000000 +0000 @@ -53,7 +53,7 @@ * 2. Using gs to do PS -> PDF and PDF -> PS will always work well. */ -#define _BSD_SOURCE /* for ctime_r(), snprintf(), strdup() */ +#define _DEFAULT_SOURCE /* for ctime_r(), snprintf(), strdup() */ #include "cairoint.h" #include "cairo-ps.h" @@ -77,6 +77,7 @@ #include "cairo-output-stream-private.h" #include "cairo-type3-glyph-surface-private.h" #include "cairo-image-info-private.h" +#include "cairo-tag-attributes-private.h" #include #include @@ -84,6 +85,13 @@ #include #include +/* Forms are emitted at the start and stored in memory so we limit the + * total size of all forms to prevent running out of memory. If this + * limit is exceeded, surfaces that would be stored in forms are + * emitted each time the surface is used. */ +#define MAX_L2_FORM_DATA (256*1024) +#define MAX_L3_FORM_DATA (2*1024*1024) /* Assume Level 3 printers have more memory */ + /* #define DEBUG_PS 1 */ #if DEBUG_PS @@ -105,6 +113,39 @@ * * The PostScript surface is used to render cairo graphics to Adobe * PostScript files and is a multi-page vector surface backend. + * + * The following mime types are supported: %CAIRO_MIME_TYPE_JPEG, + * %CAIRO_MIME_TYPE_UNIQUE_ID, + * %CAIRO_MIME_TYPE_CCITT_FAX, %CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, + * %CAIRO_MIME_TYPE_CCITT_FAX, %CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, + * %CAIRO_MIME_TYPE_EPS, %CAIRO_MIME_TYPE_EPS_PARAMS. + * + * Source surfaces used by the PostScript surface that have a + * %CAIRO_MIME_TYPE_UNIQUE_ID mime type will be stored in PostScript + * printer memory for the duration of the print + * job. %CAIRO_MIME_TYPE_UNIQUE_ID should only be used for small + * frequently used sources. + * + * The %CAIRO_MIME_TYPE_CCITT_FAX and %CAIRO_MIME_TYPE_CCITT_FAX_PARAMS mime types + * are documented in [CCITT Fax Images][ccitt]. + * + * # Embedding EPS files # {#eps} + * + * Encapsulated PostScript files can be embedded in the PS output by + * setting the CAIRO_MIME_TYPE_EPS mime data on a surface to the EPS + * data and painting the surface. The EPS will be scaled and + * translated to the extents of the surface the EPS data is attached + * to. + * + * The %CAIRO_MIME_TYPE_EPS mime type requires the + * %CAIRO_MIME_TYPE_EPS_PARAMS mime data to also be provided in order + * to specify the embeddding parameters. %CAIRO_MIME_TYPE_EPS_PARAMS + * mime data must contain a string of the form "bbox=[llx lly urx + * ury]" that specifies the bounding box (in PS coordinates) of the + * EPS graphics. The parameters are: lower left x, lower left y, upper + * right x, upper right y. Normally the bbox data is identical to the + * %%%BoundingBox data in the EPS file. + * **/ /** @@ -120,7 +161,30 @@ CAIRO_PS_COMPRESS_NONE, CAIRO_PS_COMPRESS_LZW, CAIRO_PS_COMPRESS_DEFLATE - } cairo_ps_compress_t; +} cairo_ps_compress_t; + +typedef enum { + CAIRO_EMIT_SURFACE_ANALYZE, + CAIRO_EMIT_SURFACE_EMIT, + CAIRO_EMIT_SURFACE_EMIT_FORM +} cairo_emit_surface_mode_t; + +typedef struct { + /* input params */ + cairo_surface_t *src_surface; + cairo_operator_t op; + const cairo_rectangle_int_t *src_surface_extents; + cairo_bool_t src_surface_bounded; + const cairo_rectangle_int_t *src_op_extents; /* operation extents in src space */ + cairo_filter_t filter; + cairo_bool_t stencil_mask; /* TRUE if source is to be used as a mask */ + + /* output params */ + cairo_bool_t is_image; /* returns TRUE if PS image will be emitted */ + /* FALSE if recording will be emitted */ + long approx_size; + int eod_count; +} cairo_emit_surface_params_t; static const cairo_surface_backend_t cairo_ps_surface_backend; static const cairo_paginated_surface_backend_t cairo_ps_surface_paginated_backend; @@ -129,6 +193,9 @@ _cairo_ps_surface_get_extents (void *abstract_surface, cairo_rectangle_int_t *rectangle); +static void +_cairo_ps_form_emit (void *entry, void *closure); + static const cairo_ps_level_t _cairo_ps_levels[] = { CAIRO_PS_LEVEL_2, @@ -146,6 +213,8 @@ static const char *_cairo_ps_supported_mime_types[] = { CAIRO_MIME_TYPE_JPEG, + CAIRO_MIME_TYPE_CCITT_FAX, + CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, NULL }; @@ -184,6 +253,40 @@ } cairo_page_media_t; static void +_cairo_ps_form_init_key (cairo_ps_form_t *key) +{ + key->base.hash = _cairo_hash_bytes (_CAIRO_HASH_INIT_VALUE, + key->unique_id, key->unique_id_length); +} + +static cairo_bool_t +_cairo_ps_form_equal (const void *key_a, const void *key_b) +{ + const cairo_ps_form_t *a = key_a; + const cairo_ps_form_t *b = key_b; + + if (a->filter != b->filter) + return FALSE; + + if (a->unique_id_length != b->unique_id_length) + return FALSE; + + return memcmp (a->unique_id, b->unique_id, a->unique_id_length) == 0; +} + +static void +_cairo_ps_form_pluck (void *entry, void *closure) +{ + cairo_ps_form_t *surface_entry = entry; + cairo_hash_table_t *patterns = closure; + + _cairo_hash_table_remove (patterns, &surface_entry->base); + free (surface_entry->unique_id); + cairo_surface_destroy (surface_entry->src_surface); + free (surface_entry); +} + +static void _cairo_ps_surface_emit_header (cairo_ps_surface_t *surface) { char ctime_buf[26]; @@ -273,7 +376,6 @@ if (surface->eps) { _cairo_output_stream_printf (surface->final_stream, - "save\n" "50 dict begin\n"); } else { _cairo_output_stream_printf (surface->final_stream, @@ -309,9 +411,6 @@ "/W* { eoclip } bind def\n" "/BT { } bind def\n" "/ET { } bind def\n" - "/pdfmark where { pop globaldict /?pdfmark /exec load put }\n" - " { globaldict begin /?pdfmark /pop load def /pdfmark\n" - " /cleartomark load def end } ifelse\n" "/BDC { mark 3 1 roll /BDC pdfmark } bind def\n" "/EMC { mark /EMC pdfmark } bind def\n" "/cairo_store_point { /cairo_point_y exch def /cairo_point_x exch def } def\n" @@ -336,6 +435,11 @@ "/g { setgray } bind def\n" "/rg { setrgbcolor } bind def\n" "/d1 { setcachedevice } bind def\n" + "/cairo_data_source {\n" + " CairoDataIndex CairoData length lt\n" + " { CairoData CairoDataIndex get /CairoDataIndex CairoDataIndex 1 add def }\n" + " { () } ifelse\n" + "} def\n" "/cairo_flush_ascii85_file { cairo_ascii85_file status { cairo_ascii85_file flushfile } if } def\n" "/cairo_image { image cairo_flush_ascii85_file } def\n" "/cairo_imagemask { imagemask cairo_flush_ascii85_file } def\n"); @@ -374,11 +478,25 @@ " } ifelse\n" "} def\n"); } + if (surface->contains_eps) { + _cairo_output_stream_printf (surface->final_stream, + "/cairo_eps_begin {\n" + " /cairo_save_state save def\n" + " /dict_count countdictstack def\n" + " /op_count count 1 sub def\n" + " userdict begin\n" + " /showpage { } def\n" + " 0 g 0 J 1 w 0 j 10 M [ ] 0 d n\n" + "} bind def\n" + "/cairo_eps_end {\n" + " count op_count sub { pop } repeat\n" + " countdictstack dict_count sub { end } repeat\n" + " cairo_save_state restore\n" + "} bind def\n"); + } _cairo_output_stream_printf (surface->final_stream, "%%%%EndProlog\n"); - _cairo_output_stream_printf (surface->final_stream, - "%%%%BeginSetup\n"); num_comments = _cairo_array_num_elements (&surface->dsc_setup_comments); if (num_comments) { @@ -836,6 +954,16 @@ surface); } + +static cairo_int_status_t +_cairo_ps_surface_emit_forms (cairo_ps_surface_t *surface) +{ + _cairo_hash_table_foreach (surface->forms, + _cairo_ps_form_emit, + surface); + return surface->base.status; +} + static cairo_status_t _cairo_ps_surface_emit_body (cairo_ps_surface_t *surface) { @@ -863,7 +991,7 @@ if (surface->eps) { _cairo_output_stream_printf (surface->final_stream, - "end restore\n"); + "end\n"); } _cairo_output_stream_printf (surface->final_stream, @@ -1065,12 +1193,14 @@ surface->paginated_mode = CAIRO_PAGINATED_MODE_ANALYZE; surface->force_fallbacks = FALSE; surface->content = CAIRO_CONTENT_COLOR_ALPHA; - surface->use_string_datasource = FALSE; surface->current_pattern_is_solid_color = FALSE; surface->document_bbox_p1.x = 0; surface->document_bbox_p1.y = 0; surface->document_bbox_p2.x = 0; surface->document_bbox_p2.y = 0; + surface->total_form_size = 0; + surface->contains_eps = FALSE; + surface->paint_proc = FALSE; _cairo_surface_clipper_init (&surface->clipper, _cairo_ps_surface_clipper_intersect_clip_path); @@ -1086,6 +1216,14 @@ _cairo_array_init (&surface->dsc_header_comments, sizeof (char *)); _cairo_array_init (&surface->dsc_setup_comments, sizeof (char *)); _cairo_array_init (&surface->dsc_page_setup_comments, sizeof (char *)); + _cairo_array_init (&surface->recording_surf_stack, sizeof (unsigned int)); + + surface->num_forms = 0; + surface->forms = _cairo_hash_table_create (_cairo_ps_form_equal); + if (unlikely (surface->forms == NULL)) { + status = _cairo_error (CAIRO_STATUS_NO_MEMORY); + goto CLEANUP_FONT_SUBSETS; + } surface->dsc_comment_target = &surface->dsc_header_comments; @@ -1100,6 +1238,7 @@ return surface->paginated_surface; } + CLEANUP_FONT_SUBSETS: _cairo_scaled_font_subsets_destroy (surface->font_subsets); CLEANUP_OUTPUT_STREAM: status_ignored = _cairo_output_stream_destroy (surface->stream); @@ -1622,10 +1761,17 @@ _cairo_ps_surface_emit_header (surface); + _cairo_output_stream_printf (surface->final_stream, + "%%%%BeginSetup\n"); + status = _cairo_ps_surface_emit_font_subsets (surface); if (unlikely (status)) goto CLEANUP; + status = _cairo_ps_surface_emit_forms (surface); + if (unlikely (status)) + goto CLEANUP; + _cairo_output_stream_printf (surface->final_stream, "%%%%EndSetup\n"); @@ -1636,6 +1782,10 @@ _cairo_ps_surface_emit_footer (surface); CLEANUP: + _cairo_hash_table_foreach (surface->forms, + _cairo_ps_form_pluck, + surface->forms); + _cairo_hash_table_destroy (surface->forms); _cairo_scaled_font_subsets_destroy (surface->font_subsets); status2 = _cairo_output_stream_destroy (surface->stream); @@ -1677,6 +1827,8 @@ free (comments[i]); _cairo_array_fini (&surface->dsc_page_setup_comments); + _cairo_array_fini (&surface->recording_surf_stack); + _cairo_surface_clipper_reset (&surface->clipper); return status; @@ -1725,7 +1877,8 @@ /** * _cairo_ps_surface_acquire_source_surface_from_pattern: * @surface: [in] the ps surface - * @pattern: [in] A #cairo_pattern_t of type SURFACE or RASTER_SOURCE to use as the source + * @pattern: [in] A #cairo_pattern_t of type SURFACE or RASTER_SOURCE to use + * as the source * @extents: [in] extents of the operation that is using this source * @src_surface_extents: [out] return source surface extents * @src_surface_bounded: [out] return TRUE if source surface is bounded @@ -1733,38 +1886,52 @@ * @source_surface: [out] returns surface of type image surface or recording surface * @x_offset: [out] return x offset of surface * @y_offset: [out] return y offset of surface - * @image_extra: [out] returns image extra for image type surface * * Acquire source surface or raster source pattern. **/ static cairo_status_t -_cairo_ps_surface_acquire_source_surface_from_pattern (cairo_ps_surface_t *surface, - const cairo_pattern_t *pattern, - const cairo_rectangle_int_t *extents, - cairo_rectangle_int_t *src_surface_extents, - cairo_bool_t *src_surface_bounded, - cairo_rectangle_int_t *src_op_extents, - cairo_surface_t **source_surface, - double *x_offset, - double *y_offset, - void **image_extra) +_cairo_ps_surface_acquire_source_surface_from_pattern ( + cairo_ps_surface_t *surface, + const cairo_pattern_t *pattern, + const cairo_rectangle_int_t *extents, + cairo_rectangle_int_t *src_surface_extents, + cairo_bool_t *src_surface_bounded, + cairo_rectangle_int_t *src_op_extents, + cairo_surface_t **source_surface, + double *x_offset, + double *y_offset) { - cairo_status_t status; - cairo_image_surface_t *image; + cairo_status_t status; + cairo_box_t bbox; *x_offset = 0; *y_offset = 0; - *image_extra = NULL; - switch (pattern->type) { - case CAIRO_PATTERN_TYPE_SURFACE: { - cairo_box_t bbox; - cairo_surface_t *surf = ((cairo_surface_pattern_t *) pattern)->surface; + /* get the operation extents in pattern space */ + _cairo_box_from_rectangle (&bbox, extents); + _cairo_matrix_transform_bounding_box_fixed (&pattern->matrix, &bbox, NULL); + _cairo_box_round_to_rectangle (&bbox, src_op_extents); + + if (pattern->type == CAIRO_PATTERN_TYPE_RASTER_SOURCE) { + cairo_surface_t *surf; + + surf = _cairo_raster_source_pattern_acquire (pattern, &surface->base, src_op_extents); + if (!surf) + return CAIRO_INT_STATUS_UNSUPPORTED; + + *src_surface_bounded = _cairo_surface_get_extents (surf, src_surface_extents); + cairo_surface_get_device_offset (surf, x_offset, y_offset); + *source_surface = surf; + } else if (pattern->type == CAIRO_PATTERN_TYPE_SURFACE) { + cairo_surface_t *surf = NULL; + + *source_surface = ((cairo_surface_pattern_t *) pattern)->surface; + surf = *source_surface; + *src_surface_bounded = _cairo_surface_get_extents (surf, src_surface_extents); if (surf->type == CAIRO_SURFACE_TYPE_RECORDING) { - if (_cairo_surface_is_snapshot (surf)) { + if (_cairo_surface_is_snapshot (surf)) surf = _cairo_surface_snapshot_get_target (surf); - *image_extra = surf; - } + if (surf->backend->type == CAIRO_SURFACE_TYPE_SUBSURFACE) { cairo_surface_subsurface_t *sub = (cairo_surface_subsurface_t *) surf; @@ -1772,89 +1939,34 @@ *src_surface_bounded = TRUE; *x_offset = -sub->extents.x; *y_offset = -sub->extents.y; - } else { - *src_surface_bounded = _cairo_surface_get_extents (surf, src_surface_extents); - } - *source_surface = surf; - _cairo_box_from_rectangle (&bbox, extents); - _cairo_matrix_transform_bounding_box_fixed (&pattern->matrix, &bbox, NULL); - _cairo_box_round_to_rectangle (&bbox, src_op_extents); - - return CAIRO_STATUS_SUCCESS; - } else { - status = _cairo_surface_acquire_source_image (surf, &image, image_extra); - if (unlikely (status)) { - cairo_surface_destroy (*image_extra); - return status; } - } - } break; - case CAIRO_PATTERN_TYPE_RASTER_SOURCE: { - cairo_surface_t *surf; - cairo_box_t box; - cairo_rectangle_int_t rect; + cairo_surface_destroy (surf); + } else if (surf->type != CAIRO_SURFACE_TYPE_IMAGE) { + cairo_image_surface_t *image; + void *image_extra; - /* get the operation extents in pattern space */ - _cairo_box_from_rectangle (&box, extents); - _cairo_matrix_transform_bounding_box_fixed (&pattern->matrix, &box, NULL); - _cairo_box_round_to_rectangle (&box, &rect); - surf = _cairo_raster_source_pattern_acquire (pattern, &surface->base, &rect); - if (!surf) - return CAIRO_INT_STATUS_UNSUPPORTED; - assert (_cairo_surface_is_image (surf)); - image = (cairo_image_surface_t *) surf; - cairo_surface_get_device_offset (surf, x_offset, y_offset); - } break; + status = _cairo_surface_acquire_source_image (surf, &image, &image_extra); + if (unlikely (status)) + return status; - case CAIRO_PATTERN_TYPE_SOLID: - case CAIRO_PATTERN_TYPE_LINEAR: - case CAIRO_PATTERN_TYPE_RADIAL: - case CAIRO_PATTERN_TYPE_MESH: - default: + *src_surface_bounded = _cairo_surface_get_extents (&image->base, src_surface_extents); + _cairo_surface_release_source_image (surf, image, image_extra); + } + } else { ASSERT_NOT_REACHED; - break; } - src_surface_extents->x = 0; - src_surface_extents->y = 0; - src_surface_extents->width = image->width; - src_surface_extents->height = image->height; - *src_surface_bounded = TRUE; - *source_surface = &image->base; return CAIRO_STATUS_SUCCESS; } static void _cairo_ps_surface_release_source_surface_from_pattern (cairo_ps_surface_t *surface, const cairo_pattern_t *pattern, - cairo_surface_t *source_surface, - void *image_extra) + cairo_surface_t *source_surface) { - switch (pattern->type) { - case CAIRO_PATTERN_TYPE_SURFACE: { - cairo_surface_pattern_t *surf_pat = (cairo_surface_pattern_t *) pattern; - if (surf_pat->surface->type == CAIRO_SURFACE_TYPE_RECORDING) { - cairo_surface_destroy (image_extra); - } else { - cairo_image_surface_t *image = (cairo_image_surface_t *) source_surface; - _cairo_surface_release_source_image (surf_pat->surface, image, image_extra); - } - } break; - - case CAIRO_PATTERN_TYPE_RASTER_SOURCE: + if (pattern->type == CAIRO_PATTERN_TYPE_RASTER_SOURCE) _cairo_raster_source_pattern_release (pattern, source_surface); - break; - - case CAIRO_PATTERN_TYPE_SOLID: - case CAIRO_PATTERN_TYPE_LINEAR: - case CAIRO_PATTERN_TYPE_RADIAL: - case CAIRO_PATTERN_TYPE_MESH: - default: - - ASSERT_NOT_REACHED; - break; - } } /** @@ -1895,11 +2007,9 @@ _cairo_fixed_integer_floor(box.p2.y) > w || _cairo_fixed_integer_floor(box.p2.y) > h) { - pad_image = - _cairo_image_surface_create_with_pixman_format (NULL, - source->pixman_format, - rect.width, rect.height, - 0); + pad_image = _cairo_image_surface_create_with_content (source->base.content, + rect.width, + rect.height); if (pad_image->status) return pad_image->status; @@ -1934,8 +2044,8 @@ cairo_rectangle_int_t src_op_extents; cairo_surface_t *source_surface; double x_offset, y_offset; - void *image_extra; cairo_image_surface_t *image; + void *image_extra; cairo_int_status_t status; cairo_image_transparency_t transparency; @@ -1947,13 +2057,14 @@ &src_op_extents, &source_surface, &x_offset, - &y_offset, - &image_extra); + &y_offset); + if (unlikely (status)) + return status; + + status = _cairo_surface_acquire_source_image (source_surface, &image, &image_extra); if (unlikely (status)) return status; - assert (_cairo_surface_is_image (source_surface)); - image = (cairo_image_surface_t *) source_surface; if (image->base.status) return image->base.status; @@ -1980,7 +2091,8 @@ ASSERT_NOT_REACHED; } - _cairo_ps_surface_release_source_surface_from_pattern (surface, pattern, source_surface, image_extra); + _cairo_surface_release_source_image (source_surface, image, image_extra); + _cairo_ps_surface_release_source_surface_from_pattern (surface, pattern, source_surface); return status; } @@ -2167,14 +2279,9 @@ /* The "standard" implementation limit for PostScript string sizes is * 65535 characters (see PostScript Language Reference, Appendix - * B). We go one short of that because we sometimes need two - * characters in a string to represent a single ASCII85 byte, (for the - * escape sequences "\\", "\(", and "\)") and we must not split these - * across two strings. So we'd be in trouble if we went right to the - * limit and one of these escape sequences just happened to land at - * the end. + * B). */ -#define STRING_ARRAY_MAX_STRING_SIZE (65535-1) +#define STRING_ARRAY_MAX_STRING_SIZE 65535 #define STRING_ARRAY_MAX_COLUMN 72 typedef struct _string_array_stream { @@ -2182,64 +2289,62 @@ cairo_output_stream_t *output; int column; int string_size; + int tuple_count; cairo_bool_t use_strings; } string_array_stream_t; static cairo_status_t -_string_array_stream_write (cairo_output_stream_t *base, - const unsigned char *data, - unsigned int length) +_base85_string_wrap_stream_write (cairo_output_stream_t *base, + const unsigned char *data, + unsigned int length) { string_array_stream_t *stream = (string_array_stream_t *) base; unsigned char c; - const unsigned char backslash = '\\'; if (length == 0) return CAIRO_STATUS_SUCCESS; while (length--) { - if (stream->string_size == 0 && stream->use_strings) { - _cairo_output_stream_printf (stream->output, "("); - stream->column++; - } - - c = *data++; - if (stream->use_strings) { - switch (c) { - case '\\': - case '(': - case ')': - _cairo_output_stream_write (stream->output, &backslash, 1); - stream->column++; - stream->string_size++; - break; + if (stream->column == 0) { + if (stream->use_strings) { + _cairo_output_stream_printf (stream->output, "<~"); + stream->column = 2; + } else { + _cairo_output_stream_printf (stream->output, " "); + stream->column = 1; } } - /* Have to be careful to never split the final ~> sequence. */ - if (c == '~') { - _cairo_output_stream_write (stream->output, &c, 1); - stream->column++; - stream->string_size++; - if (length-- == 0) - break; - - c = *data++; - } + c = *data++; _cairo_output_stream_write (stream->output, &c, 1); stream->column++; - stream->string_size++; + /* Base85 encodes each 4 byte tuple with a 5 ASCII character + * tuple, except for 'z' with represents 4 zero bytes. We need + * to keep track of the string length after decoding. + */ + if (c == 'z') { + stream->string_size += 4; + stream->tuple_count = 0; + } else { + if (++stream->tuple_count == 5) { + stream->string_size += 4; + stream->tuple_count = 0; + } + } + + /* Split string at tuple boundary when there is not enough + * space for another tuple */ if (stream->use_strings && - stream->string_size >= STRING_ARRAY_MAX_STRING_SIZE) + stream->tuple_count == 0 && + stream->string_size > STRING_ARRAY_MAX_STRING_SIZE - 4) { - _cairo_output_stream_printf (stream->output, ")\n"); + _cairo_output_stream_printf (stream->output, "~>\n"); stream->string_size = 0; stream->column = 0; } if (stream->column >= STRING_ARRAY_MAX_COLUMN) { _cairo_output_stream_printf (stream->output, "\n "); - stream->string_size += 2; stream->column = 1; } } @@ -2248,35 +2353,28 @@ } static cairo_status_t -_string_array_stream_close (cairo_output_stream_t *base) +_base85_string_wrap_stream_close (cairo_output_stream_t *base) { - cairo_status_t status; string_array_stream_t *stream = (string_array_stream_t *) base; - if (stream->use_strings) - _cairo_output_stream_printf (stream->output, ")\n"); + if (!stream->use_strings || stream->string_size != 0) + _cairo_output_stream_printf (stream->output, "~>"); - status = _cairo_output_stream_get_status (stream->output); - - return status; + return _cairo_output_stream_get_status (stream->output); } -/* A string_array_stream wraps an existing output stream. It takes the - * data provided to it and output one or more consecutive string - * objects, each within the standard PostScript implementation limit - * of 65k characters. - * - * The strings are each separated by a space character for easy - * inclusion within an array object, (but the array delimiters are not - * added by the string_array_stream). - * +/* A _base85_strings_stream wraps an existing output stream. It takes + * base85 encoded data and splits it into strings each limited to + * STRING_ARRAY_MAX_STRING_SIZE bytes when decoded. Each string is + * enclosed in "<~" and "~>". + * The string array stream is also careful to wrap the output within - * STRING_ARRAY_MAX_COLUMN columns (+/- 1). The stream also adds - * necessary escaping for special characters within a string, - * (specifically '\', '(', and ')'). + * STRING_ARRAY_MAX_COLUMN columns. Wrapped lines start with a space + * in case an encoded line starts with %% which could be interpreted + * as a DSC comment. */ static cairo_output_stream_t * -_string_array_stream_create (cairo_output_stream_t *output) +_base85_strings_stream_create (cairo_output_stream_t *output) { string_array_stream_t *stream; @@ -2287,23 +2385,26 @@ } _cairo_output_stream_init (&stream->base, - _string_array_stream_write, + _base85_string_wrap_stream_write, NULL, - _string_array_stream_close); + _base85_string_wrap_stream_close); stream->output = output; stream->column = 0; stream->string_size = 0; + stream->tuple_count = 0; stream->use_strings = TRUE; return &stream->base; } -/* A base85_array_stream wraps an existing output stream. It wraps the - * output within STRING_ARRAY_MAX_COLUMN columns (+/- 1). The output - * is not enclosed in strings like string_array_stream. +/* A base85_wrap_stream wraps an existing output stream. It wraps the + * output within STRING_ARRAY_MAX_COLUMN columns. A base85 EOD "~>" is + * appended to the end. Wrapped lines start with a space in case an + * encoded line starts with %% which could be interpreted as a DSC + * comment. */ static cairo_output_stream_t * -_base85_array_stream_create (cairo_output_stream_t *output) +_base85_wrap_stream_create (cairo_output_stream_t *output) { string_array_stream_t *stream; @@ -2314,12 +2415,13 @@ } _cairo_output_stream_init (&stream->base, - _string_array_stream_write, + _base85_string_wrap_stream_write, NULL, - _string_array_stream_close); + _base85_string_wrap_stream_close); stream->output = output; stream->column = 0; stream->string_size = 0; + stream->tuple_count = 0; stream->use_strings = FALSE; return &stream->base; @@ -2381,9 +2483,9 @@ cairo_status_t status, status2; if (use_strings) - string_array_stream = _string_array_stream_create (surface->stream); + string_array_stream = _base85_strings_stream_create (surface->stream); else - string_array_stream = _base85_array_stream_create (surface->stream); + string_array_stream = _base85_wrap_stream_create (surface->stream); status = _cairo_output_stream_get_status (string_array_stream); if (unlikely (status)) @@ -2430,9 +2532,6 @@ break; } status = _cairo_output_stream_destroy (base85_stream); - - /* Mark end of base85 data */ - _cairo_output_stream_printf (string_array_stream, "~>"); status2 = _cairo_output_stream_destroy (string_array_stream); if (status == CAIRO_STATUS_SUCCESS) status = status2; @@ -2440,12 +2539,32 @@ return status; } +static const char * +get_interpolate (cairo_filter_t filter) +{ + const char *interpolate; + + switch (filter) { + default: + case CAIRO_FILTER_GOOD: + case CAIRO_FILTER_BEST: + case CAIRO_FILTER_BILINEAR: + interpolate = "true"; + break; + case CAIRO_FILTER_FAST: + case CAIRO_FILTER_NEAREST: + case CAIRO_FILTER_GAUSSIAN: + interpolate = "false"; + break; + } + + return interpolate; +} + static cairo_status_t -_cairo_ps_surface_emit_image (cairo_ps_surface_t *surface, - cairo_image_surface_t *image_surf, - cairo_operator_t op, - cairo_filter_t filter, - cairo_bool_t stencil_mask) +_cairo_ps_surface_emit_image (cairo_ps_surface_t *surface, + cairo_emit_surface_mode_t mode, + cairo_emit_surface_params_t *params) { cairo_status_t status; unsigned char *data; @@ -2461,10 +2580,16 @@ const char *interpolate; cairo_ps_compress_t compress; const char *compress_filter; + cairo_image_surface_t *image_surf; cairo_image_surface_t *image; + void *image_extra; - if (image_surf->base.status) - return image_surf->base.status; + if (params->src_surface->status) + return params->src_surface->status; + + status = _cairo_surface_acquire_source_image (params->src_surface, &image_surf, &image_extra); + if (unlikely (status)) + return status; image = image_surf; if (image->format != CAIRO_FORMAT_RGB24 && @@ -2475,16 +2600,16 @@ cairo_surface_t *surf; cairo_surface_pattern_t pattern; - surf = _cairo_image_surface_create_with_content (image_surf->base.content, - image_surf->width, - image_surf->height); + surf = _cairo_image_surface_create_with_content (image->base.content, + image->width, + image->height); image = (cairo_image_surface_t *) surf; if (surf->status) { status = surf->status; goto bail0; } - _cairo_pattern_init_for_surface (&pattern, &image_surf->base); + _cairo_pattern_init_for_surface (&pattern, &image->base); status = _cairo_surface_paint (surf, CAIRO_OPERATOR_SOURCE, &pattern.base, NULL); @@ -2493,22 +2618,9 @@ goto bail0; } ps_image = image; + interpolate = get_interpolate (params->filter); - switch (filter) { - default: - case CAIRO_FILTER_GOOD: - case CAIRO_FILTER_BEST: - case CAIRO_FILTER_BILINEAR: - interpolate = "true"; - break; - case CAIRO_FILTER_FAST: - case CAIRO_FILTER_NEAREST: - case CAIRO_FILTER_GAUSSIAN: - interpolate = "false"; - break; - } - - if (stencil_mask) { + if (params->stencil_mask) { use_mask = FALSE; color = CAIRO_IMAGE_IS_MONOCHROME; transparency = CAIRO_IMAGE_HAS_BILEVEL_ALPHA; @@ -2519,7 +2631,7 @@ current image over a white (or black for CONTENT_COLOR surfaces) RGB surface to eliminate it. */ - if (op == CAIRO_OPERATOR_SOURCE || + if (params->op == CAIRO_OPERATOR_SOURCE || transparency == CAIRO_IMAGE_HAS_ALPHA || (transparency == CAIRO_IMAGE_HAS_BILEVEL_ALPHA && surface->ps_level == CAIRO_PS_LEVEL_2)) @@ -2569,7 +2681,7 @@ i = 0; for (y = 0; y < ps_image->height; y++) { - if (stencil_mask || use_mask) { + if (params->stencil_mask || use_mask) { /* mask row */ if (ps_image->format == CAIRO_FORMAT_A1) { pixel8 = (uint8_t *) (ps_image->data + y * ps_image->stride); @@ -2610,7 +2722,7 @@ i++; } } - if (stencil_mask) + if (params->stencil_mask) continue; /* image row*/ @@ -2675,11 +2787,11 @@ surface->ps_level_used = CAIRO_PS_LEVEL_3; } - if (surface->use_string_datasource) { + if (surface->paint_proc) { /* Emit the image data as a base85-encoded string which will * be used as the data source for the image operator later. */ _cairo_output_stream_printf (surface->stream, - "/CairoImageData [\n"); + "/CairoData [\n"); status = _cairo_ps_surface_emit_base85_string (surface, data, @@ -2692,7 +2804,7 @@ _cairo_output_stream_printf (surface->stream, "] def\n"); _cairo_output_stream_printf (surface->stream, - "/CairoImageDataIndex 0 def\n"); + "/CairoDataIndex 0 def\n"); } else { _cairo_output_stream_printf (surface->stream, "/cairo_ascii85_file currentfile /ASCII85Decode filter def\n"); @@ -2701,17 +2813,16 @@ if (use_mask) { _cairo_output_stream_printf (surface->stream, "%s setcolorspace\n" - "5 dict dup begin\n" - " /ImageType 3 def\n" - " /InterleaveType 2 def\n" - " /DataDict 8 dict def\n" - " DataDict begin\n" - " /ImageType 1 def\n" - " /Width %d def\n" - " /Height %d def\n" - " /Interpolate %s def\n" - " /BitsPerComponent %d def\n" - " /Decode [ %s ] def\n", + "<<\n" + " /ImageType 3\n" + " /InterleaveType 2\n" + " /DataDict <<\n" + " /ImageType 1\n" + " /Width %d\n" + " /Height %d\n" + " /Interpolate %s\n" + " /BitsPerComponent %d\n" + " /Decode [ %s ]\n", color == CAIRO_IMAGE_IS_COLOR ? "/DeviceRGB" : "/DeviceGray", ps_image->width, ps_image->height, @@ -2719,85 +2830,89 @@ color == CAIRO_IMAGE_IS_MONOCHROME ? 1 : 8, color == CAIRO_IMAGE_IS_COLOR ? "0 1 0 1 0 1" : "0 1"); - if (surface->use_string_datasource) { + if (surface->paint_proc) { _cairo_output_stream_printf (surface->stream, - " /DataSource {\n" - " CairoImageData CairoImageDataIndex get\n" - " /CairoImageDataIndex CairoImageDataIndex 1 add def\n" - " CairoImageDataIndex CairoImageData length 1 sub gt\n" - " { /CairoImageDataIndex 0 def } if\n" - " } /ASCII85Decode filter /%s filter def\n", + " /DataSource { cairo_data_source } /%s filter\n", compress_filter); } else { _cairo_output_stream_printf (surface->stream, - " /DataSource cairo_ascii85_file /%s filter def\n", + " /DataSource cairo_ascii85_file /%s filter\n", compress_filter); } _cairo_output_stream_printf (surface->stream, - " /ImageMatrix [ 1 0 0 -1 0 %d ] def\n" - " end\n" - " /MaskDict 8 dict def\n" - " MaskDict begin\n" - " /ImageType 1 def\n" - " /Width %d def\n" - " /Height %d def\n" - " /Interpolate %s def\n" - " /BitsPerComponent 1 def\n" - " /Decode [ 1 0 ] def\n" - " /ImageMatrix [ 1 0 0 -1 0 %d ] def\n" - " end\n" - "end\n" + " /ImageMatrix [ %d 0 0 %d 0 %d ]\n" + " >>\n" + " /MaskDict <<\n" + " /ImageType 1\n" + " /Width %d\n" + " /Height %d\n" + " /Interpolate %s\n" + " /BitsPerComponent 1\n" + " /Decode [ 1 0 ]\n" + " /ImageMatrix [ %d 0 0 %d 0 %d ]\n" + " >>\n" + ">>\n" "image\n", + ps_image->width, + -ps_image->height, ps_image->height, ps_image->width, ps_image->height, interpolate, + ps_image->width, + -ps_image->height, ps_image->height); } else { - if (!stencil_mask) { + const char *decode; + + if (!params->stencil_mask) { _cairo_output_stream_printf (surface->stream, "%s setcolorspace\n", color == CAIRO_IMAGE_IS_COLOR ? "/DeviceRGB" : "/DeviceGray"); } + if (params->stencil_mask) + decode = "1 0"; + else if (color == CAIRO_IMAGE_IS_COLOR) + decode = "0 1 0 1 0 1"; + else + decode ="0 1"; + _cairo_output_stream_printf (surface->stream, - "8 dict dup begin\n" - " /ImageType 1 def\n" - " /Width %d def\n" - " /Height %d def\n" - " /Interpolate %s def\n" - " /BitsPerComponent %d def\n" - " /Decode [ %s ] def\n", + "<<\n" + " /ImageType 1\n" + " /Width %d\n" + " /Height %d\n" + " /Interpolate %s\n" + " /BitsPerComponent %d\n" + " /Decode [ %s ]\n", ps_image->width, ps_image->height, interpolate, color == CAIRO_IMAGE_IS_MONOCHROME ? 1 : 8, - stencil_mask ? "1 0" : color == CAIRO_IMAGE_IS_COLOR ? "0 1 0 1 0 1" : "0 1"); - if (surface->use_string_datasource) { + decode); + if (surface->paint_proc) { _cairo_output_stream_printf (surface->stream, - " /DataSource {\n" - " CairoImageData CairoImageDataIndex get\n" - " /CairoImageDataIndex CairoImageDataIndex 1 add def\n" - " CairoImageDataIndex CairoImageData length 1 sub gt\n" - " { /CairoImageDataIndex 0 def } if\n" - " } /ASCII85Decode filter /%s filter def\n", + " /DataSource { cairo_data_source } /%s filter\n", compress_filter); } else { _cairo_output_stream_printf (surface->stream, - " /DataSource cairo_ascii85_file /%s filter def\n", + " /DataSource cairo_ascii85_file /%s filter\n", compress_filter); } _cairo_output_stream_printf (surface->stream, - " /ImageMatrix [ 1 0 0 -1 0 %d ] def\n" - "end\n" + " /ImageMatrix [ %d 0 0 %d 0 %d ]\n" + ">>\n" "%s%s\n", + ps_image->width, + -ps_image->height, ps_image->height, - surface->use_string_datasource ? "" : "cairo_", - stencil_mask ? "imagemask" : "image"); + surface->paint_proc ? "" : "cairo_", + params->stencil_mask ? "imagemask" : "image"); } - if (!surface->use_string_datasource) { + if (!surface->paint_proc) { /* Emit the image data as a base85-encoded string which will * be used as the data source for the image operator. */ status = _cairo_ps_surface_emit_base85_string (surface, @@ -2821,14 +2936,15 @@ if (image != image_surf) cairo_surface_destroy (&image->base); + _cairo_surface_release_source_image (params->src_surface, image_surf, image_extra); + return status; } -static cairo_status_t -_cairo_ps_surface_emit_jpeg_image (cairo_ps_surface_t *surface, - cairo_surface_t *source, - int width, - int height) +static cairo_int_status_t +_cairo_ps_surface_emit_jpeg_image (cairo_ps_surface_t *surface, + cairo_emit_surface_mode_t mode, + cairo_emit_surface_params_t *params) { cairo_status_t status; const unsigned char *mime_data; @@ -2837,10 +2953,11 @@ const char *colorspace; const char *decode; - cairo_surface_get_mime_data (source, CAIRO_MIME_TYPE_JPEG, + if (unlikely (params->src_surface->status)) + return params->src_surface->status; + + cairo_surface_get_mime_data (params->src_surface, CAIRO_MIME_TYPE_JPEG, &mime_data, &mime_data_length); - if (unlikely (source->status)) - return source->status; if (mime_data == NULL) return CAIRO_INT_STATUS_UNSUPPORTED; @@ -2865,11 +2982,18 @@ return CAIRO_INT_STATUS_UNSUPPORTED; } - if (surface->use_string_datasource) { + /* At this point we know emitting jpeg will succeed. */ + if (mode == CAIRO_EMIT_SURFACE_ANALYZE) { + params->is_image = TRUE; + params->approx_size = mime_data_length; + return CAIRO_STATUS_SUCCESS; + } + + if (surface->paint_proc) { /* Emit the image data as a base85-encoded string which will * be used as the data source for the image operator later. */ _cairo_output_stream_printf (surface->stream, - "/CairoImageData [\n"); + "/CairoData [\n"); status = _cairo_ps_surface_emit_base85_string (surface, mime_data, @@ -2882,7 +3006,7 @@ _cairo_output_stream_printf (surface->stream, "] def\n"); _cairo_output_stream_printf (surface->stream, - "/CairoImageDataIndex 0 def\n"); + "/CairoDataIndex 0 def\n"); } else { _cairo_output_stream_printf (surface->stream, "/cairo_ascii85_file currentfile /ASCII85Decode filter def\n"); @@ -2890,39 +3014,38 @@ _cairo_output_stream_printf (surface->stream, "%s setcolorspace\n" - "8 dict dup begin\n" - " /ImageType 1 def\n" - " /Width %d def\n" - " /Height %d def\n" - " /BitsPerComponent %d def\n" - " /Decode [ %s ] def\n", + "<<\n" + " /ImageType 1\n" + " /Width %d\n" + " /Height %d\n" + " /BitsPerComponent %d\n" + " /Interpolate %s\n" + " /Decode [ %s ]\n", colorspace, info.width, info.height, info.bits_per_component, + get_interpolate (params->filter), decode); - if (surface->use_string_datasource) { + if (surface->paint_proc) { _cairo_output_stream_printf (surface->stream, - " /DataSource {\n" - " CairoImageData CairoImageDataIndex get\n" - " /CairoImageDataIndex CairoImageDataIndex 1 add def\n" - " CairoImageDataIndex CairoImageData length 1 sub gt\n" - " { /CairoImageDataIndex 0 def } if\n" - " } /ASCII85Decode filter /DCTDecode filter def\n"); + " /DataSource { cairo_data_source } /DCTDecode filter\n"); } else { _cairo_output_stream_printf (surface->stream, - " /DataSource cairo_ascii85_file /DCTDecode filter def\n"); + " /DataSource cairo_ascii85_file /DCTDecode filter\n"); } _cairo_output_stream_printf (surface->stream, - " /ImageMatrix [ 1 0 0 -1 0 %d ] def\n" - "end\n" + " /ImageMatrix [ %d 0 0 %d 0 %d ]\n" + ">>\n" "%simage\n", + info.width, + -info.height, info.height, - surface->use_string_datasource ? "" : "cairo_"); + surface->paint_proc ? "" : "cairo_"); - if (!surface->use_string_datasource) { + if (!surface->paint_proc) { /* Emit the image data as a base85-encoded string which will * be used as the data source for the image operator. */ status = _cairo_ps_surface_emit_base85_string (surface, @@ -2935,6 +3058,271 @@ return status; } +static cairo_int_status_t +_cairo_ps_surface_emit_ccitt_image (cairo_ps_surface_t *surface, + cairo_emit_surface_mode_t mode, + cairo_emit_surface_params_t *params) +{ + cairo_status_t status; + const unsigned char *ccitt_data; + unsigned long ccitt_data_len; + const unsigned char *ccitt_params_data; + unsigned long ccitt_params_data_len; + char *ccitt_params_string; + cairo_ccitt_params_t ccitt_params; + + if (unlikely (params->src_surface->status)) + return params->src_surface->status; + + cairo_surface_get_mime_data (params->src_surface, CAIRO_MIME_TYPE_CCITT_FAX, + &ccitt_data, &ccitt_data_len); + if (ccitt_data == NULL) + return CAIRO_INT_STATUS_UNSUPPORTED; + + cairo_surface_get_mime_data (params->src_surface, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, + &ccitt_params_data, &ccitt_params_data_len); + if (ccitt_params_data == NULL) + return CAIRO_INT_STATUS_UNSUPPORTED; + + /* ensure params_string is null terminated */ + ccitt_params_string = malloc (ccitt_params_data_len + 1); + memcpy (ccitt_params_string, ccitt_params_data, ccitt_params_data_len); + ccitt_params_string[ccitt_params_data_len] = 0; + status = _cairo_tag_parse_ccitt_params (ccitt_params_string, &ccitt_params); + if (unlikely(status)) + return status; + + free (ccitt_params_string); + + if (ccitt_params.columns <= 0 || ccitt_params.rows <= 0) + return CAIRO_INT_STATUS_UNSUPPORTED; + + /* At this point we know emitting ccitt will succeed. */ + if (mode == CAIRO_EMIT_SURFACE_ANALYZE) { + params->is_image = TRUE; + params->approx_size = ccitt_data_len; + return CAIRO_STATUS_SUCCESS; + } + + if (surface->paint_proc) { + /* Emit the image data as a base85-encoded string which will + * be used as the data source for the image operator later. */ + _cairo_output_stream_printf (surface->stream, + "/CairoData [\n"); + + status = _cairo_ps_surface_emit_base85_string (surface, + ccitt_data, + ccitt_data_len, + CAIRO_PS_COMPRESS_NONE, + TRUE); + if (unlikely (status)) + return status; + + _cairo_output_stream_printf (surface->stream, + "] def\n"); + _cairo_output_stream_printf (surface->stream, + "/CairoDataIndex 0 def\n"); + } else { + _cairo_output_stream_printf (surface->stream, + "/cairo_ascii85_file currentfile /ASCII85Decode filter def\n"); + } + + if (!params->stencil_mask) { + _cairo_output_stream_printf (surface->stream, + "/DeviceGray setcolorspace\n"); + } + + _cairo_output_stream_printf (surface->stream, + "<<\n" + " /ImageType 1\n" + " /Width %d\n" + " /Height %d\n" + " /BitsPerComponent 1\n" + " /Interpolate %s\n" + " /Decode [ 0 1 ]\n", + ccitt_params.columns, + ccitt_params.rows, + get_interpolate (params->filter)); + + if (surface->paint_proc) { + _cairo_output_stream_printf (surface->stream, + " /DataSource { cairo_data_source }\n"); + } else { + _cairo_output_stream_printf (surface->stream, + " /DataSource cairo_ascii85_file\n"); + } + + _cairo_output_stream_printf (surface->stream, + " << /Columns %d /Rows %d /K %d\n", + ccitt_params.columns, + ccitt_params.rows, + ccitt_params.k); + + if (ccitt_params.end_of_line) + _cairo_output_stream_printf (surface->stream, " /EndOfLine true\n"); + + if (ccitt_params.encoded_byte_align) + _cairo_output_stream_printf (surface->stream, " /EncodedByteAlign true\n"); + + if (!ccitt_params.end_of_block) + _cairo_output_stream_printf (surface->stream, " /EndOfBlock false\n"); + + if (ccitt_params.black_is_1) + _cairo_output_stream_printf (surface->stream, " /BlackIs1 true\n"); + + if (ccitt_params.damaged_rows_before_error > 0) { + _cairo_output_stream_printf (surface->stream, + " /DamagedRowsBeforeError %d\n", + ccitt_params.damaged_rows_before_error); + } + + _cairo_output_stream_printf (surface->stream, + " >> /CCITTFaxDecode filter\n"); + + _cairo_output_stream_printf (surface->stream, + " /ImageMatrix [ %d 0 0 %d 0 %d ]\n" + ">>\n" + "%s%s\n", + ccitt_params.columns, + -ccitt_params.rows, + ccitt_params.rows, + surface->paint_proc ? "" : "cairo_", + params->stencil_mask ? "imagemask" : "image"); + + if (!surface->paint_proc) { + /* Emit the image data as a base85-encoded string which will + * be used as the data source for the image operator. */ + status = _cairo_ps_surface_emit_base85_string (surface, + ccitt_data, + ccitt_data_len, + CAIRO_PS_COMPRESS_NONE, + FALSE); + } + + return status; +} + +/* The '|' character is not used in PS (including ASCII85). We can + * speed up the search by first searching for the first char before + * comparing strings. + */ +#define SUBFILE_FILTER_EOD "|EOD|" + +/* Count number of non overlapping occurrences of SUBFILE_FILTER_EOD in data. */ +static int +count_eod_strings (const unsigned char *data, unsigned long data_len) +{ + const unsigned char *p = data; + const unsigned char *end; + int first_char, len, count; + const char *eod_str = SUBFILE_FILTER_EOD; + + first_char = eod_str[0]; + len = strlen (eod_str); + p = data; + end = data + data_len - len + 1; + count = 0; + while (p < end) { + p = memchr (p, first_char, end - p); + if (!p) + break; + + if (memcmp (p, eod_str, len) == 0) { + count++; + p += len; + } + } + + return count; +} + +static cairo_status_t +_cairo_ps_surface_emit_eps (cairo_ps_surface_t *surface, + cairo_emit_surface_mode_t mode, + cairo_emit_surface_params_t *params) +{ + cairo_status_t status; + const unsigned char *eps_data = NULL; + unsigned long eps_data_len; + const unsigned char *eps_params_string = NULL; + unsigned long eps_params_string_len; + char *params_string = NULL; + cairo_eps_params_t eps_params; + cairo_matrix_t mat; + double eps_width, eps_height; + + if (unlikely (params->src_surface->status)) + return params->src_surface->status; + + /* We only embed EPS with level 3 as we may use ReusableStreamDecode and we + * don't know what level the EPS file requires. */ + if (surface->ps_level == CAIRO_PS_LEVEL_2) + return CAIRO_INT_STATUS_UNSUPPORTED; + + cairo_surface_get_mime_data (params->src_surface, CAIRO_MIME_TYPE_EPS, + &eps_data, &eps_data_len); + if (eps_data == NULL) + return CAIRO_INT_STATUS_UNSUPPORTED; + + cairo_surface_get_mime_data (params->src_surface, CAIRO_MIME_TYPE_EPS_PARAMS, + &eps_params_string, &eps_params_string_len); + if (eps_params_string == NULL) + return CAIRO_INT_STATUS_UNSUPPORTED; + + /* ensure params_string is null terminated */ + params_string = malloc (eps_params_string_len + 1); + memcpy (params_string, eps_params_string, eps_params_string_len); + params_string[eps_params_string_len] = 0; + status = _cairo_tag_parse_eps_params (params_string, &eps_params); + if (unlikely(status)) + return status; + + /* At this point we know emitting EPS will succeed. */ + if (mode == CAIRO_EMIT_SURFACE_ANALYZE) { + params->is_image = FALSE; + params->approx_size = eps_data_len; + surface->contains_eps = TRUE; + + /* Find number of occurences of SUBFILE_FILTER_EOD in the EPS data. + * We will need it before emitting the data if a ReusableStream is used. + */ + params->eod_count = count_eod_strings (eps_data, eps_data_len); + return CAIRO_STATUS_SUCCESS; + } + + surface->ps_level_used = CAIRO_PS_LEVEL_3; + _cairo_output_stream_printf (surface->stream, "cairo_eps_begin\n"); + + eps_width = eps_params.bbox.p2.x - eps_params.bbox.p1.x; + eps_height = eps_params.bbox.p2.y - eps_params.bbox.p1.y; + cairo_matrix_init_translate (&mat, + params->src_surface_extents->x, + params->src_surface_extents->y); + cairo_matrix_scale (&mat, + params->src_surface_extents->width/eps_width, + params->src_surface_extents->height/eps_height); + cairo_matrix_scale (&mat, 1, -1); + cairo_matrix_translate (&mat, -eps_params.bbox.p1.x, -eps_params.bbox.p2.y); + + if (! _cairo_matrix_is_identity (&mat)) { + _cairo_output_stream_printf (surface->stream, "[ "); + _cairo_output_stream_print_matrix (surface->stream, &mat); + _cairo_output_stream_printf (surface->stream, " ] concat\n"); + } + + _cairo_output_stream_printf (surface->stream, + "%f %f %f %f rectclip\n", + eps_params.bbox.p1.x, + eps_params.bbox.p1.y, + eps_width, + eps_height); + + _cairo_output_stream_write (surface->stream, eps_data, eps_data_len); + _cairo_output_stream_printf (surface->stream, "\ncairo_eps_end\n"); + + return CAIRO_STATUS_SUCCESS; +} + static cairo_status_t _cairo_ps_surface_emit_recording_surface (cairo_ps_surface_t *surface, cairo_surface_t *recording_surface, @@ -2948,6 +3336,25 @@ cairo_content_t old_content; cairo_surface_clipper_t old_clipper; cairo_int_status_t status; + cairo_surface_t *free_me = NULL; + unsigned int id; + int i, recording_surf_stack_size; + + /* Prevent infinite recursion if the recording_surface references a recording + * currently being emitted */ + recording_surf_stack_size = _cairo_array_num_elements (&surface->recording_surf_stack); + for (i = 0; i < recording_surf_stack_size; i++) { + _cairo_array_copy_element (&surface->recording_surf_stack, i, &id); + if (id == recording_surface->unique_id) + return CAIRO_STATUS_SUCCESS; + } + id = recording_surface->unique_id; + status = _cairo_array_append (&surface->recording_surf_stack, &id); + if (unlikely (status)) + return status; + + if (_cairo_surface_is_snapshot (recording_surface)) + free_me = recording_surface = _cairo_surface_snapshot_get_target (recording_surface); old_content = surface->content; old_width = surface->width; @@ -3015,6 +3422,9 @@ _cairo_pdf_operators_set_cairo_to_pdf_matrix (&surface->pdf_operators, &surface->cairo_to_ps); + cairo_surface_destroy (free_me); + + _cairo_array_truncate (&surface->recording_surf_stack, recording_surf_stack_size); return status; } @@ -3061,45 +3471,351 @@ red, green, blue); } -static cairo_status_t +/* + * PS Forms are used for sources that have CAIRO_MIME_TYPE_UNIQUE_ID. They will be + * emitted once in the PS header and can be rendered with the 'execform' operator. + * + * This function tries adding the source the form hash table. If the source does not + * have CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_INT_STATUS_UNSUPPORTED is returned. + + * @source: [in] the source for the form + * @params: [in] source parameters + * @test: [in] if TRUE, test if form will be used (excludes size check) + * @ps_form [out] the new or exisiting entry int the hash table. + * image or recording. + */ +static cairo_int_status_t +_cairo_ps_surface_use_form (cairo_ps_surface_t *surface, + cairo_emit_surface_params_t *params, + cairo_bool_t test, + cairo_ps_form_t **ps_form) +{ + cairo_ps_form_t source_key; + cairo_ps_form_t *source_entry; + unsigned char *unique_id = NULL; + unsigned long unique_id_length = 0; + cairo_status_t status; + long max_size; + + if (params->op != CAIRO_OPERATOR_OVER || params->stencil_mask) + return CAIRO_INT_STATUS_UNSUPPORTED; + + if (params->src_surface->backend->type == CAIRO_SURFACE_TYPE_SUBSURFACE) + return CAIRO_INT_STATUS_UNSUPPORTED; + + cairo_surface_get_mime_data (params->src_surface, CAIRO_MIME_TYPE_UNIQUE_ID, + (const unsigned char **) &source_key.unique_id, + &source_key.unique_id_length); + if (source_key.unique_id == NULL || source_key.unique_id_length == 0) + return CAIRO_INT_STATUS_UNSUPPORTED; + + if (test) + return CAIRO_STATUS_SUCCESS; + + source_key.filter = params->filter; + _cairo_ps_form_init_key (&source_key); + source_entry = _cairo_hash_table_lookup (surface->forms, &source_key.base); + if (source_entry) { + _cairo_rectangle_union (&source_entry->required_extents, params->src_op_extents); + *ps_form = source_entry; + return CAIRO_STATUS_SUCCESS; + } + + if (surface->ps_level == CAIRO_PS_LEVEL_3) + max_size = MAX_L3_FORM_DATA; + else + max_size = MAX_L3_FORM_DATA; + + /* Don't add any more Forms if we exceed the form memory limit */ + if (surface->total_form_size + params->approx_size > max_size) + return CAIRO_INT_STATUS_UNSUPPORTED; + + surface->total_form_size += params->approx_size > max_size; + unique_id = _cairo_malloc (source_key.unique_id_length); + if (unique_id == NULL) + return _cairo_error (CAIRO_STATUS_NO_MEMORY); + + unique_id_length = source_key.unique_id_length; + memcpy (unique_id, source_key.unique_id, unique_id_length); + + source_entry = calloc (sizeof (cairo_ps_form_t), 1); + if (source_entry == NULL) { + status = _cairo_error (CAIRO_STATUS_NO_MEMORY); + goto fail; + } + + source_entry->unique_id_length = unique_id_length; + source_entry->unique_id = unique_id; + source_entry->id = surface->num_forms++; + source_entry->src_surface = cairo_surface_reference (params->src_surface); + source_entry->required_extents = *params->src_op_extents; + source_entry->filter = params->filter; + source_entry->is_image = params->is_image; + _cairo_ps_form_init_key (source_entry); + status = _cairo_hash_table_insert (surface->forms, &source_entry->base); + if (unlikely(status)) + goto fail; + + *ps_form = source_entry; + return CAIRO_STATUS_SUCCESS; + + fail: + free (unique_id); + free (source_entry); + return status; +} + +static cairo_int_status_t +_cairo_ps_surface_emit_form (cairo_ps_surface_t *surface, + cairo_emit_surface_params_t *params, + cairo_bool_t test) +{ + cairo_ps_form_t *ps_form; + cairo_status_t status; + + status = _cairo_ps_surface_use_form (surface, + params, + test, + &ps_form); + if (test || status) + return status; + + /* _cairo_ps_form_emit will use Level 3 if permitted by ps_level */ + if (surface->ps_level == CAIRO_PS_LEVEL_3) + surface->ps_level_used = CAIRO_PS_LEVEL_3; + + _cairo_output_stream_printf (surface->stream, + "/cairoform-%d /Form findresource execform\n", + ps_form->id); + + return CAIRO_STATUS_SUCCESS; +} + +/* Emit a surface. This function has three modes. + * + * CAIRO_EMIT_SURFACE_ANALYZE: This will determine the surface type to + * be emitted and approximate size. is_image is set to TRUE if the + * emitted surface is an image surface (including mime images). This + * is used by the caller to setup the correct CTM. approx_size is set + * to the approximate size of the emitted surface and is used as an + * input by the emit mode. + * + * CAIRO_EMIT_SURFACE_EMIT: Emits the surface will be emitted. The + * approx_size and the surface unique id values are used to determine + * if a Form should be used. If a form is used, the exec form + * operation is emitted and the surface is added to the forms hash + * table. + * + * CAIRO_EMIT_SURFACE_EMIT_FORM: Emits the form definition for the surface. + * + * Usage is: + * 1) Setup input params and call with ANALYZE. + * 2) Setup CTM for surface and call with EMIT using same params struct. + * The EMIT_FORM mode is used when emitting the form definitions. + */ +static cairo_int_status_t _cairo_ps_surface_emit_surface (cairo_ps_surface_t *surface, - const cairo_pattern_t *source_pattern, - cairo_surface_t *source_surface, - cairo_operator_t op, - const cairo_rectangle_int_t *src_surface_extents, - cairo_bool_t src_surface_bounded, - const cairo_rectangle_int_t *src_op_extents, - cairo_bool_t stencil_mask) + cairo_emit_surface_mode_t mode, + cairo_emit_surface_params_t *params) { cairo_int_status_t status; + cairo_output_stream_t *old_stream; + cairo_bool_t use_form; - if (source_pattern->type == CAIRO_PATTERN_TYPE_SURFACE && - source_pattern->extend != CAIRO_EXTEND_PAD && src_surface_bounded) - { - cairo_surface_t *surf = ((cairo_surface_pattern_t *) source_pattern)->surface; + /* Try emitting as a form. Returns unsupported if the surface is + * deemed unsuitable for a form. */ + use_form = FALSE; + if (mode == CAIRO_EMIT_SURFACE_ANALYZE || mode == CAIRO_EMIT_SURFACE_EMIT) { + status = _cairo_ps_surface_emit_form (surface, + params, + mode == CAIRO_EMIT_SURFACE_ANALYZE); + use_form = (status == CAIRO_INT_STATUS_SUCCESS); + if (status != CAIRO_INT_STATUS_SUCCESS && status != CAIRO_INT_STATUS_UNSUPPORTED) + return status; + + if (mode == CAIRO_EMIT_SURFACE_EMIT && status == CAIRO_INT_STATUS_SUCCESS) + return status; + } + + status = _cairo_ps_surface_emit_eps (surface, mode, params); + if (status == CAIRO_INT_STATUS_SUCCESS) { + params->is_image = FALSE; + goto surface_emitted; + } + if (status != CAIRO_INT_STATUS_UNSUPPORTED) + return status; + + status = _cairo_ps_surface_emit_jpeg_image (surface, mode, params); + if (status == CAIRO_INT_STATUS_SUCCESS) { + params->is_image = TRUE; + goto surface_emitted; + } + if (status != CAIRO_INT_STATUS_UNSUPPORTED) + return status; + + status = _cairo_ps_surface_emit_ccitt_image (surface, mode, params); + if (status == CAIRO_INT_STATUS_SUCCESS) { + params->is_image = TRUE; + goto surface_emitted; + } + if (status != CAIRO_INT_STATUS_UNSUPPORTED) + return status; - status = _cairo_ps_surface_emit_jpeg_image (surface, surf, src_surface_extents->width, src_surface_extents->height); - if (status != CAIRO_INT_STATUS_UNSUPPORTED) + if (mode == CAIRO_EMIT_SURFACE_ANALYZE) { + /* Find size of image or recording surface by emitting to a memory stream */ + status = _cairo_pdf_operators_flush (&surface->pdf_operators); + if (unlikely (status)) return status; + + old_stream = surface->stream; + surface->stream = _cairo_memory_stream_create (); + _cairo_pdf_operators_set_stream (&surface->pdf_operators, surface->stream); } - if (source_surface->type == CAIRO_SURFACE_TYPE_RECORDING) { - if (source_surface->backend->type == CAIRO_SURFACE_TYPE_SUBSURFACE) { - cairo_surface_subsurface_t *sub = (cairo_surface_subsurface_t *) source_surface; - status = _cairo_ps_surface_emit_recording_surface (surface, sub->target, &sub->extents, TRUE); + if (params->src_surface->type == CAIRO_SURFACE_TYPE_RECORDING) { + params->is_image = FALSE; + if (params->src_surface->backend->type == CAIRO_SURFACE_TYPE_SUBSURFACE) { + cairo_surface_subsurface_t *sub = (cairo_surface_subsurface_t *) params->src_surface; + status = _cairo_ps_surface_emit_recording_surface (surface, + sub->target, + &sub->extents, + TRUE); } else { - status = _cairo_ps_surface_emit_recording_surface (surface, source_surface, src_op_extents, FALSE); + status = _cairo_ps_surface_emit_recording_surface (surface, + params->src_surface, + params->src_op_extents, + FALSE); } } else { - cairo_image_surface_t *image = (cairo_image_surface_t *) source_surface; + params->is_image = TRUE; + status = _cairo_ps_surface_emit_image (surface, mode, params); + } - status = _cairo_ps_surface_emit_image (surface, image, - op, source_pattern->filter, stencil_mask); + if (mode == CAIRO_EMIT_SURFACE_ANALYZE) { + unsigned char *data; + unsigned long length; + + status = _cairo_pdf_operators_flush (&surface->pdf_operators); + if (unlikely (status)) + return status; + + status = _cairo_memory_stream_destroy (surface->stream, &data, &length); + free (data); + if (unlikely (status)) + return status; + + params->approx_size = length; + surface->stream = old_stream; + _cairo_pdf_operators_set_stream (&surface->pdf_operators, + surface->stream); } + surface_emitted: + return status; } +static void +_cairo_ps_form_emit (void *entry, void *closure) +{ + cairo_ps_form_t *form = entry; + cairo_ps_surface_t *surface = closure; + cairo_emit_surface_params_t params; + cairo_int_status_t status; + cairo_output_stream_t *old_stream; + + params.src_surface = form->src_surface; + params.op = CAIRO_OPERATOR_OVER; + params.src_op_extents = &form->required_extents; + params.filter = form->filter; + params.stencil_mask = FALSE; + params.is_image = form->is_image; + params.approx_size = 0; + + _cairo_output_stream_printf (surface->final_stream, + "%%%%BeginResource: form cairoform-%d\n", + form->id); + + _cairo_output_stream_printf (surface->final_stream, + "/cairo_paint_form-%d", + form->id); + if (surface->ps_level == CAIRO_PS_LEVEL_3) { + surface->paint_proc = FALSE; + _cairo_output_stream_printf (surface->final_stream, + "\n" + "currentfile\n" + "<< /Filter /SubFileDecode\n" + " /DecodeParms << /EODString (%s) /EODCount 0 >>\n" + ">> /ReusableStreamDecode filter\n", + SUBFILE_FILTER_EOD); + } else { + surface->paint_proc = TRUE; + _cairo_output_stream_printf (surface->final_stream, + " {\n"); + } + _cairo_output_stream_printf (surface->final_stream, + "5 dict begin\n"); + + old_stream = surface->stream; + surface->stream = surface->final_stream; + _cairo_pdf_operators_set_stream (&surface->pdf_operators, surface->stream); + status = _cairo_ps_surface_emit_surface (surface, + CAIRO_EMIT_SURFACE_EMIT_FORM, + ¶ms); + status = _cairo_pdf_operators_flush (&surface->pdf_operators); + surface->stream = old_stream; + _cairo_pdf_operators_set_stream (&surface->pdf_operators, surface->stream); + + _cairo_output_stream_printf (surface->final_stream, + "end\n"); + if (surface->ps_level == CAIRO_PS_LEVEL_3) { + _cairo_output_stream_printf (surface->final_stream, + "%s\n" + "def\n", + SUBFILE_FILTER_EOD); + } else { + _cairo_output_stream_printf (surface->final_stream, + "} bind def\n"); + } + + _cairo_output_stream_printf (surface->final_stream, + "\n" + "/cairoform-%d\n" + "<<\n" + " /FormType 1\n", + form->id); + + if (form->is_image) { + _cairo_output_stream_printf (surface->final_stream, + " /BBox [ 0 0 1 1 ]\n"); + } else { + _cairo_output_stream_printf (surface->final_stream, + " /BBox [ %d %d %d %d ]\n", + form->required_extents.x, + form->required_extents.y, + form->required_extents.x + form->required_extents.width, + form->required_extents.y + form->required_extents.height); + } + + _cairo_output_stream_printf (surface->final_stream, + " /Matrix [ 1 0 0 1 0 0 ]\n" + " /PaintProc { pop cairo_paint_form-%d", + form->id); + + if (surface->ps_level == CAIRO_PS_LEVEL_3) { + _cairo_output_stream_printf (surface->final_stream, + " dup 0 setfileposition cvx exec"); + } + _cairo_output_stream_printf (surface->final_stream, + " } bind\n" + ">>\n" + "/Form defineresource pop\n"); + + _cairo_output_stream_printf (surface->final_stream, + "%%%%EndResource\n"); + if (status) + surface->base.status = status; +} static void _path_fixed_init_rectangle (cairo_path_fixed_t *path, @@ -3142,10 +3858,10 @@ cairo_rectangle_int_t src_op_extents; cairo_surface_t *source_surface; double x_offset, y_offset; - void *image_extra; cairo_status_t status; cairo_matrix_t cairo_p2d, ps_p2d; cairo_path_fixed_t path; + cairo_emit_surface_params_t params; cairo_image_surface_t *image = NULL; status = _cairo_pdf_operators_flush (&surface->pdf_operators); @@ -3160,8 +3876,7 @@ &src_op_extents, &source_surface, &x_offset, - &y_offset, - &image_extra); + &y_offset); if (unlikely (status)) return status; @@ -3236,11 +3951,25 @@ ps_p2d = surface->cairo_to_ps; cairo_matrix_multiply (&ps_p2d, &cairo_p2d, &ps_p2d); cairo_matrix_translate (&ps_p2d, x_offset, y_offset); - if (!(pattern->type == CAIRO_PATTERN_TYPE_SURFACE && - ((cairo_surface_pattern_t *)pattern)->surface->type == CAIRO_SURFACE_TYPE_RECORDING)) - { + + params.src_surface = image ? &image->base : source_surface; + params.op = op; + params.src_surface_extents = &src_surface_extents; + params.src_surface_bounded = src_surface_bounded; + params.src_op_extents = &src_op_extents; + params.filter = pattern->filter; + params.stencil_mask = stencil_mask; + params.is_image = FALSE; + params.approx_size = 0; + + status = _cairo_ps_surface_emit_surface (surface, CAIRO_EMIT_SURFACE_ANALYZE, ¶ms); + if (unlikely (status)) + goto release_source; + + if (params.is_image) { cairo_matrix_translate (&ps_p2d, 0.0, src_surface_extents.height); cairo_matrix_scale (&ps_p2d, 1.0, -1.0); + cairo_matrix_scale (&ps_p2d, src_surface_extents.width, src_surface_extents.height); } if (! _cairo_matrix_is_identity (&ps_p2d)) { @@ -3249,20 +3978,13 @@ _cairo_output_stream_printf (surface->stream, " ] concat\n"); } - status = _cairo_ps_surface_emit_surface (surface, - pattern, - image ? &image->base : source_surface, - op, - &src_surface_extents, - image ? TRUE : src_surface_bounded, - &src_op_extents, - stencil_mask); + status = _cairo_ps_surface_emit_surface (surface, CAIRO_EMIT_SURFACE_EMIT, ¶ms); release_source: if (image) cairo_surface_destroy (&image->base); - _cairo_ps_surface_release_source_surface_from_pattern (surface, pattern, source_surface, image_extra); + _cairo_ps_surface_release_source_surface_from_pattern (surface, pattern, source_surface); return status; } @@ -3278,12 +4000,12 @@ cairo_rectangle_int_t pattern_extents; cairo_bool_t bounded; cairo_matrix_t cairo_p2d, ps_p2d; - cairo_bool_t old_use_string_datasource; + cairo_bool_t old_paint_proc; double x_offset, y_offset; cairo_surface_t *source_surface; cairo_image_surface_t *image = NULL; - void *image_extra; cairo_rectangle_int_t src_op_extents; + cairo_emit_surface_params_t params; cairo_extend_t extend = cairo_pattern_get_extend (pattern); cairo_p2d = pattern->matrix; @@ -3298,8 +4020,7 @@ &bounded, &src_op_extents, &source_surface, - &x_offset, &y_offset, - &image_extra); + &x_offset, &y_offset); if (unlikely (status)) return status; @@ -3379,8 +4100,30 @@ pattern_extents.x, pattern_extents.y, pattern_extents.width, pattern_extents.height); - old_use_string_datasource = surface->use_string_datasource; - surface->use_string_datasource = TRUE; + if (extend == CAIRO_EXTEND_REPEAT || extend == CAIRO_EXTEND_REFLECT) + src_op_extents = pattern_extents; + + old_paint_proc = surface->paint_proc; + surface->paint_proc = TRUE; + params.src_surface = image ? &image->base : source_surface; + params.op = op; + params.src_surface_extents = &pattern_extents; + params.src_surface_bounded = bounded; + params.src_op_extents = &src_op_extents; + params.filter = pattern->filter; + params.stencil_mask = FALSE; + params.is_image = FALSE; + params.approx_size = 0; + status = _cairo_ps_surface_emit_surface (surface, CAIRO_EMIT_SURFACE_ANALYZE, ¶ms); + if (unlikely (status)) + goto release_source; + + if (params.is_image) { + _cairo_output_stream_printf (surface->stream, + "[ %d 0 0 %d 0 0 ] concat\n", + pattern_extents.width, pattern_extents.height); + } + if (op == CAIRO_OPERATOR_SOURCE) { _cairo_output_stream_printf (surface->stream, "%d g %d %d %f %f rectfill\n", @@ -3389,21 +4132,10 @@ xstep, ystep); } - if (extend == CAIRO_EXTEND_REPEAT || extend == CAIRO_EXTEND_REFLECT) - src_op_extents = pattern_extents; - - status = _cairo_ps_surface_emit_surface (surface, - pattern, - image ? &image->base : source_surface, - op, - &pattern_extents, - bounded, - &src_op_extents, - FALSE); + status = _cairo_ps_surface_emit_surface (surface, CAIRO_EMIT_SURFACE_EMIT, ¶ms); if (unlikely (status)) goto release_source; - surface->use_string_datasource = old_use_string_datasource; _cairo_output_stream_printf (surface->stream, " Q } bind def\n"); @@ -3492,11 +4224,13 @@ " ]\n" "makepattern setpattern\n"); + surface->paint_proc = old_paint_proc; + release_source: if (image) cairo_surface_destroy (&image->base); - _cairo_ps_surface_release_source_surface_from_pattern (surface, pattern, source_surface, image_extra); + _cairo_ps_surface_release_source_surface_from_pattern (surface, pattern, source_surface); return status; } diff -Nru cairo-1.15.8/src/cairo-ps-surface-private.h cairo-1.15.10/src/cairo-ps-surface-private.h --- cairo-1.15.8/src/cairo-ps-surface-private.h 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-ps-surface-private.h 2017-12-07 02:14:36.000000000 +0000 @@ -49,6 +49,19 @@ #include +typedef struct _cairo_ps_form { + cairo_hash_entry_t base; + unsigned char *unique_id; + unsigned long unique_id_length; + cairo_bool_t is_image; + int id; + cairo_surface_t *src_surface; + cairo_filter_t filter; + + /* Union of source extents required for all operations using this form */ + cairo_rectangle_int_t required_extents; +} cairo_ps_form_t; + typedef struct cairo_ps_surface { cairo_surface_t base; @@ -63,6 +76,7 @@ cairo_output_stream_t *stream; cairo_bool_t eps; + cairo_bool_t contains_eps; cairo_content_t content; double width; double height; @@ -70,8 +84,7 @@ cairo_rectangle_int_t surface_extents; cairo_bool_t surface_bounded; cairo_matrix_t cairo_to_ps; - - cairo_bool_t use_string_datasource; + cairo_bool_t paint_proc; /* TRUE if surface will be used in a PaintProc */ cairo_bool_t current_pattern_is_solid_color; cairo_color_t current_color; @@ -91,6 +104,8 @@ cairo_array_t dsc_setup_comments; cairo_array_t dsc_page_setup_comments; + cairo_array_t recording_surf_stack; + cairo_array_t *dsc_comment_target; cairo_ps_level_t ps_level; @@ -100,6 +115,9 @@ cairo_pdf_operators_t pdf_operators; cairo_surface_t *paginated_surface; + cairo_hash_table_t *forms; + int num_forms; + long total_form_size; } cairo_ps_surface_t; #endif /* CAIRO_PS_SURFACE_PRIVATE_H */ diff -Nru cairo-1.15.8/src/cairo-scaled-font.c cairo-1.15.10/src/cairo-scaled-font.c --- cairo-1.15.8/src/cairo-scaled-font.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-scaled-font.c 2017-12-07 02:14:36.000000000 +0000 @@ -46,12 +46,6 @@ #include "cairo-scaled-font-private.h" #include "cairo-surface-backend-private.h" -#if _XOPEN_SOURCE >= 600 || defined (_ISOC99_SOURCE) -#define ISFINITE(x) isfinite (x) -#else -#define ISFINITE(x) ((x) * (x) >= 0.) /* check for NaNs */ -#endif - /** * SECTION:cairo-scaled-font * @Title: cairo_scaled_font_t @@ -2929,6 +2923,7 @@ { cairo_scaled_glyph_page_t *page; + assert (scaled_font->cache_frozen); assert (! cairo_list_is_empty (&scaled_font->glyph_pages)); page = cairo_list_last_entry (&scaled_font->glyph_pages, cairo_scaled_glyph_page_t, @@ -2938,6 +2933,9 @@ _cairo_scaled_glyph_fini (scaled_font, scaled_glyph); if (--page->num_glyphs == 0) { + _cairo_scaled_font_thaw_cache (scaled_font); + CAIRO_MUTEX_LOCK (scaled_font->mutex); + CAIRO_MUTEX_LOCK (_cairo_scaled_glyph_page_cache_mutex); /* Temporarily disconnect callback to avoid recursive locking */ cairo_scaled_glyph_page_cache.entry_destroy = NULL; @@ -2946,6 +2944,9 @@ _cairo_scaled_glyph_page_destroy (scaled_font, page); cairo_scaled_glyph_page_cache.entry_destroy = _cairo_scaled_glyph_page_pluck; CAIRO_MUTEX_UNLOCK (_cairo_scaled_glyph_page_cache_mutex); + + CAIRO_MUTEX_UNLOCK (scaled_font->mutex); + _cairo_scaled_font_freeze_cache (scaled_font); } } diff -Nru cairo-1.15.8/src/cairo-scaled-font-subsets.c cairo-1.15.10/src/cairo-scaled-font-subsets.c --- cairo-1.15.8/src/cairo-scaled-font-subsets.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-scaled-font-subsets.c 2017-12-07 02:13:45.000000000 +0000 @@ -40,7 +40,7 @@ * Adrian Johnson */ -#define _BSD_SOURCE /* for snprintf(), strdup() */ +#define _DEFAULT_SOURCE /* for snprintf(), strdup() */ #include "cairoint.h" #include "cairo-error-private.h" diff -Nru cairo-1.15.8/src/cairo-script-surface.c cairo-1.15.10/src/cairo-script-surface.c --- cairo-1.15.8/src/cairo-script-surface.c 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/cairo-script-surface.c 2017-12-07 02:14:36.000000000 +0000 @@ -1202,7 +1202,8 @@ _write_image_surface (cairo_output_stream_t *output, const cairo_image_surface_t *image) { - int stride, row, width; + int row, width; + ptrdiff_t stride; uint8_t row_stack[CAIRO_STACK_BUFFER_SIZE]; uint8_t *rowdata; uint8_t *data; diff -Nru cairo-1.15.8/src/cairo-surface.c cairo-1.15.10/src/cairo-surface.c --- cairo-1.15.8/src/cairo-surface.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-surface.c 2017-12-07 02:14:36.000000000 +0000 @@ -1025,8 +1025,6 @@ { cairo_status_t status; - surface->finished = TRUE; - /* call finish even if in error mode */ if (surface->backend->finish) { status = surface->backend->finish (surface); @@ -1034,6 +1032,8 @@ _cairo_surface_set_error (surface, status); } + surface->finished = TRUE; + assert (surface->snapshot_of == NULL); assert (!_cairo_surface_has_snapshots (surface)); } @@ -1224,6 +1224,80 @@ free (mime_data); } + +static const char *_cairo_surface_image_mime_types[] = { + CAIRO_MIME_TYPE_JPEG, + CAIRO_MIME_TYPE_PNG, + CAIRO_MIME_TYPE_JP2, + CAIRO_MIME_TYPE_JBIG2, + CAIRO_MIME_TYPE_CCITT_FAX, +}; + +cairo_bool_t +_cairo_surface_has_mime_image (cairo_surface_t *surface) +{ + cairo_user_data_slot_t *slots; + int i, j, num_slots; + + /* Prevent reads of the array during teardown */ + if (! CAIRO_REFERENCE_COUNT_HAS_REFERENCE (&surface->ref_count)) + return FALSE; + + /* The number of mime-types attached to a surface is usually small, + * typically zero. Therefore it is quicker to do a strcmp() against + * each key than it is to intern the string (i.e. compute a hash, + * search the hash table, and do a final strcmp). + */ + num_slots = surface->mime_data.num_elements; + slots = _cairo_array_index (&surface->mime_data, 0); + for (i = 0; i < num_slots; i++) { + if (slots[i].key != NULL) { + for (j = 0; j < ARRAY_LENGTH (_cairo_surface_image_mime_types); j++) { + if (strcmp ((char *) slots[i].key, _cairo_surface_image_mime_types[j]) == 0) + return TRUE; + } + } + } + + return FALSE; +} + +/** + * CAIRO_MIME_TYPE_CCITT_FAX: + * + * Group 3 or Group 4 CCITT facsimile encoding (International + * Telecommunication Union, Recommendations T.4 and T.6.) + * + * Since: 1.16 + **/ + +/** + * CAIRO_MIME_TYPE_CCITT_FAX_PARAMS: + * + * Decode parameters for Group 3 or Group 4 CCITT facsimile encoding. + * See [CCITT Fax Images][ccitt]. + * + * Since: 1.16 + **/ + +/** + * CAIRO_MIME_TYPE_EPS: + * + * Encapsulated PostScript file. + * [Encapsulated PostScript File Format Specification](http://wwwimages.adobe.com/content/dam/Adobe/endevnet/postscript/pdfs/5002.EPSF_Spec.pdf) + * + * Since: 1.16 + **/ + +/** + * CAIRO_MIME_TYPE_EPS_PARAMS: + * + * Embedding parameters Encapsulated PostScript data. + * See [Embedding EPS files][eps]. + * + * Since: 1.16 + **/ + /** * CAIRO_MIME_TYPE_JBIG2: * @@ -1314,7 +1388,8 @@ * The recognized MIME types are the following: %CAIRO_MIME_TYPE_JPEG, * %CAIRO_MIME_TYPE_PNG, %CAIRO_MIME_TYPE_JP2, %CAIRO_MIME_TYPE_URI, * %CAIRO_MIME_TYPE_UNIQUE_ID, %CAIRO_MIME_TYPE_JBIG2, - * %CAIRO_MIME_TYPE_JBIG2_GLOBAL, %CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID. + * %CAIRO_MIME_TYPE_JBIG2_GLOBAL, %CAIRO_MIME_TYPE_JBIG2_GLOBAL_ID, + * %CAIRO_MIME_TYPE_CCITT_FAX, %CAIRO_MIME_TYPE_CCITT_FAX_PARAMS. * * See corresponding backend surface docs for details about which MIME * types it can handle. Caution: the associated MIME data will be @@ -1386,6 +1461,8 @@ return _cairo_surface_set_error (surface, status); } + surface->is_clear = FALSE; + return CAIRO_STATUS_SUCCESS; } slim_hidden_def (cairo_surface_set_mime_data); @@ -1460,6 +1537,8 @@ _cairo_mime_data_reference, NULL); + dst->is_clear = FALSE; + return CAIRO_STATUS_SUCCESS; } @@ -2571,7 +2650,10 @@ pattern = cairo_pattern_create_for_surface ((cairo_surface_t *)glyph_surface); cairo_matrix_init_translate (&matrix, - x, - y); cairo_pattern_set_matrix (pattern, &matrix); - status = surface->backend->paint (surface, op, pattern, clip); + if (op == CAIRO_OPERATOR_SOURCE || op == CAIRO_OPERATOR_CLEAR) + status = surface->backend->mask (surface, op, pattern, pattern, clip); + else + status = surface->backend->paint (surface, op, pattern, clip); } return status; diff -Nru cairo-1.15.8/src/cairo-svg.h cairo-1.15.10/src/cairo-svg.h --- cairo-1.15.8/src/cairo-svg.h 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-svg.h 2017-12-07 02:14:36.000000000 +0000 @@ -53,6 +53,46 @@ CAIRO_SVG_VERSION_1_2 } cairo_svg_version_t; +/** + * cairo_svg_version_t: + * + * @CAIRO_SVG_UNIT_USER: User unit, a value in the current coordinate system. + * If used in the root element for the initial coordinate systems it + * corresponds to pixels. (Since 1.16) + * @CAIRO_SVG_UNIT_EM: The size of the element's font. (Since 1.16) + * @CAIRO_SVG_UNIT_EX: The x-height of the element’s font. (Since 1.16) + * @CAIRO_SVG_UNIT_PX: Pixels (1px = 1/96th of 1in). (Since 1.16) + * @CAIRO_SVG_UNIT_IN: Inches (1in = 2.54cm = 96px). (Since 1.16) + * @CAIRO_SVG_UNIT_CM: Centimeters (1cm = 96px/2.54). (Since 1.16) + * @CAIRO_SVG_UNIT_MM: Millimeters (1mm = 1/10th of 1cm). (Since 1.16) + * @CAIRO_SVG_UNIT_PT: Points (1pt = 1/72th of 1in). (Since 1.16) + * @CAIRO_SVG_UNIT_PC: Picas (1pc = 1/6th of 1in). (Since 1.16) + * @CAIRO_SVG_UNIT_PERCENT: Percent, a value that is some fraction of another + * reference value. (Since 1.16) + * + * #cairo_svg_unit_t is used to describe the units valid for coordinates and + * lengths in the SVG specification. + * + * See also: + * https://www.w3.org/TR/SVG/coords.html#Units + * https://www.w3.org/TR/SVG/types.html#DataTypeLength + * https://www.w3.org/TR/css-values-3/#lengths + * + * Since: 1.16 + **/ +typedef enum _cairo_svg_unit { + CAIRO_SVG_UNIT_USER = 0, + CAIRO_SVG_UNIT_EM, + CAIRO_SVG_UNIT_EX, + CAIRO_SVG_UNIT_PX, + CAIRO_SVG_UNIT_IN, + CAIRO_SVG_UNIT_CM, + CAIRO_SVG_UNIT_MM, + CAIRO_SVG_UNIT_PT, + CAIRO_SVG_UNIT_PC, + CAIRO_SVG_UNIT_PERCENT +} cairo_svg_unit_t; + cairo_public cairo_surface_t * cairo_svg_surface_create (const char *filename, double width_in_points, @@ -75,6 +115,13 @@ cairo_public const char * cairo_svg_version_to_string (cairo_svg_version_t version); +cairo_public void +cairo_svg_surface_set_document_unit (cairo_surface_t *surface, + cairo_svg_unit_t unit); + +cairo_public cairo_svg_unit_t +cairo_svg_surface_get_document_unit (cairo_surface_t *surface); + CAIRO_END_DECLS #else /* CAIRO_HAS_SVG_SURFACE */ diff -Nru cairo-1.15.8/src/cairo-svg-surface.c cairo-1.15.10/src/cairo-svg-surface.c --- cairo-1.15.8/src/cairo-svg-surface.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-svg-surface.c 2017-12-07 22:13:32.000000000 +0000 @@ -39,7 +39,7 @@ * Carl Worth */ -#define _BSD_SOURCE /* for snprintf() */ +#define _DEFAULT_SOURCE /* for snprintf() */ #include "cairoint.h" #include "cairo-svg.h" @@ -94,6 +94,7 @@ { CAIRO_MIME_TYPE_JPEG, CAIRO_MIME_TYPE_PNG, + CAIRO_MIME_TYPE_UNIQUE_ID, CAIRO_MIME_TYPE_URI, NULL }; @@ -121,6 +122,20 @@ "1.2" }; +static const char * _cairo_svg_unit_strings[] = +{ + [CAIRO_SVG_UNIT_USER] = "", + [CAIRO_SVG_UNIT_EM] = "em", + [CAIRO_SVG_UNIT_EX] = "ex", + [CAIRO_SVG_UNIT_PX] = "px", + [CAIRO_SVG_UNIT_IN] = "in", + [CAIRO_SVG_UNIT_CM] = "cm", + [CAIRO_SVG_UNIT_MM] = "mm", + [CAIRO_SVG_UNIT_PT] = "pt", + [CAIRO_SVG_UNIT_PC] = "pc", + [CAIRO_SVG_UNIT_PERCENT] = "%" +}; + struct cairo_svg_page { unsigned int surface_id; unsigned int clip_level; @@ -135,6 +150,7 @@ double width; double height; + cairo_svg_unit_t unit; cairo_output_stream_t *xml_node_defs; cairo_output_stream_t *xml_node_glyphs; @@ -176,7 +192,9 @@ _cairo_svg_surface_create_for_document (cairo_svg_document_t *document, cairo_content_t content, double width, - double height); + double height, + cairo_bool_t bounded); + static cairo_surface_t * _cairo_svg_surface_create_for_stream_internal (cairo_output_stream_t *stream, double width, @@ -252,6 +270,9 @@ * or %CAIRO_MIME_TYPE_PNG is specified, the corresponding data is * Base64-encoded and emitted. * + * If %CAIRO_MIME_TYPE_UNIQUE_ID is present, all surfaces with the same + * unique identifier will only be embedded once. + * * Return value: a pointer to the newly created surface. The caller * owns the surface and should call cairo_surface_destroy() when done * with it. @@ -399,6 +420,164 @@ return _cairo_svg_version_strings[version]; } +/** + * cairo_svg_surface_set_document_unit: + * @surface: a SVG #cairo_surface_t + * @unit: SVG unit + * + * Use the specified unit for the width and height of the generated SVG file. + * See #cairo_svg_unit_t for a list of available unit values that can be used + * here. + * + * This function can be called at any time before generating the SVG file. + * + * However to minimize the risk of ambiguities it's recommended to call it + * before any drawing operations have been performed on the given surface, to + * make it clearer what the unit used in the drawing operations is. + * + * The simplest way to do this is to call this function immediately after + * creating the SVG surface. + * + * Note if this function is never called, the default unit for SVG documents + * generated by cairo will be "pt". This is for historical reasons. + * + * Since: 1.16 + **/ +void +cairo_svg_surface_set_document_unit (cairo_surface_t *abstract_surface, + cairo_svg_unit_t unit) +{ + cairo_svg_surface_t *surface = NULL; /* hide compiler warning */ + + if (! _extract_svg_surface (abstract_surface, &surface)) + return; + + if (unit <= CAIRO_SVG_UNIT_PERCENT) + surface->document->unit = unit; +} + +/** + * cairo_svg_surface_get_document_unit: + * @surface: a SVG #cairo_surface_t + * + * Get the unit of the SVG surface. + * + * If the surface passed as an argument is not a SVG surface, the function + * sets the error status to CAIRO_STATUS_SURFACE_TYPE_MISMATCH and returns + * CAIRO_SVG_UNIT_USER. + * + * Return value: the SVG unit of the SVG surface. + * + * Since: 1.16 + **/ +cairo_svg_unit_t +cairo_svg_surface_get_document_unit (cairo_surface_t *abstract_surface) +{ + cairo_svg_surface_t *surface = NULL; /* hide compiler warning */ + + if (! _extract_svg_surface (abstract_surface, &surface)) { + _cairo_error_throw (CAIRO_STATUS_SURFACE_TYPE_MISMATCH); + return CAIRO_SVG_UNIT_USER; + } + + return surface->document->unit; +} + +static void +_cairo_svg_source_surface_init_key (cairo_svg_source_surface_t *key) +{ + if (key->unique_id && key->unique_id_length > 0) { + key->base.hash = _cairo_hash_bytes (_CAIRO_HASH_INIT_VALUE, + key->unique_id, key->unique_id_length); + } else { + key->base.hash = key->id; + } +} + +static cairo_bool_t +_cairo_svg_source_surface_equal (const void *key_a, const void *key_b) +{ + const cairo_svg_source_surface_t *a = key_a; + const cairo_svg_source_surface_t *b = key_b; + + if (a->unique_id && b->unique_id && a->unique_id_length == b->unique_id_length) + return (memcmp (a->unique_id, b->unique_id, a->unique_id_length) == 0); + + return (a->id == b->id); +} + +static void +_cairo_svg_source_surface_pluck (void *entry, void *closure) +{ + cairo_svg_source_surface_t *surface_entry = entry; + cairo_hash_table_t *patterns = closure; + + _cairo_hash_table_remove (patterns, &surface_entry->base); + free (surface_entry->unique_id); + free (surface_entry); +} + +static cairo_status_t +_cairo_svg_surface_add_source_surface (cairo_svg_surface_t *surface, + cairo_surface_t *source_surface, + int *source_id, + cairo_bool_t *is_new) +{ + cairo_svg_source_surface_t source_key; + cairo_svg_source_surface_t *source_entry; + unsigned char *unique_id = NULL; + unsigned long unique_id_length = 0; + cairo_status_t status; + + source_key.id = source_surface->unique_id; + cairo_surface_get_mime_data (source_surface, CAIRO_MIME_TYPE_UNIQUE_ID, + (const unsigned char **) &source_key.unique_id, + &source_key.unique_id_length); + _cairo_svg_source_surface_init_key (&source_key); + source_entry = _cairo_hash_table_lookup (surface->source_surfaces, &source_key.base); + if (source_entry) { + *source_id = source_entry->id; + *is_new = FALSE; + return CAIRO_STATUS_SUCCESS; + } + + if (source_key.unique_id && source_key.unique_id_length > 0) { + unique_id = _cairo_malloc (source_key.unique_id_length); + if (unique_id == NULL) { + return _cairo_error (CAIRO_STATUS_NO_MEMORY); + } + + unique_id_length = source_key.unique_id_length; + memcpy (unique_id, source_key.unique_id, unique_id_length); + } else { + unique_id = NULL; + unique_id_length = 0; + } + + source_entry = malloc (sizeof (cairo_svg_source_surface_t)); + if (source_entry == NULL) { + status = _cairo_error (CAIRO_STATUS_NO_MEMORY); + goto fail; + } + + source_entry->id = source_key.id; + source_entry->unique_id_length = unique_id_length; + source_entry->unique_id = unique_id; + _cairo_svg_source_surface_init_key (source_entry); + status = _cairo_hash_table_insert (surface->source_surfaces, &source_entry->base); + if (unlikely(status)) + goto fail; + + *is_new = TRUE; + *source_id = source_entry->id; + return CAIRO_STATUS_SUCCESS; + + fail: + free (unique_id); + free (source_entry); + return status; +} + static cairo_bool_t _cliprect_covers_surface (cairo_svg_surface_t *surface, cairo_path_fixed_t *path) @@ -470,7 +649,8 @@ _cairo_svg_surface_create_for_document (cairo_svg_document_t *document, cairo_content_t content, double width, - double height) + double height, + cairo_bool_t bounded) { cairo_svg_surface_t *surface; cairo_surface_t *paginated; @@ -488,6 +668,7 @@ surface->width = width; surface->height = height; + surface->surface_bounded = bounded; surface->document = _cairo_svg_document_reference (document); @@ -520,6 +701,12 @@ surface->force_fallbacks = FALSE; surface->content = content; + surface->source_surfaces = _cairo_hash_table_create (_cairo_svg_source_surface_equal); + if (unlikely (surface->source_surfaces == NULL)) { + status = _cairo_error (CAIRO_STATUS_NO_MEMORY); + goto CLEANUP; + } + paginated = _cairo_paginated_surface_create (&surface->base, surface->content, &cairo_svg_surface_paginated_backend); @@ -561,7 +748,7 @@ } surface = _cairo_svg_surface_create_for_document (document, CAIRO_CONTENT_COLOR_ALPHA, - width, height); + width, height, TRUE); if (surface->status) { status = _cairo_svg_document_destroy (document); return surface; @@ -1011,6 +1198,11 @@ _cairo_surface_clipper_reset (&surface->clipper); + _cairo_hash_table_foreach (surface->source_surfaces, + _cairo_svg_source_surface_pluck, + surface->source_surfaces); + _cairo_hash_table_destroy (surface->source_surfaces); + status2 = _cairo_svg_document_destroy (document); if (status == CAIRO_STATUS_SUCCESS) status = status2; @@ -1282,7 +1474,8 @@ static cairo_status_t _cairo_svg_surface_emit_surface (cairo_svg_document_t *document, - cairo_surface_t *surface) + cairo_surface_t *surface, + int source_id) { cairo_rectangle_int_t extents; cairo_bool_t is_bounded; @@ -1290,18 +1483,12 @@ const unsigned char *uri; unsigned long uri_len; - if (_cairo_user_data_array_get_data (&surface->user_data, - (cairo_user_data_key_t *) document)) - { - return CAIRO_STATUS_SUCCESS; - } - is_bounded = _cairo_surface_get_extents (surface, &extents); assert (is_bounded); _cairo_output_stream_printf (document->xml_node_defs, "unique_id, + source_id, extents.width, extents.height); _cairo_output_stream_printf (document->xml_node_defs, " xlink:href=\""); @@ -1320,10 +1507,7 @@ _cairo_output_stream_printf (document->xml_node_defs, "\"/>\n"); - /* and tag it */ - return _cairo_user_data_array_set_data (&surface->user_data, - (cairo_user_data_key_t *) document, - document, NULL); + return CAIRO_STATUS_SUCCESS; } static cairo_status_t @@ -1337,17 +1521,29 @@ { cairo_status_t status; cairo_matrix_t p2u; + int source_id; + cairo_bool_t is_new; p2u = pattern->base.matrix; status = cairo_matrix_invert (&p2u); /* cairo_pattern_set_matrix ensures the matrix is invertible */ assert (status == CAIRO_STATUS_SUCCESS); - status = _cairo_svg_surface_emit_surface (svg_surface->document, - pattern->surface); + status = _cairo_svg_surface_add_source_surface (svg_surface, + pattern->surface, + &source_id, + &is_new); if (unlikely (status)) return status; + if (is_new) { + status = _cairo_svg_surface_emit_surface (svg_surface->document, + pattern->surface, + source_id); + if (unlikely (status)) + return status; + } + if (pattern_id != invalid_pattern_id) { cairo_rectangle_int_t extents; cairo_bool_t is_bounded; @@ -1369,7 +1565,7 @@ _cairo_output_stream_printf (output, "surface->unique_id); + source_id); if (extra_attributes) _cairo_output_stream_printf (output, " %s", extra_attributes); @@ -1390,25 +1586,23 @@ static cairo_status_t _cairo_svg_surface_emit_recording_surface (cairo_svg_document_t *document, - cairo_recording_surface_t *source) + cairo_recording_surface_t *source, + int source_id) { cairo_status_t status; cairo_surface_t *paginated_surface; cairo_svg_surface_t *svg_surface; cairo_array_t *page_set; - + cairo_rectangle_int_t extents; + cairo_bool_t bounded; cairo_output_stream_t *contents; - if (_cairo_user_data_array_get_data (&source->base.user_data, - (cairo_user_data_key_t *) document)) - { - return CAIRO_STATUS_SUCCESS; - } - + bounded = _cairo_surface_get_extents (&source->base, &extents); paginated_surface = _cairo_svg_surface_create_for_document (document, source->base.content, - source->extents_pixels.width, - source->extents_pixels.height); + extents.width, + extents.height, + bounded); if (unlikely (paginated_surface->status)) return paginated_surface->status; @@ -1436,13 +1630,17 @@ if (! svg_surface->is_base_clip_emitted) { svg_surface->is_base_clip_emitted = TRUE; - _cairo_output_stream_printf (document->xml_node_defs, - "\n" - " \n" - "\n", - svg_surface->base_clip, - svg_surface->width, - svg_surface->height); + if (_cairo_surface_get_extents (&svg_surface->base, &extents)) { + _cairo_output_stream_printf (document->xml_node_defs, + "\n" + " \n" + "\n", + svg_surface->base_clip, + extents.x, + extents.y, + extents.width, + extents.height); + } } if (source->base.content == CAIRO_CONTENT_ALPHA) { @@ -1451,13 +1649,13 @@ "\n", - source->base.unique_id, + source_id, svg_surface->base_clip); } else { _cairo_output_stream_printf (document->xml_node_defs, "\n", - source->base.unique_id, + source_id, svg_surface->base_clip); } @@ -1483,13 +1681,7 @@ status = cairo_surface_status (paginated_surface); cairo_surface_destroy (paginated_surface); - if (unlikely (status)) - return status; - - /* and tag it */ - return _cairo_user_data_array_set_data (&source->base.user_data, - (cairo_user_data_key_t *) document, - document, NULL); + return status; } static cairo_recording_surface_t * @@ -1516,17 +1708,28 @@ cairo_recording_surface_t *recording_surface; cairo_matrix_t p2u; cairo_status_t status; + int source_id; + cairo_bool_t is_new; p2u = pattern->base.matrix; status = cairo_matrix_invert (&p2u); /* cairo_pattern_set_matrix ensures the matrix is invertible */ assert (status == CAIRO_STATUS_SUCCESS); - recording_surface = to_recording_surface (pattern); - status = _cairo_svg_surface_emit_recording_surface (document, recording_surface); + status = _cairo_svg_surface_add_source_surface (surface, + pattern->surface, + &source_id, + &is_new); if (unlikely (status)) return status; + recording_surface = to_recording_surface (pattern); + if (is_new) { + status = _cairo_svg_surface_emit_recording_surface (document, recording_surface, source_id); + if (unlikely (status)) + return status; + } + if (pattern_id != invalid_pattern_id) { _cairo_output_stream_printf (output, "base.unique_id); + source_id); if (pattern_id == invalid_pattern_id) { _cairo_svg_surface_emit_operator (output, surface, op); @@ -2258,7 +2461,7 @@ rectangle->width = ceil (surface->width); rectangle->height = ceil (surface->height); - return TRUE; + return surface->surface_bounded; } static cairo_status_t @@ -2676,6 +2879,7 @@ document->finished = FALSE; document->width = width; document->height = height; + document->unit = CAIRO_SVG_UNIT_PT; document->linear_pattern_id = 0; document->radial_pattern_id = 0; @@ -2778,9 +2982,10 @@ "\n" "\n", - document->width, document->height, + document->width, _cairo_svg_unit_strings [document->unit], + document->height, _cairo_svg_unit_strings [document->unit], document->width, document->height, _cairo_svg_internal_version_strings [document->svg_version]); diff -Nru cairo-1.15.8/src/cairo-svg-surface-private.h cairo-1.15.10/src/cairo-svg-surface-private.h --- cairo-1.15.8/src/cairo-svg-surface-private.h 2017-04-24 17:17:20.000000000 +0000 +++ cairo-1.15.10/src/cairo-svg-surface-private.h 2017-12-07 02:14:36.000000000 +0000 @@ -48,6 +48,13 @@ typedef struct cairo_svg_document cairo_svg_document_t; +typedef struct _cairo_svg_source_surface { + cairo_hash_entry_t base; + unsigned int id; + unsigned char *unique_id; + unsigned long unique_id_length; +} cairo_svg_source_surface_t; + typedef struct cairo_svg_surface { cairo_surface_t base; @@ -55,11 +62,13 @@ double width; double height; + cairo_bool_t surface_bounded; cairo_svg_document_t *document; cairo_output_stream_t *xml_node; cairo_array_t page_set; + cairo_hash_table_t *source_surfaces; cairo_surface_clipper_t clipper; unsigned int clip_level; diff -Nru cairo-1.15.8/src/cairo-tag-attributes.c cairo-1.15.10/src/cairo-tag-attributes.c --- cairo-1.15.8/src/cairo-tag-attributes.c 2017-08-29 16:58:07.000000000 +0000 +++ cairo-1.15.10/src/cairo-tag-attributes.c 2017-12-07 02:14:36.000000000 +0000 @@ -113,6 +113,50 @@ { NULL } }; +/* + * Required: + * Columns - width of the image in pixels. + * Rows - height of the image in scan lines. + * + * Optional: + * K - An integer identifying the encoding scheme used. < 0 is 2 dimensional + * Group 4, = 0 is Group3 1 dimensional, > 0 is mixed 1 and 2 dimensional + * encoding. Default: 0. + * EndOfLine - If true end-of-line bit patterns are present. Default: false. + * EncodedByteAlign - If true the end of line is padded with 0 bits so the next + * line begins on a byte boundary. Default: false. + * EndOfBlock - If true the data contains an end-of-block pattern. Default: true. + * BlackIs1 - If true 1 bits are black pixels. Default: false. + * DamagedRowsBeforeError - Number of damages rows tolerated before an error + * occurs. Default: 0. + */ +static attribute_spec_t _ccitt_params_spec[] = +{ + { "Columns", ATTRIBUTE_INT }, + { "Rows", ATTRIBUTE_INT }, + { "K", ATTRIBUTE_INT }, + { "EndOfLine", ATTRIBUTE_BOOL }, + { "EncodedByteAlign", ATTRIBUTE_BOOL }, + { "EndOfBlock", ATTRIBUTE_BOOL }, + { "BlackIs1", ATTRIBUTE_BOOL }, + { "DamagedRowsBeforeError", ATTRIBUTE_INT }, + { NULL } +}; + +/* + * bbox - Bounding box of EPS file. The format is [ llx lly urx ury ] + * llx - lower left x xoordinate + * lly - lower left y xoordinate + * urx - upper right x xoordinate + * ury - upper right y xoordinate + * all cordinates are in PostScript coordinates. + */ +static attribute_spec_t _eps_params_spec[] = +{ + { "bbox", ATTRIBUTE_FLOAT, 4 }, + { NULL } +}; + typedef union { cairo_bool_t b; int i; @@ -388,6 +432,8 @@ fail2: _cairo_array_fini (&attrib->array); + if (attrib->type == ATTRIBUTE_STRING) + free (attrib->scalar.s); free (attrib); fail1: free (name); @@ -405,6 +451,8 @@ cairo_list_del (&attr->link); free (attr->name); _cairo_array_fini (&attr->array); + if (attr->type == ATTRIBUTE_STRING) + free (attr->scalar.s); free (attr); } } @@ -566,6 +614,89 @@ cleanup: free_attributes_list (&list); + + return status; +} + +cairo_int_status_t +_cairo_tag_parse_ccitt_params (const char *attributes, cairo_ccitt_params_t *ccitt_params) +{ + cairo_list_t list; + cairo_int_status_t status; + attribute_t *attr; + + ccitt_params->columns = -1; + ccitt_params->rows = -1; + + /* set defaults */ + ccitt_params->k = 0; + ccitt_params->end_of_line = FALSE; + ccitt_params->encoded_byte_align = FALSE; + ccitt_params->end_of_block = TRUE; + ccitt_params->black_is_1 = FALSE; + ccitt_params->damaged_rows_before_error = 0; + + cairo_list_init (&list); + status = parse_attributes (attributes, _ccitt_params_spec, &list); + if (unlikely (status)) + goto cleanup; + + cairo_list_foreach_entry (attr, attribute_t, &list, link) + { + if (strcmp (attr->name, "Columns") == 0) { + ccitt_params->columns = attr->scalar.i; + } else if (strcmp (attr->name, "Rows") == 0) { + ccitt_params->rows = attr->scalar.i; + } else if (strcmp (attr->name, "K") == 0) { + ccitt_params->k = attr->scalar.i; + } else if (strcmp (attr->name, "EndOfLine") == 0) { + ccitt_params->end_of_line = attr->scalar.b; + } else if (strcmp (attr->name, "EncodedByteAlign") == 0) { + ccitt_params->encoded_byte_align = attr->scalar.b; + } else if (strcmp (attr->name, "EndOfBlock") == 0) { + ccitt_params->end_of_block = attr->scalar.b; + } else if (strcmp (attr->name, "BlackIs1") == 0) { + ccitt_params->black_is_1 = attr->scalar.b; + } else if (strcmp (attr->name, "DamagedRowsBeforeError") == 0) { + ccitt_params->damaged_rows_before_error = attr->scalar.b; + } + } + + cleanup: + free_attributes_list (&list); + + return status; +} + +cairo_int_status_t +_cairo_tag_parse_eps_params (const char *attributes, cairo_eps_params_t *eps_params) +{ + cairo_list_t list; + cairo_int_status_t status; + attribute_t *attr; + attrib_val_t val; + + cairo_list_init (&list); + status = parse_attributes (attributes, _eps_params_spec, &list); + if (unlikely (status)) + goto cleanup; + + cairo_list_foreach_entry (attr, attribute_t, &list, link) + { + if (strcmp (attr->name, "bbox") == 0) { + _cairo_array_copy_element (&attr->array, 0, &val); + eps_params->bbox.p1.x = val.f; + _cairo_array_copy_element (&attr->array, 1, &val); + eps_params->bbox.p1.y = val.f; + _cairo_array_copy_element (&attr->array, 2, &val); + eps_params->bbox.p2.x = val.f; + _cairo_array_copy_element (&attr->array, 3, &val); + eps_params->bbox.p2.y = val.f; + } + } + + cleanup: + free_attributes_list (&list); return status; } diff -Nru cairo-1.15.8/src/cairo-tag-attributes-private.h cairo-1.15.10/src/cairo-tag-attributes-private.h --- cairo-1.15.8/src/cairo-tag-attributes-private.h 2017-08-29 16:58:07.000000000 +0000 +++ cairo-1.15.10/src/cairo-tag-attributes-private.h 2017-12-07 02:14:36.000000000 +0000 @@ -39,6 +39,7 @@ #include "cairo-array-private.h" #include "cairo-error-private.h" +#include "cairo-types-private.h" typedef enum { TAG_LINK_INVALID = 0, @@ -68,10 +69,31 @@ cairo_bool_t internal; } cairo_dest_attrs_t; +typedef struct _cairo_ccitt_params { + int columns; + int rows; + int k; + cairo_bool_t end_of_line; + cairo_bool_t encoded_byte_align; + cairo_bool_t end_of_block; + cairo_bool_t black_is_1; + int damaged_rows_before_error; +} cairo_ccitt_params_t; + +typedef struct _cairo_eps_params { + cairo_box_double_t bbox; +} cairo_eps_params_t; + cairo_private cairo_int_status_t _cairo_tag_parse_link_attributes (const char *attributes, cairo_link_attrs_t *link_attrs); cairo_private cairo_int_status_t _cairo_tag_parse_dest_attributes (const char *attributes, cairo_dest_attrs_t *dest_attrs); +cairo_private cairo_int_status_t +_cairo_tag_parse_ccitt_params (const char *attributes, cairo_ccitt_params_t *dest_attrs); + +cairo_private cairo_int_status_t +_cairo_tag_parse_eps_params (const char *attributes, cairo_eps_params_t *dest_attrs); + #endif /* CAIRO_TAG_ATTRIBUTES_PRIVATE_H */ diff -Nru cairo-1.15.8/src/cairo-toy-font-face.c cairo-1.15.10/src/cairo-toy-font-face.c --- cairo-1.15.8/src/cairo-toy-font-face.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-toy-font-face.c 2017-12-07 02:13:45.000000000 +0000 @@ -39,7 +39,7 @@ * Behdad Esfahbod */ -#define _BSD_SOURCE /* for strdup() */ +#define _DEFAULT_SOURCE /* for strdup() */ #include "cairoint.h" #include "cairo-error-private.h" diff -Nru cairo-1.15.8/src/cairo-truetype-subset.c cairo-1.15.10/src/cairo-truetype-subset.c --- cairo-1.15.8/src/cairo-truetype-subset.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-truetype-subset.c 2017-12-07 02:14:36.000000000 +0000 @@ -40,7 +40,7 @@ * http://www.microsoft.com/typography/specs/default.htm */ -#define _BSD_SOURCE /* for snprintf(), strdup() */ +#define _DEFAULT_SOURCE /* for snprintf(), strdup() */ #include "cairoint.h" #include "cairo-array-private.h" @@ -77,22 +77,22 @@ struct { char *font_name; char *ps_name; - unsigned int num_glyphs; - int *widths; + int num_glyphs_in_face; /* glyphs in font */ long x_min, y_min, x_max, y_max; long ascent, descent; int units_per_em; } base; - subset_glyph_t *glyphs; + subset_glyph_t *glyphs; /* array size: num_glyphs_in_face + 2 */ const cairo_scaled_font_backend_t *backend; - int num_glyphs_in_face; + unsigned int num_glyphs; /* glyphs used */ + int *widths; /* array size: num_glyphs_in_face + 1 */ int checksum_index; cairo_array_t output; cairo_array_t string_offsets; unsigned long last_offset; unsigned long last_boundary; - int *parent_to_subset; + int *parent_to_subset; /* array size: num_glyphs_in_face + 1 */ cairo_status_t status; cairo_bool_t is_pdf; }; @@ -198,7 +198,7 @@ return _cairo_error (CAIRO_STATUS_NO_MEMORY); font->backend = backend; - font->num_glyphs_in_face = be16_to_cpu (maxp.num_glyphs); + font->base.num_glyphs_in_face = be16_to_cpu (maxp.num_glyphs); font->scaled_font_subset = scaled_font_subset; font->last_offset = 0; @@ -208,20 +208,24 @@ if (unlikely (status)) goto fail1; - font->glyphs = calloc (font->num_glyphs_in_face + 1, sizeof (subset_glyph_t)); + /* Add 2: +1 case font does not contain .notdef, and +1 because an extra + * entry is required to contain the end location of the last glyph. + */ + font->glyphs = calloc (font->base.num_glyphs_in_face + 2, sizeof (subset_glyph_t)); if (unlikely (font->glyphs == NULL)) { status = _cairo_error (CAIRO_STATUS_NO_MEMORY); goto fail1; } - font->parent_to_subset = calloc (font->num_glyphs_in_face, sizeof (int)); + /* Add 1 in case font does not contain .notdef */ + font->parent_to_subset = calloc (font->base.num_glyphs_in_face + 1, sizeof (int)); if (unlikely (font->parent_to_subset == NULL)) { status = _cairo_error (CAIRO_STATUS_NO_MEMORY); goto fail2; } font->is_pdf = is_pdf; - font->base.num_glyphs = 0; + font->num_glyphs = 0; font->base.x_min = (int16_t) be16_to_cpu (head.x_min); font->base.y_min = (int16_t) be16_to_cpu (head.y_min); font->base.x_max = (int16_t) be16_to_cpu (head.x_max); @@ -253,8 +257,9 @@ scaled_font_subset->subset_id); } - font->base.widths = calloc (font->num_glyphs_in_face, sizeof (int)); - if (unlikely (font->base.widths == NULL)) { + /* Add 1 in case font does not contain .notdef */ + font->widths = calloc (font->base.num_glyphs_in_face + 1, sizeof (int)); + if (unlikely (font->widths == NULL)) { status = _cairo_error (CAIRO_STATUS_NO_MEMORY); goto fail4; } @@ -272,7 +277,7 @@ fail5: _cairo_array_fini (&font->string_offsets); - free (font->base.widths); + free (font->widths); fail4: free (font->base.ps_name); fail3: @@ -291,7 +296,7 @@ cairo_truetype_font_destroy (cairo_truetype_font_t *font) { _cairo_array_fini (&font->string_offsets); - free (font->base.widths); + free (font->widths); free (font->base.ps_name); free (font->base.font_name); free (font->parent_to_subset); @@ -613,9 +618,9 @@ return _cairo_truetype_font_set_error (font, status); if (be16_to_cpu (header.index_to_loc_format) == 0) - size = sizeof (int16_t) * (font->num_glyphs_in_face + 1); + size = sizeof (int16_t) * (font->base.num_glyphs_in_face + 1); else - size = sizeof (int32_t) * (font->num_glyphs_in_face + 1); + size = sizeof (int32_t) * (font->base.num_glyphs_in_face + 1); u.bytes = malloc (size); if (unlikely (u.bytes == NULL)) @@ -627,7 +632,7 @@ return _cairo_truetype_font_set_error (font, status); start_offset = _cairo_array_num_elements (&font->output); - for (i = 0; i < font->base.num_glyphs; i++) { + for (i = 0; i < font->num_glyphs; i++) { index = font->glyphs[i].parent_index; if (be16_to_cpu (header.index_to_loc_format) == 0) { begin = be16_to_cpu (u.short_offsets[index]) * 2; @@ -755,7 +760,7 @@ if (unlikely (status)) return _cairo_truetype_font_set_error (font, status); - hhea->num_hmetrics = cpu_to_be16 ((uint16_t)(font->base.num_glyphs)); + hhea->num_hmetrics = cpu_to_be16 ((uint16_t)(font->num_glyphs)); return CAIRO_STATUS_SUCCESS; } @@ -785,7 +790,7 @@ num_hmetrics = be16_to_cpu(hhea.num_hmetrics); - for (i = 0; i < font->base.num_glyphs; i++) { + for (i = 0; i < font->num_glyphs; i++) { long_entry_size = 2 * sizeof (int16_t); short_entry_size = sizeof (int16_t); status = cairo_truetype_font_allocate_write_buffer (font, @@ -819,7 +824,7 @@ if (unlikely (status)) return _cairo_truetype_font_set_error (font, status); } - font->base.widths[i] = be16_to_cpu (p[0]); + font->widths[i] = be16_to_cpu (p[0]); } return CAIRO_STATUS_SUCCESS; @@ -846,10 +851,10 @@ if (be16_to_cpu (header.index_to_loc_format) == 0) { - for (i = 0; i < font->base.num_glyphs + 1; i++) + for (i = 0; i < font->num_glyphs + 1; i++) cairo_truetype_font_write_be16 (font, font->glyphs[i].location / 2); } else { - for (i = 0; i < font->base.num_glyphs + 1; i++) + for (i = 0; i < font->num_glyphs + 1; i++) cairo_truetype_font_write_be32 (font, font->glyphs[i].location); } @@ -877,7 +882,7 @@ if (unlikely (status)) return _cairo_truetype_font_set_error (font, status); - maxp->num_glyphs = cpu_to_be16 (font->base.num_glyphs); + maxp->num_glyphs = cpu_to_be16 (font->num_glyphs); return CAIRO_STATUS_SUCCESS; } @@ -1021,13 +1026,13 @@ unsigned short glyph, unsigned short *out) { - if (glyph >= font->num_glyphs_in_face) + if (glyph >= font->base.num_glyphs_in_face) return CAIRO_INT_STATUS_UNSUPPORTED; if (font->parent_to_subset[glyph] == 0) { - font->parent_to_subset[glyph] = font->base.num_glyphs; - font->glyphs[font->base.num_glyphs].parent_index = glyph; - font->base.num_glyphs++; + font->parent_to_subset[glyph] = font->num_glyphs; + font->glyphs[font->num_glyphs].parent_index = glyph; + font->num_glyphs++; } *out = font->parent_to_subset[glyph]; @@ -1180,7 +1185,7 @@ goto fail3; } for (i = 0; i < font->scaled_font_subset->num_glyphs; i++) - truetype_subset->widths[i] = (double)font->base.widths[i]/font->base.units_per_em; + truetype_subset->widths[i] = (double)font->widths[i]/font->base.units_per_em; truetype_subset->x_min = (double)font->base.x_min/font->base.units_per_em; truetype_subset->y_min = (double)font->base.y_min/font->base.units_per_em; @@ -1426,6 +1431,12 @@ return status; } +/* + * Sanity check on font name length as some broken fonts may return very long + * strings of garbage. 127 is maximum length of a PS name. + */ +#define MAX_FONT_NAME_LENGTH 127 + static cairo_status_t find_name (tt_name_t *name, int name_id, int platform, int encoding, int language, char **str_out) { @@ -1444,11 +1455,17 @@ be16_to_cpu (record->encoding) == encoding && (language == -1 || be16_to_cpu (record->language) == language)) { - str = malloc (be16_to_cpu (record->length) + 1); + len = be16_to_cpu (record->length); + if (platform == 3 && len > MAX_FONT_NAME_LENGTH*2) /* UTF-16 name */ + break; + + if (len > MAX_FONT_NAME_LENGTH) + break; + + str = malloc (len + 1); if (str == NULL) return _cairo_error (CAIRO_STATUS_NO_MEMORY); - len = be16_to_cpu (record->length); memcpy (str, ((char*)name) + be16_to_cpu (name->strings_offset) + be16_to_cpu (record->offset), len); diff -Nru cairo-1.15.8/src/cairo-type1-fallback.c cairo-1.15.10/src/cairo-type1-fallback.c --- cairo-1.15.8/src/cairo-type1-fallback.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-type1-fallback.c 2017-12-07 02:13:45.000000000 +0000 @@ -33,7 +33,7 @@ * Adrian Johnson */ -#define _BSD_SOURCE /* for snprintf(), strdup() */ +#define _DEFAULT_SOURCE /* for snprintf(), strdup() */ #include "cairoint.h" #include "cairo-array-private.h" diff -Nru cairo-1.15.8/src/cairo-type1-subset.c cairo-1.15.10/src/cairo-type1-subset.c --- cairo-1.15.8/src/cairo-type1-subset.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-type1-subset.c 2017-12-07 02:14:36.000000000 +0000 @@ -40,7 +40,7 @@ */ -#define _BSD_SOURCE /* for snprintf(), strdup() */ +#define _DEFAULT_SOURCE /* for snprintf(), strdup() */ #include "cairoint.h" #include "cairo-array-private.h" @@ -311,7 +311,7 @@ const char *decimal_point; int decimal_point_len; - decimal_point = cairo_get_locale_decimal_point (); + decimal_point = _cairo_get_locale_decimal_point (); decimal_point_len = strlen (decimal_point); assert (decimal_point_len != 0); diff -Nru cairo-1.15.8/src/cairo-unicode.c cairo-1.15.10/src/cairo-unicode.c --- cairo-1.15.8/src/cairo-unicode.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-unicode.c 2017-12-07 02:14:36.000000000 +0000 @@ -357,8 +357,6 @@ _cairo_ucs4_to_utf16 (uint32_t unicode, uint16_t *utf16) { - int len; - if (unicode < 0x10000) { if (utf16) utf16[0] = unicode; diff -Nru cairo-1.15.8/src/cairo-xlib-core-compositor.c cairo-1.15.10/src/cairo-xlib-core-compositor.c --- cairo-1.15.8/src/cairo-xlib-core-compositor.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-xlib-core-compositor.c 2017-12-07 02:14:36.000000000 +0000 @@ -632,9 +632,10 @@ const cairo_compositor_t * _cairo_xlib_core_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_compositor_t compositor; - if (compositor.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { compositor.delegate = _cairo_xlib_fallback_compositor_get (); compositor.paint = _cairo_xlib_core_compositor_paint; @@ -642,6 +643,8 @@ compositor.fill = _cairo_xlib_core_compositor_fill; compositor.stroke = _cairo_xlib_core_compositor_stroke; compositor.glyphs = NULL; /* XXX PolyGlyph? */ + + _cairo_atomic_init_once_leave(&once); } return &compositor; diff -Nru cairo-1.15.8/src/cairo-xlib-render-compositor.c cairo-1.15.10/src/cairo-xlib-render-compositor.c --- cairo-1.15.8/src/cairo-xlib-render-compositor.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/cairo-xlib-render-compositor.c 2017-12-07 02:14:36.000000000 +0000 @@ -1725,9 +1725,10 @@ const cairo_compositor_t * _cairo_xlib_mask_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_mask_compositor_t compositor; - if (compositor.base.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { _cairo_mask_compositor_init (&compositor, _cairo_xlib_fallback_compositor_get ()); @@ -1745,6 +1746,8 @@ compositor.composite_boxes = composite_boxes; compositor.check_composite_glyphs = check_composite_glyphs; compositor.composite_glyphs = composite_glyphs; + + _cairo_atomic_init_once_leave(&once); } return &compositor.base; @@ -1973,9 +1976,10 @@ const cairo_compositor_t * _cairo_xlib_traps_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_traps_compositor_t compositor; - if (compositor.base.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { _cairo_traps_compositor_init (&compositor, _cairo_xlib_mask_compositor_get ()); @@ -1997,6 +2001,8 @@ compositor.composite_tristrip = composite_tristrip; compositor.check_composite_glyphs = check_composite_glyphs; compositor.composite_glyphs = composite_glyphs; + + _cairo_atomic_init_once_leave(&once); } return &compositor.base; diff -Nru cairo-1.15.8/src/Makefile.am.features cairo-1.15.10/src/Makefile.am.features --- cairo-1.15.8/src/Makefile.am.features 2017-04-24 22:50:27.000000000 +0000 +++ cairo-1.15.10/src/Makefile.am.features 2017-12-07 02:15:43.000000000 +0000 @@ -321,6 +321,22 @@ enabled_cairo_pkgconf += cairo-glesv2.pc endif +unsupported_cairo_headers += $(cairo_glesv3_headers) +all_cairo_headers += $(cairo_glesv3_headers) +all_cairo_private += $(cairo_glesv3_private) +all_cairo_cxx_sources += $(cairo_glesv3_cxx_sources) +all_cairo_sources += $(cairo_glesv3_sources) +if CAIRO_HAS_GLESV3_SURFACE +enabled_cairo_headers += $(cairo_glesv3_headers) +enabled_cairo_private += $(cairo_glesv3_private) +enabled_cairo_cxx_sources += $(cairo_glesv3_cxx_sources) +enabled_cairo_sources += $(cairo_glesv3_sources) +endif +all_cairo_pkgconf += cairo-glesv3.pc +if CAIRO_HAS_GLESV3_SURFACE +enabled_cairo_pkgconf += cairo-glesv3.pc +endif + unsupported_cairo_headers += $(cairo_cogl_headers) all_cairo_headers += $(cairo_cogl_headers) all_cairo_private += $(cairo_cogl_private) diff -Nru cairo-1.15.8/src/Makefile.in cairo-1.15.10/src/Makefile.in --- cairo-1.15.8/src/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/src/Makefile.in 2017-12-11 21:03:10.000000000 +0000 @@ -146,7 +146,7 @@ build_triplet = @build@ host_triplet = @host@ EXTRA_PROGRAMS = -TESTS = $(am__EXEEXT_1) $(am__append_186) +TESTS = $(am__EXEEXT_1) $(am__append_191) check_PROGRAMS = check-link$(EXEEXT) @CAIRO_HAS_XLIB_SURFACE_TRUE@am__append_1 = $(cairo_xlib_headers) @CAIRO_HAS_XLIB_SURFACE_TRUE@am__append_2 = $(cairo_xlib_private) @@ -243,107 +243,111 @@ @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_93 = $(cairo_glesv2_cxx_sources) @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_94 = $(cairo_glesv2_sources) @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__append_95 = cairo-glesv2.pc -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_96 = $(cairo_cogl_headers) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_97 = $(cairo_cogl_private) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_98 = $(cairo_cogl_cxx_sources) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_99 = $(cairo_cogl_sources) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_100 = cairo-cogl.pc -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_101 = $(cairo_directfb_headers) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_102 = $(cairo_directfb_private) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_103 = $(cairo_directfb_cxx_sources) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_104 = $(cairo_directfb_sources) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_105 = cairo-directfb.pc -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_106 = $(cairo_vg_headers) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_107 = $(cairo_vg_private) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_108 = $(cairo_vg_cxx_sources) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_109 = $(cairo_vg_sources) -@CAIRO_HAS_VG_SURFACE_TRUE@am__append_110 = cairo-vg.pc -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_111 = $(cairo_egl_headers) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_112 = $(cairo_egl_private) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_113 = $(cairo_egl_cxx_sources) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_114 = $(cairo_egl_sources) -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_115 = cairo-egl.pc -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_116 = $(cairo_glx_headers) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_117 = $(cairo_glx_private) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_118 = $(cairo_glx_cxx_sources) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_119 = $(cairo_glx_sources) -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_120 = cairo-glx.pc -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_121 = $(cairo_wgl_headers) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_122 = $(cairo_wgl_private) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_123 = $(cairo_wgl_cxx_sources) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_124 = $(cairo_wgl_sources) -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_125 = cairo-wgl.pc -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_126 = $(cairo_script_headers) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_127 = $(cairo_script_private) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_128 = $(cairo_script_cxx_sources) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_129 = $(cairo_script_sources) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_130 = cairo-script.pc -@CAIRO_HAS_FT_FONT_TRUE@am__append_131 = $(cairo_ft_headers) -@CAIRO_HAS_FT_FONT_TRUE@am__append_132 = $(cairo_ft_private) -@CAIRO_HAS_FT_FONT_TRUE@am__append_133 = $(cairo_ft_cxx_sources) -@CAIRO_HAS_FT_FONT_TRUE@am__append_134 = $(cairo_ft_sources) -@CAIRO_HAS_FT_FONT_TRUE@am__append_135 = cairo-ft.pc -@CAIRO_HAS_FC_FONT_TRUE@am__append_136 = $(cairo_fc_headers) -@CAIRO_HAS_FC_FONT_TRUE@am__append_137 = $(cairo_fc_private) -@CAIRO_HAS_FC_FONT_TRUE@am__append_138 = $(cairo_fc_cxx_sources) -@CAIRO_HAS_FC_FONT_TRUE@am__append_139 = $(cairo_fc_sources) -@CAIRO_HAS_FC_FONT_TRUE@am__append_140 = cairo-fc.pc -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_141 = $(cairo_ps_headers) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_142 = $(cairo_ps_private) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_143 = $(cairo_ps_cxx_sources) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_144 = $(cairo_ps_sources) -@CAIRO_HAS_PS_SURFACE_TRUE@am__append_145 = cairo-ps.pc -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_146 = $(cairo_pdf_headers) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_147 = $(cairo_pdf_private) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_148 = $(cairo_pdf_cxx_sources) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_149 = $(cairo_pdf_sources) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_150 = cairo-pdf.pc -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_151 = $(cairo_svg_headers) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_152 = $(cairo_svg_private) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_153 = $(cairo_svg_cxx_sources) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_154 = $(cairo_svg_sources) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_155 = cairo-svg.pc -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_156 = $(cairo_test_surfaces_private) $(cairo_test_surfaces_headers) -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_157 = $(cairo_test_surfaces_cxx_sources) -@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_158 = $(cairo_test_surfaces_sources) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_159 = $(cairo_tee_headers) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_160 = $(cairo_tee_private) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_161 = $(cairo_tee_cxx_sources) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_162 = $(cairo_tee_sources) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_163 = cairo-tee.pc -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_164 = $(cairo_xml_headers) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_165 = $(cairo_xml_private) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_166 = $(cairo_xml_cxx_sources) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_167 = $(cairo_xml_sources) -@CAIRO_HAS_XML_SURFACE_TRUE@am__append_168 = cairo-xml.pc -@CAIRO_HAS_PTHREAD_TRUE@am__append_169 = $(cairo_pthread_private) $(cairo_pthread_headers) -@CAIRO_HAS_PTHREAD_TRUE@am__append_170 = $(cairo_pthread_cxx_sources) -@CAIRO_HAS_PTHREAD_TRUE@am__append_171 = $(cairo_pthread_sources) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_172 = $(cairo_gobject_headers) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_173 = $(cairo_gobject_private) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_174 = $(cairo_gobject_cxx_sources) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_175 = $(cairo_gobject_sources) -@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_176 = cairo-gobject.pc -@CAIRO_HAS_TRACE_TRUE@am__append_177 = $(cairo_trace_private) $(cairo_trace_headers) -@CAIRO_HAS_TRACE_TRUE@am__append_178 = $(cairo_trace_cxx_sources) -@CAIRO_HAS_TRACE_TRUE@am__append_179 = $(cairo_trace_sources) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_180 = $(cairo_interpreter_private) $(cairo_interpreter_headers) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_181 = $(cairo_interpreter_cxx_sources) -@CAIRO_HAS_INTERPRETER_TRUE@am__append_182 = $(cairo_interpreter_sources) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_183 = $(cairo_symbol_lookup_private) $(cairo_symbol_lookup_headers) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_184 = $(cairo_symbol_lookup_cxx_sources) -@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_185 = $(cairo_symbol_lookup_sources) -@CROSS_COMPILING_FALSE@am__append_186 = check-link$(EXEEXT) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_96 = $(cairo_glesv3_headers) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_97 = $(cairo_glesv3_private) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_98 = $(cairo_glesv3_cxx_sources) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_99 = $(cairo_glesv3_sources) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__append_100 = cairo-glesv3.pc +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_101 = $(cairo_cogl_headers) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_102 = $(cairo_cogl_private) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_103 = $(cairo_cogl_cxx_sources) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_104 = $(cairo_cogl_sources) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__append_105 = cairo-cogl.pc +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_106 = $(cairo_directfb_headers) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_107 = $(cairo_directfb_private) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_108 = $(cairo_directfb_cxx_sources) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_109 = $(cairo_directfb_sources) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__append_110 = cairo-directfb.pc +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_111 = $(cairo_vg_headers) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_112 = $(cairo_vg_private) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_113 = $(cairo_vg_cxx_sources) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_114 = $(cairo_vg_sources) +@CAIRO_HAS_VG_SURFACE_TRUE@am__append_115 = cairo-vg.pc +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_116 = $(cairo_egl_headers) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_117 = $(cairo_egl_private) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_118 = $(cairo_egl_cxx_sources) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_119 = $(cairo_egl_sources) +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__append_120 = cairo-egl.pc +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_121 = $(cairo_glx_headers) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_122 = $(cairo_glx_private) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_123 = $(cairo_glx_cxx_sources) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_124 = $(cairo_glx_sources) +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__append_125 = cairo-glx.pc +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_126 = $(cairo_wgl_headers) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_127 = $(cairo_wgl_private) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_128 = $(cairo_wgl_cxx_sources) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_129 = $(cairo_wgl_sources) +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__append_130 = cairo-wgl.pc +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_131 = $(cairo_script_headers) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_132 = $(cairo_script_private) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_133 = $(cairo_script_cxx_sources) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_134 = $(cairo_script_sources) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__append_135 = cairo-script.pc +@CAIRO_HAS_FT_FONT_TRUE@am__append_136 = $(cairo_ft_headers) +@CAIRO_HAS_FT_FONT_TRUE@am__append_137 = $(cairo_ft_private) +@CAIRO_HAS_FT_FONT_TRUE@am__append_138 = $(cairo_ft_cxx_sources) +@CAIRO_HAS_FT_FONT_TRUE@am__append_139 = $(cairo_ft_sources) +@CAIRO_HAS_FT_FONT_TRUE@am__append_140 = cairo-ft.pc +@CAIRO_HAS_FC_FONT_TRUE@am__append_141 = $(cairo_fc_headers) +@CAIRO_HAS_FC_FONT_TRUE@am__append_142 = $(cairo_fc_private) +@CAIRO_HAS_FC_FONT_TRUE@am__append_143 = $(cairo_fc_cxx_sources) +@CAIRO_HAS_FC_FONT_TRUE@am__append_144 = $(cairo_fc_sources) +@CAIRO_HAS_FC_FONT_TRUE@am__append_145 = cairo-fc.pc +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_146 = $(cairo_ps_headers) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_147 = $(cairo_ps_private) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_148 = $(cairo_ps_cxx_sources) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_149 = $(cairo_ps_sources) +@CAIRO_HAS_PS_SURFACE_TRUE@am__append_150 = cairo-ps.pc +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_151 = $(cairo_pdf_headers) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_152 = $(cairo_pdf_private) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_153 = $(cairo_pdf_cxx_sources) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_154 = $(cairo_pdf_sources) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__append_155 = cairo-pdf.pc +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_156 = $(cairo_svg_headers) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_157 = $(cairo_svg_private) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_158 = $(cairo_svg_cxx_sources) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_159 = $(cairo_svg_sources) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__append_160 = cairo-svg.pc +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_161 = $(cairo_test_surfaces_private) $(cairo_test_surfaces_headers) +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_162 = $(cairo_test_surfaces_cxx_sources) +@CAIRO_HAS_TEST_SURFACES_TRUE@am__append_163 = $(cairo_test_surfaces_sources) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_164 = $(cairo_tee_headers) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_165 = $(cairo_tee_private) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_166 = $(cairo_tee_cxx_sources) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_167 = $(cairo_tee_sources) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__append_168 = cairo-tee.pc +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_169 = $(cairo_xml_headers) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_170 = $(cairo_xml_private) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_171 = $(cairo_xml_cxx_sources) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_172 = $(cairo_xml_sources) +@CAIRO_HAS_XML_SURFACE_TRUE@am__append_173 = cairo-xml.pc +@CAIRO_HAS_PTHREAD_TRUE@am__append_174 = $(cairo_pthread_private) $(cairo_pthread_headers) +@CAIRO_HAS_PTHREAD_TRUE@am__append_175 = $(cairo_pthread_cxx_sources) +@CAIRO_HAS_PTHREAD_TRUE@am__append_176 = $(cairo_pthread_sources) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_177 = $(cairo_gobject_headers) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_178 = $(cairo_gobject_private) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_179 = $(cairo_gobject_cxx_sources) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_180 = $(cairo_gobject_sources) +@CAIRO_HAS_GOBJECT_FUNCTIONS_TRUE@am__append_181 = cairo-gobject.pc +@CAIRO_HAS_TRACE_TRUE@am__append_182 = $(cairo_trace_private) $(cairo_trace_headers) +@CAIRO_HAS_TRACE_TRUE@am__append_183 = $(cairo_trace_cxx_sources) +@CAIRO_HAS_TRACE_TRUE@am__append_184 = $(cairo_trace_sources) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_185 = $(cairo_interpreter_private) $(cairo_interpreter_headers) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_186 = $(cairo_interpreter_cxx_sources) +@CAIRO_HAS_INTERPRETER_TRUE@am__append_187 = $(cairo_interpreter_sources) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_188 = $(cairo_symbol_lookup_private) $(cairo_symbol_lookup_headers) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_189 = $(cairo_symbol_lookup_cxx_sources) +@CAIRO_HAS_SYMBOL_LOOKUP_TRUE@am__append_190 = $(cairo_symbol_lookup_sources) +@CROSS_COMPILING_FALSE@am__append_191 = check-link$(EXEEXT) subdir = src ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/build/aclocal.cairo.m4 \ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -369,11 +373,11 @@ cairo-quartz.pc cairo-quartz-font.pc cairo-quartz-image.pc \ cairo-win32.pc cairo-win32-font.pc cairo-skia.pc cairo-os2.pc \ cairo-beos.pc cairo-drm.pc cairo-gallium.pc cairo-png.pc \ - cairo-gl.pc cairo-glesv2.pc cairo-cogl.pc cairo-directfb.pc \ - cairo-vg.pc cairo-egl.pc cairo-glx.pc cairo-wgl.pc \ - cairo-script.pc cairo-ft.pc cairo-fc.pc cairo-ps.pc \ - cairo-pdf.pc cairo-svg.pc cairo-tee.pc cairo-xml.pc \ - cairo-gobject.pc + cairo-gl.pc cairo-glesv2.pc cairo-glesv3.pc cairo-cogl.pc \ + cairo-directfb.pc cairo-vg.pc cairo-egl.pc cairo-glx.pc \ + cairo-wgl.pc cairo-script.pc cairo-ft.pc cairo-fc.pc \ + cairo-ps.pc cairo-pdf.pc cairo-svg.pc cairo-tee.pc \ + cairo-xml.pc cairo-gobject.pc CONFIG_CLEAN_VPATH_FILES = am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ @@ -463,11 +467,12 @@ cairo-truetype-subset-private.h cairo-type1-private.h \ cairo-type3-glyph-surface-private.h \ cairo-pdf-operators-private.h cairo-pdf-shading-private.h \ - cairo-xlib-private.h cairo-xlib-surface-private.h \ - cairo-xlib-xrender-private.h cairo-xcb-private.h \ - cairo-quartz-private.h win32/cairo-win32-private.h \ - skia/cairo-skia-private.h cairo-os2-private.h \ - drm/cairo-drm-private.h drm/cairo-drm-intel-private.h \ + cairo-tag-attributes-private.h cairo-xlib-private.h \ + cairo-xlib-surface-private.h cairo-xlib-xrender-private.h \ + cairo-xcb-private.h cairo-quartz-private.h \ + win32/cairo-win32-private.h skia/cairo-skia-private.h \ + cairo-os2-private.h drm/cairo-drm-private.h \ + drm/cairo-drm-intel-private.h \ drm/cairo-drm-intel-brw-defines.h \ drm/cairo-drm-intel-brw-structs.h drm/cairo-drm-intel-brw-eu.h \ drm/cairo-drm-intel-command-private.h \ @@ -480,8 +485,8 @@ cairo-cogl-utils-private.h cairo-script-private.h \ cairo-ft-private.h cairo-ps-surface-private.h \ cairo-pdf-surface-private.h cairo-tag-stack-private.h \ - cairo-tag-attributes-private.h cairo-svg-surface-private.h \ - test-compositor-surface.h test-compositor-surface-private.h \ + cairo-svg-surface-private.h test-compositor-surface.h \ + test-compositor-surface-private.h \ test-null-compositor-surface.h test-paginated-surface.h \ cairo-tee-surface-private.h cairo-analysis-surface.c \ cairo-arc.c cairo-array.c cairo-atomic.c cairo-base64-stream.c \ @@ -530,8 +535,9 @@ cairo-type1-fallback.c cairo-type1-glyph-names.c \ cairo-type1-subset.c cairo-type3-glyph-surface.c \ cairo-pdf-operators.c cairo-pdf-shading.c \ - cairo-deflate-stream.c cairo-xlib-display.c \ - cairo-xlib-core-compositor.c cairo-xlib-fallback-compositor.c \ + cairo-tag-attributes.c cairo-deflate-stream.c \ + cairo-xlib-display.c cairo-xlib-core-compositor.c \ + cairo-xlib-fallback-compositor.c \ cairo-xlib-render-compositor.c cairo-xlib-screen.c \ cairo-xlib-source.c cairo-xlib-surface.c \ cairo-xlib-surface-shm.c cairo-xlib-visual.c \ @@ -567,10 +573,10 @@ cairo-egl-context.c cairo-glx-context.c cairo-wgl-context.c \ cairo-script-surface.c cairo-ft-font.c cairo-ps-surface.c \ cairo-pdf-surface.c cairo-pdf-interchange.c cairo-tag-stack.c \ - cairo-tag-attributes.c cairo-svg-surface.c \ - test-compositor-surface.c test-null-compositor-surface.c \ - test-base-compositor-surface.c test-paginated-surface.c \ - cairo-tee-surface.c cairo-xml-surface.c cairo-version.h + cairo-svg-surface.c test-compositor-surface.c \ + test-null-compositor-surface.c test-base-compositor-surface.c \ + test-paginated-surface.c cairo-tee-surface.c \ + cairo-xml-surface.c cairo-version.h am__objects_1 = @CAIRO_HAS_XLIB_SURFACE_TRUE@am__objects_2 = $(am__objects_1) @CAIRO_HAS_XLIB_XRENDER_SURFACE_TRUE@am__objects_3 = $(am__objects_1) @@ -586,51 +592,53 @@ @CAIRO_HAS_GL_SURFACE_TRUE@am__objects_13 = $(am__objects_1) am__objects_14 = $(am__objects_1) @CAIRO_HAS_GLESV2_SURFACE_TRUE@am__objects_15 = $(am__objects_14) -@CAIRO_HAS_COGL_SURFACE_TRUE@am__objects_16 = $(am__objects_1) -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__objects_17 = $(am__objects_1) -@CAIRO_HAS_VG_SURFACE_TRUE@am__objects_18 = $(am__objects_1) -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__objects_19 = $(am__objects_1) -@CAIRO_HAS_FT_FONT_TRUE@am__objects_20 = $(am__objects_1) -@CAIRO_HAS_PS_SURFACE_TRUE@am__objects_21 = $(am__objects_1) -@CAIRO_HAS_PDF_SURFACE_TRUE@am__objects_22 = $(am__objects_1) -@CAIRO_HAS_SVG_SURFACE_TRUE@am__objects_23 = $(am__objects_1) -@CAIRO_HAS_TEE_SURFACE_TRUE@am__objects_24 = $(am__objects_1) -@CAIRO_HAS_XML_SURFACE_TRUE@am__objects_25 = $(am__objects_1) -am__objects_26 = $(am__objects_1) $(am__objects_2) $(am__objects_3) \ +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__objects_16 = $(am__objects_14) +@CAIRO_HAS_COGL_SURFACE_TRUE@am__objects_17 = $(am__objects_1) +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__objects_18 = $(am__objects_1) +@CAIRO_HAS_VG_SURFACE_TRUE@am__objects_19 = $(am__objects_1) +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__objects_20 = $(am__objects_1) +@CAIRO_HAS_FT_FONT_TRUE@am__objects_21 = $(am__objects_1) +@CAIRO_HAS_PS_SURFACE_TRUE@am__objects_22 = $(am__objects_1) +@CAIRO_HAS_PDF_SURFACE_TRUE@am__objects_23 = $(am__objects_1) +@CAIRO_HAS_SVG_SURFACE_TRUE@am__objects_24 = $(am__objects_1) +@CAIRO_HAS_TEE_SURFACE_TRUE@am__objects_25 = $(am__objects_1) +@CAIRO_HAS_XML_SURFACE_TRUE@am__objects_26 = $(am__objects_1) +am__objects_27 = $(am__objects_1) $(am__objects_2) $(am__objects_3) \ $(am__objects_4) $(am__objects_1) $(am__objects_1) \ $(am__objects_5) $(am__objects_6) $(am__objects_1) \ $(am__objects_7) $(am__objects_8) $(am__objects_1) \ $(am__objects_9) $(am__objects_10) $(am__objects_11) \ $(am__objects_12) $(am__objects_1) $(am__objects_1) \ $(am__objects_13) $(am__objects_15) $(am__objects_16) \ - $(am__objects_17) $(am__objects_18) $(am__objects_1) \ - $(am__objects_1) $(am__objects_1) $(am__objects_19) \ - $(am__objects_20) $(am__objects_1) $(am__objects_21) \ + $(am__objects_17) $(am__objects_18) $(am__objects_19) \ + $(am__objects_1) $(am__objects_1) $(am__objects_1) \ + $(am__objects_20) $(am__objects_21) $(am__objects_1) \ $(am__objects_22) $(am__objects_23) $(am__objects_24) \ - $(am__objects_25) $(am__objects_1) -am__objects_27 = $(am__objects_1) $(am__objects_1) -@CAIRO_HAS_TEST_SURFACES_TRUE@am__objects_28 = $(am__objects_1) -am__objects_29 = $(am__objects_27) $(am__objects_2) $(am__objects_1) \ + $(am__objects_25) $(am__objects_26) $(am__objects_1) +am__objects_28 = $(am__objects_1) $(am__objects_1) +@CAIRO_HAS_TEST_SURFACES_TRUE@am__objects_29 = $(am__objects_1) +am__objects_30 = $(am__objects_28) $(am__objects_2) $(am__objects_1) \ $(am__objects_4) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_6) $(am__objects_1) \ $(am__objects_1) $(am__objects_8) $(am__objects_1) \ $(am__objects_9) $(am__objects_10) $(am__objects_1) \ $(am__objects_12) $(am__objects_1) $(am__objects_1) \ $(am__objects_13) $(am__objects_15) $(am__objects_16) \ + $(am__objects_17) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) $(am__objects_1) $(am__objects_19) \ - $(am__objects_20) $(am__objects_1) $(am__objects_21) \ - $(am__objects_22) $(am__objects_23) $(am__objects_28) \ - $(am__objects_24) $(am__objects_1) $(am__objects_1) \ + $(am__objects_20) $(am__objects_21) $(am__objects_1) \ + $(am__objects_22) $(am__objects_23) $(am__objects_24) \ + $(am__objects_29) $(am__objects_25) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) -am__objects_30 = cairo-cff-subset.lo cairo-scaled-font-subsets.lo \ + $(am__objects_1) $(am__objects_1) +am__objects_31 = cairo-cff-subset.lo cairo-scaled-font-subsets.lo \ cairo-truetype-subset.lo cairo-type1-fallback.lo \ cairo-type1-glyph-names.lo cairo-type1-subset.lo \ cairo-type3-glyph-surface.lo -am__objects_31 = cairo-pdf-operators.lo cairo-pdf-shading.lo -am__objects_32 = cairo-deflate-stream.lo -am__objects_33 = cairo-analysis-surface.lo cairo-arc.lo cairo-array.lo \ +am__objects_32 = cairo-pdf-operators.lo cairo-pdf-shading.lo \ + cairo-tag-attributes.lo +am__objects_33 = cairo-deflate-stream.lo +am__objects_34 = cairo-analysis-surface.lo cairo-arc.lo cairo-array.lo \ cairo-atomic.lo cairo-base64-stream.lo cairo-base85-stream.lo \ cairo-bentley-ottmann.lo cairo-bentley-ottmann-rectangular.lo \ cairo-bentley-ottmann-rectilinear.lo \ @@ -672,38 +680,38 @@ cairo-clip-tor-scan-converter.lo cairo-toy-font-face.lo \ cairo-traps.lo cairo-tristrip.lo cairo-traps-compositor.lo \ cairo-unicode.lo cairo-user-font.lo cairo-version.lo \ - cairo-wideint.lo $(am__objects_30) $(am__objects_31) \ - $(am__objects_32) -am__objects_34 = cairo-xlib-display.lo cairo-xlib-core-compositor.lo \ + cairo-wideint.lo $(am__objects_31) $(am__objects_32) \ + $(am__objects_33) +am__objects_35 = cairo-xlib-display.lo cairo-xlib-core-compositor.lo \ cairo-xlib-fallback-compositor.lo \ cairo-xlib-render-compositor.lo cairo-xlib-screen.lo \ cairo-xlib-source.lo cairo-xlib-surface.lo \ cairo-xlib-surface-shm.lo cairo-xlib-visual.lo \ cairo-xlib-xcb-surface.lo -@CAIRO_HAS_XLIB_SURFACE_TRUE@am__objects_35 = $(am__objects_34) -am__objects_36 = cairo-xcb-connection.lo cairo-xcb-connection-core.lo \ +@CAIRO_HAS_XLIB_SURFACE_TRUE@am__objects_36 = $(am__objects_35) +am__objects_37 = cairo-xcb-connection.lo cairo-xcb-connection-core.lo \ cairo-xcb-connection-render.lo cairo-xcb-connection-shm.lo \ cairo-xcb-screen.lo cairo-xcb-shm.lo cairo-xcb-surface.lo \ cairo-xcb-surface-core.lo cairo-xcb-surface-render.lo \ cairo-xcb-resources.lo -@CAIRO_HAS_XCB_SURFACE_TRUE@am__objects_37 = $(am__objects_36) -am__objects_38 = cairo-quartz-surface.lo -@CAIRO_HAS_QUARTZ_SURFACE_TRUE@am__objects_39 = $(am__objects_38) -am__objects_40 = cairo-quartz-font.lo -@CAIRO_HAS_QUARTZ_FONT_TRUE@am__objects_41 = $(am__objects_40) -am__objects_42 = cairo-quartz-image-surface.lo -@CAIRO_HAS_QUARTZ_IMAGE_SURFACE_TRUE@am__objects_43 = \ -@CAIRO_HAS_QUARTZ_IMAGE_SURFACE_TRUE@ $(am__objects_42) -am__objects_44 = cairo-win32-debug.lo cairo-win32-device.lo \ +@CAIRO_HAS_XCB_SURFACE_TRUE@am__objects_38 = $(am__objects_37) +am__objects_39 = cairo-quartz-surface.lo +@CAIRO_HAS_QUARTZ_SURFACE_TRUE@am__objects_40 = $(am__objects_39) +am__objects_41 = cairo-quartz-font.lo +@CAIRO_HAS_QUARTZ_FONT_TRUE@am__objects_42 = $(am__objects_41) +am__objects_43 = cairo-quartz-image-surface.lo +@CAIRO_HAS_QUARTZ_IMAGE_SURFACE_TRUE@am__objects_44 = \ +@CAIRO_HAS_QUARTZ_IMAGE_SURFACE_TRUE@ $(am__objects_43) +am__objects_45 = cairo-win32-debug.lo cairo-win32-device.lo \ cairo-win32-gdi-compositor.lo cairo-win32-system.lo \ cairo-win32-surface.lo cairo-win32-display-surface.lo \ cairo-win32-printing-surface.lo -@CAIRO_HAS_WIN32_SURFACE_TRUE@am__objects_45 = $(am__objects_44) -am__objects_46 = cairo-win32-font.lo -@CAIRO_HAS_WIN32_FONT_TRUE@am__objects_47 = $(am__objects_46) -am__objects_48 = cairo-os2-surface.lo -@CAIRO_HAS_OS2_SURFACE_TRUE@am__objects_49 = $(am__objects_48) -am__objects_50 = cairo-drm.lo cairo-drm-bo.lo cairo-drm-surface.lo \ +@CAIRO_HAS_WIN32_SURFACE_TRUE@am__objects_46 = $(am__objects_45) +am__objects_47 = cairo-win32-font.lo +@CAIRO_HAS_WIN32_FONT_TRUE@am__objects_48 = $(am__objects_47) +am__objects_49 = cairo-os2-surface.lo +@CAIRO_HAS_OS2_SURFACE_TRUE@am__objects_50 = $(am__objects_49) +am__objects_51 = cairo-drm.lo cairo-drm-bo.lo cairo-drm-surface.lo \ cairo-drm-intel.lo cairo-drm-intel-debug.lo \ cairo-drm-intel-surface.lo cairo-drm-i915-surface.lo \ cairo-drm-i915-glyphs.lo cairo-drm-i915-shader.lo \ @@ -712,68 +720,69 @@ cairo-drm-i965-spans.lo cairo-drm-intel-brw-eu.lo \ cairo-drm-intel-brw-eu-emit.lo cairo-drm-intel-brw-eu-util.lo \ cairo-drm-radeon.lo cairo-drm-radeon-surface.lo -@CAIRO_HAS_DRM_SURFACE_TRUE@am__objects_51 = $(am__objects_50) -am__objects_52 = cairo-drm-gallium-surface.lo -@CAIRO_HAS_GALLIUM_SURFACE_TRUE@am__objects_53 = $(am__objects_52) -am__objects_54 = cairo-png.lo -@CAIRO_HAS_PNG_FUNCTIONS_TRUE@am__objects_55 = $(am__objects_54) -am__objects_56 = cairo-gl-composite.lo cairo-gl-device.lo \ +@CAIRO_HAS_DRM_SURFACE_TRUE@am__objects_52 = $(am__objects_51) +am__objects_53 = cairo-drm-gallium-surface.lo +@CAIRO_HAS_GALLIUM_SURFACE_TRUE@am__objects_54 = $(am__objects_53) +am__objects_55 = cairo-png.lo +@CAIRO_HAS_PNG_FUNCTIONS_TRUE@am__objects_56 = $(am__objects_55) +am__objects_57 = cairo-gl-composite.lo cairo-gl-device.lo \ cairo-gl-dispatch.lo cairo-gl-glyphs.lo cairo-gl-gradient.lo \ cairo-gl-info.lo cairo-gl-operand.lo cairo-gl-shaders.lo \ cairo-gl-msaa-compositor.lo cairo-gl-spans-compositor.lo \ cairo-gl-traps-compositor.lo cairo-gl-source.lo \ cairo-gl-surface.lo -@CAIRO_HAS_GL_SURFACE_TRUE@am__objects_57 = $(am__objects_56) -am__objects_58 = $(am__objects_56) -@CAIRO_HAS_GLESV2_SURFACE_TRUE@am__objects_59 = $(am__objects_58) -am__objects_60 = cairo-cogl-surface.lo cairo-cogl-gradient.lo \ +@CAIRO_HAS_GL_SURFACE_TRUE@am__objects_58 = $(am__objects_57) +am__objects_59 = $(am__objects_57) +@CAIRO_HAS_GLESV2_SURFACE_TRUE@am__objects_60 = $(am__objects_59) +@CAIRO_HAS_GLESV3_SURFACE_TRUE@am__objects_61 = $(am__objects_59) +am__objects_62 = cairo-cogl-surface.lo cairo-cogl-gradient.lo \ cairo-cogl-context.lo cairo-cogl-utils.lo -@CAIRO_HAS_COGL_SURFACE_TRUE@am__objects_61 = $(am__objects_60) -am__objects_62 = cairo-directfb-surface.lo -@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__objects_63 = $(am__objects_62) -am__objects_64 = cairo-vg-surface.lo -@CAIRO_HAS_VG_SURFACE_TRUE@am__objects_65 = $(am__objects_64) -am__objects_66 = cairo-egl-context.lo -@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__objects_67 = $(am__objects_66) -am__objects_68 = cairo-glx-context.lo -@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__objects_69 = $(am__objects_68) -am__objects_70 = cairo-wgl-context.lo -@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__objects_71 = $(am__objects_70) -am__objects_72 = cairo-script-surface.lo -@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__objects_73 = $(am__objects_72) -am__objects_74 = cairo-ft-font.lo -@CAIRO_HAS_FT_FONT_TRUE@am__objects_75 = $(am__objects_74) -am__objects_76 = cairo-ps-surface.lo -@CAIRO_HAS_PS_SURFACE_TRUE@am__objects_77 = $(am__objects_76) -am__objects_78 = cairo-pdf-surface.lo cairo-pdf-interchange.lo \ - cairo-tag-stack.lo cairo-tag-attributes.lo -@CAIRO_HAS_PDF_SURFACE_TRUE@am__objects_79 = $(am__objects_78) -am__objects_80 = cairo-svg-surface.lo -@CAIRO_HAS_SVG_SURFACE_TRUE@am__objects_81 = $(am__objects_80) -am__objects_82 = test-compositor-surface.lo \ +@CAIRO_HAS_COGL_SURFACE_TRUE@am__objects_63 = $(am__objects_62) +am__objects_64 = cairo-directfb-surface.lo +@CAIRO_HAS_DIRECTFB_SURFACE_TRUE@am__objects_65 = $(am__objects_64) +am__objects_66 = cairo-vg-surface.lo +@CAIRO_HAS_VG_SURFACE_TRUE@am__objects_67 = $(am__objects_66) +am__objects_68 = cairo-egl-context.lo +@CAIRO_HAS_EGL_FUNCTIONS_TRUE@am__objects_69 = $(am__objects_68) +am__objects_70 = cairo-glx-context.lo +@CAIRO_HAS_GLX_FUNCTIONS_TRUE@am__objects_71 = $(am__objects_70) +am__objects_72 = cairo-wgl-context.lo +@CAIRO_HAS_WGL_FUNCTIONS_TRUE@am__objects_73 = $(am__objects_72) +am__objects_74 = cairo-script-surface.lo +@CAIRO_HAS_SCRIPT_SURFACE_TRUE@am__objects_75 = $(am__objects_74) +am__objects_76 = cairo-ft-font.lo +@CAIRO_HAS_FT_FONT_TRUE@am__objects_77 = $(am__objects_76) +am__objects_78 = cairo-ps-surface.lo +@CAIRO_HAS_PS_SURFACE_TRUE@am__objects_79 = $(am__objects_78) +am__objects_80 = cairo-pdf-surface.lo cairo-pdf-interchange.lo \ + cairo-tag-stack.lo +@CAIRO_HAS_PDF_SURFACE_TRUE@am__objects_81 = $(am__objects_80) +am__objects_82 = cairo-svg-surface.lo +@CAIRO_HAS_SVG_SURFACE_TRUE@am__objects_83 = $(am__objects_82) +am__objects_84 = test-compositor-surface.lo \ test-null-compositor-surface.lo \ test-base-compositor-surface.lo test-paginated-surface.lo -@CAIRO_HAS_TEST_SURFACES_TRUE@am__objects_83 = $(am__objects_82) -am__objects_84 = cairo-tee-surface.lo -@CAIRO_HAS_TEE_SURFACE_TRUE@am__objects_85 = $(am__objects_84) -am__objects_86 = cairo-xml-surface.lo -@CAIRO_HAS_XML_SURFACE_TRUE@am__objects_87 = $(am__objects_86) -am__objects_88 = $(am__objects_33) $(am__objects_35) $(am__objects_1) \ - $(am__objects_37) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) $(am__objects_39) $(am__objects_41) \ - $(am__objects_43) $(am__objects_45) $(am__objects_47) \ - $(am__objects_1) $(am__objects_49) $(am__objects_1) \ - $(am__objects_51) $(am__objects_53) $(am__objects_55) \ - $(am__objects_57) $(am__objects_59) $(am__objects_61) \ +@CAIRO_HAS_TEST_SURFACES_TRUE@am__objects_85 = $(am__objects_84) +am__objects_86 = cairo-tee-surface.lo +@CAIRO_HAS_TEE_SURFACE_TRUE@am__objects_87 = $(am__objects_86) +am__objects_88 = cairo-xml-surface.lo +@CAIRO_HAS_XML_SURFACE_TRUE@am__objects_89 = $(am__objects_88) +am__objects_90 = $(am__objects_34) $(am__objects_36) $(am__objects_1) \ + $(am__objects_38) $(am__objects_1) $(am__objects_1) \ + $(am__objects_1) $(am__objects_40) $(am__objects_42) \ + $(am__objects_44) $(am__objects_46) $(am__objects_48) \ + $(am__objects_1) $(am__objects_50) $(am__objects_1) \ + $(am__objects_52) $(am__objects_54) $(am__objects_56) \ + $(am__objects_58) $(am__objects_60) $(am__objects_61) \ $(am__objects_63) $(am__objects_65) $(am__objects_67) \ $(am__objects_69) $(am__objects_71) $(am__objects_73) \ - $(am__objects_75) $(am__objects_1) $(am__objects_77) \ + $(am__objects_75) $(am__objects_77) $(am__objects_1) \ $(am__objects_79) $(am__objects_81) $(am__objects_83) \ - $(am__objects_85) $(am__objects_87) $(am__objects_1) \ + $(am__objects_85) $(am__objects_87) $(am__objects_89) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) -am_libcairo_la_OBJECTS = $(am__objects_26) $(am__objects_29) \ - $(am__objects_88) + $(am__objects_1) $(am__objects_1) +am_libcairo_la_OBJECTS = $(am__objects_27) $(am__objects_30) \ + $(am__objects_90) nodist_libcairo_la_OBJECTS = libcairo_la_OBJECTS = $(am_libcairo_la_OBJECTS) \ $(nodist_libcairo_la_OBJECTS) @@ -840,11 +849,12 @@ cairo-truetype-subset-private.h cairo-type1-private.h \ cairo-type3-glyph-surface-private.h \ cairo-pdf-operators-private.h cairo-pdf-shading-private.h \ - cairo-xlib-private.h cairo-xlib-surface-private.h \ - cairo-xlib-xrender-private.h cairo-xcb-private.h \ - cairo-quartz-private.h win32/cairo-win32-private.h \ - skia/cairo-skia-private.h cairo-os2-private.h \ - drm/cairo-drm-private.h drm/cairo-drm-intel-private.h \ + cairo-tag-attributes-private.h cairo-xlib-private.h \ + cairo-xlib-surface-private.h cairo-xlib-xrender-private.h \ + cairo-xcb-private.h cairo-quartz-private.h \ + win32/cairo-win32-private.h skia/cairo-skia-private.h \ + cairo-os2-private.h drm/cairo-drm-private.h \ + drm/cairo-drm-intel-private.h \ drm/cairo-drm-intel-brw-defines.h \ drm/cairo-drm-intel-brw-structs.h drm/cairo-drm-intel-brw-eu.h \ drm/cairo-drm-intel-command-private.h \ @@ -857,33 +867,34 @@ cairo-cogl-utils-private.h cairo-script-private.h \ cairo-ft-private.h cairo-ps-surface-private.h \ cairo-pdf-surface-private.h cairo-tag-stack-private.h \ - cairo-tag-attributes-private.h cairo-svg-surface-private.h \ - test-compositor-surface.h test-compositor-surface-private.h \ + cairo-svg-surface-private.h test-compositor-surface.h \ + test-compositor-surface-private.h \ test-null-compositor-surface.h test-paginated-surface.h \ cairo-tee-surface-private.h cairo-qt-surface.cpp \ skia/cairo-skia-context.cpp skia/cairo-skia-surface.cpp \ cairo-beos-surface.cpp -am__objects_89 = cairo-qt-surface.lo -@CAIRO_HAS_QT_SURFACE_TRUE@am__objects_90 = $(am__objects_89) -am__objects_91 = cairo-skia-context.lo cairo-skia-surface.lo -@CAIRO_HAS_SKIA_SURFACE_TRUE@am__objects_92 = $(am__objects_91) -am__objects_93 = cairo-beos-surface.lo -@CAIRO_HAS_BEOS_SURFACE_TRUE@am__objects_94 = $(am__objects_93) -am__objects_95 = $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) $(am__objects_1) $(am__objects_90) \ - $(am__objects_1) $(am__objects_1) $(am__objects_1) \ +am__objects_91 = cairo-qt-surface.lo +@CAIRO_HAS_QT_SURFACE_TRUE@am__objects_92 = $(am__objects_91) +am__objects_93 = cairo-skia-context.lo cairo-skia-surface.lo +@CAIRO_HAS_SKIA_SURFACE_TRUE@am__objects_94 = $(am__objects_93) +am__objects_95 = cairo-beos-surface.lo +@CAIRO_HAS_BEOS_SURFACE_TRUE@am__objects_96 = $(am__objects_95) +am__objects_97 = $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_92) \ - $(am__objects_1) $(am__objects_94) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ + $(am__objects_1) $(am__objects_1) $(am__objects_94) \ + $(am__objects_1) $(am__objects_96) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ $(am__objects_1) $(am__objects_1) $(am__objects_1) \ - $(am__objects_1) $(am__objects_1) $(am__objects_1) -am_libcairo_cxx_la_OBJECTS = $(am__objects_26) $(am__objects_29) \ - $(am__objects_95) + $(am__objects_1) $(am__objects_1) $(am__objects_1) \ + $(am__objects_1) $(am__objects_1) $(am__objects_1) \ + $(am__objects_1) +am_libcairo_cxx_la_OBJECTS = $(am__objects_27) $(am__objects_30) \ + $(am__objects_97) libcairo_cxx_la_OBJECTS = $(am_libcairo_cxx_la_OBJECTS) libcairo_cxx_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CXX \ $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=link $(CXXLD) \ @@ -1225,6 +1236,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -1323,6 +1339,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ @@ -1502,16 +1520,26 @@ cairo_egl_sources = cairo-egl-context.c cairo_glx_sources = cairo-glx-context.c cairo_wgl_sources = cairo-wgl-context.c -_cairo_pdf_operators_private = cairo-pdf-operators-private.h cairo-pdf-shading-private.h -_cairo_pdf_operators_sources = cairo-pdf-operators.c cairo-pdf-shading.c +_cairo_pdf_operators_private = \ + cairo-pdf-operators-private.h \ + cairo-pdf-shading-private.h \ + cairo-tag-attributes-private.h \ + $(NULL) + +_cairo_pdf_operators_sources = \ + cairo-pdf-operators.c \ + cairo-pdf-shading.c \ + cairo-tag-attributes.c \ + $(NULL) + cairo_png_sources = cairo-png.c cairo_ps_headers = cairo-ps.h cairo_ps_private = cairo-ps-surface-private.h cairo_ps_sources = cairo-ps-surface.c _cairo_deflate_stream_sources = cairo-deflate-stream.c cairo_pdf_headers = cairo-pdf.h -cairo_pdf_private = cairo-pdf-surface-private.h cairo-tag-stack-private.h cairo-tag-attributes-private.h -cairo_pdf_sources = cairo-pdf-surface.c cairo-pdf-interchange.c cairo-tag-stack.c cairo-tag-attributes.c +cairo_pdf_private = cairo-pdf-surface-private.h cairo-tag-stack-private.h +cairo_pdf_sources = cairo-pdf-surface.c cairo-pdf-interchange.c cairo-tag-stack.c cairo_svg_headers = cairo-svg.h cairo_svg_private = cairo-svg-surface-private.h cairo_svg_sources = cairo-svg-surface.c @@ -1632,6 +1660,9 @@ cairo_glesv2_headers = $(cairo_gl_headers) cairo_glesv2_private = $(cairo_gl_private) cairo_glesv2_sources = $(cairo_gl_sources) +cairo_glesv3_headers = $(cairo_gl_headers) +cairo_glesv3_private = $(cairo_gl_private) +cairo_glesv3_sources = $(cairo_gl_sources) cairo_directfb_headers = cairo-directfb.h cairo_directfb_sources = cairo-directfb-surface.c cairo_drm_headers = cairo-drm.h @@ -1705,9 +1736,9 @@ $(cairo_skia_headers) $(cairo_os2_headers) \ $(cairo_beos_headers) $(cairo_drm_headers) \ $(cairo_gallium_headers) $(cairo_gl_headers) \ - $(cairo_glesv2_headers) $(cairo_cogl_headers) \ - $(cairo_directfb_headers) $(cairo_vg_headers) \ - $(cairo_tee_headers) $(cairo_xml_headers) + $(cairo_glesv2_headers) $(cairo_glesv3_headers) \ + $(cairo_cogl_headers) $(cairo_directfb_headers) \ + $(cairo_vg_headers) $(cairo_tee_headers) $(cairo_xml_headers) all_cairo_headers = $(cairo_headers) $(cairo_xlib_headers) \ $(cairo_xlib_xrender_headers) $(cairo_xcb_headers) \ $(cairo_xlib_xcb_headers) $(cairo_xcb_shm_headers) \ @@ -1718,15 +1749,16 @@ $(cairo_beos_headers) $(cairo_drm_headers) \ $(cairo_gallium_headers) $(cairo_png_headers) \ $(cairo_gl_headers) $(cairo_glesv2_headers) \ - $(cairo_cogl_headers) $(cairo_directfb_headers) \ - $(cairo_vg_headers) $(cairo_egl_headers) $(cairo_glx_headers) \ - $(cairo_wgl_headers) $(cairo_script_headers) \ - $(cairo_ft_headers) $(cairo_fc_headers) $(cairo_ps_headers) \ - $(cairo_pdf_headers) $(cairo_svg_headers) \ - $(cairo_image_headers) $(cairo_mime_headers) \ - $(cairo_recording_headers) $(cairo_observer_headers) \ - $(cairo_tee_headers) $(cairo_xml_headers) \ - $(cairo_user_headers) $(cairo_gobject_headers) + $(cairo_glesv3_headers) $(cairo_cogl_headers) \ + $(cairo_directfb_headers) $(cairo_vg_headers) \ + $(cairo_egl_headers) $(cairo_glx_headers) $(cairo_wgl_headers) \ + $(cairo_script_headers) $(cairo_ft_headers) \ + $(cairo_fc_headers) $(cairo_ps_headers) $(cairo_pdf_headers) \ + $(cairo_svg_headers) $(cairo_image_headers) \ + $(cairo_mime_headers) $(cairo_recording_headers) \ + $(cairo_observer_headers) $(cairo_tee_headers) \ + $(cairo_xml_headers) $(cairo_user_headers) \ + $(cairo_gobject_headers) all_cairo_private = $(cairo_private) $(cairo_xlib_private) \ $(cairo_xlib_xrender_private) $(cairo_xcb_private) \ $(cairo_xlib_xcb_private) $(cairo_xcb_shm_private) \ @@ -1737,20 +1769,21 @@ $(cairo_beos_private) $(cairo_drm_private) \ $(cairo_gallium_private) $(cairo_png_private) \ $(cairo_gl_private) $(cairo_glesv2_private) \ - $(cairo_cogl_private) $(cairo_directfb_private) \ - $(cairo_vg_private) $(cairo_egl_private) $(cairo_glx_private) \ - $(cairo_wgl_private) $(cairo_script_private) \ - $(cairo_ft_private) $(cairo_fc_private) $(cairo_ps_private) \ - $(cairo_pdf_private) $(cairo_svg_private) \ - $(cairo_test_surfaces_private) $(cairo_test_surfaces_headers) \ - $(cairo_image_private) $(cairo_mime_private) \ - $(cairo_recording_private) $(cairo_observer_private) \ - $(cairo_tee_private) $(cairo_xml_private) \ - $(cairo_user_private) $(cairo_pthread_private) \ - $(cairo_pthread_headers) $(cairo_gobject_private) \ - $(cairo_trace_private) $(cairo_trace_headers) \ - $(cairo_interpreter_private) $(cairo_interpreter_headers) \ - $(cairo_symbol_lookup_private) $(cairo_symbol_lookup_headers) + $(cairo_glesv3_private) $(cairo_cogl_private) \ + $(cairo_directfb_private) $(cairo_vg_private) \ + $(cairo_egl_private) $(cairo_glx_private) $(cairo_wgl_private) \ + $(cairo_script_private) $(cairo_ft_private) \ + $(cairo_fc_private) $(cairo_ps_private) $(cairo_pdf_private) \ + $(cairo_svg_private) $(cairo_test_surfaces_private) \ + $(cairo_test_surfaces_headers) $(cairo_image_private) \ + $(cairo_mime_private) $(cairo_recording_private) \ + $(cairo_observer_private) $(cairo_tee_private) \ + $(cairo_xml_private) $(cairo_user_private) \ + $(cairo_pthread_private) $(cairo_pthread_headers) \ + $(cairo_gobject_private) $(cairo_trace_private) \ + $(cairo_trace_headers) $(cairo_interpreter_private) \ + $(cairo_interpreter_headers) $(cairo_symbol_lookup_private) \ + $(cairo_symbol_lookup_headers) all_cairo_cxx_sources = $(cairo_cxx_sources) $(cairo_xlib_cxx_sources) \ $(cairo_xlib_xrender_cxx_sources) $(cairo_xcb_cxx_sources) \ $(cairo_xlib_xcb_cxx_sources) $(cairo_xcb_shm_cxx_sources) \ @@ -1761,19 +1794,19 @@ $(cairo_os2_cxx_sources) $(cairo_beos_cxx_sources) \ $(cairo_drm_cxx_sources) $(cairo_gallium_cxx_sources) \ $(cairo_png_cxx_sources) $(cairo_gl_cxx_sources) \ - $(cairo_glesv2_cxx_sources) $(cairo_cogl_cxx_sources) \ - $(cairo_directfb_cxx_sources) $(cairo_vg_cxx_sources) \ - $(cairo_egl_cxx_sources) $(cairo_glx_cxx_sources) \ - $(cairo_wgl_cxx_sources) $(cairo_script_cxx_sources) \ - $(cairo_ft_cxx_sources) $(cairo_fc_cxx_sources) \ - $(cairo_ps_cxx_sources) $(cairo_pdf_cxx_sources) \ - $(cairo_svg_cxx_sources) $(cairo_test_surfaces_cxx_sources) \ - $(cairo_image_cxx_sources) $(cairo_mime_cxx_sources) \ - $(cairo_recording_cxx_sources) $(cairo_observer_cxx_sources) \ - $(cairo_tee_cxx_sources) $(cairo_xml_cxx_sources) \ - $(cairo_user_cxx_sources) $(cairo_pthread_cxx_sources) \ - $(cairo_gobject_cxx_sources) $(cairo_trace_cxx_sources) \ - $(cairo_interpreter_cxx_sources) \ + $(cairo_glesv2_cxx_sources) $(cairo_glesv3_cxx_sources) \ + $(cairo_cogl_cxx_sources) $(cairo_directfb_cxx_sources) \ + $(cairo_vg_cxx_sources) $(cairo_egl_cxx_sources) \ + $(cairo_glx_cxx_sources) $(cairo_wgl_cxx_sources) \ + $(cairo_script_cxx_sources) $(cairo_ft_cxx_sources) \ + $(cairo_fc_cxx_sources) $(cairo_ps_cxx_sources) \ + $(cairo_pdf_cxx_sources) $(cairo_svg_cxx_sources) \ + $(cairo_test_surfaces_cxx_sources) $(cairo_image_cxx_sources) \ + $(cairo_mime_cxx_sources) $(cairo_recording_cxx_sources) \ + $(cairo_observer_cxx_sources) $(cairo_tee_cxx_sources) \ + $(cairo_xml_cxx_sources) $(cairo_user_cxx_sources) \ + $(cairo_pthread_cxx_sources) $(cairo_gobject_cxx_sources) \ + $(cairo_trace_cxx_sources) $(cairo_interpreter_cxx_sources) \ $(cairo_symbol_lookup_cxx_sources) all_cairo_sources = $(cairo_sources) $(cairo_xlib_sources) \ $(cairo_xlib_xrender_sources) $(cairo_xcb_sources) \ @@ -1785,18 +1818,18 @@ $(cairo_beos_sources) $(cairo_drm_sources) \ $(cairo_gallium_sources) $(cairo_png_sources) \ $(cairo_gl_sources) $(cairo_glesv2_sources) \ - $(cairo_cogl_sources) $(cairo_directfb_sources) \ - $(cairo_vg_sources) $(cairo_egl_sources) $(cairo_glx_sources) \ - $(cairo_wgl_sources) $(cairo_script_sources) \ - $(cairo_ft_sources) $(cairo_fc_sources) $(cairo_ps_sources) \ - $(cairo_pdf_sources) $(cairo_svg_sources) \ - $(cairo_test_surfaces_sources) $(cairo_image_sources) \ - $(cairo_mime_sources) $(cairo_recording_sources) \ - $(cairo_observer_sources) $(cairo_tee_sources) \ - $(cairo_xml_sources) $(cairo_user_sources) \ - $(cairo_pthread_sources) $(cairo_gobject_sources) \ - $(cairo_trace_sources) $(cairo_interpreter_sources) \ - $(cairo_symbol_lookup_sources) + $(cairo_glesv3_sources) $(cairo_cogl_sources) \ + $(cairo_directfb_sources) $(cairo_vg_sources) \ + $(cairo_egl_sources) $(cairo_glx_sources) $(cairo_wgl_sources) \ + $(cairo_script_sources) $(cairo_ft_sources) \ + $(cairo_fc_sources) $(cairo_ps_sources) $(cairo_pdf_sources) \ + $(cairo_svg_sources) $(cairo_test_surfaces_sources) \ + $(cairo_image_sources) $(cairo_mime_sources) \ + $(cairo_recording_sources) $(cairo_observer_sources) \ + $(cairo_tee_sources) $(cairo_xml_sources) \ + $(cairo_user_sources) $(cairo_pthread_sources) \ + $(cairo_gobject_sources) $(cairo_trace_sources) \ + $(cairo_interpreter_sources) $(cairo_symbol_lookup_sources) enabled_cairo_headers = $(cairo_headers) $(am__append_1) \ $(am__append_6) $(am__append_11) $(am__append_16) \ $(am__append_21) $(am__append_26) $(am__append_31) \ @@ -1808,10 +1841,10 @@ $(am__append_111) $(am__append_116) $(am__append_121) \ $(am__append_126) $(am__append_131) $(am__append_136) \ $(am__append_141) $(am__append_146) $(am__append_151) \ - $(cairo_image_headers) $(cairo_mime_headers) \ + $(am__append_156) $(cairo_image_headers) $(cairo_mime_headers) \ $(cairo_recording_headers) $(cairo_observer_headers) \ - $(am__append_159) $(am__append_164) $(cairo_user_headers) \ - $(am__append_172) + $(am__append_164) $(am__append_169) $(cairo_user_headers) \ + $(am__append_177) enabled_cairo_private = $(cairo_private) $(am__append_2) \ $(am__append_7) $(am__append_12) $(am__append_17) \ $(am__append_22) $(am__append_27) $(am__append_32) \ @@ -1823,11 +1856,11 @@ $(am__append_112) $(am__append_117) $(am__append_122) \ $(am__append_127) $(am__append_132) $(am__append_137) \ $(am__append_142) $(am__append_147) $(am__append_152) \ - $(am__append_156) $(cairo_image_private) $(cairo_mime_private) \ - $(cairo_recording_private) $(cairo_observer_private) \ - $(am__append_160) $(am__append_165) $(cairo_user_private) \ - $(am__append_169) $(am__append_173) $(am__append_177) \ - $(am__append_180) $(am__append_183) + $(am__append_157) $(am__append_161) $(cairo_image_private) \ + $(cairo_mime_private) $(cairo_recording_private) \ + $(cairo_observer_private) $(am__append_165) $(am__append_170) \ + $(cairo_user_private) $(am__append_174) $(am__append_178) \ + $(am__append_182) $(am__append_185) $(am__append_188) enabled_cairo_cxx_sources = $(cairo_cxx_sources) $(am__append_3) \ $(am__append_8) $(am__append_13) $(am__append_18) \ $(am__append_23) $(am__append_28) $(am__append_33) \ @@ -1839,12 +1872,12 @@ $(am__append_113) $(am__append_118) $(am__append_123) \ $(am__append_128) $(am__append_133) $(am__append_138) \ $(am__append_143) $(am__append_148) $(am__append_153) \ - $(am__append_157) $(cairo_image_cxx_sources) \ + $(am__append_158) $(am__append_162) $(cairo_image_cxx_sources) \ $(cairo_mime_cxx_sources) $(cairo_recording_cxx_sources) \ - $(cairo_observer_cxx_sources) $(am__append_161) \ - $(am__append_166) $(cairo_user_cxx_sources) $(am__append_170) \ - $(am__append_174) $(am__append_178) $(am__append_181) \ - $(am__append_184) + $(cairo_observer_cxx_sources) $(am__append_166) \ + $(am__append_171) $(cairo_user_cxx_sources) $(am__append_175) \ + $(am__append_179) $(am__append_183) $(am__append_186) \ + $(am__append_189) enabled_cairo_sources = $(cairo_sources) $(am__append_4) \ $(am__append_9) $(am__append_14) $(am__append_19) \ $(am__append_24) $(am__append_29) $(am__append_34) \ @@ -1856,21 +1889,21 @@ $(am__append_114) $(am__append_119) $(am__append_124) \ $(am__append_129) $(am__append_134) $(am__append_139) \ $(am__append_144) $(am__append_149) $(am__append_154) \ - $(am__append_158) $(cairo_image_sources) $(cairo_mime_sources) \ - $(cairo_recording_sources) $(cairo_observer_sources) \ - $(am__append_162) $(am__append_167) $(cairo_user_sources) \ - $(am__append_171) $(am__append_175) $(am__append_179) \ - $(am__append_182) $(am__append_185) + $(am__append_159) $(am__append_163) $(cairo_image_sources) \ + $(cairo_mime_sources) $(cairo_recording_sources) \ + $(cairo_observer_sources) $(am__append_167) $(am__append_172) \ + $(cairo_user_sources) $(am__append_176) $(am__append_180) \ + $(am__append_184) $(am__append_187) $(am__append_190) all_cairo_pkgconf = cairo.pc cairo-xlib.pc cairo-xlib-xrender.pc \ cairo-xcb.pc cairo-xlib-xcb.pc cairo-xcb-shm.pc cairo-qt.pc \ cairo-quartz.pc cairo-quartz-font.pc cairo-quartz-image.pc \ cairo-win32.pc cairo-win32-font.pc cairo-skia.pc cairo-os2.pc \ cairo-beos.pc cairo-drm.pc cairo-gallium.pc cairo-png.pc \ - cairo-gl.pc cairo-glesv2.pc cairo-cogl.pc cairo-directfb.pc \ - cairo-vg.pc cairo-egl.pc cairo-glx.pc cairo-wgl.pc \ - cairo-script.pc cairo-ft.pc cairo-fc.pc cairo-ps.pc \ - cairo-pdf.pc cairo-svg.pc cairo-tee.pc cairo-xml.pc \ - cairo-gobject.pc + cairo-gl.pc cairo-glesv2.pc cairo-glesv3.pc cairo-cogl.pc \ + cairo-directfb.pc cairo-vg.pc cairo-egl.pc cairo-glx.pc \ + cairo-wgl.pc cairo-script.pc cairo-ft.pc cairo-fc.pc \ + cairo-ps.pc cairo-pdf.pc cairo-svg.pc cairo-tee.pc \ + cairo-xml.pc cairo-gobject.pc enabled_cairo_pkgconf = cairo.pc $(am__append_5) $(am__append_10) \ $(am__append_15) $(am__append_20) $(am__append_25) \ $(am__append_30) $(am__append_35) $(am__append_40) \ @@ -1881,8 +1914,8 @@ $(am__append_105) $(am__append_110) $(am__append_115) \ $(am__append_120) $(am__append_125) $(am__append_130) \ $(am__append_135) $(am__append_140) $(am__append_145) \ - $(am__append_150) $(am__append_155) $(am__append_163) \ - $(am__append_168) $(am__append_176) + $(am__append_150) $(am__append_155) $(am__append_160) \ + $(am__append_168) $(am__append_173) $(am__append_181) #MAINTAINERCLEANFILES += $(srcdir)/Makefile.win32.features AM_CPPFLAGS = -I$(srcdir) $(CAIRO_CFLAGS) AM_LDFLAGS = $(CAIRO_LDFLAGS) @@ -2019,6 +2052,8 @@ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ cairo-glesv2.pc: $(top_builddir)/config.status $(srcdir)/cairo-features.pc.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ +cairo-glesv3.pc: $(top_builddir)/config.status $(srcdir)/cairo-features.pc.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ cairo-cogl.pc: $(top_builddir)/config.status $(srcdir)/cairo-features.pc.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ cairo-directfb.pc: $(top_builddir)/config.status $(srcdir)/cairo-features.pc.in diff -Nru cairo-1.15.8/src/Makefile.sources cairo-1.15.10/src/Makefile.sources --- cairo-1.15.8/src/Makefile.sources 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/Makefile.sources 2017-12-07 02:14:36.000000000 +0000 @@ -264,8 +264,16 @@ cairo_glx_sources = cairo_wgl_sources = -_cairo_pdf_operators_private = cairo-pdf-operators-private.h cairo-pdf-shading-private.h -_cairo_pdf_operators_sources = cairo-pdf-operators.c cairo-pdf-shading.c +_cairo_pdf_operators_private = \ + cairo-pdf-operators-private.h \ + cairo-pdf-shading-private.h \ + cairo-tag-attributes-private.h \ + $(NULL) +_cairo_pdf_operators_sources = \ + cairo-pdf-operators.c \ + cairo-pdf-shading.c \ + cairo-tag-attributes.c \ + $(NULL) cairo_private += $(_cairo_pdf_operators_private) cairo_sources += $(_cairo_pdf_operators_sources) @@ -279,8 +287,8 @@ cairo_sources += $(_cairo_deflate_stream_sources) cairo_pdf_headers = cairo-pdf.h -cairo_pdf_private = cairo-pdf-surface-private.h cairo-tag-stack-private.h cairo-tag-attributes-private.h -cairo_pdf_sources = cairo-pdf-surface.c cairo-pdf-interchange.c cairo-tag-stack.c cairo-tag-attributes.c +cairo_pdf_private = cairo-pdf-surface-private.h cairo-tag-stack-private.h +cairo_pdf_sources = cairo-pdf-surface.c cairo-pdf-interchange.c cairo-tag-stack.c cairo_svg_headers = cairo-svg.h cairo_svg_private = cairo-svg-surface-private.h @@ -407,6 +415,10 @@ cairo_glesv2_private = $(cairo_gl_private) cairo_glesv2_sources = $(cairo_gl_sources) +cairo_glesv3_headers = $(cairo_gl_headers) +cairo_glesv3_private = $(cairo_gl_private) +cairo_glesv3_sources = $(cairo_gl_sources) + cairo_egl_sources += cairo-egl-context.c cairo_glx_sources += cairo-glx-context.c cairo_wgl_sources += cairo-wgl-context.c diff -Nru cairo-1.15.8/src/Makefile.win32.features cairo-1.15.10/src/Makefile.win32.features --- cairo-1.15.8/src/Makefile.win32.features 2017-08-22 02:50:04.000000000 +0000 +++ cairo-1.15.10/src/Makefile.win32.features 2017-12-07 02:14:36.000000000 +0000 @@ -325,6 +325,22 @@ enabled_cairo_pkgconf += cairo-glesv2.pc endif +unsupported_cairo_headers += $(cairo_glesv3_headers) +all_cairo_headers += $(cairo_glesv3_headers) +all_cairo_private += $(cairo_glesv3_private) +all_cairo_cxx_sources += $(cairo_glesv3_cxx_sources) +all_cairo_sources += $(cairo_glesv3_sources) +ifeq ($(CAIRO_HAS_GLESV3_SURFACE),1) +enabled_cairo_headers += $(cairo_glesv3_headers) +enabled_cairo_private += $(cairo_glesv3_private) +enabled_cairo_cxx_sources += $(cairo_glesv3_cxx_sources) +enabled_cairo_sources += $(cairo_glesv3_sources) +endif +all_cairo_pkgconf += cairo-glesv3.pc +ifeq ($(CAIRO_HAS_GLESV3_SURFACE),1) +enabled_cairo_pkgconf += cairo-glesv3.pc +endif + unsupported_cairo_headers += $(cairo_cogl_headers) all_cairo_headers += $(cairo_cogl_headers) all_cairo_private += $(cairo_cogl_private) diff -Nru cairo-1.15.8/src/test-null-compositor-surface.c cairo-1.15.10/src/test-null-compositor-surface.c --- cairo-1.15.8/src/test-null-compositor-surface.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/test-null-compositor-surface.c 2017-12-07 02:14:36.000000000 +0000 @@ -404,9 +404,10 @@ static const cairo_compositor_t * no_traps_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_traps_compositor_t compositor; - if (compositor.base.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { _cairo_traps_compositor_init (&compositor, no_fallback_compositor_get ()); @@ -426,6 +427,8 @@ compositor.composite_traps = composite_traps; compositor.check_composite_glyphs = check_composite_glyphs; compositor.composite_glyphs = composite_glyphs; + + _cairo_atomic_init_once_leave(&once); } return &compositor.base; @@ -434,9 +437,10 @@ static const cairo_compositor_t * no_spans_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_spans_compositor_t compositor; - if (compositor.base.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { _cairo_spans_compositor_init (&compositor, no_traps_compositor_get()); @@ -448,6 +452,8 @@ //compositor.check_span_renderer = check_span_renderer; compositor.renderer_init = span_renderer_init; compositor.renderer_fini = span_renderer_fini; + + _cairo_atomic_init_once_leave(&once); } return &compositor.base; diff -Nru cairo-1.15.8/src/win32/cairo-win32-display-surface.c cairo-1.15.10/src/win32/cairo-win32-display-surface.c --- cairo-1.15.8/src/win32/cairo-win32-display-surface.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/win32/cairo-win32-display-surface.c 2017-12-07 22:13:32.000000000 +0000 @@ -936,7 +936,7 @@ * * Return value: the newly created surface, NULL on failure * - * Since: 1.14.3 + * Since: 1.14 **/ cairo_surface_t * cairo_win32_surface_create_with_format (HDC hdc, cairo_format_t format) diff -Nru cairo-1.15.8/src/win32/cairo-win32-gdi-compositor.c cairo-1.15.10/src/win32/cairo-win32-gdi-compositor.c --- cairo-1.15.8/src/win32/cairo-win32-gdi-compositor.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/src/win32/cairo-win32-gdi-compositor.c 2017-12-07 02:14:36.000000000 +0000 @@ -634,9 +634,10 @@ const cairo_compositor_t * _cairo_win32_gdi_compositor_get (void) { + static cairo_atomic_once_t once = CAIRO_ATOMIC_ONCE_INIT; static cairo_compositor_t compositor; - if (compositor.delegate == NULL) { + if (_cairo_atomic_init_once_enter(&once)) { compositor.delegate = &_cairo_fallback_compositor; compositor.paint = _cairo_win32_gdi_compositor_paint; @@ -644,6 +645,8 @@ compositor.fill = _cairo_win32_gdi_compositor_fill; compositor.stroke = _cairo_win32_gdi_compositor_stroke; compositor.glyphs = _cairo_win32_gdi_compositor_glyphs; + + _cairo_atomic_init_once_leave(&once); } return &compositor; diff -Nru cairo-1.15.8/test/any2ppm.c cairo-1.15.10/test/any2ppm.c --- cairo-1.15.8/test/any2ppm.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/test/any2ppm.c 2017-12-07 02:14:36.000000000 +0000 @@ -244,6 +244,7 @@ return NULL; } +#if CAIRO_HAS_INTERPRETER static cairo_surface_t * _create_image (void *closure, cairo_content_t content, @@ -268,7 +269,6 @@ return cairo_surface_reference (*out); } -#if CAIRO_HAS_INTERPRETER static const char * _cairo_script_render_page (const char *filename, cairo_surface_t **surface_out) diff -Nru cairo-1.15.8/test/cairo-test.c cairo-1.15.10/test/cairo-test.c --- cairo-1.15.8/test/cairo-test.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/test/cairo-test.c 2017-12-07 02:14:36.000000000 +0000 @@ -1668,6 +1668,7 @@ { cairo_surface_t *image; cairo_status_t status; + char *unique_id; image = cairo_image_surface_create_from_png (filename); status = cairo_surface_status (image); @@ -1683,6 +1684,10 @@ free (srcdir_filename); } } + unique_id = strdup(filename); + cairo_surface_set_mime_data (image, CAIRO_MIME_TYPE_UNIQUE_ID, + (unsigned char *)unique_id, strlen(unique_id), + free, unique_id); return image; } diff -Nru cairo-1.15.8/test/cairo-test-constructors.c cairo-1.15.10/test/cairo-test-constructors.c --- cairo-1.15.8/test/cairo-test-constructors.c 2017-08-29 17:05:45.000000000 +0000 +++ cairo-1.15.10/test/cairo-test-constructors.c 2017-12-11 21:03:31.000000000 +0000 @@ -563,13 +563,22 @@ extern void _register_ft_text_vertical_layout_type1 (void); extern void _register_ft_text_vertical_layout_type3 (void); extern void _register_ft_text_antialias_none (void); +extern void _register_pdf_features (void); +extern void _register_pdf_mime_data (void); +extern void _register_pdf_surface_source (void); +extern void _register_pdf_tagged_text (void); extern void _register_ps_eps (void); extern void _register_ps_features (void); extern void _register_ps_surface_source (void); extern void _register_svg_surface (void); extern void _register_svg_clip (void); extern void _register_svg_surface_source (void); +extern void _register_xcb_surface_source (void); +extern void _register_xlib_surface (void); +extern void _register_xlib_surface_source (void); +extern void _register_get_xrender_format (void); extern void _register_multi_page (void); +extern void _register_mime_unique_id (void); extern void _register_fallback_resolution (void); void @@ -1134,12 +1143,21 @@ _register_ft_text_vertical_layout_type1 (); _register_ft_text_vertical_layout_type3 (); _register_ft_text_antialias_none (); + _register_pdf_features (); + _register_pdf_mime_data (); + _register_pdf_surface_source (); + _register_pdf_tagged_text (); _register_ps_eps (); _register_ps_features (); _register_ps_surface_source (); _register_svg_surface (); _register_svg_clip (); _register_svg_surface_source (); + _register_xcb_surface_source (); + _register_xlib_surface (); + _register_xlib_surface_source (); + _register_get_xrender_format (); _register_multi_page (); + _register_mime_unique_id (); _register_fallback_resolution (); } diff -Nru cairo-1.15.8/test/Makefile.in cairo-1.15.10/test/Makefile.in --- cairo-1.15.8/test/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/test/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -125,10 +125,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -323,7 +322,8 @@ ps-surface-source.c svg-surface.c svg-clip.c \ svg-surface-source.c xcb-surface-source.c xlib-surface.c \ xlib-surface-source.c get-xrender-format.c multi-page.c \ - fallback-resolution.c cairo-test-constructors.c + mime-unique-id.c fallback-resolution.c \ + cairo-test-constructors.c am__objects_1 = cairo_test_suite-buffer-diff.$(OBJEXT) \ cairo_test_suite-cairo-test.$(OBJEXT) \ cairo_test_suite-cairo-test-runner.$(OBJEXT) @@ -370,7 +370,8 @@ am__objects_23 = cairo_test_suite-get-xrender-format.$(OBJEXT) @CAIRO_HAS_XLIB_XRENDER_SURFACE_TRUE@am__objects_24 = \ @CAIRO_HAS_XLIB_XRENDER_SURFACE_TRUE@ $(am__objects_23) -am__objects_25 = cairo_test_suite-multi-page.$(OBJEXT) +am__objects_25 = cairo_test_suite-multi-page.$(OBJEXT) \ + cairo_test_suite-mime-unique-id.$(OBJEXT) @CAIRO_HAS_MULTI_PAGE_SURFACES_TRUE@am__objects_26 = \ @CAIRO_HAS_MULTI_PAGE_SURFACES_TRUE@ $(am__objects_25) am__objects_27 = cairo_test_suite-fallback-resolution.$(OBJEXT) @@ -1190,6 +1191,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -1288,6 +1294,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ @@ -1555,7 +1563,7 @@ xlib-surface-source.c xlib_xrender_surface_test_sources = get-xrender-format.c -multi_page_surface_test_sources = multi-page.c +multi_page_surface_test_sources = multi-page.c mime-unique-id.c fallback_resolution_test_sources = fallback-resolution.c cairo_test_suite_headers = \ buffer-diff.h \ @@ -2050,6 +2058,7 @@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-mesh-pattern.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-mime-data.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-mime-surface-api.Po@am__quote@ +@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-mime-unique-id.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-miter-precision.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-move-to-show-surface.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cairo_test_suite-multi-page.Po@am__quote@ @@ -8204,6 +8213,20 @@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-multi-page.obj `if test -f 'multi-page.c'; then $(CYGPATH_W) 'multi-page.c'; else $(CYGPATH_W) '$(srcdir)/multi-page.c'; fi` +cairo_test_suite-mime-unique-id.o: mime-unique-id.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-mime-unique-id.o -MD -MP -MF $(DEPDIR)/cairo_test_suite-mime-unique-id.Tpo -c -o cairo_test_suite-mime-unique-id.o `test -f 'mime-unique-id.c' || echo '$(srcdir)/'`mime-unique-id.c +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-mime-unique-id.Tpo $(DEPDIR)/cairo_test_suite-mime-unique-id.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='mime-unique-id.c' object='cairo_test_suite-mime-unique-id.o' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-mime-unique-id.o `test -f 'mime-unique-id.c' || echo '$(srcdir)/'`mime-unique-id.c + +cairo_test_suite-mime-unique-id.obj: mime-unique-id.c +@am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-mime-unique-id.obj -MD -MP -MF $(DEPDIR)/cairo_test_suite-mime-unique-id.Tpo -c -o cairo_test_suite-mime-unique-id.obj `if test -f 'mime-unique-id.c'; then $(CYGPATH_W) 'mime-unique-id.c'; else $(CYGPATH_W) '$(srcdir)/mime-unique-id.c'; fi` +@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-mime-unique-id.Tpo $(DEPDIR)/cairo_test_suite-mime-unique-id.Po +@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='mime-unique-id.c' object='cairo_test_suite-mime-unique-id.obj' libtool=no @AMDEPBACKSLASH@ +@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ +@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -c -o cairo_test_suite-mime-unique-id.obj `if test -f 'mime-unique-id.c'; then $(CYGPATH_W) 'mime-unique-id.c'; else $(CYGPATH_W) '$(srcdir)/mime-unique-id.c'; fi` + cairo_test_suite-fallback-resolution.o: fallback-resolution.c @am__fastdepCC_TRUE@ $(AM_V_CC)$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(cairo_test_suite_CFLAGS) $(CFLAGS) -MT cairo_test_suite-fallback-resolution.o -MD -MP -MF $(DEPDIR)/cairo_test_suite-fallback-resolution.Tpo -c -o cairo_test_suite-fallback-resolution.o `test -f 'fallback-resolution.c' || echo '$(srcdir)/'`fallback-resolution.c @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/cairo_test_suite-fallback-resolution.Tpo $(DEPDIR)/cairo_test_suite-fallback-resolution.Po diff -Nru cairo-1.15.8/test/Makefile.sources cairo-1.15.10/test/Makefile.sources --- cairo-1.15.8/test/Makefile.sources 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/test/Makefile.sources 2017-12-07 02:14:36.000000000 +0000 @@ -440,7 +440,7 @@ xlib_xrender_surface_test_sources = get-xrender-format.c -multi_page_surface_test_sources = multi-page.c +multi_page_surface_test_sources = multi-page.c mime-unique-id.c fallback_resolution_test_sources = fallback-resolution.c diff -Nru cairo-1.15.8/test/mime-data.c cairo-1.15.10/test/mime-data.c --- cairo-1.15.8/test/mime-data.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/test/mime-data.c 2017-12-07 02:14:36.000000000 +0000 @@ -207,6 +207,56 @@ } static cairo_test_status_t +paint_ccitt_file (cairo_t *cr, int x, int y) +{ + const cairo_test_context_t *ctx = cairo_test_get_context (cr); + cairo_surface_t *image; + unsigned char *mime_data; + unsigned int mime_length; + cairo_status_t status; + const char *ccitt_image_filename = "ccitt.g3"; + const char *ccitt_image_params = "Columns=200 Rows=50 K=-1"; + + /* Deliberately use a non-matching MIME images, so that we can identify + * when the MIME representation is used in preference to the plain image + * surface. + */ + + status = read_file (ctx, ccitt_image_filename, &mime_data, &mime_length); + if (status) + return cairo_test_status_from_status (ctx, status); + + image = cairo_image_surface_create (CAIRO_FORMAT_RGB24, 200, 50); + + /* Set the CCITT image data */ + status = cairo_surface_set_mime_data (image, CAIRO_MIME_TYPE_CCITT_FAX, + mime_data, mime_length, + free, mime_data); + if (status) { + cairo_surface_destroy (image); + free (mime_data); + return cairo_test_status_from_status (ctx, status); + } + + /* Set the CCITT image paramaters */ + status = cairo_surface_set_mime_data (image, CAIRO_MIME_TYPE_CCITT_FAX_PARAMS, + (unsigned char *)ccitt_image_params, + strlen (ccitt_image_params), + NULL, NULL); + if (status) { + cairo_surface_destroy (image); + return cairo_test_status_from_status (ctx, status); + } + + cairo_set_source_surface (cr, image, x, y); + cairo_surface_destroy (image); + + cairo_paint (cr); + + return CAIRO_TEST_SUCCESS; +} + +static cairo_test_status_t draw (cairo_t *cr, int width, int height) { const char jpg_filename[] = "jpeg.jpg"; @@ -230,6 +280,10 @@ if (status) return status; + status = paint_ccitt_file (cr, 0, 250); + if (status) + return status; + return CAIRO_TEST_SUCCESS; } @@ -237,5 +291,5 @@ "Check that the mime-data embedding works", "jpeg, api", /* keywords */ NULL, /* requirements */ - 200, 250, + 200, 300, NULL, draw) diff -Nru cairo-1.15.8/test/mime-unique-id.c cairo-1.15.10/test/mime-unique-id.c --- cairo-1.15.8/test/mime-unique-id.c 1970-01-01 00:00:00.000000000 +0000 +++ cairo-1.15.10/test/mime-unique-id.c 2017-12-07 02:14:36.000000000 +0000 @@ -0,0 +1,511 @@ +/* + * Copyright © 2017 Adrian Johnson + * + * Permission is hereby granted, free of charge, to any person + * obtaining a copy of this software and associated documentation + * files (the "Software"), to deal in the Software without + * restriction, including without limitation the rights to use, copy, + * modify, merge, publish, distribute, sublicense, and/or sell copies + * of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be + * included in all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, + * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND + * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS + * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN + * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + * + * Author: Adrian Johnson + */ + + +/* Check that source surfaces with same CAIRO_MIME_TYPE_UNIQUE_ID are + * embedded only once in PDF/PS. + * + * To exercise all the surface embedding code in PS/PDF, four types of + * source surfaces are painted on each page, each with its own UNIQUE_ID: + * - an image surface + * - a recording surface with a jpeg mime attached + * - a bounded recording surface + * - an unbounded recording surface. + * + * Four pages are generated. Each source is clipped starting with the + * smallest area on the first page increasing to the unclipped size on + * the last page. This is to ensure the output does not embed the + * source clipped to a smaller size than used on subsequent pages. + * + * The test verifies the use of UNIQUE_ID by comparing the file size + * with the expected size. + */ + +#include "cairo-test.h" + +#include +#include + +#include + +#if CAIRO_HAS_PS_SURFACE +#include +#endif + +#if CAIRO_HAS_PDF_SURFACE +#include +#endif + +#define NUM_PAGES 4 + +#define WIDTH 275 +#define HEIGHT 275 + +#define BASENAME "mime-unique-id" + + +/* Expected file size to check that surfaces are embedded only once. + * SIZE_TOLERANCE should be large enough to allow some variation in + * file size due to changes to the PS/PDF surfaces while being small + * enough to catch any attempt to embed the surface more than + * once. The compressed size of each surface embedded in PDF is: + * - image: 108,774 + * - jpeg: 11,400 + * - recording: 17,518 + * + * If the size check fails, manually check the output and if the + * surfaces are still embedded only once, update the expected sizes. + */ +#define PS2_EXPECTED_SIZE 417510 +#define PS3_EXPECTED_SIZE 381554 +#define PDF_EXPECTED_SIZE 347182 +#define SIZE_TOLERANCE 5000 + +static const char *png_filename = "romedalen.png"; +static const char *jpeg_filename = "romedalen.jpg"; + +static cairo_test_status_t +create_image_surface (cairo_test_context_t *ctx, cairo_surface_t **surface) +{ + cairo_status_t status; + const char *unique_id = "image"; + + *surface = cairo_test_create_surface_from_png (ctx, png_filename); + status = cairo_surface_set_mime_data (*surface, CAIRO_MIME_TYPE_UNIQUE_ID, + (unsigned char *)unique_id, + strlen (unique_id), + NULL, NULL); + if (status) { + cairo_surface_destroy (*surface); + return cairo_test_status_from_status (ctx, status); + } + + return CAIRO_TEST_SUCCESS; +} + +static cairo_test_status_t +create_recording_surface_with_mime_jpg (cairo_test_context_t *ctx, cairo_surface_t **surface) +{ + cairo_status_t status; + FILE *f; + unsigned char *data; + long len; + const char *unique_id = "jpeg"; + cairo_rectangle_t extents = { 0, 0, 1, 1 }; + + *surface = cairo_recording_surface_create (CAIRO_CONTENT_COLOR_ALPHA, &extents); + f = fopen (jpeg_filename, "rb"); + if (f == NULL) { + cairo_test_log (ctx, "Unable to open file %s\n", jpeg_filename); + return CAIRO_TEST_FAILURE; + } + + fseek (f, 0, SEEK_END); + len = ftell(f); + fseek (f, 0, SEEK_SET); + data = malloc (len); + if (fread(data, len, 1, f) != 1) { + cairo_test_log (ctx, "Unable to read file %s\n", jpeg_filename); + return CAIRO_TEST_FAILURE; + } + + fclose(f); + status = cairo_surface_set_mime_data (*surface, + CAIRO_MIME_TYPE_JPEG, + data, len, + free, data); + if (status) { + cairo_surface_destroy (*surface); + return cairo_test_status_from_status (ctx, status); + } + + status = cairo_surface_set_mime_data (*surface, CAIRO_MIME_TYPE_UNIQUE_ID, + (unsigned char *)unique_id, + strlen (unique_id), + NULL, NULL); + if (status) { + cairo_surface_destroy (*surface); + return cairo_test_status_from_status (ctx, status); + } + + return CAIRO_TEST_SUCCESS; +} + +static void +draw_tile (cairo_t *cr) +{ + cairo_move_to (cr, 10 + 5, 10); + cairo_arc (cr, 10, 10, 5, 0, 2*M_PI); + cairo_close_path (cr); + cairo_set_source_rgb (cr, 1, 0, 0); + cairo_fill (cr); + + cairo_move_to (cr, 30, 10-10*0.43); + cairo_line_to (cr, 25, 10+10*0.43); + cairo_line_to (cr, 35, 10+10*0.43); + cairo_close_path (cr); + cairo_set_source_rgb (cr, 0, 1, 0); + cairo_fill (cr); + + cairo_rectangle (cr, 5, 25, 10, 10); + cairo_set_source_rgb (cr, 0, 0, 0); + cairo_fill (cr); + + cairo_save (cr); + cairo_translate (cr, 30, 30); + cairo_rotate (cr, M_PI/4.0); + cairo_rectangle (cr, -5, -5, 10, 10); + cairo_set_source_rgb (cr, 1, 0, 1); + cairo_fill (cr); + cairo_restore (cr); +} + +#define RECORDING_SIZE 800 +#define TILE_SIZE 40 + +static cairo_test_status_t +create_recording_surface (cairo_test_context_t *ctx, cairo_surface_t **surface, cairo_bool_t bounded) +{ + cairo_status_t status; + int x, y; + cairo_t *cr; + cairo_matrix_t ctm; + int start, size; + const char *bounded_id = "recording bounded"; + const char *unbounded_id = "recording unbounded"; + cairo_rectangle_t extents = { 0, 0, RECORDING_SIZE, RECORDING_SIZE }; + + if (bounded) { + *surface = cairo_recording_surface_create (CAIRO_CONTENT_COLOR_ALPHA, &extents); + start = 0; + size = RECORDING_SIZE; + } else { + *surface = cairo_recording_surface_create (CAIRO_CONTENT_COLOR_ALPHA, NULL); + start = RECORDING_SIZE / 2; + size = RECORDING_SIZE * 2; + } + + /* Draw each tile instead of creating a cairo pattern to make size + * of the emitted recording as large as possible. + */ + cr = cairo_create (*surface); + cairo_set_source_rgb (cr, 1, 1, 0); + cairo_paint (cr); + cairo_get_matrix (cr, &ctm); + for (y = start; y < size; y += TILE_SIZE) { + for (x = start; x < size; x += TILE_SIZE) { + draw_tile (cr); + cairo_translate (cr, TILE_SIZE, 0); + } + cairo_matrix_translate (&ctm, 0, TILE_SIZE); + cairo_set_matrix (cr, &ctm); + } + cairo_destroy (cr); + + status = cairo_surface_set_mime_data (*surface, CAIRO_MIME_TYPE_UNIQUE_ID, + (unsigned char *)(bounded ? bounded_id : unbounded_id), + strlen (bounded ? bounded_id : unbounded_id), + NULL, NULL); + if (status) { + cairo_surface_destroy (*surface); + return cairo_test_status_from_status (ctx, status); + } + + return CAIRO_TEST_SUCCESS; +} + +/* Draw @source scaled to fit @rect and clipped to a rectangle + * @clip_margin units smaller on each side. @rect will be stroked + * with a solid line and the clip rect stroked with a dashed line. + */ +static void +draw_surface (cairo_t *cr, cairo_surface_t *source, cairo_rectangle_int_t *rect, int clip_margin) +{ + cairo_surface_type_t type; + int width, height; + cairo_rectangle_t extents; + const double dashes[2] = { 2, 2 }; + + type = cairo_surface_get_type (source); + if (type == CAIRO_SURFACE_TYPE_IMAGE) { + width = cairo_image_surface_get_width (source); + height = cairo_image_surface_get_height (source); + } else { + if (cairo_recording_surface_get_extents (source, &extents)) { + width = extents.width; + height = extents.height; + } else { + width = RECORDING_SIZE; + height = RECORDING_SIZE; + } + } + + cairo_save (cr); + cairo_rectangle (cr, rect->x, rect->y, rect->width, rect->height); + cairo_stroke (cr); + cairo_rectangle (cr, + rect->x + clip_margin, + rect->y + clip_margin, + rect->width - clip_margin*2, + rect->height - clip_margin*2); + cairo_set_dash (cr, dashes, 2, 0); + cairo_stroke_preserve (cr); + cairo_clip (cr); + + cairo_translate (cr, rect->x, rect->y); + cairo_scale (cr, (double)rect->width/width, (double)rect->height/height); + cairo_set_source_surface (cr, source, 0, 0); + cairo_paint (cr); + + cairo_restore (cr); +} + +static cairo_test_status_t +draw_pages (cairo_test_context_t *ctx, cairo_surface_t *surface) +{ + cairo_t *cr; + int i; + cairo_rectangle_int_t img_rect; + cairo_rectangle_int_t jpg_rect; + cairo_rectangle_int_t bounded_rect; + cairo_rectangle_int_t unbounded_rect; + int clip_margin; + cairo_surface_t *source; + cairo_test_status_t status; + + cr = cairo_create (surface); + + /* target area to fill with the image source */ + img_rect.x = 25; + img_rect.y = 25; + img_rect.width = 100; + img_rect.height = 100; + + /* target area to fill with the recording with jpeg mime source */ + jpg_rect.x = 150; + jpg_rect.y = 25; + jpg_rect.width = 100; + jpg_rect.height = 100; + + /* target area to fill with the bounded recording source */ + bounded_rect.x = 25; + bounded_rect.y = 150; + bounded_rect.width = 100; + bounded_rect.height = 100; + + /* target area to fill with the unbounded recording source */ + unbounded_rect.x = 150; + unbounded_rect.y = 150; + unbounded_rect.width = 100; + unbounded_rect.height = 100; + + /* Draw the image and recording surface on each page. The sources + * are clipped starting with a small clip area on the first page + * and increasing to the source size on last page to ensure the + * embedded source is not clipped to the area used on the first + * page. + * + * The sources are created each time they are used to ensure + * CAIRO_MIME_TYPE_UNIQUE_ID is tested. + */ + for (i = 0; i < NUM_PAGES; i++) { + clip_margin = (NUM_PAGES - i - 1) * 5; + + status = create_image_surface (ctx, &source); + if (status) + return status; + draw_surface (cr, source, &img_rect, clip_margin); + cairo_surface_destroy (source); + + status = create_recording_surface_with_mime_jpg (ctx, &source); + if (status) + return status; + draw_surface (cr, source, &jpg_rect, clip_margin); + cairo_surface_destroy (source); + + status = create_recording_surface (ctx, &source, TRUE); + if (status) + return status; + draw_surface (cr, source, &bounded_rect, clip_margin); + cairo_surface_destroy (source); + + status = create_recording_surface (ctx, &source, FALSE); + if (status) + return status; + draw_surface (cr, source, &unbounded_rect, clip_margin); + cairo_surface_destroy (source); + + cairo_show_page (cr); + } + + cairo_destroy (cr); + + return CAIRO_TEST_SUCCESS; +} + +static cairo_test_status_t +check_file_size (cairo_test_context_t *ctx, const char *filename, long expected_size) +{ + FILE *f; + long size; + + f = fopen (filename, "rb"); + if (f == NULL) { + cairo_test_log (ctx, "Unable to open file %s\n", filename); + return CAIRO_TEST_FAILURE; + } + + fseek (f, 0, SEEK_END); + size = ftell (f); + fclose(f); + + if (labs(size - expected_size) > SIZE_TOLERANCE) { + cairo_test_log (ctx, + "mime-unique-id: File %s has size %ld. Expected size %ld +/- %ld." + " Check if surfaces are embedded once.\n", + filename, size, expected_size, (long)SIZE_TOLERANCE); + return CAIRO_TEST_FAILURE; + } + + return CAIRO_TEST_SUCCESS; +} + +static cairo_test_status_t +preamble (cairo_test_context_t *ctx) +{ + cairo_surface_t *surface; + cairo_status_t status; + char *filename; + cairo_test_status_t result = CAIRO_TEST_UNTESTED; + cairo_test_status_t test_status; + const char *path = cairo_test_mkdir (CAIRO_TEST_OUTPUT_DIR) ? CAIRO_TEST_OUTPUT_DIR : "."; + +#if CAIRO_HAS_PS_SURFACE + if (cairo_test_is_target_enabled (ctx, "ps2")) + { + xasprintf (&filename, "%s/%s.ps2.out.ps", path, BASENAME); + surface = cairo_ps_surface_create (filename, WIDTH, HEIGHT); + status = cairo_surface_status (surface); + if (status) { + cairo_test_log (ctx, "Failed to create ps surface for file %s: %s\n", + filename, cairo_status_to_string (status)); + test_status = CAIRO_TEST_FAILURE; + goto ps2_finish; + } + + cairo_ps_surface_restrict_to_level (surface, CAIRO_PS_LEVEL_2); + + test_status = draw_pages (ctx, surface); + cairo_surface_destroy (surface); + + if (test_status == CAIRO_TEST_SUCCESS) + test_status = check_file_size (ctx, filename, PS2_EXPECTED_SIZE); + + ps2_finish: + cairo_test_log (ctx, "TEST: %s TARGET: %s RESULT: %s\n", + ctx->test->name, + "ps2", + test_status ? "FAIL" : "PASS"); + + if (result == CAIRO_TEST_UNTESTED || test_status == CAIRO_TEST_FAILURE) + result = test_status; + + free (filename); + } + + if (cairo_test_is_target_enabled (ctx, "ps3")) + { + xasprintf (&filename, "%s/%s.ps3.out.ps", path, BASENAME); + surface = cairo_ps_surface_create (filename, WIDTH, HEIGHT); + status = cairo_surface_status (surface); + if (status) { + cairo_test_log (ctx, "Failed to create ps surface for file %s: %s\n", + filename, cairo_status_to_string (status)); + test_status = CAIRO_TEST_FAILURE; + goto ps3_finish; + } + + test_status = draw_pages (ctx, surface); + cairo_surface_destroy (surface); + + if (test_status == CAIRO_TEST_SUCCESS) + test_status = check_file_size (ctx, filename, PS3_EXPECTED_SIZE); + + ps3_finish: + cairo_test_log (ctx, "TEST: %s TARGET: %s RESULT: %s\n", + ctx->test->name, + "ps3", + test_status ? "FAIL" : "PASS"); + + if (result == CAIRO_TEST_UNTESTED || test_status == CAIRO_TEST_FAILURE) + result = test_status; + + free (filename); + } +#endif + +#if CAIRO_HAS_PDF_SURFACE + if (cairo_test_is_target_enabled (ctx, "pdf")) + { + xasprintf (&filename, "%s/%s.pdf.out.pdf", path, BASENAME); + surface = cairo_pdf_surface_create (filename, WIDTH, HEIGHT); + status = cairo_surface_status (surface); + if (status) { + cairo_test_log (ctx, "Failed to create pdf surface for file %s: %s\n", + filename, cairo_status_to_string (status)); + test_status = CAIRO_TEST_FAILURE; + goto pdf_finish; + } + + test_status = draw_pages (ctx, surface); + cairo_surface_destroy (surface); + + if (test_status == CAIRO_TEST_SUCCESS) + test_status = check_file_size (ctx, filename, PDF_EXPECTED_SIZE); + + + pdf_finish: + cairo_test_log (ctx, "TEST: %s TARGET: %s RESULT: %s\n", + ctx->test->name, + "pdf", + test_status ? "FAIL" : "PASS"); + + if (result == CAIRO_TEST_UNTESTED || test_status == CAIRO_TEST_FAILURE) + result = test_status; + + free (filename); + } +#endif + + return result; +} + +CAIRO_TEST (mime_unique_id, + "Check that paginated surfaces embed only one copy of surfaces with the same CAIRO_MIME_TYPE_UNIQUE_ID.", + "paginated", /* keywords */ + "target=vector", /* requirements */ + 0, 0, + preamble, NULL) diff -Nru cairo-1.15.8/test/pdiff/Makefile.in cairo-1.15.10/test/pdiff/Makefile.in --- cairo-1.15.8/test/pdiff/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/test/pdiff/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -97,10 +97,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -458,6 +457,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -556,6 +560,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/test/record.c cairo-1.15.10/test/record.c --- cairo-1.15.8/test/record.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/test/record.c 2017-12-07 02:14:36.000000000 +0000 @@ -46,6 +46,8 @@ 0xff00ff00, 0xff00ff00, 0xff0000ff, 0xff0000ff }; +static const char *unique_id = "data"; + static const char *png_filename = "romedalen.png"; static cairo_t * @@ -70,6 +72,9 @@ surface = cairo_image_surface_create_for_data ((unsigned char *) data, CAIRO_FORMAT_RGB24, 4, 4, 16); + cairo_surface_set_mime_data (surface, CAIRO_MIME_TYPE_UNIQUE_ID, + (unsigned char *)unique_id, strlen(unique_id), + NULL, NULL); cairo_test_paint_checkered (cr); @@ -106,6 +111,9 @@ surface = cairo_image_surface_create_for_data ((unsigned char *) data, CAIRO_FORMAT_RGB24, 4, 4, 16); + cairo_surface_set_mime_data (surface, CAIRO_MIME_TYPE_UNIQUE_ID, + (unsigned char *)unique_id, strlen(unique_id), + NULL, NULL); cairo_test_paint_checkered (cr); @@ -131,6 +139,9 @@ surface = cairo_image_surface_create_for_data ((unsigned char *) data, CAIRO_FORMAT_RGB24, 4, 4, 16); + cairo_surface_set_mime_data (surface, CAIRO_MIME_TYPE_UNIQUE_ID, + (unsigned char *)unique_id, strlen(unique_id), + NULL, NULL); cairo_test_paint_checkered (cr); Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/mime-data.base.argb32.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/mime-data.base.argb32.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/mime-data.base.rgb24.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/mime-data.base.rgb24.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/mime-data.pdf.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/mime-data.pdf.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/mime-data.ps.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/mime-data.ps.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/mime-data.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/mime-data.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/mime-data.script.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/mime-data.script.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/mime-data.svg.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/mime-data.svg.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/record-extend-pad.ps.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/record-extend-pad.ps.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/recording-surface-extend-none.pdf.argb32.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/recording-surface-extend-none.pdf.argb32.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/recording-surface-extend-none.pdf.rgb24.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/recording-surface-extend-none.pdf.rgb24.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/recording-surface-extend-reflect.pdf.argb32.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/recording-surface-extend-reflect.pdf.argb32.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/recording-surface-extend-reflect.pdf.rgb24.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/recording-surface-extend-reflect.pdf.rgb24.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/recording-surface-extend-repeat.pdf.argb32.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/recording-surface-extend-repeat.pdf.argb32.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/recording-surface-extend-repeat.pdf.rgb24.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/recording-surface-extend-repeat.pdf.rgb24.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/record-text-transform.ps.argb32.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/record-text-transform.ps.argb32.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/record-text-transform.ps.rgb24.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/record-text-transform.ps.rgb24.ref.png differ Binary files /tmp/tmpXP6rIq/bzye15akFi/cairo-1.15.8/test/reference/scale-offset-similar.pdf.ref.png and /tmp/tmpXP6rIq/Qy0RWVdEmL/cairo-1.15.10/test/reference/scale-offset-similar.pdf.ref.png differ diff -Nru cairo-1.15.8/test/svg2png.c cairo-1.15.10/test/svg2png.c --- cairo-1.15.8/test/svg2png.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/test/svg2png.c 2017-12-07 02:14:36.000000000 +0000 @@ -27,8 +27,6 @@ #include #include -#include -#include #include #define FAIL(msg) \ diff -Nru cairo-1.15.8/util/cairo-fdr/Makefile.in cairo-1.15.10/util/cairo-fdr/Makefile.in --- cairo-1.15.8/util/cairo-fdr/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/util/cairo-fdr/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -94,10 +94,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -277,6 +276,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -375,6 +379,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/util/cairo-gobject/Makefile.in cairo-1.15.10/util/cairo-gobject/Makefile.in --- cairo-1.15.8/util/cairo-gobject/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/util/cairo-gobject/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -95,10 +95,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -285,6 +284,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -383,6 +387,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/util/cairo-missing/Makefile.in cairo-1.15.10/util/cairo-missing/Makefile.in --- cairo-1.15.8/util/cairo-missing/Makefile.in 2017-08-29 17:02:13.000000000 +0000 +++ cairo-1.15.10/util/cairo-missing/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -94,10 +94,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -249,6 +248,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -347,6 +351,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/util/cairo-script/cairo-script-interpreter.c cairo-1.15.10/util/cairo-script/cairo-script-interpreter.c --- cairo-1.15.8/util/cairo-script/cairo-script-interpreter.c 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/util/cairo-script/cairo-script-interpreter.c 2017-12-07 02:13:46.000000000 +0000 @@ -179,6 +179,17 @@ #endif } +csi_status_t +_csi_stack_push (csi_t *ctx, csi_stack_t *stack, + const csi_object_t *obj) +{ + if (_csi_unlikely (stack->len == stack->size)) + return _csi_stack_push_internal (ctx, stack, obj); + + stack->objects[stack->len++] = *obj; + return CSI_STATUS_SUCCESS; +} + static void _csi_perm_fini (csi_t *ctx) { diff -Nru cairo-1.15.8/util/cairo-script/cairo-script-private.h cairo-1.15.10/util/cairo-script/cairo-script-private.h --- cairo-1.15.8/util/cairo-script/cairo-script-private.h 2017-08-22 02:50:05.000000000 +0000 +++ cairo-1.15.10/util/cairo-script/cairo-script-private.h 2017-12-07 02:14:36.000000000 +0000 @@ -916,16 +916,9 @@ } } -static inline csi_status_t +csi_status_t _csi_stack_push (csi_t *ctx, csi_stack_t *stack, - const csi_object_t *obj) -{ - if (_csi_unlikely (stack->len == stack->size)) - return _csi_stack_push_internal (ctx, stack, obj); - - stack->objects[stack->len++] = *obj; - return CSI_STATUS_SUCCESS; -} + const csi_object_t *obj); static inline csi_boolean_t _csi_check_ostack (csi_t *ctx, csi_integer_t count) diff -Nru cairo-1.15.8/util/cairo-script/examples/Makefile.in cairo-1.15.10/util/cairo-script/examples/Makefile.in --- cairo-1.15.8/util/cairo-script/examples/Makefile.in 2017-08-29 17:02:13.000000000 +0000 +++ cairo-1.15.10/util/cairo-script/examples/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -93,10 +93,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -197,6 +196,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -295,6 +299,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/util/cairo-script/Makefile.in cairo-1.15.10/util/cairo-script/Makefile.in --- cairo-1.15.8/util/cairo-script/Makefile.in 2017-08-29 17:02:13.000000000 +0000 +++ cairo-1.15.10/util/cairo-script/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -98,10 +98,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -366,6 +365,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -464,6 +468,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/util/cairo-sphinx/Makefile.in cairo-1.15.10/util/cairo-sphinx/Makefile.in --- cairo-1.15.8/util/cairo-sphinx/Makefile.in 2017-08-29 17:02:13.000000000 +0000 +++ cairo-1.15.10/util/cairo-sphinx/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -96,10 +96,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -287,6 +286,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -385,6 +389,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/util/cairo-trace/Makefile.in cairo-1.15.10/util/cairo-trace/Makefile.in --- cairo-1.15.8/util/cairo-trace/Makefile.in 2017-08-29 17:02:13.000000000 +0000 +++ cairo-1.15.10/util/cairo-trace/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -101,10 +101,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -295,6 +294,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -393,6 +397,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@ diff -Nru cairo-1.15.8/util/font-view.c cairo-1.15.10/util/font-view.c --- cairo-1.15.8/util/font-view.c 2017-04-24 17:17:20.000000000 +0000 +++ cairo-1.15.10/util/font-view.c 2017-12-07 02:13:46.000000000 +0000 @@ -24,6 +24,8 @@ * Author: Chris Wilson */ +#include +#include #include #include diff -Nru cairo-1.15.8/util/Makefile.in cairo-1.15.10/util/Makefile.in --- cairo-1.15.8/util/Makefile.in 2017-08-29 17:02:12.000000000 +0000 +++ cairo-1.15.10/util/Makefile.in 2017-12-11 21:03:11.000000000 +0000 @@ -107,10 +107,9 @@ $(top_srcdir)/build/aclocal.compare.m4 \ $(top_srcdir)/build/aclocal.enable.m4 \ $(top_srcdir)/build/aclocal.float.m4 \ - $(top_srcdir)/build/aclocal.gtk-doc.m4 \ $(top_srcdir)/build/aclocal.makefile.m4 \ $(top_srcdir)/build/aclocal.pkg.m4 \ - $(top_srcdir)/build/libtool.m4 \ + $(top_srcdir)/build/gtk-doc.m4 $(top_srcdir)/build/libtool.m4 \ $(top_srcdir)/build/ltoptions.m4 \ $(top_srcdir)/build/ltsugar.m4 \ $(top_srcdir)/build/ltversion.m4 \ @@ -563,6 +562,11 @@ GREP = @GREP@ GS = @GS@ GTKDOC_CHECK = @GTKDOC_CHECK@ +GTKDOC_CHECK_PATH = @GTKDOC_CHECK_PATH@ +GTKDOC_DEPS_CFLAGS = @GTKDOC_DEPS_CFLAGS@ +GTKDOC_DEPS_LIBS = @GTKDOC_DEPS_LIBS@ +GTKDOC_MKPDF = @GTKDOC_MKPDF@ +GTKDOC_REBASE = @GTKDOC_REBASE@ HTML_DIR = @HTML_DIR@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ @@ -661,6 +665,8 @@ gl_LIBS = @gl_LIBS@ glesv2_CFLAGS = @glesv2_CFLAGS@ glesv2_LIBS = @glesv2_LIBS@ +glesv3_CFLAGS = @glesv3_CFLAGS@ +glesv3_LIBS = @glesv3_LIBS@ glib_CFLAGS = @glib_CFLAGS@ glib_LIBS = @glib_LIBS@ gtk_CFLAGS = @gtk_CFLAGS@