diff --git a/Installer/color-build.sh b/Installer/color-build.sh index 11d502b..57b5ea0 100755 --- a/Installer/color-build.sh +++ b/Installer/color-build.sh @@ -1,35 +1,39 @@ -#!/bin/sh -eu +#!/bin/sh # From github.com/skinatro/theme-tool help() { - cat < -s +Usage: ${0##*/} -o -s -f -o Output directory -s Source file + -f Flavour name (Mocha, Macchiato, Frappe, Latte) EOF - exit 1 # Exit script after printing help + exit 1 # Exit script after printing help } -while getopts o:s: opt; do - case "$opt" in - o) OUT="$OPTARG" ;; - s) SOURCE="$OPTARG" ;; - ?) help ;; # Print help in case parameter is non-existent - esac +while getopts o:s:f: opt; do + case "$opt" in + o) OUT="$OPTARG" ;; + s) SOURCE="$OPTARG" ;; + f) FLAVOURNAME="$OPTARG" ;; # New case for -f + ?) help ;; + esac done # Print help in case parameters are empty -if [ -z "$OUT" ] || [ -z "$SOURCE" ]; then - echo "Some or all of the parameters are empty" - help +if [ -z "$OUT" ] || [ -z "$SOURCE" ] || [ -z "$FLAVOURNAME" ]; then + echo "Some or all of the parameters are empty" + help fi # no arrays due to posix compliancy if echo "$FLAVOURNAME" | grep -Evq 'Mocha|Macchiato|Frappe|Latte'; then - clear - echo "Invalid palette $FLAVOURNAME" - exit + clear + echo "Invalid palette $FLAVOURNAME" + exit fi -sed -f Installer/Pallets/"$FLAVOURNAME".sed "$SOURCE" > "$OUT" + +FLAVOUR_SED="Installer/Pallets/${FLAVOURNAME}.sed" +sed -f "$FLAVOUR_SED" "$SOURCE" > "$OUT" diff --git a/README.md b/README.md index 7e4f5e8..7c2bfa1 100644 --- a/README.md +++ b/README.md @@ -50,20 +50,14 @@ ## Notes -1. To get a modern, more consistent look, install the [Lightly application style](https://github.com/Luwx/Lightly) and select it from System Settings > Appearance > Application Style > Lightly. -2. If you encounter an error similar to 'connection refused' while running the installation script, it may be due to store.kde.org being down or issues with your internet connection. +If you encounter an error similar to 'connection refused' while running the installation script, it may be due to store.kde.org being down or issues with your internet connection. -## Licensing -The theme makes modifications to [doncsugar's](https://github.com/doncsugar) [lightly plasma style](https://github.com/doncsugar/lightly-plasma). It is licensed under GPL 3.0 and as such, all the changes to the plasma theme are also licensed under GPL. The MIT License still applies to the color scheme, splash screen and the window decorations theme. +## 💝 Current Maintainer +- [Sourcastic](https://github.com/Sourcastic) -## 💝 Thanks to - +## 💖 Past Maintainers - [Prayag2](https://github.com/Prayag2) -- [Sourcastic](https://github.com/Sourcastic) -- [Cequallium](https://github.com/Cequallium) -- [justTOBBI](https://github.com/justTOBBI) -   diff --git a/Resources/LookAndFeel/defaults b/Resources/LookAndFeel/defaults index 703c457..b9be988 100644 --- a/Resources/LookAndFeel/defaults +++ b/Resources/LookAndFeel/defaults @@ -11,7 +11,7 @@ library=org.kde.kwin.aurorae theme=--aurorae [plasmarc][Theme] -name=lightly-plasma-git +name=default [KSplash] Theme=Catppuccin---flavour---accentName-splash diff --git a/Resources/LookAndFeel/metadata.desktop b/Resources/LookAndFeel/metadata.desktop index cde73a6..14a3e06 100644 --- a/Resources/LookAndFeel/metadata.desktop +++ b/Resources/LookAndFeel/metadata.desktop @@ -10,4 +10,4 @@ X-KDE-PluginInfo-Name=Catppuccin---flavour---accentName X-KDE-PluginInfo-Version=0.2.6 X-KDE-PluginInfo-Website=github.com/catppuccin/KDE X-KDE-ServiceTypes=Plasma/LookAndFeel -X-KPackage-Dependencies=kns://plasma-themes.knsrc/api.kde-look.org/1879921,kns://aurorae.knsrc/api.kde-look.org/--StoreAuroraeNo +X-KPackage-Dependencies=kns://aurorae.knsrc/api.kde-look.org/--StoreAuroraeNo diff --git a/Resources/LookAndFeel/metadata.json b/Resources/LookAndFeel/metadata.json index bd0a078..9da55e4 100644 --- a/Resources/LookAndFeel/metadata.json +++ b/Resources/LookAndFeel/metadata.json @@ -17,7 +17,6 @@ "Version": "0.2.6" }, "X-KPackage-Dependencies": [ - "kns://plasma-themes.knsrc/api.kde-look.org/1879921", "kns://aurorae.knsrc/api.kde-look.org/--StoreAuroraeNo" ] } diff --git a/Resources/splash-screen/contents/splash/Splash.qml b/Resources/splash-screen/contents/splash/Splash.qml index 0e7a163..65b8f2a 100644 --- a/Resources/splash-screen/contents/splash/Splash.qml +++ b/Resources/splash-screen/contents/splash/Splash.qml @@ -7,10 +7,8 @@ SPDX-License-Identifier: MIT */ -import Qt5Compat.GraphicalEffects 1.15 -import QtQuick 2.5 -import QtQuick.Window 2.2 -import org.kde.plasma.core as PlasmaCore +import QtQuick +import org.kde.kirigami 2 as Kirigami Rectangle { id: root @@ -33,7 +31,8 @@ Rectangle { id: content anchors.fill: parent opacity: 0 - + //TODO: Figure out how to port DropShadow to KDE6, erase comment when ported. +/* DropShadow { anchors.fill: logo horizontalOffset: 0 @@ -44,17 +43,17 @@ Rectangle { source: logo opacity: 0.1 } - +*/ Image { id: logo //match SDDM/lockscreen avatar positioning - property real size: PlasmaCore.Units.gridUnit * 8 + readonly property real size: Kirigami.Units.gridUnit * 8 anchors.centerIn: parent source: "images/Logo.png" sourceSize.width: size - sourceSize.height: size + sourceSize.height: sizes smooth: true visible: true } @@ -65,15 +64,15 @@ Rectangle { y: parent.height - (parent.height - logo.y) / 2 - height/2 anchors.horizontalCenter: parent.horizontalCenter source: "images/busywidget.svg" - sourceSize.height: PlasmaCore.Units.gridUnit * 3.5 - sourceSize.width: PlasmaCore.Units.gridUnit * 3.5 + sourceSize.height: Kirigami.Units.gridUnit * 3.5 + sourceSize.width: Kirigami.Units.gridUnit * 3.5 RotationAnimator on rotation { id: rotationAnimator from: 0 to: 360 duration: 2000 loops: Animation.Infinite - running: PlasmaCore.Units.longDuration > 1 + running: Kirigami.Units.longDuration > 1 } } } @@ -84,7 +83,7 @@ Rectangle { target: content from: 0 to: 1 - duration: PlasmaCore.Units.veryLongDuration * 2 + duration: Kirigami.Units.veryLongDuration * 2 easing.type: Easing.InOutQuad } } diff --git a/install.sh b/install.sh index 58caecf..37ece2e 100755 --- a/install.sh +++ b/install.sh @@ -3,9 +3,9 @@ # Syntax check_command_exists() { - command_name="$@" + command_name="${*}" - if ! command -v "$command_name" &> /dev/null; then + if ! command -v "$command_name" >/dev/null 2>&1; then echo "Error: Dependency '$command_name' is not met." echo "Exiting.." exit 1 @@ -20,11 +20,10 @@ check_command_exists "lookandfeeltool" COLORDIR="${XDG_DATA_HOME:-$HOME/.local/share}/color-schemes" AURORAEDIR="${XDG_DATA_HOME:-$HOME/.local/share}/aurorae/themes" LOOKANDFEELDIR="${XDG_DATA_HOME:-$HOME/.local/share}/plasma/look-and-feel" -DESKTOPTHEMEDIR="${XDG_DATA_HOME:-$HOME/.local/share}/plasma/desktoptheme" CURSORDIR="${XDG_DATA_HOME:-$HOME/.local/share}/icons" echo "Creating theme directories.." -mkdir -p "$COLORDIR" "$AURORAEDIR" "$LOOKANDFEELDIR" "$DESKTOPTHEMEDIR" "$CURSORDIR" +mkdir -p "$COLORDIR" "$AURORAEDIR" "$LOOKANDFEELDIR" "$CURSORDIR" mkdir ./dist # Fast install @@ -238,7 +237,7 @@ case "$WINDECSTYLE" in 1) WINDECSTYLENAME=Modern WINDECSTYLECODE=__aurorae__svg__Catppuccin"$FLAVOURNAME"-Modern - + case "$FLAVOUR" in 1) StoreAuroraeNo="2135229" ;; 2) StoreAuroraeNo="2135227" ;; @@ -259,7 +258,7 @@ EOF 2) WINDECSTYLENAME=Classic WINDECSTYLECODE=__aurorae__svg__Catppuccin"$FLAVOURNAME"-Classic - + case "$FLAVOUR" in 1) StoreAuroraeNo="2135228" ;; 2) StoreAuroraeNo="2135226" ;; @@ -275,29 +274,11 @@ EOF *) echo "Not a valid Window decoration" ;; esac -ModifyLightlyPlasma() { - rm -rf "$DESKTOPTHEMEDIR"/lightly-plasma-git/icons/* - rm -rf "$DESKTOPTHEMEDIR"/lightly-plasma-git/translucent - rm "$DESKTOPTHEMEDIR"/lightly-plasma-git/widgets/tabbar.svgz - rm "$DESKTOPTHEMEDIR"/lightly-plasma-git/dialogs/background.svgz - - # Copy Patches - cp -rf "$DESKTOPTHEMEDIR"/lightly-plasma-git/solid/* "$DESKTOPTHEMEDIR"/lightly-plasma-git - cp -rf ./Patches/glowbar.svg "$DESKTOPTHEMEDIR"/lightly-plasma-git/widgets - cp -rf ./Patches/background.svg "$DESKTOPTHEMEDIR"/lightly-plasma-git/widgets - cp ./Patches/panel-background.svgz "$DESKTOPTHEMEDIR"/lightly-plasma-git/widgets - - # Modify description to state that it has been modified by the KDE Catppuccin Installer - sed -i 's/A plasma style with close to the look of the newest Lightly./*MODIFIED BY CATPPUCCIN KDE INSTALLER* &/g' "$DESKTOPTHEMEDIR"/lightly-plasma-git/metadata.desktop - cp -f "$DESKTOPTHEMEDIR"/metadata.desktop "$DESKTOPTHEMEDIR"/lightly-plasma-git/metadata.desktop - rm "$DESKTOPTHEMEDIR"/metadata.desktop -} - BuildColorscheme() { # Add Metadata & Replace Accent in colors file sed "s/--accentColor/$ACCENTCOLOR/g; s/--flavour/$FLAVOURNAME/g; s/--accentName/$ACCENTNAME/g" ./Resources/Base.colors > ./dist/base.colors # Hydrate Dummy colors according to Pallet - FLAVOURNAME="$FLAVOURNAME" ./Installer/color-build.sh -o ./dist/Catppuccin"$FLAVOURNAME$ACCENTNAME".colors -s ./dist/base.colors + ./Installer/color-build.sh -f "$FLAVOURNAME" -o ./dist/Catppuccin"$FLAVOURNAME$ACCENTNAME".colors -s ./dist/base.colors } BuildSplashScreen() { @@ -323,13 +304,13 @@ BuildSplashScreen() { else cp ./Resources/splash-screen/contents/splash/images/Latte_Logo.png ./dist/"$SPLASHSCREENNAME"/contents/splash/images/Logo.png fi - sed "s/--accentName/$ACCENTNAME/g; s/--flavour/$FLAVOURNAME/g" ./Resources/splash-screen/metadata.desktop > ./dist/"$SPLASHSCREENNAME"/metadata.desktop - sed "s/--accentName/$ACCENTNAME/g; s/--flavour/$FLAVOURNAME/g" ./Resources/splash-screen/metadata.json > ./dist/"$SPLASHSCREENNAME"/metadata.json - cp ./dist/"$GLOBALTHEMENAME"/contents/defaults ./dist/"$SPLASHSCREENNAME"/contents/defaults + #sed "s/--accentName/$ACCENTNAME/g; s/--flavour/$FLAVOURNAME/g" ./Resources/splash-screen/metadata.desktop > ./dist/"$SPLASHSCREENNAME"/metadata.desktop + #sed "s/--accentName/$ACCENTNAME/g; s/--flavour/$FLAVOURNAME/g" ./Resources/splash-screen/metadata.json > ./dist/"$SPLASHSCREENNAME"/metadata.json mkdir ./dist/"$SPLASHSCREENNAME"/contents/previews cp ./Resources/splash-previews/"$FLAVOURNAME".png ./dist/"$SPLASHSCREENNAME"/contents/previews/splash.png - cp ./Resources/splash-previews/"$FLAVOURNAME".png ./dist/"$SPLASHSCREENNAME"/contents/previews/preview.png - cp -r ./dist/"$SPLASHSCREENNAME" "$LOOKANDFEELDIR"/ + # cp ./Resources/splash-previews/"$FLAVOURNAME".png ./dist/"$SPLASHSCREENNAME"/contents/previews/preview.png + cp -r ./dist/"$SPLASHSCREENNAME"/contents/splash/ "$LOOKANDFEELDIR"/"$GLOBALTHEMENAME"/contents/ + cp -r ./dist/"$SPLASHSCREENNAME"/contents/previews/* "$LOOKANDFEELDIR"/"$GLOBALTHEMENAME"/contents/previews/ } InstallAuroraeTheme() { @@ -357,9 +338,7 @@ InstallGlobalTheme() { # Modify 'defaults' to set the correct Aurorae Theme sed "s/--accentName/$ACCENTNAME/g; s/--flavour/$FLAVOURNAME/g; s/--aurorae/$WINDECSTYLECODE/g" ./Resources/LookAndFeel/defaults > ./dist/Catppuccin-"$FLAVOURNAME"-"$ACCENTNAME"/contents/defaults - # Build SplashScreen - echo "Building SplashScreen.." - BuildSplashScreen + # Install Global Theme. # This refers to the QDBusConnection: error: could not send signal to service error @@ -368,42 +347,20 @@ InstallGlobalTheme() { cat <