[cairo] cairo_surface_supports_mime_type
Jean Abou Samra
jean at abou-samra.fr
Wed Dec 28 19:01:39 UTC 2022
Hi,
The Cairo documentation says
/**
* SECTION:cairo-ps
* @Title: PostScript Surfaces
* @Short_Description: Rendering PostScript documents
* @See_Also: #cairo_surface_t
*
* 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.
Indeed, I can successfully embed EPS images into generated
PS files using CAIRO_MIME_TYPE_EPS and CAIRO_MIME_TYPE_EPS_PARAMS
as explained in the docs.
However, later in the source code, there is
static const char *_cairo_ps_supported_mime_types[] =
{
CAIRO_MIME_TYPE_JPEG,
CAIRO_MIME_TYPE_CCITT_FAX,
CAIRO_MIME_TYPE_CCITT_FAX_PARAMS,
NULL
};
This makes
cairo_surface_supports_mime_type (my_ps_surface, CAIRO_MIME_TYPE_EPS)
return false.
What am I missing?
Thanks,
Jean
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 236 bytes
Desc: OpenPGP digital signature
URL: <https://lists.cairographics.org/archives/cairo/attachments/20221228/79cdb0b3/attachment.sig>
More information about the cairo
mailing list