Posted: Mon 15 Oct 2018, 10:15
Yeah, seems to be that any value for <width> or <height> other than -1 prevents gif animation (or of course leaving width and height values out altogether). I'm using the following simple test program (this is with gtkwialog, which accepts the preserve-aspect-ratio tag, which can of course be omitted if using gtkdialog instead).
I haven't actually tried my new code yet and also a couple of other things I'll try. For example, there is a break statement in current gtkwialog and gtkwialog and gtkdialog4 code to load only one image into pixbuf (different code altogether in gtkdialog3 for pixbuf stuff - no such break); I will try removing that break in the gtkwialog pixbuf loading loop... - not sure how that effects animated gif type file (I don't know animated gif format, except number of images in the file, so suspicious if that break statement is the problem in gtkdialog4).
gtkdialog3 uses GtkImageMenuItem [EDIT: No - that's just for menu stock/icons] functions (deprecated), gtkwialog4 on the other hand uses straight GtkImage functions.
I'm just documenting these points here to remind me when I look into it further tomorrow.
wiak
Code: Select all
#! /bin/sh
# Needs test.gif image in script start directory
export MAIN_DIALOG='
<window>
<vbox>
<pixmap preserve-aspect-ratio="false">
<variable>IMAGEN</variable>
<height>300</height>
<input file>./try.gif</input>
</pixmap>
</vbox>
</window>'
gtkwialog -p MAIN_DIALOG
gtkdialog3 uses GtkImageMenuItem [EDIT: No - that's just for menu stock/icons] functions (deprecated), gtkwialog4 on the other hand uses straight GtkImage functions.
I'm just documenting these points here to remind me when I look into it further tomorrow.
wiak