sakithb / media-controls

A media indicator for the Gnome shell.
MIT License
236 stars 36 forks source link

[Feature request] Make track label scroll if wider than max widget width #58

Closed t-aus-m closed 11 months ago

t-aus-m commented 2 years ago

I just recently stumbled upon this shell extension and so far I really like it!

Only one thing I found to be missing: It seems like this shell extension does not really handle track labels that are wider than the max widget width. If this occurs the label is just cut to size and therefore not fully readable, which is a shame.

There is an extension for macOS that does similar things to this shell extension personally I really like the way it handles wide track labels. I asked a friend of mine to make a screen recording of it to visualize how an implementation could work:

https://user-images.githubusercontent.com/12219297/152526725-9b9b1f0b-7af1-4965-bcc4-d98370430c98.mov

Would it be a consideration to implement this?

bdaase commented 2 years ago

FWIW, as a workaround, you can set the max width to 0 and shouldn't experience any cut off.

ChrisLauinger77 commented 12 months ago

Could be helpful: https://blog.hubspot.com/website/scrolling-text-css#how-to-create-scrolling-text-css

https://gjs.guide/extensions/upgrading/gnome-shell-45.html#misc-animationutils

https://gitlab.gnome.org/GNOME/gnome-shell/-/blob/main/js/misc/animationUtils.js

sakithb commented 11 months ago

61f9d80 @ChrisLauinger77 , I've completed this after jumping through many hoops 😄. I feel like there is a better way to do this, but we can work on that in a later version. For now we just have to add an option to enable scrolling.

ChrisLauinger77 commented 11 months ago

@sakithb cool Want me to add the option or wanna do it yourself ? I test it on gnome45 now ...

sakithb commented 11 months ago

If it's not too much trouble, sure

ChrisLauinger77 commented 11 months ago

No I can do it very quick. I do it in main and you can overtake it to dev-leg

sakithb commented 11 months ago

Sure

ChrisLauinger77 commented 11 months ago

Have it working on gnome45. Now I add the setting...

ChrisLauinger77 commented 11 months ago

@sakithb settings for scrolling is checked into main including german translations updated this._extension.scrolltracklabel in main (settings in widget) this._extension.settings.scrolltracklabel in legacy (settings in own file)

some changes by hand are nec I am afraid - cherry pick can only partly work

sakithb commented 11 months ago

It's alright, were you able to get the setting to work?

ChrisLauinger77 commented 11 months ago

Yes in main it works I uploaded also a new screenshot

ChrisLauinger77 commented 11 months ago

https://github.com/sakithb/media-controls/blob/main/images/Screenshot_settings_page1.png

ChrisLauinger77 commented 11 months ago

Ah one more thing - the clip texts in track info menu is not in gnome44. I thought gnome44 only bugfixes so new features which I implemented are only in main.

sakithb commented 11 months ago

We'll do new features for gnome 44 for this release only. Can you give me a list of new features you added in main, so I can post them to gnome44.

ChrisLauinger77 commented 11 months ago

The only new feature which is in main but not gnome44 is the clipping texts. It was not really much a new settings a new function in utils which called 2 times out of player.

ChrisLauinger77 commented 11 months ago

I forgot the Hotkey to open the media info panel. This I also added only in 45.