-
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat!: use breeze scripts to build xcursors & plasma scalable SVGs (#40)
Co-authored-by: isabel <[email protected]> Co-authored-by: sgoudham <[email protected]>
- Loading branch information
1 parent
6ed521a
commit 3c9b12e
Showing
241 changed files
with
617 additions
and
3,258 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
Cursors: | ||
Alexey varfolomeev <[email protected]> - volantes-cursors | ||
Kylie <https://github.com/covkie> - whiskers template conversion & optimizations | ||
|
||
Colors: | ||
elkrien <https://github.com/elkrien> - coloring cursors with Catppuccin palette | ||
|
@@ -10,3 +11,4 @@ Build script: | |
Moded by Efus10n & jnzhng from https://github.com/keeferrourke/capitaine-cursors | ||
Goudham Suresh <https://github.com/sgoudham> - script performance improvements | ||
Jeffrey Geer <https://github.com/trowgundam> - hyprcursor support | ||
Breeze script authors @ <https://invent.kde.org/plasma/breeze/-/blob/master/cursors/src/> build.sh #05b7c781f8bc7c167364a0278ab7d6861a8124c0 & generate_cursors #79402e44ca482dfff1bd348c0b3a895a5d485f33 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -euo pipefail | ||
|
||
BIN_DIR="$( dirname "${BASH_SOURCE[0]}" )" | ||
SRC_DIR="src" | ||
BUILD_DIR="$2" | ||
RAWSVG_DIR="$1" | ||
ALIASES="$SRC_DIR/cursorList" | ||
|
||
NOMINAL_SIZE=24 | ||
REAL_SIZE=32 | ||
FRAME_TIME=30 | ||
SCALES="50 75 100 125 150 175 200 225 250 275 300" | ||
|
||
# Make folders | ||
for scale in $SCALES; do | ||
mkdir -p "$BUILD_DIR/x$scale" | ||
done | ||
mkdir -p "$BUILD_DIR/config" | ||
|
||
# Generate pixmaps | ||
for RAWSVG in ${RAWSVG_DIR}/*.svg; do | ||
BASENAME=${RAWSVG##*/} | ||
BASENAME=${BASENAME%.*} | ||
genPixmaps="file-open:${RAWSVG};" | ||
|
||
for scale in $SCALES; do | ||
DIR="$BUILD_DIR/x${scale}" | ||
if [[ "${DIR}/${BASENAME}.png" -ot ${RAWSVG} ]]; then | ||
genPixmaps="${genPixmaps} export-width:$((${REAL_SIZE}*scale/100)); export-height:$((${REAL_SIZE}*scale/100)); export-filename:${DIR}/${BASENAME}.png; export-do;" | ||
fi | ||
done | ||
if [ "$genPixmaps" != "file-open:${RAWSVG};" ]; then | ||
inkscape --shell <<<${genPixmaps} &>/dev/null | ||
fi | ||
|
||
done | ||
|
||
# Generate cursor theme | ||
OUTPUT=$3 | ||
rm -rf "$OUTPUT" | ||
mkdir -p "$OUTPUT/cursors" | ||
mkdir -p "$OUTPUT/cursors_scalable" | ||
$BIN_DIR/generate-xcursor-plasmasvg ${RAWSVG_DIR} "$BUILD_DIR" "$OUTPUT/cursors" "$OUTPUT/cursors_scalable" ${NOMINAL_SIZE} ${FRAME_TIME} ${SCALES} | ||
|
||
# Generate shortcuts | ||
while read ALIAS ; do | ||
FROM=${ALIAS% *} | ||
TO=${ALIAS#* } | ||
|
||
if [[ -e "$OUTPUT/cursors/$FROM" ]]; then | ||
continue | ||
fi | ||
|
||
ln -s "$TO" "$OUTPUT/cursors/$FROM" | ||
done < $ALIASES | ||
|
||
while read ALIAS ; do | ||
FROM=${ALIAS% *} | ||
TO=${ALIAS#* } | ||
|
||
if [[ -e "$OUTPUT/cursors_scalable/$FROM" ]]; then | ||
continue | ||
fi | ||
|
||
ln -s "$TO" "$OUTPUT/cursors_scalable/$FROM" | ||
done < $ALIASES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.