From 56d8cd14fd3070caf6c1c8e33221180bc08e6ca8 Mon Sep 17 00:00:00 2001 From: Daniel Napora Date: Mon, 30 Sep 2024 00:41:52 +0200 Subject: [PATCH] upd --- bin/colorizer-fonts | 2 +- bin/conkyctl | 44 +++++++++++++++++++++++--------------------- 2 files changed, 24 insertions(+), 22 deletions(-) diff --git a/bin/colorizer-fonts b/bin/colorizer-fonts index 652d626..b4628b2 100755 --- a/bin/colorizer-fonts +++ b/bin/colorizer-fonts @@ -375,7 +375,7 @@ if [[ "$1" == "-s" ]]; then MENU_PADDING_TOP=$((jgtools_padding + 150)) #WALLPAPER - read WALLPATH<<< $(grep file "$HOME"/.config/nitrogen/bg-saved.cfg | cut -d'=' -f2) + read WALLPATH<<< $(grep file "$HOME"/.config/nitrogen/bg-saved.cfg | tail -1 | cut -d'=' -f2) THUMBDIR="$HOME/.cache/colorizer/thumbs" mkdir -p ${THUMBDIR} NAME=${WALLPATH////_} diff --git a/bin/conkyctl b/bin/conkyctl index 67ca023..2e8d563 100755 --- a/bin/conkyctl +++ b/bin/conkyctl @@ -817,9 +817,10 @@ if [[ "$OLD_SYNTAX" = "true" ]];then fi - +if [[ "$FONT" != "" ]];then if [[ "$1" != *"logo_mbcolor"* ]]; then if [[ "$1" != *"quoter_mbcolor"* ]]; then + out+=("󰛖 $FONTS [ $FONT $FONTSIZE ],^checkout(fontsingle)") out2+=("^tag(fontsingle)") out2+=("^sep($FONTS)") @@ -828,32 +829,32 @@ if [[ "$OLD_SYNTAX" = "true" ]];then out2+=("󰧴 $INCREASE $((FONTSIZE+1)) px,conkyctl basefont_inc ${1};$me") out2+=("󰧳 $DECREASE $((FONTSIZE-1)) px,conkyctl basefont_dec ${1};$me") out2+=("^sep()") - sizes=(14 13 12 11 10 9 8 7 6) - for i in "${sizes[@]}" - do - [[ "$FONTSIZE" == "$i" ]] && out2+=(" $i px,conkyctl basefont_size ${1} $i;$me") || out2+=(" $i px,conkyctl basefont_size ${1} $i;$me") - done - - if [ -f "$HOME/.config/mabox/fonts.list" ];then - mapfile -t favfonts < <( grep -vE "^($|#)" ~/.config/mabox/fonts.list) - else - mapfile -t favfonts < <( grep -vE "^($|#)" /usr/share/mabox-colorizer/fonts.list) - cp /usr/share/mabox-colorizer/fonts.list ~/.config/mabox/ - fi - #notify-send.sh "Ile" "${#favfonts[@]}" - if [ "${#favfonts[@]}" -gt 0 ];then - out2+=("^sep($FONTFAMILY_LBL)") - for fon in "${favfonts[@]}";do - [[ "$FONT" == "$fon" ]] && out2+=(" ${fon},$me") || out2+=(" ${fon},conkyctl basefont_family ${1} \"${fon}\";$me") + sizes=(14 13 12 11 10 9 8 7 6) + for i in "${sizes[@]}" + do + [[ "$FONTSIZE" == "$i" ]] && out2+=(" $i px,conkyctl basefont_size ${1} $i;$me") || out2+=(" $i px,conkyctl basefont_size ${1} $i;$me") done - fi + + if [ -f "$HOME/.config/mabox/fonts.list" ];then + mapfile -t favfonts < <( grep -vE "^($|#)" ~/.config/mabox/fonts.list) + else + mapfile -t favfonts < <( grep -vE "^($|#)" /usr/share/mabox-colorizer/fonts.list) + cp /usr/share/mabox-colorizer/fonts.list ~/.config/mabox/ + fi + #notify-send.sh "Ile" "${#favfonts[@]}" + if [ "${#favfonts[@]}" -gt 0 ];then + out2+=("^sep($FONTFAMILY_LBL)") + for fon in "${favfonts[@]}";do + [[ "$FONT" == "$fon" ]] && out2+=(" ${fon},$me") || out2+=(" ${fon},conkyctl basefont_family ${1} \"${fon}\";$me") + done + fi out2+=("^sep()") out2+=(" $_EDIT_FAVFONTS,geany ~/.config/mabox/fonts.list") - + fi [[ "$SHADOWS" == "shadow" ]] && out+=("󰄲 $SHADOW,conkyctl shades no ${1};$me") || out+=("󰄱 $SHADOW,conkyctl shades shadow ${1};$me") [[ "$SHADOWS" == "outline" ]] && out+=("󰄲 $OLINE,conkyctl shades no ${1};$me") || out+=("󰄱 $OLINE,conkyctl shades outline ${1};$me") - out+=("^sep()") + #out+=("^sep()") fi [[ "$BORD" == false ]] && out+=("󰄱 $BORDERS [ $STIP ],^checkout(bordersingle)") || out+=("󰄲 $BORDERS [ $STIP ],^checkout(bordersingle)") @@ -868,6 +869,7 @@ if [[ "$OLD_SYNTAX" = "true" ]];then out2+=("2,conkyctl stippled_borders 2 ${1};$me") out2+=("3,conkyctl stippled_borders 3 ${1};$me") out2+=("4,conkyctl stippled_borders 4 ${1};$me") +fi fi #OLD SYNTAX CHECK out+=("^sep()") out+=(" $EDIT ${title^},xdg-open ${1}")