gimp/libgimp/gimpexportoptions.h
Alx Sa bcdd4974bb core, pdb, plug-ins: Create GimpExportOptions class
This patch creates a GimpExportOptions class in both
libgimpbase and in libgimp. Currently it is a mostly empty
object, but it will be added to after 3.0 to allow for
additional export options (like resizing on export while
leaving the original image intact)

libgimp/gimpexport.c was removed, and most of its content
was copied into libgimp/gimpexportoptions.c. gimp_export_image ()
was replaced with gimp_export_options_get_image () in all
export plug-ins.

GimpExportProcedure has a new function to set the default
image capabilities for each plug-in on creation. It also sets up
a new callback function, which allows the options to respond to
user setting changes (such as toggling 'Save as Animation' in the
GIF or WEBP Plug-in).
2024-08-18 22:03:14 +02:00

55 lines
1.6 KiB
C

/* LIBGIMP - The GIMP Library
* Copyright (C) 1995-2000 Peter Mattis and Spencer Kimball
*
* gimpexportoptions.h
* Copyright (C) 2024 Alx Sa.
*
* This library is free software: you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 3 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library. If not, see
* <https://www.gnu.org/licenses/>.
*/
#if !defined (__GIMP_H_INSIDE__) && !defined (GIMP_COMPILATION)
#error "Only <libgimp/gimp.h> can be included directly."
#endif
#ifndef __LIBGIMP_GIMP_EXPORT_OPTIONS_H__
#define __LIBGIMP_GIMP_EXPORT_OPTIONS_H__
G_BEGIN_DECLS
/* For information look into the C source or the html documentation */
/**
* GimpExportReturn:
* @GIMP_EXPORT_IGNORE: The image is unmodified but export shall continue anyway
* @GIMP_EXPORT_EXPORT: The chosen transforms were applied to the image
*
* Possible return values of gimp_export_image().
**/
typedef enum
{
GIMP_EXPORT_IGNORE,
GIMP_EXPORT_EXPORT
} GimpExportReturn;
GimpExportReturn gimp_export_options_get_image (GimpExportOptions *options,
GimpImage **image);
G_END_DECLS
#endif /* __LIBGIMP_GIMP_EXPORT_OPTIONS_H__ */