/usr/lib/gtkdialog/box_splash and animated gif icons?

Please post any bugs you have found
Message
Author
User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

/usr/lib/gtkdialog/box_splash and animated gif icons?

#1 Post by Argolance »

Bonsoir,
I wanted to test "yaf-splash" running multiple Puppies because some users reported strange behaviors. I installed slacko-6.3.0, xenialpup-7.5, stretch-7.5, tahr-6.0.5 to an USB stick and I noticed something very annoying: none of these Puppy versions that have /usr/lib/gtkdialog/box_splash instead of the previous /usr/bin/gtkdialog-splash (with which all works properly) seem to support animated gif icons. Sometimes, huge windows are displayed as shown below.

I'm not sure about myself, but I think it is important that this be verified!

Cordialement.
Attachments
yaf-splash.jpg
(21.68 KiB) Downloaded 586 times

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#2 Post by musher0 »

Allô, Argolance.

My most sincere sympathies...

IMO, in such a case, one should include the "dialog" variant that works with
one's script. This eliminates the problem of the variant in various Puppies
AND the problem of the evolution of the distro taken somewhere undesirable
by the gods.

With this approach, the Puppy gods in woof-CE Heaven can change whatever
they wish, you simple mortal developer are always providing the "dialog"
variant your script needs (hehe).

Because, as you probably know by now, one cannot change the gods' minds.
:twisted:

Just a thought. / Une idée comme ça.
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#3 Post by Argolance »

Hello musher0,
This is indeed the temporary solution I found and chose, but it is a second best solution! I think it's not a choice on the part of the designers, just a dysfunction they probably ignore and to be corrected, for the good of all puppyists.

À la tienne Étienne!
Cordialement!

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

Re: /usr/lib/gtkdialog/box_splash and animated gif icons?

#4 Post by MochiMoppel »

Argolance wrote:I noticed something very annoying: none of these Puppy versions that have /usr/lib/gtkdialog/box_splash instead of the previous /usr/bin/gtkdialog-splash (with which all works properly) seem to support animated gif icons.
Are you suggesting that your gtkdialog-splash does support animated gif icons? Mine does not. I don't see how this would be possible as the gtkdialog-splash code sets a fixed width for the icon, which prevents the animation. Same in box_splash. Both versions share the same core code that is responsible for icon display. Both gtkdialog-splash and box_splash work fine for me in Slacko 5.6. Can't say much about the Puppy versions you mentioned.

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#5 Post by Argolance »

Bonsoir,
Thank you for your answer.
MochiMoppel wrote:Are you suggesting that your gtkdialog-splash does support animated gif icons? Mine does not. I don't see how this would be possible as the gtkdialog-splash code sets a fixed width for the icon, which prevents the animation. Same in box_splash. Both versions share the same core code that is responsible for icon display. Both gtkdialog-splash and box_splash work fine for me in Slacko 5.6. Can't say much about the Puppy versions you mentioned.
I am asserting that Puppy Precise 5.7.3 (and ToOpPy based on it) /usr/bin/gtkdialog-splash supports animated gifs and suggesting that box_splash seems not to do so.
For example, this command works fine for me (regardless of the size of the gif image):

Code: Select all

yaf-splash -placement top -icon "/usr/share/pixmaps/wait.gif" -text "Please wait..." -close never &
Cordialement.
Attachments
181009_220109_166x68_easyshot.jpg
2 different moments of the animation...
(3.57 KiB) Downloaded 482 times

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#6 Post by Argolance »

This may be helpful to know:
I imported box_splash in my Puppy Precise 5.7.3 based system and typed this command in console:

Code: Select all

 /usr/lib/gtkdialog/box_splash -placement top -icon "/usr/share/pixmaps/wait.gif" -text "Please wait..." -close never &
I see that box_splash supports animated gifs too even if the icon is larger than the default size (32 pixels)! In this case, pop-up windows are truncated, in some others (see picture above) huge.
Attached image shows the same command executed twice simultaneously to let you guess the animation, the first displaying just a part of the icon, the second the entire icon (-icon_width 52).
This works as long as the /tmp/yaf-splash is linked to /usr/sbin/gtkdialog3. If I delete this link, box_splash creates automatically a link to /usr/sbin/gtkdialog which is a link to gtkdialog4 and animated gifs are not supported anymore.

Cordialement.
Attachments
181010_103706_474x76_easyshot.jpg
(6.63 KiB) Downloaded 452 times

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

#7 Post by MochiMoppel »

