Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to change the icon for application/x-hwp files. I've added the icons to the proper places, and checked it with assoGiate (after reading this thread). It shows that my desired icon is associated with the file type. Nevertheless, Nautilus is still showing the old icon. How can I make Nautilus show the correct icon?

share|improve this question
@Rinzwind: Thanks. Unfortunately, that link solves a different problem. It's based on changing the icons of individual files. I want to change the default icon for all files of a given type. – Scott Severance Jul 7 '11 at 13:47
Are you using a custom icon theme? That could be interfering with the icon that is supposed to show up. – RBurgundy Jul 7 '11 at 19:23
I'm using the stock Ambiance theme. Anyway, it shouldn't matter, because to my knowledge no icon themes cover this file type. I'm just getting the icon that appears by default when Nautilus doesn't know what other icon to display. Additionally, icon themes are hierarchical, so if an appropriate icon can't be found in the current theme, the hierarchy will be searched, ultimately culminating with the hicolor theme. My icons are installed in both the ubuntu0mono-dark and hicolor themes. – Scott Severance Jul 7 '11 at 23:42

Here is a set of instructions that should get you a custom icon for hwp files.

Open a terminal :

  • Check the MIME type exists : grep 'hwp' /etc/mime.types

    if you get an output resembling application/x-hwp hwp skip the next step.

  • Create the MIME type sudo -H gedit /etc/mime.types and add the line application/x-hwp hwp

  • Add the icon (which must be called application-x-hwp.svg):

    sudo cp PathToIcon/application-x-hwp.svg /usr/share/icons/gnome/scalable/mimetypes

    (don't forget to replace PathToIcon)

Got the information from here

share|improve this answer
Thanks for the suggestion. I haven't had a chance to try it thoroughly yet (so far, no success), but I'm awarding the bounty because the other suggestions haven't worked and I won't have a chance to work on this any more before the bounty expires. – Scott Severance Aug 14 '11 at 15:22
You maybe should check if your icon theme inherits from gnome (most icon themes do). You will find that information in index.theme located in the directory of your icon set – danjjl Aug 14 '11 at 16:03

I hope you tried logout and login to refresh icon cache.

See also if your icon is available in proper size (the one you're using to display file type in nautilus).

You also might missed running gtk-update-icon-cache.

Try this tutorial:

Try to manually create icon.theme, here is an example I have from awn:

[Icon Theme]



Manual is here:

share|improve this answer
I've installed a 48x48 icon and set Nautilus to 100%, which uses 48x48. No dice. Re-logging in makes no difference. Running gtk-update-icon-cache has no effect. – Scott Severance Aug 8 '11 at 8:16
I updated my answer, did it help? – Krzysztof Hasiński Aug 8 '11 at 16:21
I haven't manually created an icon theme, because I don't want a new theme. I just want the icon to go into the hicolor theme, because that's the base of all the icon themes. Creating a new theme will defeat my purpose. – Scott Severance Aug 11 '11 at 3:58


 sudo apt-get install assogiate

follow this good tutorial with nice pictures


If file type is not detected correctly, or showing incorrect file type find your file type identifying characters

EX: rar go to

identifier "Hex: 52 61 72 21 1A 07 00 , ASCII: Rar!"

open file in a bless or any hex editor and find the identifier and offset (where your keywords starts)

in our case it the firs bit so offset is "0".

Then go "File types Editor" edit or make a new item, then select edit and under file contents

select "string" from drop down, input "Rar!" and set offset "0".


share|improve this answer
As I noted in my original question, assogiate doesn't work. – Scott Severance Aug 1 '12 at 14:02

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.