plasmusic-toolbar icon indicating copy to clipboard operation
plasmusic-toolbar copied to clipboard

request for option to turn off album cover

Open Azosion opened this issue 10 months ago • 12 comments

Request for option to turn off the album cover

Hello,

I've tried to do this myself, but I am very inexperienced in qml, and my code is of very poor quality (I had to hard code much of the scale to my liking, so it definitety doesn't look good on all systems). Here are some screenshots

What it looks like in my taskbar Image

What it looks like on my desktop Image

you can find my code on my fork https://github.com/Azosion/plasmusic-toolbar

P.S

I am quite new to both qml and open source software, so I apologize for any mistake I might have made while creating this request.

Thanks

Azosion avatar Feb 14 '25 01:02 Azosion

Hi @Azosion, thanks for your suggestion. I'm quite busy right now, and I've been working on other features lately so I don't know when I can work on this.

ccatterina avatar Feb 15 '25 16:02 ccatterina

Hello @ccatterina, Thanks for the quick reply, What I have set up right now works perfectly fine for me right now, so feel free to put this request as low down on your priorities list as you want.

Thanks,

Azosion avatar Feb 15 '25 22:02 Azosion

Hello @ccatterina, I've decided to try this again since I am now a bit more experienced in qml, so I've been able to get everything working much better (and cleaner) than before, but I am stuck on how to reduce the height of the widget itself, do you know what controls the height?

Size I have:

Image

Size I want:

Image

(I want to half the height)

Thanks,

Azosion avatar May 07 '25 00:05 Azosion

hi @Azosion , that's strange, the height of the widget in the full representation should adapt to the content of the widget. Can you link a branch with your changes?

ccatterina avatar May 08 '25 16:05 ccatterina

hi @ccatterina , my changes are pretty minimal, here is the branch, the thing turning off album cover is "visible: togglealbum" in rectangle (which is self-evident I guess). I thought that "rectangle" might be not visible, but still affecting the sizing, but I don't really know, because the text is aligned properly, and when I change the width & height of rectangle, the widget is still the same height, so I don't really know.

Azosion avatar May 08 '25 17:05 Azosion

👍 I'll take a look at it tomorrow and let you know

ccatterina avatar May 08 '25 19:05 ccatterina

Hi @Azosion, I tried your branch, there are some little things to adjust, like the configuration button that should be a checkbox or some styling details, but the widget's height seems correct. This is how it looks on my PC:

Image

Could it be that maybe you changed the size of the widget manually?

Image

ccatterina avatar May 09 '25 15:05 ccatterina

Hello @ccatterina, I didn't really articulate this well, but the issue I'm having is that when toggling the album cover, the width of the widget gets adjusted, but not the height, which just feels wrong. If possible I would like to fix this, but if it is isnt due to a quirk of the widget or something, I can live with it (it isn't that big of a problem anyway).

Before toggle:

Image

After toggle:

Image

Azosion avatar May 10 '25 02:05 Azosion

Hi @Azosion , you're right. I tried it again, and I experienced the behaviour you described.

The only way I found to make the height update correctly is to add maximumHeight:

Layout.maximumHeight: column.implicitHeight

But this makes the height fixed and not editable by the user.

ccatterina avatar May 12 '25 16:05 ccatterina

Hello @ccatterina , I've notice something very weird, when I restart my plasma shell (~/kde/usr/bin/plasmashell --replace & disown) while the widget is in my taskbar, the scaling works correctly, I have no clue why this happens.

Azosion avatar May 13 '25 00:05 Azosion

Ok, I might have found a solution (despite how dumb I think it is, it works). If you reset preferredHeight and Width by setting them to undefined and then back to implicitHeight, then the width no longer changes when you toggle, I still want to make it so that the default height of the widget when the album cover is turn off is 1/3 the default widget height , but I think that is a problem for another day.

https://github.com/ccatterina/plasmusic-toolbar/compare/main...Azosion:plasmusic-toolbar:toggle-album-cover

Azosion avatar May 13 '25 03:05 Azosion

Thanks for the work on this. Looking forward to this feature.

luzpaz avatar May 18 '25 22:05 luzpaz