Gtkdialog Development
Ok, it appears a bug has crept in.. (and got worse?)
Slacko Beta 1 ships with r220 that I compiled. I reverted to the original from the iso and this displays:
Not quite OK, I think.
When I just installed r241 I see what zigbert sees, definitely not OK!.
Hope this helps
Slacko Beta 1 ships with r220 that I compiled. I reverted to the original from the iso and this displays:
Not quite OK, I think.
When I just installed r241 I see what zigbert sees, definitely not OK!.
Hope this helps
Puppy Linux Blog - contact me for access
- thunor
- Posts: 350
- Joined: Thu 14 Oct 2010, 15:24
- Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings
- Contact:
There's no bug and you are essentially seeing the same thing!01micko wrote:Ok, it appears a bug has crept in.. (and got worse?)
Slacko Beta 1 ships with r220 that I compiled. I reverted to the original from the iso and this displays:
[image]
Not quite OK, I think.
When I just installed r241 I see what zigbert sees, definitely not OK!.
Hope this helps
In r226 I "modified icon from theme code so that a gtk-missing-image is shown when an image isn't found" (not the tree widget as it's not under my control) so in >= r226 you will see a missing-image icon whereby prior to that you weren't
Look in the column under Menu1 in your screenshot and you can see the compressed buttons that are missing an image but you aren't seeing the missing-image icons, and look at the pixmaps above and you can't immediately tell that they are missing because again you aren't seeing the missing-image icons and the empty pixmaps have no dimension. You could tell though by looking in the tree widgets or in the menus and comparing, and creating a list to check against.
I recommend that you use the latest Gtkdialog (r241) so that we are all testing the same thing and looking at the same thing.
Also when testing it is important to be thorough which is why I compiled a list of the icons that aren't showing.
Anyway, seeing as most stock-icons-loaded-through-the-theme show from Gtkdialog's C code or the tree widget's GTK+ function with identical results , I'm investigating the theme. I'm working on this right now in fact and have some debugging messages dumped to the terminal:
Code: Select all
[root@ese:theme-icon-support]# ./theme-icon-test
widget_button_create(): error='Icon 'gtk-discard' not present in theme'
widget_button_create(): error='Icon 'gtk-goto-first' not present in theme'
widget_button_create(): error='Icon 'gtk-goto-last' not present in theme'
widget_button_create(): error='Icon 'gtk-go-back' not present in theme'
widget_button_create(): error='Icon 'gtk-go-forward' not present in theme'
widget_button_create(): error='Icon 'gtk-indent' not present in theme'
widget_button_create(): error='Icon 'gtk-jump-to' not present in theme'
widget_button_create(): error='Icon 'gtk-media-forward' not present in theme'
widget_button_create(): error='Icon 'gtk-media-next' not present in theme'
widget_button_create(): error='Icon 'gtk-media-play' not present in theme'
widget_button_create(): error='Icon 'gtk-media-previous' not present in theme'
widget_button_create(): error='Icon 'gtk-media-rewind' not present in theme'
widget_button_create(): error='Icon 'gtk-redo' not present in theme'
widget_button_create(): error='Icon 'gtk-revert-to-saved' not present in theme'
widget_button_create(): error='Icon 'gtk-undelete' not present in theme'
widget_button_create(): error='Icon 'gtk-undo' not present in theme'
widget_button_create(): error='Icon 'gtk-unindent' not present in theme'
EXIT="Exit"
[root@ese:theme-icon-support]#
Regards,
Thunor
- thunor
- Posts: 350
- Joined: Thu 14 Oct 2010, 15:24
- Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings
- Contact:
Here's something that makes sense:zigbert wrote:that makes sense
The icons are built-in to GTK+ and in most cases the filenames are equivalent to their corresponding stock-ids except for the ones that I've noted as not showing for me in lupu-520 with GTK+ 2.20.0 using the Crux theme:
gtk-discard (this is not built-in, it's a known GTK+ "issue")
gtk-goto-first
gtk-goto-last
gtk-go-back
gtk-go-forward
gtk-indent
gtk-jump-to
gtk-media-forward
gtk-media-next
gtk-media-play
gtk-media-previous
gtk-media-rewind
gtk-redo
gtk-revert-to-saved
gtk-undelete
gtk-undo
gtk-unindent
The solution is to append every one of those stock-ids with "-ltr" or "rtl" which will give you the correct theme icon name. I can now see everything except gtk-discard.
I discovered this by looking at /usr/include/gtk-2.0/gtk/gtkstock.h
Now, I don't know the list of icons that are not showing in Slacko beta 1 because I haven't been given that information, but I can see from your screenshot that you can't see:
gtk-dialog-authentication
gtk-dialog-error
gtk-dialog-info
gtk-dialog-question
gtk-dialog-warning
gtk-discard (this is not built-in, it's a known GTK+ "issue")
gtk-goto-first
gtk-goto-last
gtk-go-back
gtk-info
gtk-jump-to
gtk-new
gtk-undelete
...
etc. etc..
Here's something that doesn't make sense: in Slacko beta 1 you can't see gtk-info, gtk-new or any of the gtk-dialog-* icons!!! In /usr/include/gtk-2.0/gtk/gtkstock.h you should see something like this:
Code: Select all
...
/**
* GTK_STOCK_NEW:
*
* The "New" item.
* <inlinegraphic fileref="gtk-new.png" format="PNG"></inlinegraphic>
*/
#define GTK_STOCK_NEW "gtk-new"
...
I've updated my icon_names.txt list a few posts back so you might want to download it and try the example again.
Regards,
Thunor
Hi Thunor... (excuse my dopiness , not a programmer at all, just a concreter, I tend to do silly things and ask silly questions)
Ok, (with ltr appended?) these are missing:
gtk-dialog-authentication
gtk-dialog-error
gtk-dialog-info
gtk-dialog-question
gtk-dialog-warning
gtk-disacard (known issue)
gtk-info
gtk-new
gtk-save
They all show ok in example 09.10
What do you think?
If it's a Slacko gtk issue I can certainly try to recompile. I'll go through the patches too. But I won't jump the gun .
Cheers
Ok, (with ltr appended?) these are missing:
gtk-dialog-authentication
gtk-dialog-error
gtk-dialog-info
gtk-dialog-question
gtk-dialog-warning
gtk-disacard (known issue)
gtk-info
gtk-new
gtk-save
They all show ok in example 09.10
What do you think?
If it's a Slacko gtk issue I can certainly try to recompile. I'll go through the patches too. But I won't jump the gun .
Cheers
Puppy Linux Blog - contact me for access
I have been playing with the example 09.03-tree_column_icons.
I modified it and made a support file called icon-names1.txt.
It shows all icons with their names except for gtk-discard which shows blank for the icon.
I also did not have to append -ltr or -rtl to any of the names for it.
If you want to play or use it as a reference, it is attached.
I modified it and made a support file called icon-names1.txt.
It shows all icons with their names except for gtk-discard which shows blank for the icon.
I also did not have to append -ltr or -rtl to any of the names for it.
If you want to play or use it as a reference, it is attached.
- Attachments
-
- All_gtk_icons.tar.gz
- Example that shows all GTK icons with names
- (1.4 KiB) Downloaded 296 times
- technosaurus
- Posts: 4853
- Joined: Mon 19 May 2008, 01:24
- Location: Blue Springs, MO
- Contact:
This may be similar. I posted it in the tips thread a long time ago... Just something I keep handy to find the name of a stock icon... but could be useful
Code: Select all
#! /bin/sh
export MAIN_DIALOG='
<vbox><hbox>
<pixmap icon_size="6" tooltip-text="gtk-about"><input file stock="gtk-about"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-add"><input file stock="gtk-add"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-apply"><input file stock="gtk-apply"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-bold"><input file stock="gtk-bold"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-cancel"><input file stock="gtk-cancel"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-cdrom"><input file stock="gtk-cdrom"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-clear"><input file stock="gtk-clear"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-close"><input file stock="gtk-close"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-color-picker"><input file stock="gtk-color-picker"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-connect"><input file stock="gtk-connect"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-convert"><input file stock="gtk-convert"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-copy"><input file stock="gtk-copy"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-cut"><input file stock="gtk-cut"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-delete"><input file stock="gtk-delete"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-dialog-authentication"><input file stock="gtk-dialog-authentication"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-dialog-error"><input file stock="gtk-dialog-error"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-dialog-info"><input file stock="gtk-dialog-info"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-dialog-question"><input file stock="gtk-dialog-question"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-dialog-warning"><input file stock="gtk-dialog-warning"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-directory"><input file stock="gtk-directory"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-disconnect"><input file stock="gtk-disconnect"></input></pixmap>
</hbox><hbox>
<pixmap icon_size="6" tooltip-text="gtk-dnd"><input file stock="gtk-dnd"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-dnd-multiple"><input file stock="gtk-dnd-multiple"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-edit"><input file stock="gtk-edit"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-execute"><input file stock="gtk-execute"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-file"><input file stock="gtk-file"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-find"><input file stock="gtk-find"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-find-and-replace"><input file stock="gtk-find-and-replace"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-floppy"><input file stock="gtk-floppy"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-fullscreen"><input file stock="gtk-fullscreen"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-go-back"><input file stock="gtk-go-back"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-go-down"><input file stock="gtk-go-down"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-go-forward"><input file stock="gtk-go-forward"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-go-up"><input file stock="gtk-go-up"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-goto-bottom"><input file stock="gtk-goto-bottom"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-goto-first"><input file stock="gtk-goto-first"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-goto-last"><input file stock="gtk-goto-last"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-goto-top"><input file stock="gtk-goto-top"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-harddisk"><input file stock="gtk-harddisk"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-help"><input file stock="gtk-help"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-home"><input file stock="gtk-home"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-indent"><input file stock="gtk-indent"></input></pixmap>
</hbox><hbox>
<pixmap icon_size="6" tooltip-text="gtk-index"><input file stock="gtk-index"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-info"><input file stock="gtk-info"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-italic"><input file stock="gtk-italic"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-jump-to"><input file stock="gtk-jump-to"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-justify-center"><input file stock="gtk-justify-center"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-justify-fill"><input file stock="gtk-justify-fill"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-justify-left"><input file stock="gtk-justify-left"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-justify-right"><input file stock="gtk-justify-right"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-leave-fullscreen"><input file stock="gtk-leave-fullscreen"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-media-forward"><input file stock="gtk-media-forward"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-media-next"><input file stock="gtk-media-next"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-media-pause"><input file stock="gtk-media-pause"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-media-play"><input file stock="gtk-media-play"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-media-previous"><input file stock="gtk-media-previous"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-media-record"><input file stock="gtk-media-record"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-media-rewind"><input file stock="gtk-media-rewind"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-media-stop"><input file stock="gtk-media-stop"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-missing-image"><input file stock="gtk-missing-image"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-network"><input file stock="gtk-network"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-new"><input file stock="gtk-new"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-no"><input file stock="gtk-no"></input></pixmap>
</hbox><hbox>
<pixmap icon_size="6" tooltip-text="gtk-ok"><input file stock="gtk-ok"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-open"><input file stock="gtk-open"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-orientation-landscape"><input file stock="gtk-orientation-landscape"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-orientation-portrait"><input file stock="gtk-orientation-portrait"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-orientation-reverse-landscape"><input file stock="gtk-orientation-reverse-landscape"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-orientation-reverse-portrait"><input file stock="gtk-orientation-reverse-portrait"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-page-setup"><input file stock="gtk-page-setup"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-paste"><input file stock="gtk-paste"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-preferences"><input file stock="gtk-preferences"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-print"><input file stock="gtk-print"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-print-error"><input file stock="gtk-print-error"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-print-paused"><input file stock="gtk-print-paused"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-print-preview"><input file stock="gtk-print-preview"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-print-report"><input file stock="gtk-print-report"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-print-warning"><input file stock="gtk-print-warning"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-properties"><input file stock="gtk-properties"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-quit"><input file stock="gtk-quit"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-redo"><input file stock="gtk-redo"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-refresh"><input file stock="gtk-refresh"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-remove"><input file stock="gtk-remove"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-revert-to-saved"><input file stock="gtk-revert-to-saved"></input></pixmap>
</hbox><hbox>
<pixmap icon_size="6" tooltip-text="gtk-save"><input file stock="gtk-save"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-save-as"><input file stock="gtk-save-as"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-select-all"><input file stock="gtk-select-all"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-select-color"><input file stock="gtk-select-color"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-select-font"><input file stock="gtk-select-font"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-sort-ascending"><input file stock="gtk-sort-ascending"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-sort-descending"><input file stock="gtk-sort-descending"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-spell-check"><input file stock="gtk-spell-check"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-stop"><input file stock="gtk-stop"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-strikethrough"><input file stock="gtk-strikethrough"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-undelete"><input file stock="gtk-undelete"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-underline"><input file stock="gtk-underline"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-undo"><input file stock="gtk-undo"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-yes"><input file stock="gtk-yes"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-unindent"><input file stock="gtk-unindent"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-zoom-100"><input file stock="gtk-zoom-100"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-zoom-fit"><input file stock="gtk-zoom-fit"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-zoom-in"><input file stock="gtk-zoom-in"></input></pixmap>
<pixmap icon_size="6" tooltip-text="gtk-zoom-out"><input file stock="gtk-zoom-out"></input></pixmap>
</hbox>
<button cancel></button>
</vbox>
'
gtkdialog3 --program=MAIN_DIALOG
- Attachments
-
- stock_icons.png
- (35.13 KiB) Downloaded 819 times
Check out my [url=https://github.com/technosaurus]github repositories[/url]. I may eventually get around to updating my [url=http://bashismal.blogspot.com]blogspot[/url].
Hi technosaurus.
running r241 in Slacko B1 and my pic is identical to yours, no need to post.
running r241 in Slacko B1 and my pic is identical to yours, no need to post.
Puppy Linux Blog - contact me for access
- BarryK
- Puppy Master
- Posts: 9392
- Joined: Mon 09 May 2005, 09:23
- Location: Perth, Western Australia
- Contact:
technosaurus,
Just tried it, yes, handy.
One point about missing gtk or gnome stock icons. if you put an icon of the appropriate name at /usr/share/icons, then gtk will use it even though it is missing from the theme -- and maybe this would work for missing gtk-builtin icons also.
For example, in Woof: rootfs-skeleton/usr/share/icons/gnome-stock-trash.xpm (doesn't have to be .png).
Just tried it, yes, handy.
One point about missing gtk or gnome stock icons. if you put an icon of the appropriate name at /usr/share/icons, then gtk will use it even though it is missing from the theme -- and maybe this would work for missing gtk-builtin icons also.
For example, in Woof: rootfs-skeleton/usr/share/icons/gnome-stock-trash.xpm (doesn't have to be .png).
[url]https://bkhome.org/news/[/url]
Thunor,
13.37... FWIW.. I booted my Slackware-13.37 install, did an svn update and the results are identical to my last Slacko results.
Cheers
ps, the pic is ok in slackware techno..
13.37... FWIW.. I booted my Slackware-13.37 install, did an svn update and the results are identical to my last Slacko results.
Cheers
ps, the pic is ok in slackware techno..
Puppy Linux Blog - contact me for access
ok, works perfect in Mageia-1
- Attachments
-
- mageia.png
- (75.29 KiB) Downloaded 692 times
Puppy Linux Blog - contact me for access
gtk+2.0-2.24.5-6.mga2.i586.rpmWhat is the version of GTK in Mageia-1?
Just a fancy theme I'd say.
technosaurus wrote:
This may be similar. I posted it in the tips thread a long time ago... Just something I keep handy to find the name of a stock icon... but could be useful
cute..but you can't drag them like ROX thumbnails.
Puppy Linux Blog - contact me for access
- thunor
- Posts: 350
- Joined: Thu 14 Oct 2010, 15:24
- Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings
- Contact:
01micko wrote:Ok, (with ltr appended?) these are missing:
gtk-dialog-authentication
gtk-dialog-error
gtk-dialog-info
gtk-dialog-question
gtk-dialog-warning
gtk-disacard (known issue)
gtk-info
gtk-new
gtk-save
I have the answers01micko wrote:13.37... FWIW.. I booted my Slackware-13.37 install, did an svn update and the results are identical to my last Slacko results.
You sent me /usr/include/gtk-2.0/gtk/gtkstock.h from Slacko beta 1 and I compared it to the version on my lupu-520 and it tells us that just because a stock ID might be gtk-new, it doesn't necessarily mean that that's the filename of the image:
Code: Select all
Stock ID Built-In Theme Icon Name
lupu-520 etc. Slacko beta 1
gtk-about "gtk-about.png" "help-about.png"
gtk-add "gtk-add.png" "list-add.png"
gtk-bold "gtk-bold.png" "format-text-bold.png"
gtk-cdrom "gtk-cdrom.png" "media-optical.png"
gtk-clear "gtk-clear.png" "edit-clear.png"
gtk-close "gtk-close.png" "window-close.png"
gtk-copy "gtk-copy.png" "edit-copy.png"
gtk-cut "gtk-cut.png" "edit-cut.png"
gtk-delete "gtk-delete.png" "edit-delete.png"
gtk-dialog-authentication "gtk-dialog-authentication.png" "dialog-password.png"
gtk-dialog-info "gtk-dialog-info.png" "dialog-information.png"
gtk-dialog-warning "gtk-dialog-warning.png" "dialog-warning.png"
gtk-dialog-error "gtk-dialog-error.png" "dialog-error.png"
gtk-dialog-question "gtk-dialog-question.png" "dialog-question.png"
gtk-directory "gtk-directory.png" "folder.png"
gtk-execute "gtk-execute.png" "system-run.png"
gtk-file "gtk-file.png" "document-x-generic.png"
gtk-find "gtk-find.png" "edit-find.png"
gtk-find-and-replace "gtk-find-and-replace.png" "edit-find-replace.png"
gtk-floppy "gtk-floppy.png" "media-floppy.png"
gtk-fullscreen "gtk-fullscreen.png" "view-fullscreen.png"
gtk-goto-bottom "gtk-goto-bottom.png" "go-bottom.png"
gtk-goto-first "gtk-goto-first-ltr.png" "go-first-ltr.png"
gtk-goto-first "gtk-goto-first-rtl.png" "go-first-rtl.png"
gtk-goto-last "gtk-goto-last-ltr.png" "go-last-ltr.png"
gtk-goto-last "gtk-goto-last-rtl.png" "go-last-rtl.png"
gtk-goto-top "gtk-goto-top.png" "go-top.png"
gtk-go-back "gtk-go-back-ltr.png" "go-previous-ltr.png"
gtk-go-back "gtk-go-back-rtl.png" "go-previous-rtl.png"
gtk-go-down "gtk-go-down.png" "go-down.png"
gtk-go-forward "gtk-go-forward-ltr.png" "go-next-ltr.png"
gtk-go-forward "gtk-go-forward-rtl.png" "go-next-rtl.png"
gtk-go-up "gtk-go-up.png" "go-up.png"
gtk-harddisk "gtk-harddisk.png" "drive-harddisk.png"
gtk-help "gtk-help.png" "help-contents.png"
gtk-home "gtk-home.png" "go-home.png"
gtk-info "gtk-info.png" "dialog-information.png"
gtk-italic "gtk-italic.png" "format-text-italic.png"
gtk-jump-to "gtk-jump-to-ltr.png" "go-jump-ltr.png"
gtk-jump-to "gtk-jump-to-rtl.png" "go-jump-rtl.png"
gtk-justify-center "gtk-justify-center.png" "format-justify-center.png"
gtk-justify-fill "gtk-justify-fill.png" "format-justify-fill.png"
gtk-justify-left "gtk-justify-left.png" "format-justify-left.png"
gtk-justify-right "gtk-justify-right.png" "format-justify-right.png"
gtk-leave-fullscreen "gtk-leave-fullscreen.png" "view-restore.png"
gtk-missing-image "gtk-missing-image.png" "image-missing.png"
gtk-media-forward "gtk-media-forward-ltr.png" "media-seek-forward-ltr.png"
gtk-media-forward "gtk-media-forward-rtl.png" "media-seek-forward-rtl.png"
gtk-media-next "gtk-media-next-ltr.png" "media-skip-forward-ltr.png"
gtk-media-next "gtk-media-next-rtl.png" "media-skip-forward-rtl.png"
gtk-media-pause "gtk-media-pause.png" "media-playback-pause.png"
gtk-media-play "gtk-media-play-ltr.png" "media-playback-start-ltr.png"
gtk-media-play "gtk-media-play-rtl.png" "media-playback-start-rtl.png"
gtk-media-previous "gtk-media-previous-ltr.png" "media-skip-backward-ltr.png"
gtk-media-previous "gtk-media-previous-rtl.png" "media-skip-backward-rtl.png"
gtk-media-record "gtk-media-record.png" "media-record.png"
gtk-media-rewind "gtk-media-rewind-ltr.png" "media-seek-backward-ltr.png"
gtk-media-rewind "gtk-media-rewind-rtl.png" "media-seek-backward-rtl.png"
gtk-media-stop "gtk-media-stop.png" "media-playback-stop.png"
gtk-network "gtk-network.png" "network-idle.png"
gtk-new "gtk-new.png" "document-new.png"
gtk-open "gtk-open.png" "document-open.png"
gtk-paste "gtk-paste.png" "edit-paste.png"
gtk-print "gtk-print.png" "document-print.png"
gtk-print-error "gtk-print-error.png" "printer-error.png"
gtk-print-paused "gtk-print-paused.png" "printer-paused.png"
gtk-print-preview "gtk-print-preview.png" "document-print-preview.png"
gtk-print-report "gtk-print-report.png" "printer-info.png"
gtk-print-warning "gtk-print-warning.png" "printer-warning.png"
gtk-properties "gtk-properties.png" "document-properties.png"
gtk-quit "gtk-quit.png" "application-exit.png"
gtk-redo "gtk-redo-ltr.png" "edit-redo-ltr.png"
gtk-redo "gtk-redo-rtl.png" "edit-redo-rtl.png"
gtk-refresh "gtk-refresh.png" "view-refresh.png"
gtk-remove "gtk-remove.png" "list-remove.png"
gtk-revert-to-saved "gtk-revert-to-saved-ltr.png" "document-revert-ltr.png"
gtk-revert-to-saved "gtk-revert-to-saved-rtl.png" "document-revert-rtl.png"
gtk-save "gtk-save.png" "document-save.png"
gtk-save-as "gtk-save-as.png" "document-save-as.png"
gtk-select-all "gtk-select-all.png" "edit-select-all.png"
gtk-sort-ascending "gtk-sort-ascending.png" "view-sort-ascending.png"
gtk-sort-descending "gtk-sort-descending.png" "view-sort-descending.png"
gtk-spell-check "gtk-spell-check.png" "tools-check-spelling.png"
gtk-stop "gtk-stop.png" "process-stop.png"
gtk-strikethrough "gtk-strikethrough.png" "format-text-strikethrough.png"
gtk-underline "gtk-underline.png" "format-text-underline.png"
gtk-undo "gtk-undo-ltr.png" "edit-undo-ltr.png"
gtk-undo "gtk-undo-rtl.png" "edit-undo-rtl.png"
gtk-unindent "gtk-unindent-ltr.png" "format-indent-less-ltr.png"
gtk-unindent "gtk-unindent-rtl.png" "format-indent-less-rtl.png"
gtk-zoom-100 "gtk-zoom-100.png" "zoom-original.png"
gtk-zoom-fit "gtk-zoom-fit.png" "zoom-fit-best.png"
gtk-zoom-in "gtk-zoom-in.png" "zoom-in.png"
gtk-zoom-out "gtk-zoom-out.png" "zoom-out.png"
Now, the information above creates another question as to why it is that you can't see all of them since none of the theme icon names are the same as the stock IDs! I'm going to hazard a guess that you have files called gtk-about.png/svg, gtk-add.png/svg etc. in one of the icon paths that GTK+ searches, or maybe they are defined in a theme file or something.
So then, stock IDs are static, theme icon names might change across GTK+ builds, /usr/include/gtk-2.0/gtk/gtkstock.h contains the answers.
The sensible thing to do would be to use stock="" to access the images using the stock IDs, and icon="" to access miscellaneous images from one of the icon paths that GTK+ searches.
Regards,
Thunor
- thunor
- Posts: 350
- Joined: Thu 14 Oct 2010, 15:24
- Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings
- Contact:
I'm currently working towards making a source package release and I'd like to change something I recently added:
I want to change the checkbox and radiobutton menuitems from saving "0/1" to a file to "true/false" to make them consistent with other toggling widgets that save to file.
I'll wait a while before I do it to give people the time to object
Regards,
Thunor
I want to change the checkbox and radiobutton menuitems from saving "0/1" to a file to "true/false" to make them consistent with other toggling widgets that save to file.
I'll wait a while before I do it to give people the time to object
Regards,
Thunor
- Dougal
- Posts: 2502
- Joined: Wed 19 Oct 2005, 13:06
- Location: Hell more grotesque than any medieval woodcut
Here's a modified version of technosaurus's example, which doesn't have the names hardcoded, so it doesn't need updating for different versions of gtk2...
Code: Select all
#!/bin/sh
MAIN_DIALOG='
<vbox><hbox>'
n=0
while read i ; do
MAIN_DIALOG="$MAIN_DIALOG
<pixmap icon_size=\"6\" tooltip-text=\"$i\"><input file stock=\"$i\"></input></pixmap> "
n=$((n+1))
if [ $((n%20)) -eq 0 ] ; then
MAIN_DIALOG="$MAIN_DIALOG
</hbox><hbox>"
fi
done <<_EOF
$(grep -F '#define GTK_STOCK' /usr/include/gtk-2.0/gtk/gtkstock.h | cut -d'"' -f2)
_EOF
export MAIN_DIALOG="$MAIN_DIALOG</hbox>
<button cancel></button>
</vbox>
"
gtkdialog3 --program=MAIN_DIALOG
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind
Some say your nose
Some say your toes
But I think it's your mind
- Dougal
- Posts: 2502
- Joined: Wed 19 Oct 2005, 13:06
- Location: Hell more grotesque than any medieval woodcut
Isn't the theme supposed to have also a symlink to it, with the proper stock name? Icon-themes are usually full of symlinks, as they don't have unique icons for everything, but need to support all the names.thunor wrote:Therefore you shouldn't assume that the theme icon name for gtk-dialog-authentication is going to be "gtk-dialog-authentication[.png]" because clearly on Slacko beta 1 it's "dialog-password[.png]".
What's the ugliest part of your body?
Some say your nose
Some say your toes
But I think it's your mind
Some say your nose
Some say your toes
But I think it's your mind
- thunor
- Posts: 350
- Joined: Thu 14 Oct 2010, 15:24
- Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings
- Contact:
Dougal
I think that there might be some confusion about what stock="" does and what icon="" does so I'll attempt to explain them:
<input file stock="gtk-new"></input> for example would load the image associated with the stock ID "gtk-new". It is a constant or a macro meant to hide the filename and also to deal with left-to-right and right-to-left variations of some images. Importantly the stock IDs do not change, they are not filenames, they are IDs and the images are possibly compiled-in.
<input file icon="gnumeric"></input> for example would load the file "gnumeric.png/svg/etc." from the current icon theme wherever that is located. My GTK+ 2 Crux theme has an IconTheme=Crux set but there's no such set of icons on my computer so GTK+ searches a default set of paths which results in "/usr/share/icons/hicolor/16x16/apps/gnumeric.png" being loaded. Importantly these are filenames minus the path and extension.
There is not going to be an issue using <input file stock="gtk-new"></input> across GTK+ builds because "gtk-new" here is an ID hiding the filename of the originating image, but there will be if you use <input file icon="gtk-new"></input> because in this case "gtk-new" is a filename.
What's been happening is that <input file icon="gtk-new"></input> has been used and it mostly worked because the originating filenames of the built-in images are mostly identical to the stock IDs (GTK+ apparently also counts built-in stock images as theme images) but on Slacko beta 1 the originating filenames of the built-in images are NOT the same as the stock IDs therefore "gtk-new" wouldn't be found as a theme icon UNLESS it does physically exist as a file somewhere within the paths GTK+ searches for theme icons.
Simply put, stock="" is for unchanging stock IDs, icon="" is for filenames [minus the path and extension] representing icons from the current theme and also within the default paths GTK+ searches for theme icons.
For the record, these are the [likely default] paths GTK+ is searching for theme icons on my lupu-520 (gtk_icon_theme_get_search_path() was used):
Regards,
Thunor
I think that there might be some confusion about what stock="" does and what icon="" does so I'll attempt to explain them:
<input file stock="gtk-new"></input> for example would load the image associated with the stock ID "gtk-new". It is a constant or a macro meant to hide the filename and also to deal with left-to-right and right-to-left variations of some images. Importantly the stock IDs do not change, they are not filenames, they are IDs and the images are possibly compiled-in.
<input file icon="gnumeric"></input> for example would load the file "gnumeric.png/svg/etc." from the current icon theme wherever that is located. My GTK+ 2 Crux theme has an IconTheme=Crux set but there's no such set of icons on my computer so GTK+ searches a default set of paths which results in "/usr/share/icons/hicolor/16x16/apps/gnumeric.png" being loaded. Importantly these are filenames minus the path and extension.
There is not going to be an issue using <input file stock="gtk-new"></input> across GTK+ builds because "gtk-new" here is an ID hiding the filename of the originating image, but there will be if you use <input file icon="gtk-new"></input> because in this case "gtk-new" is a filename.
What's been happening is that <input file icon="gtk-new"></input> has been used and it mostly worked because the originating filenames of the built-in images are mostly identical to the stock IDs (GTK+ apparently also counts built-in stock images as theme images) but on Slacko beta 1 the originating filenames of the built-in images are NOT the same as the stock IDs therefore "gtk-new" wouldn't be found as a theme icon UNLESS it does physically exist as a file somewhere within the paths GTK+ searches for theme icons.
Simply put, stock="" is for unchanging stock IDs, icon="" is for filenames [minus the path and extension] representing icons from the current theme and also within the default paths GTK+ searches for theme icons.
For the record, these are the [likely default] paths GTK+ is searching for theme icons on my lupu-520 (gtk_icon_theme_get_search_path() was used):
- /root/.icons
- /root/.local/share/icons
- /usr/share/icons
- /usr/local/share/icons -> ../lib/X11/mini-icons
- /usr/share/pixmaps
- /usr/local/share/pixmaps
Regards,
Thunor
Last edited by thunor on Sun 28 Aug 2011, 22:23, edited 2 times in total.
- thunor
- Posts: 350
- Joined: Thu 14 Oct 2010, 15:24
- Location: Minas Tirith, in the Pelennor Fields fighting the Easterlings
- Contact:
ExecuteDougal wrote:Isn't the theme supposed to have also a symlink to it, with the proper stock name? Icon-themes are usually full of symlinks, as they don't have unique icons for everything, but need to support all the names.
Code: Select all
find /usr -name "gtk-*[ps][nv]g"
Regards,
Thunor