Change icon size

Asked by splashis

any way to change the icon size in Cardapio?

Thanks for this great software. !

Question information

English Edit question
Cardapio Edit question
No assignee Edit question
Solved by:
Thiago Teixeira
Last query:
Last reply:
Revision history for this message
Jan (jancborchardt-deactivatedaccount) said :

Yes, there is if you modify the code yourself (actually pretty easy).
Open the terminal and type:
bzr clone lp:cardapio

Then go into cardapio/src/ and open, where you need to change the following lines:
606 self.icon_size_app = gtk.icon_size_lookup(gtk.ICON_SIZE_LARGE_TOOLBAR)[0]
607 self.icon_size_category = gtk.icon_size_lookup(gtk.ICON_SIZE_MENU)[0]

Into something like this:
606 self.icon_size_app = gtk.icon_size_lookup(gtk.ICON_SIZE_LARGE_TOOLBAR)[0]*2
607 self.icon_size_category = gtk.icon_size_lookup(gtk.ICON_SIZE_MENU)[0]*2

I simply added 2 as a factor to double the size of both the app and category icons.

Then you need to install it by going back to the terminal and typing:
cd cardapio
sudo make install

And finally, restart the panel by typing:
killall gnome-panel


(And if that would be your next question: I don’t think that changing them via graphical interface will be implemented because the icons are using standard icon sizes as defined by the system, namely »gtk.ICON_SIZE_LARGE_TOOLBAR« and »gtk.ICON_SIZE_MENU«.)

Revision history for this message
Best Thiago Teixeira (tvst) said :

Here's an easier way: just edit your ~/.gtkrc-2.0

1) Open GEdit and paste this text into it

gtk-icon-sizes = "gtk-large-toolbar=16,16:gtk-menu=16,16"

2) Save as ~/.gtkrc-2.0
3) Restart Cardapio



1) This will change the toolbar and menu icon sizes in all your GTK applications)

2) Because of a bug in Gtk, this may not work depending on which theme you use. That is, if the theme *already* sets the gtk-icon-sizes variable in it, then that line in your gtkrc-2.0 will be ignored.

The solution, in that case, is to remove the offending line from the theme. You can usually find the theme file at either
    - or -

Revision history for this message
splashis (splashote) said :

Great, thank you.

Revision history for this message
splashis (splashote) said :

Thanks tvst, that solved my question.