Edit context menu icon in Cinnamon
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Edit context menu icon in Cinnamon
Hi all,
I would like to customise context menu shown upon right click on desktop. In my case there is very large icon for Open as root action, which I'd like to fix.
I would like to customise context menu shown upon right click on desktop. In my case there is very large icon for Open as root action, which I'd like to fix.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
- smurphos
- Level 18
- Posts: 8501
- Joined: Fri Sep 05, 2014 12:18 am
- Location: Irish Brit in Portugal
- Contact:
Re: Edit context menu icon in Cinnamon
Hi,
I think this is a display bug / icon theme issue - if only because I see it rarely too with some icon themes.
Try going to Settings/Themes/Settings and toggling show icons on menus off. Restart cinnamon by pressing Ctrl-Alt-Esc. Toggle show icons on menus back on. Check if that's fixed it. If not try restarting Cinnamon again with Ctrl-Alt-Esc. If that still not working do the same thing but also include switching temporarily to a different icon theme in the Themes setting module.
I think this is a display bug / icon theme issue - if only because I see it rarely too with some icon themes.
Try going to Settings/Themes/Settings and toggling show icons on menus off. Restart cinnamon by pressing Ctrl-Alt-Esc. Toggle show icons on menus back on. Check if that's fixed it. If not try restarting Cinnamon again with Ctrl-Alt-Esc. If that still not working do the same thing but also include switching temporarily to a different icon theme in the Themes setting module.
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
- smurphos
- Level 18
- Posts: 8501
- Joined: Fri Sep 05, 2014 12:18 am
- Location: Irish Brit in Portugal
- Contact:
Re: Edit context menu icon in Cinnamon
What icon theme are you using?
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
- smurphos
- Level 18
- Posts: 8501
- Joined: Fri Sep 05, 2014 12:18 am
- Location: Irish Brit in Portugal
- Contact:
Re: Edit context menu icon in Cinnamon
What happens if you switch to Mint X or Mint Y as an icon theme?
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
Re: Edit context menu icon in Cinnamon
With Mint X everything is OK.
EDIT: It seems some of Sard-* icons are somehow invalid. I tested few of these and some of them give that big picture issue.
EDIT: It seems some of Sard-* icons are somehow invalid. I tested few of these and some of them give that big picture issue.
- smurphos
- Level 18
- Posts: 8501
- Joined: Fri Sep 05, 2014 12:18 am
- Location: Irish Brit in Portugal
- Contact:
Re: Edit context menu icon in Cinnamon
Icon themes can be quite complex and the Sardi family take that complexity to a somewhat ridiculous level .
I did a bit of messing around with them this morning and couldn't reproduce the issue on the desktop right click, but could on the nemo right-click menu.
That particular sardi variant doesn't have it's own version of
Easiest fix it to add Mint-Y and Mint-X into the themes inherits list in it's Index.theme file.
Use the command
I did a bit of messing around with them this morning and couldn't reproduce the issue on the desktop right click, but could on the nemo right-click menu.
That particular sardi variant doesn't have it's own version of
gtk-dialog-authentication.*
which is the name of the icon used for Open as Root in the menu. Some of the other sardi variants do have it. On my system it ends up inheriting from the Faba theme via Moka (i've got Pocillo / Moka / Faba installed nicked from the Ubuntu 18.04 repos). Unfortunately, it appears the Faba version of this icon isn't scalable or has problems scaling...I'm not sure where the icon you are seeing is coming from but it clearly has a similar issue.Easiest fix it to add Mint-Y and Mint-X into the themes inherits list in it's Index.theme file.
Use the command
xed ~/.icons/Sardi-Ghost-Flexible-Vertexed/index.theme
to open it in your text editor and then add as below. You may need to modify exactly where in the list you place them depending on which icon themes you have available and where the icon you can see is being drawn from.Code: Select all
[Icon Theme]
Name=Sardi Ghost Flexible Vertexed
Comment=Simple and flat icon theme with long shadow
Inherits=Sardi-Ghost-Flexible,Sardi,Numix-Circle,Numix,Papirus,Mint-Y,Mint-X,Moka,Surfn,breeze,gnome,hicolor
<snipped the rest>
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
Re: Edit context menu icon in Cinnamon
But I want to add custom icons in the context menu. I'm using a nemo action on right click. The action is Open in vs code. The action is working fine but I want to add a vs code icon to the left of the action.
Currently, my script looks like this:
Also, where are all the icons and their names located?
Currently, my script looks like this:
Code: Select all
[Nemo Action]
Name=Open in VS Code
Comment=Open a folder in VS Code.
Exec=code %P
Selection=any;
Extensions=any;
Icon-Name= ?????
Dependencies=code;
- smurphos
- Level 18
- Posts: 8501
- Joined: Fri Sep 05, 2014 12:18 am
- Location: Irish Brit in Portugal
- Contact:
Re: Edit context menu icon in Cinnamon
Try
com.visualstudio.code
as the icon name.Most icons are in there respective icon themes folders in
/usr/share/icons
. hicolor is the default fallback theme so a lots of applications will add there icons to hicolor, but others also use /usr/share/pixmaps
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.