v1cont / yad

Yet Another Dialog
GNU General Public License v3.0
687 stars 57 forks source link

bug or feature in version 0.42.0 with icon size #37

Closed terminologie-x closed 5 years ago

terminologie-x commented 5 years ago

yad --version 0.42.0 (GTK+ 3.24.5)

after the last update I noticed a little difference with the icons, maybe someone could give me a hint how to fix that. I am using icons with 32x32px.

with yad version 0.41.0 it looks like this: bildschirmfoto 2019-02-25 03 29 03

with the actual yad version 0.42.0 it looks like this: bildschirmfoto 2019-02-25 03 30 23

the example code:

yad --width=600 --height=200 --form --columns=4 --center --scroll \
--borders=30 --no-buttons \
--field "epiphany!/usr/share/dsys/icons/epiphany.png!(Open Source):fbtn" \
"bash -c 'browser_installation epiphany'" \
--field "vivaldi!/usr/share/dsys/icons/vivaldi.png!(Proprietär):fbtn" \
"bash -c 'browser_installation vivaldi'" \
--field "tor-browser!/usr/share/dsys/icons/tor-browser.png!(Open Source):fbtn" \
"bash -c 'browser_installation tor-browser'"

I have tried different parameter --icon-size=32, --icons --icon-width=32, but nothing changes. Do I really need to buy magnifying glasses ? :-D

terminologie-x commented 5 years ago

the default icon-size has changed in the new version, and it seems that the icon-size is fixed to 16x16px. So you cannot define the size of the icons with the option icon-size for the buttons. The question is, why is it a fixed size ignoring the original icon size from the icon file, and the second question is, do we need a feature request to get this bug fixed ?

steps to reproduce:

any idea Victor ?

terminologie-x commented 5 years ago

I am not so familiar with the c code and gtk, just guessing maybe it has something todo with the following in the file icon.c :

YAD_BIG_ICON, FALSE and YAD_SMALL_ICON, TRUE triggers the default behavior for the icons and gdk_pixbuf_scale_simple sizes the images to the default value of 16px.

vendforce commented 5 years ago

--icon-size option to icon dialog

alexsalmona commented 5 years ago

Hi I am running into the same issue. Custom icon png file (100x87 px) and when rendered on an fbtn they are super small (looks like 16x16). I have tried adding --icon-size=100 and it doesn't do anything. The buttons I'm trying to make this work with are in a field dialog that is part of a notebook. Is it no longer possible to resize icons on certain tabs in a notebook and not others? This seemed to work in version .41 but it doesn't seem to work in 1.0

alexsalmona commented 5 years ago

I ended up reverting to .41 and everything works again. Not sure what has changed since .41 when it comes to icons inside of form buttons, but hopefully this will be fixed at some point when Victor has time.

v1cont commented 5 years ago

fixed in 9a6b654

terminologie-x commented 5 years ago

Victor ! Nice 1 good job :-)

the new option --keep-icon-size did the trick. I have tested it with the version yad 3.0-1. I scripted a little tool in bash for friends and family (windows/mac user ) to get better experiences with the archlinux desktop and to help them maintaining the system automatically + voice guidance, which includes yad as the basic element.

many thanks for the good work! :+1: