mirror of
https://gitlab.gnome.org/GNOME/gimp.git
synced 2025-07-03 17:33:25 +00:00
plug-ins: Export single-page PDFs without layers
Resolves #10133 We always set GIMP_EXPORT_CAN_HANDLE_LAYER in the export options, even if the user set the "layers-as-pages" parameter to FALSE. As a result, single-page PDFs did not render the same way they appeared in GIMP, since gimp_export_options_get_image () did not process them as a single layer image. This patch makes GIMP_EXPORT_CAN_HANDLE_LAYER be conditionally set based on the value of "layers-as-pages".
This commit is contained in:
parent
6151deaff9
commit
b98fe0c3d0
1 changed files with 10 additions and 6 deletions
|
@ -839,16 +839,20 @@ export_edit_options (GimpProcedure *procedure,
|
||||||
{
|
{
|
||||||
GimpExportCapabilities capabilities;
|
GimpExportCapabilities capabilities;
|
||||||
gboolean apply_masks;
|
gboolean apply_masks;
|
||||||
|
gboolean layers_as_page;
|
||||||
|
|
||||||
g_object_get (G_OBJECT (config),
|
g_object_get (G_OBJECT (config),
|
||||||
"apply-masks", &apply_masks,
|
"apply-masks", &apply_masks,
|
||||||
|
"layers-as-pages", &layers_as_page,
|
||||||
NULL);
|
NULL);
|
||||||
|
|
||||||
capabilities = (GIMP_EXPORT_CAN_HANDLE_RGB |
|
capabilities = (GIMP_EXPORT_CAN_HANDLE_RGB |
|
||||||
GIMP_EXPORT_CAN_HANDLE_ALPHA |
|
|
||||||
GIMP_EXPORT_CAN_HANDLE_GRAY |
|
GIMP_EXPORT_CAN_HANDLE_GRAY |
|
||||||
GIMP_EXPORT_CAN_HANDLE_LAYERS |
|
GIMP_EXPORT_CAN_HANDLE_INDEXED |
|
||||||
GIMP_EXPORT_CAN_HANDLE_INDEXED);
|
GIMP_EXPORT_CAN_HANDLE_ALPHA);
|
||||||
|
|
||||||
|
if (layers_as_page)
|
||||||
|
capabilities |= GIMP_EXPORT_CAN_HANDLE_LAYERS;
|
||||||
|
|
||||||
if (! apply_masks)
|
if (! apply_masks)
|
||||||
capabilities |= GIMP_EXPORT_CAN_HANDLE_LAYER_MASKS;
|
capabilities |= GIMP_EXPORT_CAN_HANDLE_LAYER_MASKS;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue