9

I just installed the clipboard manager Diodon.

sudo add-apt-repository ppa:diodon-team/stable
sudo apt-get update
sudo apt-get install diodon

By default, it uses a dark gtk-paste icon when I use the Faenza-Dark icon theme.

enter image description here

Instead, I want it to use the gtk-paste icon from the Faenza-Darkest icon theme. enter image description here

But rather than replace the icon inside the theme, how can I simply tell Diodon to use X icon instead? I've read all suggested questions before posting this, but they lean more towards replacing the icon rather than telling it to use different one.

Alan
  • 2,770
  • Your comment below "replacing that icon it would replace it system-wide, meaning all applications that call for the gtk-paste icon would use the light (white) one" clarified that you only want to change the gtk-paste icon in the app-indicator tray but use the original icon in other places (application toolbars). I thought you just wanted to avoid editing system files. – idbrii May 06 '11 at 19:27
  • For anyone wondering, you can determine that diodon uses gtk-paste from diodon's desktop file. For another application, look for its desktop file in /usr/share/applications. (ex: /usr/share/applications/diodon.desktop)

    If that exists, look for the line that says Icon=. If it says something like Icon=gtk-paste, then you can change your icon theme to change the icon used. If it says something like Icon=/usr/share/icons/diodon/diodon.png (a file path), then you have to edit diodon.desktop to change the icon, but your change may be overwritten whenever you do an update.

    – idbrii May 13 '11 at 17:21

4 Answers4

9

I think you have four options:

  1. Use the Faenza-Darkest icon theme. (Is there a reason to not do this?)
  2. Replace the icon (which you don't want to do).
  3. Edit the app's configuration to change the icon.
  4. Make your own lightweight icon theme to set your desired icon.

Edit the app's configuration to change the icon

Edit /usr/share/applications/diodon.desktop and change Icon=gtk-paste to Icon=/usr/share/icons/Faenza-Darkest/actions/22/gtk-paste.png

Note that editing system files is generally a bad idea. You might be able to copy diodon.desktop to ~/.local/share/applications/diodon.desktop and then edit it. I'm not sure if that would work.

Make your own lightweight icon theme to set your desired icon

This is probably the best solution, but it's a little trickier. (See also this more thorough description for creating lightweight icon themes.)

Run this from a Terminal:

# Create a new theme containing the icon we want
mkdir -p ~/.icons/Faenza-Alan/actions/22
ln -s /usr/share/icons/Faenza-Darkest/actions/22/gtk-paste.png ~/.icons/Faenza-Alan/actions/22/.
# Copy the theme config and modify it for our new theme
cp /usr/share/icons/Faenza-Darkest/index.theme ~/.icons/Faenza-Alan/.
sed -i -e "s/Inherits=/Inherits=Faenza-Dark,/g" ~/.icons/Faenza-Alan/index.theme
sed -i -e "s/Faenza-Darkest/Faenza-Alan/g" ~/.icons/Faenza-Alan/index.theme

Now open Appearance and change your icon theme to Faenza-Alan.

Now your new theme will persist regardless of system upgrades. (Unless Faenza removes the gtk-paste.png icon. If you're worried about that, use cp instead of ln -s. But you won't get updates to the icon.)

My Faenza-Alan looks like this: Faenza-Alan's app-indicators and back/forward and the paste icon in gedit

In testing this, I see that it's probably a bug that Faenza uses a light app-indicator icon for any of the dark themes. Anyone know where you can file a bug?

idbrii
  • 3,162
  • Note: You could also do this without the sed steps by overriding Faenza-Dark instead of creating a new Faenza-Alan theme, but this way you can clearly see the difference between Faenza-Dark and Faenza-Alan. – idbrii May 05 '11 at 23:34
  • I did all of the above for myself so I could use this or this icon. – idbrii May 05 '11 at 23:39
  • Hi pydave, thanks for taking all that time to look into this!

    The reason I don't use Faenza-Darkest, is because it makes most all icons white (e.g, stop, reload, back, forward), and since I'm using the Orta theme, white-on-white is very hard to see. I tried editing the applications configuration file, to no avail. Looks like I'm stuck. Unfortunately there is no where I know of to file a bug, the creator hosted it on Deviant Art, but is no longer active.

    Sure wish there was another mono-theme out there with as many icons as Faenza.

    – Alan May 06 '11 at 00:27
  • it sounds to me like you should be using the "Actions" folder from Faenza and the "Status" folder from Faenza-dark – Leron May 06 '11 at 00:35
  • @Alan: Did you try the last option? (Make your own lightweight icon theme). I'll add a screenshot of what it looks like to me. – idbrii May 06 '11 at 19:16
  • @Alan: I think I better understand what you're looking for. How does the image look to you now? – idbrii May 06 '11 at 19:28
  • That looks great! Could you by chance, attach a section of a screenshot, showing the nautilus navigation buttons? Those are what appear white when I try it. But it does look like what I want to achieve. – Alan May 06 '11 at 20:12
  • Nautilus is the window with the title "bin" (I'm in /bin) that shows the Back/Forward buttons. – idbrii May 06 '11 at 20:22
  • Well that worked out just fine! The icon is as it appears in your screen-shot, and everything else appears to look normal. Although this doesn't solve solve the initial question of how to change the icon of an indicator, it does achieve exactly what I wanted. Awesome, thank you for all of the time you put into this!!! – Alan May 07 '11 at 01:21
2

Go to /usr/share/icons/Faenza-Darkest/actions/22 and copy gtk-paste.png.

Paste it in /usr/share/icons/Faenza/actions/22/

That will simply put a different icon from where the themes pulls from.

  • I looked in the Faenze-Dark actions folder and didn't see a gtk-paste.png so I bet Feanza dark uses the same icon as regular Faenza. – winchendonsprings May 05 '11 at 00:56
  • Hi. Yes, Faenza Dark uses the same gtk-paste icon from Faenza. But I want to avoid replacing the icon, so it doesn't affect anything but the applet. – Alan May 05 '11 at 01:42
  • hmm, I'm not sure there's another way to replace the one .png for just one case. You could dig through your theme and try to adjust where applets pull icons from, but I don't know that would work. I always just make a link and rename the original if I want to change an icon. – winchendonsprings May 05 '11 at 02:11
  • When you say adjust where the applet pulls icons from, do you mean the index.theme file? Also, I made a little discovery, in the Diodon configuration file it has a line that says: gtk-paste. But changing that doesn't affect the icon for some reason...hmm... – Alan May 05 '11 at 03:02
  • I upvoted because I've been down this road many times with Faenza and Awoken. If you look at the preferences.ui script it just calls for gtk-paste. Now it's up to your icon theme. When I swapped out Awoken icons I made a back up. Lets say go to Fanzea and rename it to gtk-paste-old.png and copy the gtk-paste.png from Darkest. – wojox May 05 '11 at 03:08
  • Hi wokjox. That seems to be my only option now I guess, but by replacing that icon it would replace it system-wide, meaning all applications that call for the gtk-paste icon would use the light (white) one, and since I'm using the Orta theme, it would be very hard to see it. – Alan May 05 '11 at 03:24
  • Yes, I do exactly what @wojox says. I rename the original icon as a backup. essentially what you want to do is have your theme pull in icons from two separate icon sets, I haven't got a clue how to do it. sorry – winchendonsprings May 05 '11 at 04:39
  • It's definitely not a simple procedure. At least until more themes/icons become compatible. It won't make it system wide. It will only be specific to that icon theme. : ) – wojox May 05 '11 at 04:56
2

I looked into diodon source and it just takes the icon from gtk-paste, but if that icon was white in Faenza-Dark it would not fit in Equinox's toolbars, which is the reason why it was first created.

A way around would be modifying diodon's source so it would use something like "gtk-paste-panel", if "gtk-paste-panel" is not available try "gtk-paste". After that add "gtk-paste-panel" icon to Faenza.

You can ask that to the diodon team at launchpad. It would be a nice enhancement.

1

Go into ~/.icons Then find the icon theme you're using, go into the Status folder and add the desired icon to each of the sizes.

That way you're not replacing it in the theme. You're instead using it in your current icon set

Leron
  • 1,660
  • Hi Leron. Unfortunately, I've already tried this, and for some reason, Diodon still calls for the icon from the theme. This sure is confusing. – Alan May 06 '11 at 00:30