Skip to content

Commit 5cd5b24

Browse files
authored
[CinnamonBurnMyWindows@klangman] V0.9.8, new effects, minimize events (#847)
- Add new effects from the Gnome version (Aura Glow, Mushroom, RGB Warp, Team Rocket) - Add Magic Lamp effect based on hermes83/compiz-alike-magic-lamp-effect (same as CinnamonMagicLamp) - Add the ability to apply effects to the minimize & unminimize events - Fix an issue where the window was jumping a pixel to the right post open animation (finally!) - Add Fire effect presets (5 pre-configured fire setups) - Change the Random Effects tab to use a standard List widget - Move the Application Specific settings options to its own tab - Add a custom color selection widget to save configurator GUI space - Use WM_CLASS when adding a app specific setting if no app can be found - Improvements to the Focus effect (from Gnome version) - Add an "About" tab with credits to the various authors
1 parent 9cf9d91 commit 5cd5b24

28 files changed

+7200
-1108
lines changed

CinnamonBurnMyWindows@klangman/CHANGELOG.md

+14
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,19 @@
11
# Changelog
22

3+
## 0.9.8
4+
5+
* Added new effects from the Gnome version (Aura Glow, Mushroom, RGB Warp, Team Rocket)
6+
* Added Magic Lap effect based on hermes83/compiz-alike-magic-lamp-effect (same as CinnamonMagicLamp)
7+
* Added the ability to apply effects to the minimize & unminimize events
8+
* Fixed an issue where the window was jumping a pixel to the right post open animation (finally!)
9+
* Added Fire effect presets (5 pre-configured fire setups)
10+
* Changed the Random Effects tab to use a standard List widget
11+
* Moved the Application Specific settings options to it's own tab
12+
* Added a custom color selection widget to save configurator GUI space
13+
* Use WM_CLASS when adding a app specific setting if no app can be found
14+
* Improvements to the Focus effect (from Gnome version)
15+
* Added an "About" tab with credits to the various authors
16+
317
## 0.9.7
418

519
- Added options in the configuration that allows you to define which effects will be used (if any) for dialog windows (i.e. a file open dialog). This allows you to use a more subtle or shorter running effect (i.e focus or glide) for all the dialog windows which are typically opened/closed more frequently.

CinnamonBurnMyWindows@klangman/README.md

+23-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# CinnamonBurnMyWindows
22

3-
Window open and close effects for the Cinnamon desktop
3+
Window open, close, minimize and unminimize effects for the Cinnamon desktop
44

55
This is a Cinnamon port of the Gnome extension Burn-my-Windows which can be found here:
66

@@ -21,12 +21,14 @@ This extension needs the Cinnamon.GLSLEffect class which is only available in Ci
2121
2. When closing the Steam Client "setting" window the 'close window effect' does not show the windows contents, resulting in the closing effect to show where the window had existed but otherwise has no negative effect.
2222
3. When running VirtualBox, some actions (like restarting Cinnamon or changing panel hide settings) will show a full screen animation of both the Open and Close effect. I assume this is caused by some weirdness with how VirtualBox was written. The problem can be avoided by using two "Application specific settings" list entries to disable open/close animations for the "VirtualBox" and "VirtualBoxVM" WM_CLASS names (entered under the "Application" entry box). New installs of this extension will have these entries by default, but installs that are upgraded to the latest version will need to manually enter these app rules to avoid the issues.
2323
4. The Doom open effect seems to finish animating at a noticeably lower position than where the window is actually located. This results in the sudden jump up after the animation is completed. When used as a close effect it works correctly.
24-
5. All open window effects seem to animate in a location that is one pixel off the windows real location. This causes a very small (nearly unnoticeable) jump of the window after the animation has finished. The only exception is "Doom", which as stated above has a more pronounced jump.
25-
6. The window shadows are not part of the animation and therefore they suddenly appear or disappear right after or before the animation.
24+
5. The window shadows are not part of the animation and therefore they suddenly appear or disappear right after or before the animation.
25+
6. After upgrading to 0.9.8 the Fire effect setting and the effects included in the randomized sets will be reset to default.
26+
7. The Magic Lap effect when used as a minimize effect the window "flashes" the window at the start of the effect and so far I have not been able to determine why. The issue does not appear when used as a close event which is very odd. For this reason you might want to continue using the standalone Magic Lamp Effect extension until I find a way to fix this.
2627

2728
### Currently these effects are working in Cinnamon:
2829

2930
- Apparition
31+
- Aura Glow
3032
- Doom
3133
- Energize A
3234
- Energize B
@@ -36,10 +38,14 @@ This extension needs the Cinnamon.GLSLEffect class which is only available in Ci
3638
- Glitch
3739
- Hexagon
3840
- Incinerate
41+
- Magic Lamp
42+
- Mushroom
3943
- Pixelate
4044
- Pixel Wheel
4145
- Pixel Wipe
4246
- Portal
47+
- RGB Warp
48+
- Team Rocket
4349
- TV Effect
4450
- TV Glitch
4551
- Wisps
@@ -74,3 +80,17 @@ https://github.com/Schneegans/Burn-My-Windows
7480

7581
If you want to help others find this Cinnamon extension, consider staring it here and on my Github page so that more people might learn of it's existence. The more stars it gets the more encouragement I'll have to continue working on it.
7682
Thanks!
83+
84+
## Credits
85+
86+
Ported to Cinnamon by Kevin Langman
87+
88+
https://github.com/klangman/CinnamonBurnMyWindows
89+
90+
Based on the Burn-My-Windows code by Schneegans and contributors
91+
92+
https://github.com/Schneegans/Burn-My-Windows
93+
94+
The Magic Lamp Effect is based on code by hermes83
95+
96+
https://github.com/hermes83/compiz-alike-magic-lamp-effect

CinnamonBurnMyWindows@klangman/files/CinnamonBurnMyWindows@klangman/6.2/CustomWidgets.py

+122-21
Original file line numberDiff line numberDiff line change
@@ -4,40 +4,141 @@
44
from JsonSettingsWidgets import *
55
from gi.repository import Gio, Gtk
66

7-
class TwoCheckButtonsTitleWidget(SettingsWidget):
8-
def __init__(self, info, key, settings):
7+
class FireColorChooser(SettingsWidget):
8+
def __init__(self, info, key, settings):
99
SettingsWidget.__init__(self)
1010
self.key = key
1111
self.settings = settings
1212
self.info = info
13+
rgba = Gdk.RGBA()
1314

14-
self.descLabel = Gtk.Label('', halign=Gtk.Align.START)
15-
self.descLabel.set_markup('<b>' + _(info['description']) + '</b>');
15+
self.pack_start(Gtk.Label(_(info['description']), halign=Gtk.Align.START), True, True, 0)
16+
self.cBtn1 = Gtk.ColorButton()
17+
self.cBtn1.set_use_alpha(True)
18+
self.cBtn1.set_margin_start(2)
19+
20+
self.cBtn2 = Gtk.ColorButton()
21+
self.cBtn2.set_use_alpha(True)
22+
self.cBtn2.set_margin_start(2)
23+
24+
self.cBtn3 = Gtk.ColorButton()
25+
self.cBtn3.set_use_alpha(True)
26+
self.cBtn3.set_margin_start(2)
27+
28+
self.cBtn4 = Gtk.ColorButton()
29+
self.cBtn4.set_use_alpha(True)
30+
self.cBtn4.set_margin_start(2)
1631

17-
self.label1 = Gtk.Label('', halign=Gtk.Align.END)
18-
self.label1.set_markup('<b>' + _(info['titleB']) + '</b>');
32+
self.cBtn5 = Gtk.ColorButton()
33+
self.cBtn5.set_use_alpha(True)
34+
self.cBtn5.set_margin_start(2)
1935

20-
self.label2 = Gtk.Label('', halign=Gtk.Align.END)
21-
self.label2.set_markup('<b>' + _(info['titleA']) + '</b>');
36+
self.pack_end(self.cBtn5, False, False, 2)
37+
self.pack_end(self.cBtn4, False, False, 2)
38+
self.pack_end(self.cBtn3, False, False, 2)
39+
self.pack_end(self.cBtn2, False, False, 2)
40+
self.pack_end(self.cBtn1, False, False, 2)
2241

23-
self.pack_start(self.descLabel, True, True, 0)
24-
self.pack_end(self.label1, False, False, 10)
25-
self.pack_end(self.label2, False, False, 10)
42+
rgba.parse(settings.get_value(info["color1"]))
43+
self.cBtn1.set_rgba(rgba);
44+
rgba.parse(settings.get_value(info["color2"]))
45+
self.cBtn2.set_rgba(rgba);
46+
rgba.parse(settings.get_value(info["color3"]))
47+
self.cBtn3.set_rgba(rgba);
48+
rgba.parse(settings.get_value(info["color4"]))
49+
self.cBtn4.set_rgba(rgba);
50+
rgba.parse(settings.get_value(info["color5"]))
51+
self.cBtn5.set_rgba(rgba);
2652

53+
self.cBtn1.connect('color-set', self.on_my_value_changed)
54+
self.cBtn2.connect('color-set', self.on_my_value_changed)
55+
self.cBtn3.connect('color-set', self.on_my_value_changed)
56+
self.cBtn4.connect('color-set', self.on_my_value_changed)
57+
self.cBtn5.connect('color-set', self.on_my_value_changed)
2758

28-
class TwoCheckButtonsWidget(SettingsWidget):
29-
def __init__(self, info, key, settings):
59+
def on_my_value_changed(self, widget):
60+
color_string = self.cBtn1.get_rgba().to_string()
61+
self.settings.set_value(self.info["color1"], color_string)
62+
color_string = self.cBtn2.get_rgba().to_string()
63+
self.settings.set_value(self.info["color2"], color_string)
64+
color_string = self.cBtn3.get_rgba().to_string()
65+
self.settings.set_value(self.info["color3"], color_string)
66+
color_string = self.cBtn4.get_rgba().to_string()
67+
self.settings.set_value(self.info["color4"], color_string)
68+
color_string = self.cBtn5.get_rgba().to_string()
69+
self.settings.set_value(self.info["color5"], color_string)
70+
71+
72+
class MushroomColorChooser(SettingsWidget):
73+
def __init__(self, info, key, settings):
3074
SettingsWidget.__init__(self)
3175
self.key = key
3276
self.settings = settings
3377
self.info = info
78+
rgba = Gdk.RGBA()
3479

3580
self.pack_start(Gtk.Label(_(info['description']), halign=Gtk.Align.START), True, True, 0)
36-
self.chkBtn1 = Gtk.CheckButton()
37-
self.chkBtn1.set_margin_start(17)
38-
self.chkBtn2 = Gtk.CheckButton()
39-
self.chkBtn2.set_margin_start(17)
40-
self.settings.bind(info['close'], self.chkBtn1, 'active', Gio.SettingsBindFlags.DEFAULT)
41-
self.settings.bind(info['open'], self.chkBtn2, 'active', Gio.SettingsBindFlags.DEFAULT)
42-
self.pack_end(self.chkBtn1, False, False, 10)
43-
self.pack_end(self.chkBtn2, False, False, 10)
81+
self.cBtn1 = Gtk.ColorButton()
82+
self.cBtn1.set_use_alpha(True)
83+
self.cBtn1.set_margin_start(2)
84+
85+
self.cBtn2 = Gtk.ColorButton()
86+
self.cBtn2.set_use_alpha(True)
87+
self.cBtn2.set_margin_start(2)
88+
89+
self.cBtn3 = Gtk.ColorButton()
90+
self.cBtn3.set_use_alpha(True)
91+
self.cBtn3.set_margin_start(2)
92+
93+
self.cBtn4 = Gtk.ColorButton()
94+
self.cBtn4.set_use_alpha(True)
95+
self.cBtn4.set_margin_start(2)
96+
97+
self.cBtn5 = Gtk.ColorButton()
98+
self.cBtn5.set_use_alpha(True)
99+
self.cBtn5.set_margin_start(2)
100+
101+
self.cBtn6 = Gtk.ColorButton()
102+
self.cBtn6.set_use_alpha(True)
103+
self.cBtn6.set_margin_start(2)
104+
105+
self.pack_end(self.cBtn6, False, False, 2)
106+
self.pack_end(self.cBtn5, False, False, 2)
107+
self.pack_end(self.cBtn4, False, False, 2)
108+
self.pack_end(self.cBtn3, False, False, 2)
109+
self.pack_end(self.cBtn2, False, False, 2)
110+
self.pack_end(self.cBtn1, False, False, 2)
111+
112+
rgba.parse(settings.get_value(info["color1"]))
113+
self.cBtn1.set_rgba(rgba);
114+
rgba.parse(settings.get_value(info["color2"]))
115+
self.cBtn2.set_rgba(rgba);
116+
rgba.parse(settings.get_value(info["color3"]))
117+
self.cBtn3.set_rgba(rgba);
118+
rgba.parse(settings.get_value(info["color4"]))
119+
self.cBtn4.set_rgba(rgba);
120+
rgba.parse(settings.get_value(info["color5"]))
121+
self.cBtn5.set_rgba(rgba);
122+
rgba.parse(settings.get_value(info["color6"]))
123+
self.cBtn6.set_rgba(rgba);
124+
125+
self.cBtn1.connect('color-set', self.on_my_value_changed)
126+
self.cBtn2.connect('color-set', self.on_my_value_changed)
127+
self.cBtn3.connect('color-set', self.on_my_value_changed)
128+
self.cBtn4.connect('color-set', self.on_my_value_changed)
129+
self.cBtn5.connect('color-set', self.on_my_value_changed)
130+
self.cBtn6.connect('color-set', self.on_my_value_changed)
131+
132+
def on_my_value_changed(self, widget):
133+
color_string = self.cBtn1.get_rgba().to_string()
134+
self.settings.set_value(self.info["color1"], color_string)
135+
color_string = self.cBtn2.get_rgba().to_string()
136+
self.settings.set_value(self.info["color2"], color_string)
137+
color_string = self.cBtn3.get_rgba().to_string()
138+
self.settings.set_value(self.info["color3"], color_string)
139+
color_string = self.cBtn4.get_rgba().to_string()
140+
self.settings.set_value(self.info["color4"], color_string)
141+
color_string = self.cBtn5.get_rgba().to_string()
142+
self.settings.set_value(self.info["color5"], color_string)
143+
color_string = self.cBtn6.get_rgba().to_string()
144+
self.settings.set_value(self.info["color6"], color_string)

CinnamonBurnMyWindows@klangman/files/CinnamonBurnMyWindows@klangman/6.2/ShaderFactory.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ var ShaderFactory = class ShaderFactory {
7373
});
7474
}
7575

76-
// Now create a niew instance of the newly registered shader type.
76+
// Now create a new instance of the newly registered shader type.
7777
// GObject.Object.new is only available with newer versions of GJS.
7878
if (GObject.Object.new) {
7979
shader = GObject.Object.new(GObject.type_from_name(typeName), {});

0 commit comments

Comments
 (0)