klangman / CassiaWindowList

A WindowList/PanelLauncher applet for the Cinnamon desktop environment
https://cinnamon-spices.linuxmint.com/applets/view/372
GNU General Public License v3.0
13 stars 1 forks source link

Pinned buttons margin/padding settings #5

Closed junglized closed 10 months ago

junglized commented 10 months ago

Hello,

I was wondering, would it be possible to add margin and/or padding settings for pinned items? At the current pinned items feel a little bit cramped in the panel. I found relevant variable in applet's js files but everytime I make a change it's lost after an update. Of course only if that's wouldn't take too much work, I fully understand everyone has their own lives and you develop this applet in your own free time and for free.

Thank you very much for your time and effort you put into this applet so far! 🤍

PS: the relevant setting is in applet.js file, line 1044. I change this._iconBox = new St.Group({style: 'border:0px;padding:0px;margin:0px'}); to this._iconBox = new St.Group({style: 'border:0px;padding:0px;margin:0px 2px'});

klangman commented 10 months ago

Another user asked for the same option.. My response has been that this spacing is really a property of the theme, but I guess it's something that a number of users want control over.

Your suggested change would add space on both sides of the icon for all buttons not just pinned buttons, your issue title suggests you only wanted it to apply to pinned buttons?

Also, it would look strange when the user has labels enabled since it would add a 2 px buffer between the icon and it's label I think.

I'll look into how I could add a generic window-list button spacing that looks proper in different themes. If I can getting something that doesn't mess up the look of different themes then I will add an option for it.

Thanks for the feedback. It's always nice to know that people are actually using the applet.

klangman commented 10 months ago

Maybe I now understand why you are talking about pinned buttons in particular. Normal buttons with labels you can control the spacing using the "label width" setting in the configuration, but for pinned buttons without labels you have no control over spacing. Maybe it makes sense to allow the user to add some spacing to the left of the icon and to the right of the label (a 0-width label is there even when there is no text).

I added this commit: https://github.com/klangman/CassiaWindowList/commit/6bdb1a3714eb7a6d2e89c158843f89beca965222

Does this achieve what you were hoping for?

wpwpwpwpw commented 10 months ago

Hi! What is the name of the setting? I updated the applet to this commit, but I can't find the option. Thanks!

EDIT: nevermind. I didn't update my repository. Now I see the option. Seems to be working very well! Thank you again!

junglized commented 10 months ago

@klangman

You managed to add a feature I had in mind even without me putiing myself clear enough. Yes, I meant pinned buttons without labels. I don't use lables, buttons are the cleanest visually IMHO.

Thank you very much for your time and effort!

PS, I changed issue title for more appriopriate one.