Some old themes have the flag set and also a style which expects the
borders to be stretched. Given that the documentation on techbase
describes widgets/glowbar still as "a frame without a prefix", one also
would assume that all the optional hints (which make sense) still apply.
Even more, the Air & Oxygen themes have the hint also set, though for
their rendering it makes no difference.
The small code needed seems worth the unbreaking of old themes as well
as giving theme creators another variable of freedom for their styles.
Details
- Reviewers
zzag davidedmundson - Group Reviewers
KWin - Commits
- R108:1fb4baf365ea: [effects/screenedge] Support "hint-stretch-borders"
Glow bar still works on all corners and edges with all themes as before,
though rendering now as expected for themes which have the
"hint-stretch-borders" set.
Diff Detail
- Repository
- R108 KWin
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Please change prefix to "[effects/screenedge]".
effects/screenedge/screenedgeeffect.cpp | ||
---|---|---|
347–352 | Could you please rename this variable? Maybe target? Not a serious issue but would be nice to have a bit descriptive variable names. :) |
@zzag Thanks for review.
effects/screenedge/screenedgeeffect.cpp | ||
---|---|---|
347–352 | I tried to follow the name pattern of pixmapPosition, so thought it was descriptive, being the "rect" for the very "c" :) |
At some point it would be good to use the Plasma FrameSVG import. That does tiling and stretching all on the GPU in the render instead of creating giant pixmaps.
There's another hint "hint-compose-over-border" which I don't want duplicating, because it's mental.
This fix is definitely an improvement ++
Yes, that's what I initially tried to use, but I got lost over tracking pixmaps & images & resolution & final blitting and making sure to have the right parts painted, given that presence of any margins hints also brings the question what part of the border should be used for glow... so I escaped into this simple enough solution for now :) as the other code had been growing beyond the existing one in the time I gave myself.
There's another hint "hint-compose-over-border" which I don't want duplicating, because it's mental.
In the case of the glow the center is also not used, so that hint would not be interesting here, or?
This fix is definitely an improvement ++
Thanks for ++ :)