diff --git a/user-shadows@nathan818fr/README.md b/user-shadows@nathan818fr/README.md index c5e62f9e..3f98db62 100644 --- a/user-shadows@nathan818fr/README.md +++ b/user-shadows@nathan818fr/README.md @@ -8,7 +8,8 @@ A Cinnamon extension to customize window shadows. ### Cinnamon Spices -Download it [from Cinnamon Spices][spices] or search for _"User Shadows"_ in your Cinnamon extension settings. +Download it [from Cinnamon Spices][spices] or search for _"User Shadows"_ in +your Cinnamon extension settings. ### From source @@ -17,7 +18,7 @@ To download the source and install it, execute the following as a normal user: ```bash git clone https://github.com/nathan818fr/cinnamon-user-shadows.git cd cinnamon-user-shadows -cinnamon-install-spice extension files/user-shadows@nathan818fr +npm run install-extension ``` ## Issues @@ -26,8 +27,10 @@ If you find any bug, you can report on the [Github issues page][issues]. ## Contributing -Contributions are welcome. Please submit pull requests [to the extension repository][repo] (**not** the Spices repository, which is only a distribution channel).
-It is recommended to open an issue before introducing new features to discuss them. +Contributions are welcome. Please submit pull requests [to the extension +repository][repo] (**not** the Spices repository, which is only a distribution +channel).
It is recommended to open an issue before introducing new +features to discuss them. ## FAQ @@ -37,11 +40,12 @@ No. The APIs required to do that are not exposed to cinnamon extensions. ### • The shadow of some windows is not modified, what to do? -This extension only applies to windows rendered by the cinnamon window manager (a.k.a. Muffin). -It is likely that you are dealing with [Gtk CSD windows](https://en.wikipedia.org/wiki/Client-side_decoration), whose shadow is defined by the Gtk theme you are using. - +This extension only applies to windows rendered by the cinnamon window manager +(a.k.a. Muffin). It is likely that you are dealing with +[Gtk CSD windows](https://en.wikipedia.org/wiki/Client-side_decoration), whose +shadow is defined by the Gtk theme you are using. [repo]: https://github.com/nathan818fr/cinnamon-user-shadows -[commits]: https://github.com/nathan818fr/cinnamon-user-shadows/commits/master +[commits]: https://github.com/nathan818fr/cinnamon-user-shadows/commits/main [issues]: https://github.com/nathan818fr/cinnamon-user-shadows/issues [spices]: https://cinnamon-spices.linuxmint.com/extensions/view/88 diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/metadata.json b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/metadata.json index ba0cee4e..66b18f68 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/metadata.json +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/metadata.json @@ -1,10 +1,8 @@ { - "uuid": "user-shadows@nathan818fr", - "name": "User Shadows", - "description": "Customize the shadows of cinnamon windows", - "author": "Nathan Poirier ", - "cinnamon-version": [ - "4.8" - ], - "url": "https://github.com/linuxmint/cinnamon-spices-extensions/tree/master/user-shadows%40nathan818fr" -} \ No newline at end of file + "uuid": "user-shadows@nathan818fr", + "name": "User Shadows", + "description": "Customize the shadows of cinnamon windows", + "author": "Nathan Poirier ", + "cinnamon-version": ["4.8", "5.0", "5.2", "5.4", "5.6"], + "url": "https://github.com/linuxmint/cinnamon-spices-extensions/tree/master/user-shadows%40nathan818fr" +} diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/da.po b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/da.po index fac4db2a..d3c253cc 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/da.po +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/da.po @@ -2,62 +2,62 @@ msgid "" msgstr "" "Project-Id-Version: user-shadows@nathan818fr\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-06-24 17:04+0200\n" -"PO-Revision-Date: 2022-08-16 20:39+0200\n" +"POT-Creation-Date: 2023-09-13 12:05+0200\n" +"PO-Revision-Date: 2023-09-13 12:20+0200\n" +"Last-Translator: Nathan POirier \n" "Language-Team: \n" +"Language: da\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.3\n" -"Last-Translator: Alan Mortensen \n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -"Language: da\n" +"X-Generator: Poedit 3.3.1\n" -#: custom-settings-widgets.py:12 +#: custom-settings-widgets.py:19 msgid "Radius" msgstr "Radius" -#: custom-settings-widgets.py:13 +#: custom-settings-widgets.py:20 msgid "Top Fade" msgstr "Udton toppen" -#: custom-settings-widgets.py:14 +#: custom-settings-widgets.py:21 msgid "X Offset" msgstr "x-forskydning" -#: custom-settings-widgets.py:15 +#: custom-settings-widgets.py:22 msgid "Y Offset" msgstr "y-forskydning" -#: custom-settings-widgets.py:16 +#: custom-settings-widgets.py:23 msgid "Opacity" msgstr "Uigennemsigtighed" -#: custom-settings-widgets.py:39 +#: custom-settings-widgets.py:46 msgid "Class Name" msgstr "Klassenavn" -#: custom-settings-widgets.py:42 +#: custom-settings-widgets.py:49 msgid "State" msgstr "Tilstand" -#: custom-settings-widgets.py:102 +#: custom-settings-widgets.py:109 msgid "Import" msgstr "Importér" -#: custom-settings-widgets.py:106 +#: custom-settings-widgets.py:113 msgid "Export" msgstr "Eksportér" -#: custom-settings-widgets.py:110 +#: custom-settings-widgets.py:117 msgid "Set from..." msgstr "Indstil fra …" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose where to save your configuration" msgstr "Vælg, hvor konfigurationen skal gemmes" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose a configuration to load" msgstr "Vælg en konfiguration, der skal indlæses" diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/fr.po b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/fr.po index 6af35c88..060aac6a 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/fr.po +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/fr.po @@ -2,62 +2,62 @@ msgid "" msgstr "" "Project-Id-Version: user-shadows@nathan818fr\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-06-24 17:04+0200\n" -"PO-Revision-Date: 2021-06-24 17:09+0200\n" +"POT-Creation-Date: 2023-09-13 12:05+0200\n" +"PO-Revision-Date: 2023-09-13 12:11+0200\n" +"Last-Translator: Nathan Poirier \n" "Language-Team: \n" +"Language: fr\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 3.0\n" -"Last-Translator: Nathan Poirier \n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" -"Language: fr\n" +"X-Generator: Poedit 3.3.1\n" -#: custom-settings-widgets.py:12 +#: custom-settings-widgets.py:19 msgid "Radius" msgstr "Rayon" -#: custom-settings-widgets.py:13 +#: custom-settings-widgets.py:20 msgid "Top Fade" msgstr "Fondu supérieur" -#: custom-settings-widgets.py:14 +#: custom-settings-widgets.py:21 msgid "X Offset" msgstr "Décalage X" -#: custom-settings-widgets.py:15 +#: custom-settings-widgets.py:22 msgid "Y Offset" msgstr "Décalage Y" -#: custom-settings-widgets.py:16 +#: custom-settings-widgets.py:23 msgid "Opacity" msgstr "Opacité" -#: custom-settings-widgets.py:39 +#: custom-settings-widgets.py:46 msgid "Class Name" msgstr "Classe" -#: custom-settings-widgets.py:42 +#: custom-settings-widgets.py:49 msgid "State" msgstr "État" -#: custom-settings-widgets.py:102 +#: custom-settings-widgets.py:109 msgid "Import" msgstr "Importer" -#: custom-settings-widgets.py:106 +#: custom-settings-widgets.py:113 msgid "Export" msgstr "Exporter" -#: custom-settings-widgets.py:110 +#: custom-settings-widgets.py:117 msgid "Set from..." msgstr "Définir à partir de..." -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose where to save your configuration" msgstr "Choisissez où enregistrer votre configuration" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose a configuration to load" msgstr "Choisissez une configuration à charger" diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/hu.po b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/hu.po index 83a7ff5e..a1e4b88f 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/hu.po +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/hu.po @@ -2,61 +2,61 @@ msgid "" msgstr "" "Project-Id-Version: user-shadows@nathan818fr\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-06-24 17:04+0200\n" -"PO-Revision-Date: 2021-09-26 08:36+0200\n" +"POT-Creation-Date: 2023-09-13 12:05+0200\n" +"PO-Revision-Date: 2023-09-13 12:13+0200\n" +"Last-Translator: Nathan POirier \n" +"Language-Team: \n" "Language: hu\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"Last-Translator: Kálmán „KAMI” Szalai \n" -"Language-Team: \n" -"X-Generator: Poedit 2.3\n" +"X-Generator: Poedit 3.3.1\n" -#: custom-settings-widgets.py:12 +#: custom-settings-widgets.py:19 msgid "Radius" msgstr "Sugár" -#: custom-settings-widgets.py:13 +#: custom-settings-widgets.py:20 msgid "Top Fade" msgstr "Felső előtűnés" -#: custom-settings-widgets.py:14 +#: custom-settings-widgets.py:21 msgid "X Offset" msgstr "X eltolás" -#: custom-settings-widgets.py:15 +#: custom-settings-widgets.py:22 msgid "Y Offset" msgstr "Y eltolás" -#: custom-settings-widgets.py:16 +#: custom-settings-widgets.py:23 msgid "Opacity" msgstr "Átlátszatlanság" -#: custom-settings-widgets.py:39 +#: custom-settings-widgets.py:46 msgid "Class Name" msgstr "Osztálynév" -#: custom-settings-widgets.py:42 +#: custom-settings-widgets.py:49 msgid "State" msgstr "Állapot" -#: custom-settings-widgets.py:102 +#: custom-settings-widgets.py:109 msgid "Import" msgstr "Importálás" -#: custom-settings-widgets.py:106 +#: custom-settings-widgets.py:113 msgid "Export" msgstr "Exportálás" -#: custom-settings-widgets.py:110 +#: custom-settings-widgets.py:117 msgid "Set from..." msgstr "Beállítások betöltése…" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose where to save your configuration" msgstr "Beállítások mentés helyének megadása" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose a configuration to load" msgstr "Betöltendő konfiguráció kiválasztása" diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/it.po b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/it.po index 62c8ab0e..06b30570 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/it.po +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/it.po @@ -2,62 +2,62 @@ msgid "" msgstr "" "Project-Id-Version: user-shadows@nathan818fr\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-06-24 17:04+0200\n" -"PO-Revision-Date: 2022-06-03 11:21+0200\n" +"POT-Creation-Date: 2023-09-13 12:05+0200\n" +"PO-Revision-Date: 2023-09-13 12:14+0200\n" +"Last-Translator: Nathan POirier \n" "Language-Team: \n" +"Language: it\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.3\n" -"Last-Translator: Dragone2 \n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" -"Language: it\n" +"X-Generator: Poedit 3.3.1\n" -#: custom-settings-widgets.py:12 +#: custom-settings-widgets.py:19 msgid "Radius" msgstr "Raggio" -#: custom-settings-widgets.py:13 +#: custom-settings-widgets.py:20 msgid "Top Fade" msgstr "Dissolvenza Superiore" -#: custom-settings-widgets.py:14 +#: custom-settings-widgets.py:21 msgid "X Offset" msgstr "Offset X" -#: custom-settings-widgets.py:15 +#: custom-settings-widgets.py:22 msgid "Y Offset" msgstr "Offset Y" -#: custom-settings-widgets.py:16 +#: custom-settings-widgets.py:23 msgid "Opacity" msgstr "Opacità" -#: custom-settings-widgets.py:39 +#: custom-settings-widgets.py:46 msgid "Class Name" msgstr "Nome Classe" -#: custom-settings-widgets.py:42 +#: custom-settings-widgets.py:49 msgid "State" msgstr "Stato" -#: custom-settings-widgets.py:102 +#: custom-settings-widgets.py:109 msgid "Import" msgstr "Importa" -#: custom-settings-widgets.py:106 +#: custom-settings-widgets.py:113 msgid "Export" msgstr "Esporta" -#: custom-settings-widgets.py:110 +#: custom-settings-widgets.py:117 msgid "Set from..." msgstr "Imposta da..." -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose where to save your configuration" msgstr "Scegli dove salvare la tua configurazione" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose a configuration to load" msgstr "Scegli una configurazione da caricare" diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/pt_BR.po b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/pt_BR.po index 5629da5d..58e0c0b9 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/pt_BR.po +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/pt_BR.po @@ -2,62 +2,62 @@ msgid "" msgstr "" "Project-Id-Version: user-shadows@nathan818fr\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-06-24 17:04+0200\n" -"PO-Revision-Date: 2021-09-24 12:05-0300\n" +"POT-Creation-Date: 2023-09-13 12:05+0200\n" +"PO-Revision-Date: 2023-09-13 12:14+0200\n" +"Last-Translator: Nathan POirier \n" "Language-Team: \n" +"Language: pt_BR\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 3.0\n" -"Last-Translator: Marcelo Aof\n" "Plural-Forms: nplurals=2; plural=(n > 1);\n" -"Language: pt_BR\n" +"X-Generator: Poedit 3.3.1\n" -#: custom-settings-widgets.py:12 +#: custom-settings-widgets.py:19 msgid "Radius" msgstr "Raio" -#: custom-settings-widgets.py:13 +#: custom-settings-widgets.py:20 msgid "Top Fade" msgstr "Esmaecimento superior" -#: custom-settings-widgets.py:14 +#: custom-settings-widgets.py:21 msgid "X Offset" msgstr "Deslocamento em X" -#: custom-settings-widgets.py:15 +#: custom-settings-widgets.py:22 msgid "Y Offset" msgstr "Deslocamento em Y" -#: custom-settings-widgets.py:16 +#: custom-settings-widgets.py:23 msgid "Opacity" msgstr "Opacidade" -#: custom-settings-widgets.py:39 +#: custom-settings-widgets.py:46 msgid "Class Name" msgstr "Nome da classe" -#: custom-settings-widgets.py:42 +#: custom-settings-widgets.py:49 msgid "State" msgstr "Estado" -#: custom-settings-widgets.py:102 +#: custom-settings-widgets.py:109 msgid "Import" msgstr "Importar" -#: custom-settings-widgets.py:106 +#: custom-settings-widgets.py:113 msgid "Export" msgstr "Exportar" -#: custom-settings-widgets.py:110 +#: custom-settings-widgets.py:117 msgid "Set from..." msgstr "Definir de..." -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose where to save your configuration" msgstr "Escolha onde salvar o seu ajuste" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose a configuration to load" msgstr "Escolha uma configuração para carregar" diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/ro.po b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/ro.po index 235129a3..6fc7aa14 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/ro.po +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/ro.po @@ -1,63 +1,64 @@ msgid "" msgstr "" -"Content-Transfer-Encoding: 8bit\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Language: ro\n" -"Language-Team: \n" -"Last-Translator: \n" -"MIME-Version: 1.0\n" -"PO-Revision-Date: 2022-08-06 01:54+0200\n" -"POT-Creation-Date: 2021-06-24 17:04+0200\n" -"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n==0 || (n!=1 && n%100>=1 && n%100<=19) ? 1 : 2);\n" "Project-Id-Version: user-shadows@nathan818fr\n" "Report-Msgid-Bugs-To: \n" -"X-Generator: Poedit 3.0.1\n" +"POT-Creation-Date: 2023-09-13 12:05+0200\n" +"PO-Revision-Date: 2023-09-13 12:22+0200\n" +"Last-Translator: Nathan POirier \n" +"Language-Team: \n" +"Language: ro\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n==0 || (n!=1 && n%100>=1 && " +"n%100<=19) ? 1 : 2);\n" +"X-Generator: Poedit 3.3.1\n" -#: custom-settings-widgets.py:12 +#: custom-settings-widgets.py:19 msgid "Radius" msgstr "Rază" -#: custom-settings-widgets.py:13 +#: custom-settings-widgets.py:20 msgid "Top Fade" msgstr "Fade de sus" -#: custom-settings-widgets.py:14 +#: custom-settings-widgets.py:21 msgid "X Offset" msgstr "Decalaj X" -#: custom-settings-widgets.py:15 +#: custom-settings-widgets.py:22 msgid "Y Offset" msgstr "Decalaj Y" -#: custom-settings-widgets.py:16 +#: custom-settings-widgets.py:23 msgid "Opacity" msgstr "Opacitate" -#: custom-settings-widgets.py:39 +#: custom-settings-widgets.py:46 msgid "Class Name" msgstr "Numele clasei" -#: custom-settings-widgets.py:42 +#: custom-settings-widgets.py:49 msgid "State" msgstr "Stare" -#: custom-settings-widgets.py:102 +#: custom-settings-widgets.py:109 msgid "Import" msgstr "Importă" -#: custom-settings-widgets.py:106 +#: custom-settings-widgets.py:113 msgid "Export" msgstr "Exportă" -#: custom-settings-widgets.py:110 +#: custom-settings-widgets.py:117 msgid "Set from..." msgstr "Setează din..." -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose where to save your configuration" msgstr "Alege unde să îți salvezi configurația" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose a configuration to load" msgstr "Alege o configurație de încărcat" diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/user-shadows@nathan818fr.pot b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/user-shadows@nathan818fr.pot index f22ac4e9..2c0f3e9c 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/user-shadows@nathan818fr.pot +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/po/user-shadows@nathan818fr.pot @@ -3,60 +3,60 @@ msgid "" msgstr "" "Project-Id-Version: user-shadows@nathan818fr\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-06-24 17:04+0200\n" +"POT-Creation-Date: 2023-09-13 12:05+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" "Language: \n" "MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=CHARSET\n" +"Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#: custom-settings-widgets.py:12 +#: custom-settings-widgets.py:19 msgid "Radius" msgstr "" -#: custom-settings-widgets.py:13 +#: custom-settings-widgets.py:20 msgid "Top Fade" msgstr "" -#: custom-settings-widgets.py:14 +#: custom-settings-widgets.py:21 msgid "X Offset" msgstr "" -#: custom-settings-widgets.py:15 +#: custom-settings-widgets.py:22 msgid "Y Offset" msgstr "" -#: custom-settings-widgets.py:16 +#: custom-settings-widgets.py:23 msgid "Opacity" msgstr "" -#: custom-settings-widgets.py:39 +#: custom-settings-widgets.py:46 msgid "Class Name" msgstr "" -#: custom-settings-widgets.py:42 +#: custom-settings-widgets.py:49 msgid "State" msgstr "" -#: custom-settings-widgets.py:102 +#: custom-settings-widgets.py:109 msgid "Import" msgstr "" -#: custom-settings-widgets.py:106 +#: custom-settings-widgets.py:113 msgid "Export" msgstr "" -#: custom-settings-widgets.py:110 +#: custom-settings-widgets.py:117 msgid "Set from..." msgstr "" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose where to save your configuration" msgstr "" -#: custom-settings-widgets.py:169 +#: custom-settings-widgets.py:176 msgid "Choose a configuration to load" msgstr "" diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/settings-schema.json b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/settings-schema.json index b1284a75..137a6eb4 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/settings-schema.json +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/settings-schema.json @@ -1,28 +1,28 @@ { - "preset": { - "description": "Shadows preset", - "type": "combobox", - "options": { - "Default": "default", - "No Shadows": "no-shadow", - "Arc Theme (Dark)": "arc-theme-dark", - "Arc Theme (Light)": "arc-theme-light", - "Custom": "_custom" - }, - "default": "default" + "preset": { + "description": "Shadows preset", + "type": "combobox", + "options": { + "Default": "default", + "No Shadows": "no-shadow", + "Arc Theme (Dark)": "arc-theme-dark", + "Arc Theme (Light)": "arc-theme-light", + "Custom": "_custom" }, - "customClasses": { - "type": "generic", - "default": {} - }, - "_customClassesWidget": { - "type": "custom", - "file": "custom-settings-widgets.py", - "widget": "CustomClassesWidget", - "dependency": "preset=_custom" - }, - "_extensionVars": { - "type": "generic", - "default": {} - } -} \ No newline at end of file + "default": "default" + }, + "customClasses": { + "type": "generic", + "default": {} + }, + "_customClassesWidget": { + "type": "custom", + "file": "custom-settings-widgets.py", + "widget": "CustomClassesWidget", + "dependency": "preset=_custom" + }, + "_extensionVars": { + "type": "generic", + "default": {} + } +} diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/constants.js b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/constants.js index cf11197d..6741245c 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/constants.js +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/constants.js @@ -1,4 +1,14 @@ -const SHADOW_CLASS_NAMES = ['normal', 'dialog', 'modal_dialog', 'utility', 'border', 'menu', 'popup-menu', 'dropdown-menu', 'attached']; +const SHADOW_CLASS_NAMES = [ + 'normal', + 'dialog', + 'modal_dialog', + 'utility', + 'border', + 'menu', + 'popup-menu', + 'dropdown-menu', + 'attached', +]; const SHADOW_STATES = { focused: 0, @@ -6,26 +16,58 @@ const SHADOW_STATES = { }; const SHADOW_PARAMS = { - radius: { index: 0, min: 1, max: 1024 }, - topFade: { index: 1, min: -1, max: 1024 }, - xOffset: { index: 2, min: -1024, max: 1024 }, - yOffset: { index: 3, min: -1024, max: 1024 }, - opacity: { index: 4, min: 0, max: 255 }, + radius: {index: 0, min: 1, max: 1024}, + topFade: {index: 1, min: -1, max: 1024}, + xOffset: {index: 2, min: -1024, max: 1024}, + yOffset: {index: 3, min: -1024, max: 1024}, + opacity: {index: 4, min: 0, max: 255}, }; // Fallback shadow classes, corresponding to the latest cinnamon version // (from: https://github.com/linuxmint/muffin/blob/bc2df248ac7395e86f62fc5d16cd7b9c9cb0f119/src/compositor/meta-shadow-factory.c#L120) const FALLBACK_SHADOW_CLASSES = { // className: [focused[radius, topFade, xOffset, yOffset, opacity], unfocused[...]] - 'normal': [[6, -1, 0, 3, 255], [3, -1, 0, 3, 128]], - 'dialog': [[6, -1, 0, 3, 255], [3, -1, 0, 3, 128]], - 'modal_dialog': [[6, -1, 0, 1, 255], [3, -1, 0, 3, 128]], - 'utility': [[3, -1, 0, 1, 255], [3, -1, 0, 1, 128]], - 'border': [[6, -1, 0, 3, 255], [3, -1, 0, 3, 128]], - 'menu': [[6, -1, 0, 3, 255], [3, -1, 0, 0, 128]], - 'popup-menu': [[1, -1, 0, 1, 128], [1, -1, 0, 1, 128]], - 'dropdown-menu': [[1, 10, 0, 1, 128], [1, 10, 0, 1, 128]], - 'attached': [[6, -1, 0, 1, 255], [3, -1, 0, 3, 128]], + normal: [ + [6, -1, 0, 3, 255], + [3, -1, 0, 3, 128], + ], + dialog: [ + [6, -1, 0, 3, 255], + [3, -1, 0, 3, 128], + ], + modal_dialog: [ + [6, -1, 0, 1, 255], + [3, -1, 0, 3, 128], + ], + utility: [ + [3, -1, 0, 1, 255], + [3, -1, 0, 1, 128], + ], + border: [ + [6, -1, 0, 3, 255], + [3, -1, 0, 3, 128], + ], + menu: [ + [6, -1, 0, 3, 255], + [3, -1, 0, 0, 128], + ], + 'popup-menu': [ + [1, -1, 0, 1, 128], + [1, -1, 0, 1, 128], + ], + 'dropdown-menu': [ + [1, 10, 0, 1, 128], + [1, 10, 0, 1, 128], + ], + attached: [ + [6, -1, 0, 1, 255], + [3, -1, 0, 3, 128], + ], }; -module.exports = { SHADOW_CLASS_NAMES, SHADOW_STATES, SHADOW_PARAMS, FALLBACK_SHADOW_CLASSES }; +module.exports = { + SHADOW_CLASS_NAMES, + SHADOW_STATES, + SHADOW_PARAMS, + FALLBACK_SHADOW_CLASSES, +}; diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/extension.js b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/extension.js index 4bcd4ba9..51be4799 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/extension.js +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/extension.js @@ -1,13 +1,13 @@ const Meta = imports.gi.Meta; const Settings = imports.ui.settings; -const { SHADOW_CLASS_NAMES, SHADOW_STATES, SHADOW_PARAMS, FALLBACK_SHADOW_CLASSES } = require('src/constants'); -const { getPresets } = require('src/presets'); -const { safeGet } = require('src/utils'); +const {SHADOW_CLASS_NAMES, SHADOW_STATES, SHADOW_PARAMS, FALLBACK_SHADOW_CLASSES} = require('src/constants'); +const {getPresets} = require('src/presets'); +const {safeGet} = require('src/utils'); class UserShadowsExtension { constructor(meta) { this._meta = meta; - this._instanceId = (Date.now() + Math.floor(Math.random() * 1000000)).toString(16) + this._instanceId = (Date.now() + Math.floor(Math.random() * 1000000)).toString(16); } enable() { @@ -52,7 +52,7 @@ class UserShadowsExtension { classNames: SHADOW_CLASS_NAMES, states: SHADOW_STATES, params: SHADOW_PARAMS, - presets: this._presets + presets: this._presets, }); }; set(); @@ -70,8 +70,16 @@ class UserShadowsExtension { _applyShadowClasses(shadowClasses) { for (const className of SHADOW_CLASS_NAMES) { - this._shadowFactory.set_params(className, true, this._deserializeShadowParams(shadowClasses, className, SHADOW_STATES.focused)); - this._shadowFactory.set_params(className, false, this._deserializeShadowParams(shadowClasses, className, SHADOW_STATES.unfocused)); + this._shadowFactory.set_params( + className, + true, + this._deserializeShadowParams(shadowClasses, className, SHADOW_STATES.focused) + ); + this._shadowFactory.set_params( + className, + false, + this._deserializeShadowParams(shadowClasses, className, SHADOW_STATES.unfocused) + ); } } @@ -94,11 +102,11 @@ class UserShadowsExtension { const params = safeGet(shadowClasses, className, stateIndex); const fallbackParams = (FALLBACK_SHADOW_CLASSES[className] || FALLBACK_SHADOW_CLASSES.normal)[stateIndex]; return new Meta.ShadowParams({ - 'radius': this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.radius), - 'top_fade': this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.topFade), - 'x_offset': this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.xOffset), - 'y_offset': this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.yOffset), - 'opacity': this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.opacity), + radius: this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.radius), + top_fade: this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.topFade), + x_offset: this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.xOffset), + y_offset: this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.yOffset), + opacity: this._deserializeShadowParam(params, fallbackParams, SHADOW_PARAMS.opacity), }); } diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/presets.js b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/presets.js index 9a91ded5..552ae70a 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/presets.js +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/presets.js @@ -1,4 +1,4 @@ -const { SHADOW_CLASS_NAMES } = require('src/constants'); +const {SHADOW_CLASS_NAMES} = require('src/constants'); function getPresets() { return { @@ -6,16 +6,40 @@ function getPresets() { 'no-shadow': all([1, 0, 0, 0, 0], [1, 0, 0, 0, 0]), 'arc-theme-dark': { - 'normal': [[ 7, -1, 0, 7, 89], [ 4, -1, 0, 4, 89]], - 'dialog': [[ 7, -1, 0, 7, 89], [ 4, -1, 0, 4, 89]], - 'modal_dialog': [[ 7, -1, 0, 7, 89], [ 4, -1, 0, 4, 89]], - 'border': [[ 7, -1, 0, 7, 89], [ 4, -1, 0, 4, 89]], + normal: [ + [7, -1, 0, 7, 89], + [4, -1, 0, 4, 89], + ], + dialog: [ + [7, -1, 0, 7, 89], + [4, -1, 0, 4, 89], + ], + modal_dialog: [ + [7, -1, 0, 7, 89], + [4, -1, 0, 4, 89], + ], + border: [ + [7, -1, 0, 7, 89], + [4, -1, 0, 4, 89], + ], }, 'arc-theme-light': { - 'normal': [[ 7, -1, 0, 7, 51], [ 4, -1, 0, 4, 51]], - 'dialog': [[ 7, -1, 0, 7, 51], [ 4, -1, 0, 4, 51]], - 'modal_dialog': [[ 7, -1, 0, 7, 51], [ 4, -1, 0, 4, 51]], - 'border': [[ 7, -1, 0, 7, 51], [ 4, -1, 0, 4, 51]], + normal: [ + [7, -1, 0, 7, 51], + [4, -1, 0, 4, 51], + ], + dialog: [ + [7, -1, 0, 7, 51], + [4, -1, 0, 4, 51], + ], + modal_dialog: [ + [7, -1, 0, 7, 51], + [4, -1, 0, 4, 51], + ], + border: [ + [7, -1, 0, 7, 51], + [4, -1, 0, 4, 51], + ], }, // TODO: Add Windows 10, mac OS, etc @@ -30,4 +54,4 @@ function all(focused, unfocused) { return ret; } -module.exports = { getPresets }; +module.exports = {getPresets}; diff --git a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/utils.js b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/utils.js index a5ddfdb2..2d1b260d 100644 --- a/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/utils.js +++ b/user-shadows@nathan818fr/files/user-shadows@nathan818fr/src/utils.js @@ -8,4 +8,4 @@ function safeGet(obj, ...keys) { return obj; } -module.exports = { safeGet }; +module.exports = {safeGet}; diff --git a/user-shadows@nathan818fr/info.json b/user-shadows@nathan818fr/info.json index 54f915a9..16957fd7 100644 --- a/user-shadows@nathan818fr/info.json +++ b/user-shadows@nathan818fr/info.json @@ -1,4 +1,4 @@ { - "author": "nathan818fr", - "license": "MIT" -} \ No newline at end of file + "author": "nathan818fr", + "license": "MIT" +}