Argolance wrote:This works as long as the /tmp/yaf-splash is linked to /usr/sbin/gtkdialog3. If I delete this link, box_splash creates automatically a link to /usr/sbin/gtkdialog which is a link to gtkdialog4 and animated gifs are not supported anymore..
In other words: It's not a bug?
Older Puppies like Precise kept gtkdialog3 and gtkdialog4 as 2 different gtkdialog versions. In newer Puppies gtkdialog3 is kept for backward compatibility, but only as a symlink to /usr/sbin/gtkdialog. Could well be that gtkdialog3 supported resized animated gifs.

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#8 Post by Argolance »

Bonjour,
In other words: It's not a bug?
Dear MochiMoppel,
Call it what you like! :wink:
It is nevertheless frustrating (and I thought it was worth reporting) that the yaf-splash functionality of the Puppies mentioned above do not correctly display animated gifs, as well as truncated or oversized windows in some cases.
Could well be that gtkdialog3 supported resized animated gifs.
The option -icon_width comes with box_splash and is not included among the options of gtkdialog-splash. And after all, why shouldn't gtkdialog4 support animated gifs while gtkdialog3 did it well?
What is the advantage and should this be ignored?

Note that I am here to understand, learn and eventually help, not to give lessons...

Cordialement.

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

#9 Post by MochiMoppel »

Argolance wrote:The option -icon_width comes with box_splash and is not included among the options of gtkdialog-splash.
It is included in gtkdialog-splash that came with my Slacko 5.6. If -icon_width is not set it uses a default width of 32.

Now comes the important point: The gtkdialog-splash you are referring to, the one in Precise, didn't have a default width, let alone a -icon_width option . In fact this version is so old and simple that the string "width" doesn't even appear anywhere in the script. If in gtkdialog (3 or 4 doesn't matter) a width is stipulated for a pixmap (= the icon we are talking about), an animated gif loses it's animation, even if the stipulated size is the same as the gif's original size. So the lost functionality for animated gifs is a result of the added functionality for icon size. But this already happened long ago and is not something that came with box_splash.

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#10 Post by fredx181 »

Argolance wrote:Attached image shows the same command executed twice simultaneously to let you guess the animation, the first displaying just a part of the icon, the second the entire icon (-icon_width 52).
This works as long as the /tmp/yaf-splash is linked to /usr/sbin/gtkdialog3. If I delete this link, box_splash creates automatically a link to /usr/sbin/gtkdialog which is a link to gtkdialog4 and animated gifs are not supported anymore.
Great find, always wanted to be able to use .gif with box_splash (or gtkdialog-splash), thanks !
A workaround I found is hacking box_splash, remove the second occurance of "<width>$ICON_WIDTH</width>", so becomes instead of:

Code: Select all

 	*) icon="<pixmap width-request="$ICON_WIDTH" space-expand="false" space-fill="false">
	  <width>$ICON_WIDTH</width>
Just this:

Code: Select all

 	*) icon="<pixmap width-request="$ICON_WIDTH" space-expand="false" space-fill="false">
But then in case of using e.g. a .png image, the resize functionality doesn't work anymore... (when using -icon_width)
So what I would do is to make separate *hacked* box_splash script with name e.g. box_splash_gif and call that for these special occasions.

Fred

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#11 Post by Argolance »

MochiMoppel wrote:But this already happened long ago and is not something that came with box_splash.
Obviously, the "so old" gtkdialog-splash I was referring to, is the one in Precise... the important point being it does something that the next releases DO NOT. :)
So, at the risk of sounding insistent, let me ask you again:
what is the advantage of adding a feature that cancels out another very useful one, especially if the animated icons were displayed correctly, regardless of their size? :shock: :roll:

[EDIT]
@fredx181
Sorry, our messages have crossed paths!
So what I would do is to make separate *hacked* box_splash script with name e.g. box_splash_gif and call that for these special occasions.
As suggested at the beginning of this thread, why not bypass this inconvenience simply by using the "old" gtkdialog-splash which does the job well, unless it is the cause of other unexpected problems, the best thing being for the designers not to turn a deaf ear, take our remarks seriously and then do something to fix this "thing" that fairly bugs some honest Puppy users. Isn't it? 8)

Cordialement.
Last edited by Argolance on Wed 10 Oct 2018, 16:32, edited 1 time in total.

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#12 Post by fredx181 »

Argolance wrote:[EDIT]
@fredx181
Sorry, our messages have crossed paths!
No problem :)
I didn't go very deep into this, but I think that gtkdialog-splash is the most focused on using e.g. .png images with resize functionality, which is not supported for .gif images to display properly.

BTW, forgot earlier to attach my .gif made with hacked box-splash (with .gif display), see below :)

Fred
Attachments
try.gif
With *hacked&quot; box_splash
(151.57 KiB) Downloaded 421 times

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#13 Post by Argolance »

