How to : Change an icon in 16.04 [duplicate]

Is it possible to replace a particular icon with one of our choice in 16.04 Ubuntu ? If yes, kindly share.


How to change the icon of a Unity Launcher:

Unity Launchers are files stored in your computer, with a .desktop extension. These files are used to launch a specific application, but in Unity they are also used so as to create right-click menus for each application, which you can access from the Unity Launcher.

Such file looks something like this:

[Desktop Entry]
Version=x.y
Name=ProgramName
Comment=This is my comment
Exec=/home/$USER/Documents/exec.sh
Icon=/home/$USER/Pictures/icon.png
Terminal=false
Type=Application
Categories=Utility;Application;

Icon field is the icon that should be used by the launcher and represents the application. All icons that are under the directory /usr/share/pixmaps don't need to have their full path specified, but their filename without the extension.

For example, if the icon file is /usr/share/pixmaps/wallch.png, then the Icon field should be just wallch. All other icons should have their full path specified.


Therefore, in order to change the icon for a specific program, you need to:

1. Find the related .desktop file, they are commonly under /usr/share/....

You can do so with:

locate program_name.desktop

or if you can't seem to find it:

locate .desktop

and scroll through the list.

2. Open the .desktop you want to modify:

gedit /path/to/program_name.desktop

3. Modify any of the fields you wish:

Just to be save, make a backup first, which you can replace for the original file in case you screw up:

cp /path/to/program_name.desktop /path/to/program_name_backup

Source and further information:

https://help.ubuntu.com/community/UnityLaunchersAndDesktopFiles