After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 346016 - file-ico-save ignores run-mode parameter
file-ico-save ignores run-mode parameter
Status: RESOLVED FIXED
Product: GIMP
Classification: Other
Component: Plugins
2.2.x
Other All
: Normal minor
: 2.4
Assigned To: GIMP Bugs
GIMP Bugs
Depends on:
Blocks:
 
 
Reported: 2006-06-27 10:50 UTC by Klaus Schmidinger
Modified: 2008-01-15 13:09 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Klaus Schmidinger 2006-06-27 10:50:32 UTC
Please describe the problem:
I want to create a Windows icon file that contains an image in
several different resolutions. To do this, I use the following
script:


---------------------- cut --------------------------------------
gimp -i -b - <<EOF
(
let* ((image (car (gimp-file-load 1 "test.png" "test.png")))
      (drawable (car (gimp-image-get-active-layer image))))

(set! layer (car (gimp-layer-new-from-drawable drawable image)))
(gimp-image-add-layer image layer -1)
(gimp-layer-scale layer 32 32 FALSE)

(set! layer (car (gimp-layer-new-from-drawable drawable image)))
(gimp-image-add-layer image layer -1)
(gimp-layer-scale layer 24 24 FALSE)

(set! layer (car (gimp-layer-new-from-drawable drawable image)))
(gimp-image-add-layer image layer -1)
(gimp-layer-scale layer 16 16 FALSE)

(gimp-layer-scale drawable 48 48 FALSE)

(file-ico-save 1 image drawable "test.ico" "test.ico")

(gimp-quit 0)
)
EOF
---------------------- cut --------------------------------------


Despite the '1' in the call to 'file-ico-save', GIMP shows me the
"Icon details" dialog before saving the icon file. This is preventing
me from running this completely in batch mode.

Steps to reproduce:
Run the script I've posted.

Actual results:
The "Icon details" dialog appears when it shouldn't.

Expected results:
The script should run without any interaction.

Does this happen every time?
Yes.

Other information:
Comment 1 Sven Neumann 2006-06-27 12:43:07 UTC
The plug-in seems to ignore the run-mode parameter. Patches to fix this would be very much appreciated. Preferably against current CVS.
Comment 2 Sven Neumann 2006-10-16 11:21:53 UTC
2006-10-06  Sven Neumann  <sven@gimp.org>

        * plug-ins/winicon/icodialog.[ch]
        * plug-ins/winicon/icoload.[ch]
        * plug-ins/winicon/icosave.[ch]
        * plug-ins/winicon/main.[ch]: applied patch from Aurimas Juška
        with code cleanup and fixes for bug #346016 and other issues
        (see bug #352899).