[EDIT]
@fredx181
Sorry, our messages have crossed paths!
Again! :D

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#14 Post by fredx181 »

Argolance wrote:
[EDIT]
@fredx181
Sorry, our messages have crossed paths!
Again! :D
Ah, yes, noticed your above edited post.
Quote:
So what I would do is to make separate *hacked* box_splash script with name e.g. box_splash_gif and call that for these special occasions.

As suggested at the beginning of this thread, why not bypass this inconvenience simply by using the "old" gtkdialog-splash which does the job well, unless it is the cause of other unexpected problems, the best thing being for the designers not to turn a deaf ear, take our remarks seriously and then do something to fix this "thing" that fairly bugs some honest Puppy users. Isn't it? Cool
Well, the (older) gtkdialog-splash I have on my system doesn't do "the job well" with .gif images.
But to be honest, I don't remember how or from where I got it, so I can't really have opinion about this issue.
Maybe it's possible to have support for resizeable images and also make .gif images display correctly, but... will be difficult, I guess.

Fred

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#15 Post by Argolance »

This is the Puppy Precise 5.7.3 gtkdialog-splash, to be renamed without the gz extension, the one that "does the job" and may be used as stand alone script, renamed otherwise so as not to conflict with the one with the same name in /usr/bin directory which refers to box_splash.
Isn't it, sometimes, in old pots that the best soup is made? :)
Maybe it's possible to have support for resizeable images and also make .gif images display correctly, but... will be difficult, I guess.
Why could it be so difficult?
With a little goodwill, anything is possible!
Attachments
gtkdialog-splash.gz
(6.97 KiB) Downloaded 261 times

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#16 Post by fredx181 »

Argolance wrote:This is the Puppy Precise 5.7.3 gtkdialog-splash, to be renamed without the gz extension, the one that "does the job" and may be used as stand alone script, renamed otherwise so as not to conflict with the one with the same name in /usr/bin directory which refers to box_splash.
Isn't it, sometimes, in old pots that the best soup is made? :)


Yes. works for me displaying .gif image correctly.
But (as you probably noticed) the -icon_width cannot be set, so depends on the size of the icon how big or small it's displayed AFAIK
Maybe it's possible to have support for resizeable images and also make .gif images display correctly, but... will be difficult, I guess.
Why could it be so difficult?
With a little goodwill, anything is possible!
Okay, better should have said that I personally have no clue how to do it :roll:

Fred

ITSMERSH

#17 Post by ITSMERSH »

This old (Argolance's) gtkdialog-splash is interesting.

Downloaded and archived! :D

Thanks!

User avatar
MochiMoppel
Posts: 2084
Joined: Wed 26 Jan 2011, 09:06
Location: Japan

#18 Post by MochiMoppel »

Argolance wrote:So, at the risk of sounding insistent, let me ask you again:
what is the advantage of adding a feature that cancels out another very useful one, especially if the animated icons were displayed correctly, regardless of their size? :shock: :roll:
You are insistent and I don't know why you keep asking me. I wasn't there when it happened, I have no part in it. I am innocent! :lol:
I can only speculate: When changing from gtkdialog3 to gtkdialog4, SVG support was the new craze and setting an arbitrary size for an icon and still have it displayed nicely was a nice new feature. Probably nobody noticed what this meant for animated GIFs. And if it was noticed then the new feature may have been considered more important than the lost feature. That's what is called a compromise :wink:
fredx181 wrote:Maybe it's possible to have support for resizeable images and also make .gif images display correctly, but... will be difficult, I guess.
In principle I did this already in MMview. Here the viewer shows images resized (= scaled to fit viewer) by default, but does not resize when the image is small enough for the viewer. This displays GIFs animated if they fit into the viewer and static if they don't.

User avatar
Argolance
Posts: 3767
Joined: Sun 06 Jan 2008, 22:57
Location: PORT-BRILLET (Mayenne - France)
Contact:

#19 Post by Argolance »

Bonjour,
MochiMoppel wrote:You are insistent and I don't know why you keep asking me.
... But I was right to be because you finally gave me the answer I was waiting for... :)
By the way and since you mention it: I sincerely think MMView is a major tool that should be integrated to all Puppies and therefore it is a pity that it is not internationalized - you see how "insistent" I am...). :wink:

Cheers.

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#20 Post by fredx181 »

Just experimented for fun :lol: :

Image

To run, download:
https://dl.dropboxusercontent.com/s/xg2 ... ar.gz?dl=1

Extract launch.tar.gz and run "launch" (inside "launch" folder)
Has 15 seconds timeout, it's using the older gtkdialog-splash that Argolance shared earlier in this thread.

Fred

Post Reply