Gimp.Image.prototype.metadata_save_prepare

function metadata_save_prepare(mime_type: String, suggested_flags: Gimp.MetadataSaveFlags): Gimp.Metadata {
    // Gjs wrapper for gimp_image_metadata_save_prepare()
}
  

Gets the image metadata for saving it using Gimp.Image.prototype.metadata_save_finish.

The suggested_flags are determined from what kind of metadata (Exif, XMP, ...) is actually present in the image and the preferences for metadata exporting. The calling application may still update @available_flags, for instance to follow the settings from a previous export in the same session, or a previous export of the same image. But it should not override the preferences without a good reason since it is a data leak.

The suggested value for Gimp.MetadataSaveFlags.thumbnail is determined by whether there was a thumbnail in the previously imported image.

Since 2.10

mime_type

The saved file's mime-type

suggested_flags

Suggested default values for the @flags passed to Gimp.Image.prototype.metadata_save_finish

Returns

The image's metadata, prepared for saving.