Burn-My-Windows icon indicating copy to clipboard operation
Burn-My-Windows copied to clipboard

Specify effect for certain applications

Open hasecilu opened this issue 3 years ago • 5 comments

The Motivation

Some applications may benefit more aesthetically from certain effects. For example:

  • terminals (tilix, guake, alacritty ...) can look better with Matrix effect.
  • media players (mpv, vlc, ...) can look better while closing with TV Effect

The Solution

Create a Advanced options tab to specify a closing effect and a opening effect. This settings should overwrite the General options settings. Example:

  • If in Open Window Animation Energize A and Energize B are selected mpv must not have any opening effect (view image below)
  • If in Close Window Animation all are selected Tilix must close with Matrix effect and not perform a random selection(view image below)

This idea was conceived for individual applications but can be applied to groups, ie, instead of choose effects individually for tilix, guake and alacritty I want to create a group called Terminals, assign it some effects and then add tilix, guake and alacritty to that group, the selected effects in Terminals are applied to those applications

Screenshot from 2022-02-02 15-26-20

The Alternatives

In #37 is presented the idea of disabling effects for certain applications, that feature is the complement of this Feature Request.

hasecilu avatar Feb 02 '22 21:02 hasecilu

This is a pretty good idea! I think I'll close #37 in favor of this one here, as this solution sounds very good and would include #37. However, it also seems to be quite a lot of work UI-wise, so there will be other things with a higher priority for me. But I'll keep this on the list 😉

Schneegans avatar Feb 03 '22 09:02 Schneegans

I see that #37 is closed in favor this one. I would love this feature to be added. I use the ddterm (dropdown terminal) extension and every time I hide that terminal, the animation runs on it. I do think #37 would be a bit simpler to implement on it's own (i.e. add a single setting with a list of exclusions) and I might even be down to try and tackle that. This issue is probably more than I have availability for though.

vozeldr avatar Apr 14 '22 16:04 vozeldr

To be honest, I am a bit hesitant to start working on this (or encourage anybody else to do it) because of the Preset System idea which popped up in several places. Various people suggested that it would be nice if one could have different configurations of the same effect for opening and closing windows. Or maybe for different applications (e.g. red fire for firefox and blue fire for thunderbird etc.).

I haven't put too much thought into this up to now, but this would certainly require a complete redesign of the settings dialog. The basic idea would be that the user can create an arbitrary number of effect configurations (e.g. several variants of the fire effect, a few variants of the matrix effect, and so on), and then can select which configuration is used for which event.

While this will require a much more sophisticated UI, it would also make the work done for this issue here more or less obsolete...

Schneegans avatar Apr 15 '22 10:04 Schneegans

Hopefully the complexity of that configuration screen won't be overwhelming to users and there will still be a default configuration for anything not specifically overwritten.

vozeldr avatar Apr 15 '22 13:04 vozeldr

Yep. That's why I haven't started to think about this in detail :laughing: For me, it would be a strict requirement that the configuration does not get more complicated for simple use cases as it is right now. This will be difficult to achieve, but possible I think.

Schneegans avatar Apr 15 '22 13:04 Schneegans

I thought about this alot in the recent days and I think that I have a proper solution now. Here's what I would like to have:

  • Possibility to exclude specific applications from BMW effects
  • Specify specific effects per-application
  • Different configurations of the same effect for opening or closing windows
  • Selecting effects based on other factors, such as performance profile, window type, night light, power mode, ...
  • ... and all this without making the experience for new users significantly more complex :sweat_smile:

The solution for this may be Effect Profiles. The default profile is enabled under all conditions. If you want, you can add more specific profiles, which are only used if the corresponding conditions are met. Here's a mockup how this could look like. The settings dialog does not change much, the only differences are the added profile selection in the header bar and that effects can now only be enabled / disabled; there is no separate selection for opening / closing animation anymore: image In fact, this may make things a bit more easy for first-time users. Then, if you edit the Default Profile, this pops up: image You can limit the cases where this profile is applied, or add new profiles. For example, this could look like this: image This will be pretty complex to implement, but I think that it would solve many issues!

Schneegans avatar Jan 14 '23 13:01 Schneegans

Actually, that sounds great! Can't really offer time to help code, but happy to beta test bits, and potentially debug.

fnxweb avatar Jan 14 '23 15:01 fnxweb

I am currently working on this in the feature/effect-profiles branch. It's not yet functional, but already pretty promising! Stay tuned for future updates!

Schneegans avatar Jan 29 '23 13:01 Schneegans

If I understood correctly you can add n profiles at once and every profile includes a set of constraints/rules, if you want more tweaks you add more profiles. I'll be happy to test it.

hasecilu avatar Jan 29 '23 15:01 hasecilu

If I understood correctly you can add n profiles at once and every profile includes a set of constraints/rules, if you want more tweaks you add more profiles. I'll be happy to test it.

Yes, pretty much this. I'll let you know when its ready for testing!

Schneegans avatar Jan 29 '23 17:01 Schneegans

The feature/effect-profiles now works already pretty well (I hope :smile:) on GNOME 43. So if you are on this version, you could start playing around. The basic approach would be:

git clone https://github.com/Schneegans/Burn-My-Windows.git
cd Burn-My-Windows
git checkout feature/effect-profiles
make install

Then restart GNOME Shell with Alt + F2, r + Enter or logout / login if you are on Wayland.

But please keep in mind, that this my break on a daily basis as I am actively working on it.

Btw, I am tracking the progress here: #292.

Schneegans avatar Jan 30 '23 13:01 Schneegans

I have some hours using it, and haven't encountered any problems with the rules. The window picker is very handy. Having multiple applications per profile can reduce the number of profiles needed when you want the same rule for various programs, not a big deal if just are 2 or 3. Apart from that it's very nice.

hasecilu avatar Jan 31 '23 21:01 hasecilu

Thanks for the feedback! A simple solution would be to allow for a list of applications. Maybe separated with a "|". Like "Firefox | gnome-terminal". The window picker would then just append to the list.

At some point in the future libadwaita may support tagged entries which would be very cool here.

Schneegans avatar Feb 01 '23 04:02 Schneegans

The above mentioned branch should now also work on GNOME Shell 40, 41, and 42. So if anybody wants to test it, I would be happy about more feedback! :smile:

Schneegans avatar Feb 02 '23 18:02 Schneegans