Bug 377733

Summary: gnome file-chooser displays wrong icons
Product: [openSUSE] openSUSE 11.0 Reporter: Dean Sawash <munkiiboi>
Component: GNOMEAssignee: Federico Mena Quintero <federico>
Status: RESOLVED WONTFIX QA Contact: E-mail List <qa-bugs>
Severity: Major    
Priority: P2 - High CC: kontakt, vuntz
Version: Alpha 3   
Target Milestone: ---   
Hardware: Other   
OS: openSUSE 11.0   
Whiteboard: gnome-wrong-out-of-the-box
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Bug Depends on:    
Bug Blocks: 338003    
Attachments: file-chooser being stupid
file chooser, gnome-vfs backend
First attempt to fix this

Description Dean Sawash 2008-04-07 20:36:55 UTC
Created attachment 206586 [details]
file-chooser being stupid

file-chooser doesn't use current icon theme in gnome, see screenshot..
Comment 1 Federico Mena Quintero 2008-04-08 00:54:43 UTC
The upstream bug for this could be http://bugzilla.gnome.org/show_bug.cgi?id=526190 but I'm not 100% sure.
Comment 2 Dean Sawash 2008-04-08 01:39:12 UTC
this seems like the reverse or what i'm experiencing, MIME icons seem to look alright, while folders and drivers use wrong icons here - looks like it's going to take a long time to fix since nobody has a clue of what's going on.. =S
Comment 3 Dean Sawash 2008-04-30 19:43:00 UTC
Created attachment 211627 [details]
file chooser, gnome-vfs backend
Comment 4 Dean Sawash 2008-04-30 19:46:45 UTC
ok, the problem might be with the gio backend, i switched to gnome-vfs and i got a better looking icons, except for thumbnails, they don't get rendered at all, see screenshot
Comment 5 Vincent Untz 2008-04-30 21:11:30 UTC
Created attachment 211644 [details]
First attempt to fix this

Federico, here's an attempt to fix this. Basically, gio gives us a list of icon and right now, only the first one is used. However, the first icon is the most specific one and generally doesn't exist in icon themes.

So we can use gtk_icon_theme_choose_icon() instead.

However, this patch is broken in a few ways:

 + it's hard-coding the icon size to 16
 + it's giving the icon path instead of the icon name to the upper layers, which means no update when the icon theme changes
 + in an ideal world, we'd pass the array of icon names to the upper layers so that when changing an icon theme, we look for the best icon again among all icon names (and we might find a better one this way in the new icon theme).

First item should be easily fixable. Second item doesn't seem to be fixable since GtkIconInfo doesn't contain the icon name :/ Third item needs quite some work.

(btw, Federico, I'd love to get set_icon_names() functions complementing the set_icon_name() ones)
Comment 6 Federico Mena Quintero 2009-06-19 21:25:12 UTC
Marking as WONTFIX; this is obsolete now that the gio backend is fully folded into GTK+.