tsujan / BreezeEnhanced

A fork of KDE Breeze decoration with additional options
GNU General Public License v3.0
162 stars 13 forks source link

is it possible to have overrides for specific window types? #13

Closed kupiqu closed 5 years ago

kupiqu commented 5 years ago

could this be a feasible feature request/enhancement?

tsujan commented 5 years ago

Yes, of course!

It had been mentioned before but it may be needed to be implemented outside Breeze(Enhanced). Since I'm not sure yet, I leave this open.

trmdi commented 5 years ago

An idea from the past: https://github.com/tsujan/BreezeEnhanced/issues/1#issuecomment-427245556

Can you make BreezeEnhanced's window-selection like the Kwin's one ? It lacks Window Role, Window type...

image

kupiqu commented 5 years ago

Sorry @trmdi, missed that you mentioned this already

tsujan commented 5 years ago

It's good to have a separate issue for it.

FYI:

If you take a look at my other programs, you'll find that they are all purely based on Qt -- not on KDE -- so that, with them, I can do virtually anything I want (with a little exaggeration). Only BreezeEnhanced is at the mercy of KDE :( So, some things are out of my control -- or, at least, I think so for now.

tsujan commented 5 years ago

Sorry for the long delay! I was very busy with other projects but, at last, found time to look into this.

Window types can be covered but I think distinguishing between normal windows and dialogs is enough — covering other types would be an overkill. This is what I did here:

dialog

When "Only for dialogs" is checked (it's unchecked by default), the settings above it will be applied only to dialogs.

I tested it with QTerminal and it was effective. In the following screenshot, I've chosen a very dark color for QTerminal itself but given the color of Kvantum's KvCurves to its dialog; the title-bar opacity is 60 for normal window but 90 for the dialog:

qterminal

The rule for qterminal dialog should be above the rule for its normal window because it should be checked before it.

@kupiqu, @trmdi Is this OK to you?

tsujan commented 5 years ago

OK, this is cool. I added this rule at the top:

dialogs

Made a dialog color scheme for KvAmbience and now, dialogs have a nice title-bar:

KvAmbience_dialog

I'll go with it — will make a commit after testing it for a while.

trmdi commented 5 years ago

LGTM. Waiting for the commit. ;-)

tsujan commented 5 years ago

Done.

Made the commit sooner for it to be tested by more users. The changes were elementary.

Thanks for the good idea!

kupiqu commented 5 years ago

Looks great!

I guess I only miss the option to do the opposite, to apply the override only to the main window and not to the dialog.

tsujan commented 5 years ago

to apply the override only to the main window and not to the dialog.

Add the overrides for the main window and then add a rule without override only for its dialogs above it (by just checking "Only for dialogs). I haven't tried that but I think it'll work.

tsujan commented 5 years ago

@kupiqu I tested my above-mentioned theory and it worked :)

All in all, current options are very flexible. The user just needs to how to use and sort them (the order of overrides is sometimes important). That's the case with KWin's custom title-bar colors too; so, those who have played with the latter know how to use the former.