Compare commits

..

No commits in common. "master" and "0.9.76" have entirely different histories.

8 changed files with 27 additions and 318 deletions

View File

@ -124,7 +124,6 @@ case "$LANG" in
RESETCOLORS="Przywróć domyślne kolory" RESETCOLORS="Przywróć domyślne kolory"
AREYOUSURE="Czy aby napewno?" AREYOUSURE="Czy aby napewno?"
_COLORIZER_ROOT="<b>Colorizer</b> - menu główne" _COLORIZER_ROOT="<b>Colorizer</b> - menu główne"
_LEFTSIDEPANEL="Lewy panel boczny"
;; ;;
*) *)
COLORIZECONKY="Conky Manager" COLORIZECONKY="Conky Manager"
@ -182,7 +181,6 @@ case "$LANG" in
RESETCOLORS="Restore default colors" RESETCOLORS="Restore default colors"
AREYOUSURE="Are you sure?" AREYOUSURE="Are you sure?"
_COLORIZER_ROOT="<b>Colorizer</b> rootmenu" _COLORIZER_ROOT="<b>Colorizer</b> rootmenu"
_LEFTSIDEPANEL="Left Sidepanel"
;; ;;
esac esac
@ -479,7 +477,6 @@ if [[ "$1" == "-s" ]]; then
out+=("^sep()") out+=("^sep()")
out+=(" ${arrow_string_left} $_COLORIZER_ROOT,colorizer -s") out+=(" ${arrow_string_left} $_COLORIZER_ROOT,colorizer -s")
out+=(" ${arrow_string_left} ${arrow_string_left} $_LEFTSIDEPANEL,mb-jgtools places")
if [[ "$colorizer_size" == "full" ]];then if [[ "$colorizer_size" == "full" ]];then
eval $(xdotool getdisplaygeometry --shell) eval $(xdotool getdisplaygeometry --shell)

View File

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
# #
# colorizer - set of tools for Mabox (auto)theming # colorizer - set of tools for Mabox (auto)theming
# Copyright (C) 2022-2024 Daniel Napora <napcok@gmail.com> # Copyright (C) 2022-2023 Daniel Napora <napcok@gmail.com>
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by # it under the terms of the GNU General Public License as published by
@ -70,7 +70,6 @@ case "$LANG" in
_USE="Użyj czcionki" _USE="Użyj czcionki"
_FOR="dla..." _FOR="dla..."
_COLORIZER_ROOT="<b>Colorizer</b> - menu główne" _COLORIZER_ROOT="<b>Colorizer</b> - menu główne"
_LEFTSIDEPANEL="Lewy panel boczny"
;; ;;
*) *)
_INCREASE_ALL="Increase all" _INCREASE_ALL="Increase all"
@ -108,7 +107,6 @@ case "$LANG" in
_USE="Use" _USE="Use"
_FOR="font for ..." _FOR="font for ..."
_COLORIZER_ROOT="<b>Colorizer</b> rootmenu" _COLORIZER_ROOT="<b>Colorizer</b> rootmenu"
_LEFTSIDEPANEL="Left Sidepanel"
;; ;;
esac esac
@ -352,7 +350,6 @@ if [[ "$1" == "-s" ]]; then
out+=("^sep()") out+=("^sep()")
out+=(" ${arrow_string_left} $_COLORIZER_ROOT,colorizer -s") out+=(" ${arrow_string_left} $_COLORIZER_ROOT,colorizer -s")
out+=(" ${arrow_string_left} ${arrow_string_left} $_LEFTSIDEPANEL,mb-jgtools places")
if [[ "$colorizer_size" == "full" ]];then if [[ "$colorizer_size" == "full" ]];then
eval $(xdotool getdisplaygeometry --shell) eval $(xdotool getdisplaygeometry --shell)
@ -375,7 +372,7 @@ if [[ "$1" == "-s" ]]; then
MENU_PADDING_TOP=$((jgtools_padding + 150)) MENU_PADDING_TOP=$((jgtools_padding + 150))
#WALLPAPER #WALLPAPER
read WALLPATH<<< $(grep file "$HOME"/.config/nitrogen/bg-saved.cfg | tail -1 | cut -d'=' -f2) read WALLPATH<<< $(grep file "$HOME"/.config/nitrogen/bg-saved.cfg | cut -d'=' -f2)
THUMBDIR="$HOME/.cache/colorizer/thumbs" THUMBDIR="$HOME/.cache/colorizer/thumbs"
mkdir -p ${THUMBDIR} mkdir -p ${THUMBDIR}
NAME=${WALLPATH////_} NAME=${WALLPATH////_}

View File

@ -147,7 +147,6 @@ case "$LANG" in
FILE="plik" FILE="plik"
SET_RANDOM="Ustaw losowy motyw menu" SET_RANDOM="Ustaw losowy motyw menu"
_COLORIZER_ROOT="<b>Colorizer</b> - menu główne" _COLORIZER_ROOT="<b>Colorizer</b> - menu główne"
_LEFTSIDEPANEL="Lewy panel boczny"
;; ;;
*) *)
MENU_THEME="Menu theme" MENU_THEME="Menu theme"
@ -232,7 +231,6 @@ case "$LANG" in
FILE="file" FILE="file"
SET_RANDOM="Set random menu theme" SET_RANDOM="Set random menu theme"
_COLORIZER_ROOT="<b>Colorizer</b> rootmenu" _COLORIZER_ROOT="<b>Colorizer</b> rootmenu"
_LEFTSIDEPANEL="Left Sidepanel"
;; ;;
esac esac
@ -575,7 +573,6 @@ if [[ "$1" == "-s" ]]; then
out+=("^sep()") out+=("^sep()")
out+=(" ${arrow_string_left} $_COLORIZER_ROOT,colorizer -s") out+=(" ${arrow_string_left} $_COLORIZER_ROOT,colorizer -s")
out+=(" ${arrow_string_left} ${arrow_string_left} $_LEFTSIDEPANEL,mb-jgtools places")
if [[ "$colorizer_size" == "full" ]];then if [[ "$colorizer_size" == "full" ]];then
eval $(xdotool getdisplaygeometry --shell) eval $(xdotool getdisplaygeometry --shell)

View File

@ -140,7 +140,6 @@ case "$LANG" in
UNLOCK="odblokuj swoją kreatywność..." UNLOCK="odblokuj swoją kreatywność..."
SWITCH_TO_MBCOLORS="Przełącz na <b>MBColors</b>" SWITCH_TO_MBCOLORS="Przełącz na <b>MBColors</b>"
_COLORIZER_ROOT="<b>Colorizer</b> - menu główne" _COLORIZER_ROOT="<b>Colorizer</b> - menu główne"
_LEFTSIDEPANEL="Lewy panel boczny"
;; ;;
*) *)
QUICK_TWEAKS="Global Settings/Quick Tweaks" QUICK_TWEAKS="Global Settings/Quick Tweaks"
@ -226,7 +225,6 @@ case "$LANG" in
UNLOCK="Unlock your creativity..." UNLOCK="Unlock your creativity..."
SWITCH_TO_MBCOLORS="Switch to <b>MBColors</b>" SWITCH_TO_MBCOLORS="Switch to <b>MBColors</b>"
_COLORIZER_ROOT="<b>Colorizer</b> rootmenu" _COLORIZER_ROOT="<b>Colorizer</b> rootmenu"
_LEFTSIDEPANEL="Left Sidepanel"
;; ;;
esac esac
@ -669,7 +667,6 @@ source $HOME/.config/colorizer/colorizer.conf
out+=("^sep()") out+=("^sep()")
out+=(" ${arrow_string_left} $_COLORIZER_ROOT,colorizer -s") out+=(" ${arrow_string_left} $_COLORIZER_ROOT,colorizer -s")
out+=(" ${arrow_string_left} ${arrow_string_left} $_LEFTSIDEPANEL,mb-jgtools places")
if [[ "$colorizer_size" == "full" ]];then if [[ "$colorizer_size" == "full" ]];then

View File

@ -817,10 +817,9 @@ if [[ "$OLD_SYNTAX" = "true" ]];then
fi fi
if [[ "$FONT" != "" ]];then
if [[ "$1" != *"logo_mbcolor"* ]]; then if [[ "$1" != *"logo_mbcolor"* ]]; then
if [[ "$1" != *"quoter_mbcolor"* ]]; then if [[ "$1" != *"quoter_mbcolor"* ]]; then
out+=("<big>󰛖</big> $FONTS [ <b><span font_family=\"${FONT}\">$FONT</span> $FONTSIZE</b> ],^checkout(fontsingle)") out+=("<big>󰛖</big> $FONTS [ <b><span font_family=\"${FONT}\">$FONT</span> $FONTSIZE</b> ],^checkout(fontsingle)")
out2+=("^tag(fontsingle)") out2+=("^tag(fontsingle)")
out2+=("^sep($FONTS)") out2+=("^sep($FONTS)")
@ -854,7 +853,7 @@ if [[ "$FONT" != "" ]];then
fi fi
[[ "$SHADOWS" == "shadow" ]] && out+=("<big>󰄲</big> $SHADOW,conkyctl shades no ${1};$me") || out+=("<big>󰄱</big> $SHADOW,conkyctl shades shadow ${1};$me") [[ "$SHADOWS" == "shadow" ]] && out+=("<big>󰄲</big> $SHADOW,conkyctl shades no ${1};$me") || out+=("<big>󰄱</big> $SHADOW,conkyctl shades shadow ${1};$me")
[[ "$SHADOWS" == "outline" ]] && out+=("<big>󰄲</big> $OLINE,conkyctl shades no ${1};$me") || out+=("<big>󰄱</big> $OLINE,conkyctl shades outline ${1};$me") [[ "$SHADOWS" == "outline" ]] && out+=("<big>󰄲</big> $OLINE,conkyctl shades no ${1};$me") || out+=("<big>󰄱</big> $OLINE,conkyctl shades outline ${1};$me")
#out+=("^sep()") out+=("^sep()")
fi fi
[[ "$BORD" == false ]] && out+=("<big>󰄱</big> $BORDERS [ <b>$STIP</b> ],^checkout(bordersingle)") || out+=("<big>󰄲</big> $BORDERS [ <b>$STIP</b> ],^checkout(bordersingle)") [[ "$BORD" == false ]] && out+=("<big>󰄱</big> $BORDERS [ <b>$STIP</b> ],^checkout(bordersingle)") || out+=("<big>󰄲</big> $BORDERS [ <b>$STIP</b> ],^checkout(bordersingle)")
@ -869,7 +868,6 @@ if [[ "$FONT" != "" ]];then
out2+=("2,conkyctl stippled_borders 2 ${1};$me") out2+=("2,conkyctl stippled_borders 2 ${1};$me")
out2+=("3,conkyctl stippled_borders 3 ${1};$me") out2+=("3,conkyctl stippled_borders 3 ${1};$me")
out2+=("4,conkyctl stippled_borders 4 ${1};$me") out2+=("4,conkyctl stippled_borders 4 ${1};$me")
fi
fi #OLD SYNTAX CHECK fi #OLD SYNTAX CHECK
out+=("^sep()") out+=("^sep()")
out+=(" $EDIT ${title^},xdg-open ${1}") out+=(" $EDIT ${title^},xdg-open ${1}")
@ -1022,9 +1020,7 @@ cmdmenu () {
label=${line%,*} label=${line%,*}
done <<< $(grep -v '^\s*$\|^#\|^\s*#' ${CONKYDIR}/menuscripts/${name}.csv) done <<< $(grep -v '^\s*$\|^#\|^\s*#' ${CONKYDIR}/menuscripts/${name}.csv)
#notify-send.sh "${label}" "${cmd[@]}" #notify-send.sh "${label}" "${cmd[@]}"
sleep .1
${cmd[@]} ${cmd[@]}
exit 0
else else
# more than 1 lines - show menu # more than 1 lines - show menu
CUSTOMCOMMANDS=". ${CONKYDIR}/menuscripts/${name}.csv" CUSTOMCOMMANDS=". ${CONKYDIR}/menuscripts/${name}.csv"
@ -1035,7 +1031,7 @@ cmdmenu () {
# otherwise build and show standalone menu with custom commands # otherwise build and show standalone menu with custom commands
sleep .1 sleep .2
read WINTRANS <<< "$(grep own_window_transparent ${CONKYCFG} | cut -d'=' -f2 | cut -d"," -f1)" read WINTRANS <<< "$(grep own_window_transparent ${CONKYCFG} | cut -d'=' -f2 | cut -d"," -f1)"
read FONTDEF <<< "$(grep "font .*=.*,$" ${CONKYCFG} | cut -d'=' -f2,3 |cut -d"'" -f2)" read FONTDEF <<< "$(grep "font .*=.*,$" ${CONKYCFG} | cut -d'=' -f2,3 |cut -d"'" -f2)"
FONT=${FONTDEF%:*} FONT=${FONTDEF%:*}
@ -1382,7 +1378,7 @@ case "$1" in
toggleone) toggleone "$2";; toggleone) toggleone "$2";;
restartone) restartone "$2";; restartone) restartone "$2";;
contextmenu) contextmenu;; contextmenu) contextmenu;;
cmdmenu) cmdmenu "$2";; cmdmenu) cmdmenu;;
cmdmenu_edit) cmdmenu_edit "$2";; cmdmenu_edit) cmdmenu_edit "$2";;
makemoveableall) makemoveableall;; makemoveableall) makemoveableall;;
saveposall) saveposall;; saveposall) saveposall;;

View File

@ -1,275 +0,0 @@
#!/bin/bash
# papirus-folder-color.sh
# Generate icon theme inheriting Papirus or Papirus-Dark,
# but with different coloured folder icons.
#
# Copyright: 2019-2022 John Crawley <john@bunsenlabs.org>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# If not overruled by --name option, this will be included in generated theme name.
# Other vendors, please edit to taste:
vendor=Mabox
USAGE="
papirus-folder-color.sh [OPTIONS]
Generates a user custom icon theme with a different folder color from
the default Papirus blue.
Options:
-h, --help
Show this message.
-c, --color <color>
Choose icon color.
-s, --source_path <path>
Set path to directory holding Papirus theme to be used.
-t, --target_path <path>
Set path to directory where new theme will be generated.
-n, --name <name>
Set name of generated theme.
-l, --link
Symlink icons to source instead of copying.
-d, --dark
Declare theme to be dark and inherit Papirus-Dark.
color must be specified and can be one of:
black,blue,bluegrey,breeze,brown,cyan,deeporange,green,grey,indigo,magenta,nordic,orange,palebrown,paleorange,pink,red,teal,violet,white,yaru,yellow,custom
NB \"custom\" color corresponds to jet black, while \"black\" is actually dark grey.
\"jet-black\" may also be passed as an alias for \"custom\".
If --source_path is not passed, the Papirus theme is read from
/usr/share/icons/Papirus
If --target_path is not passed, the generated theme is written to
~/.local/share/icons/<new theme name>
If --name is not passed, the generated theme will be named
Papirus-${vendor}[-Dark]-<color>.
By default icons will be copied into the new theme, not symlinked.
This increases the size, but improves portability.
Pass --link to generate symlinks instead.
If source_path and target_path are under the same top-level directory
then symlinked icons will use relative paths, otherwise absolute paths.
"
## default variables
## these can (should, at least for color) be overridden by script options
source_path=/usr/share/icons # place to find source Papirus theme
target_path="$HOME/.local/share/icons" # place to put generated theme
#target_path="$PWD"
copy_files=true # If true, copy icons into new theme instead of symlinking.
new_theme=''
color=''
error_exit() {
echo "$0 error: $1" >&2
exit 1
}
while [[ -n $1 ]]
do
case "$1" in
--color|-c)
color=$2
shift 2
;;
--source_path|-s)
source_path=$2
shift 2
;;
--target_path|-t)
target_path=$2
shift 2
;;
--name|-n)
new_theme=$2
shift 2
;;
--link|-l)
copy_files=false
shift
;;
--dark|-d)
dark_theme=true
shift
;;
--help|-h)
echo "$USAGE"
exit
;;
*)
error_exit "$1: Unrecognized option."
;;
esac
done
########################################################################
case "$color" in
adwaita|black|blue|bluegrey|breeze|brown|carmine|cyan|darkcyan|deeporange|green|grey|indigo|magenta|nordic|orange|palebrown|paleorange|pink|red|teal|violet|white|yaru|yellow|custom)
;;
jet-black)
color=custom;;
*)
error_exit "${color}: Unrecognized colour."
esac
[[ -n $new_theme ]] || {
if [[ $dark_theme = true ]]
then
new_theme="Papirus-${vendor}-Dark-${color}"
else
new_theme="Papirus-${vendor}-${color}"
fi
}
source_dir="$source_path/Papirus"
target_dir="$target_path/$new_theme"
[[ $(basename "$source_dir") = Papirus ]] || error_exit "$source_dir: Not a Papirus theme directory"
[[ $(basename "$target_dir") = Papirus* ]] || error_exit "$target_dir: Not a Papirus theme directory" # try to avoid accidents
# Define function to make symlinks,
# relative if source & target have same top-level directory.
# If copy_files is true, copy instead of linking.
set_linking() {
if [[ $copy_files = true ]]
then
link_file() { cp "$1" "$2"; }
else
local tld_src=$( readlink -f "${source_dir}" )
tld_src=${tld_src#/}
tld_src=${tld_src%%/*}
local tld_tgt=$( readlink -f "${target_dir}" )
tld_tgt=${tld_tgt#/}
tld_tgt=${tld_tgt%%/*}
if [[ "$tld_src" = "$tld_tgt" ]]
then
link_file() { ln -sfr "$1" "$2"; }
else
link_file() { ln -sf "$1" "$2"; }
fi
fi
}
set_linking
[[ -e "$target_dir" ]] && {
echo "$target_dir will be removed and replaced, OK?"
read -r -p ' remove? (y/n) '
case ${REPLY^^} in
Y|YES)
rm -rf "$target_dir" || error_exit "Failed to remove $target_dir";;
*)
echo 'User cancelled. Exiting...'; exit;;
esac
}
mkdir -p "$target_dir" || error_exit "Failed to create $target_dir"
defcolor=blue # the Papirus default
shortdirlist=
longdirlist=
for subdir in "$source_dir"/*
do
[[ -d ${subdir}/places && ! -h $subdir ]] || continue # only use icons in "places" directories
files=()
while IFS= read -r -d '' file
do
files+=("$file")
done < <(find "${subdir}/places" -type l \( -ilname "*-$defcolor-*" -o -lname "*-$defcolor.*" \) ! -iname "*-$defcolor-*" ! -iname "*-$defcolor.*" -print0)
[[ ${#files[@]} -gt 0 ]] || continue
dirname=${subdir##*/}
mkdir -p "$target_dir/${dirname}/places" || error_exit "Failed to create $target_dir/${dirname}/places"
scaledname=${dirname}@2x
[[ $dirname != symbolic ]] && ln -s "${dirname}" "${target_dir}/${scaledname}" || error_exit "Failed to link ${target_dir}/${scaledname} to ${dirname}"
for i in "${files[@]}"
do
find "${subdir}/places" -type l -lname "${i##*/}" -exec cp --no-dereference '{}' "$target_dir/${dirname}/places" \;
target="$(readlink "$i")"
target="${target/-${defcolor}/-${color}}"
[[ -f "$subdir/places/$target" ]] || { echo "$subdir/places/$target: not found"; continue; }
link_file "$subdir/places/$target" "$target_dir/$dirname/places/${i##*/}" || error_exit "Failed to link_file() $target_dir/$dirname/places/${i##*/} to $subdir/places/$target"
done
case "${dirname}" in
symbolic)
shortdirlist+="${dirname}/places,"
longdirlist+="[${dirname}/places]
Context=Places
Size=16
MinSize=16
MaxSize=512
Type=Scalable
"
;;
*)
shortdirlist+="${dirname}/places,${scaledname}/places,"
longdirlist+="[${dirname}/places]
Context=Places
Size=${dirname%x*}
Type=Fixed
[${scaledname}/places]
Context=Places
Size=${dirname%x*}
Scale=2
Type=Fixed
"
;;
esac
done
if [[ $dark_theme = true ]]
then
inherit="Papirus-Dark,breeze-dark"
else
inherit="Papirus,breeze"
fi
cat <<EOF > "$target_dir/index.theme"
[Icon Theme]
Name=$new_theme
Comment=Recoloured Papirus icon theme for Mabox Linux
Inherits=${inherit},hicolor
Example=folder
FollowsColorScheme=true
DesktopDefault=48
DesktopSizes=16,22,24,32,48,64
ToolbarDefault=22
ToolbarSizes=16,22,24,32,48
MainToolbarDefault=22
MainToolbarSizes=16,22,24,32,48
SmallDefault=16
SmallSizes=16,22,24,32,48
PanelDefault=48
PanelSizes=16,22,24,32,48,64
DialogDefault=48
DialogSizes=16,22,24,32,48,64
# Directory list
Directories=${shortdirlist%,}
$longdirlist
EOF
gtk-update-icon-cache "$target_dir"

View File

@ -135,7 +135,7 @@ h5 {font-size: 2vw !important;border-bottom: 1px solid;padding-left: 1em;}
</nav> </nav>
<div class="fixeddown"> <div class="fixeddown">
<div class="center small" style="margin: 0 4px 4px 2px;"> <div class="center small" style="margin: 0 4px 4px 2px;">
<p><a class="tag small indigo" href="run://jgwallpaperchanger -s"> Wallpaper...</a> <a class="tag small indigo" href="run://mbwallpaper -o"></a></p> <p><a class="tag small indigo" href="run://pcmanwp"> Wallpaper...</a> <a class="tag small indigo" href="run://mbwallpaper -o"></a></p>
<p><em>dynamic menus:</em></p> <p><em>dynamic menus:</em></p>
<p> <p>
<a class="tag small purple" href="run://colorizer -s"> Colorizer</a><br /> <a class="tag small purple" href="run://colorizer -s"> Colorizer</a><br />

View File

@ -136,7 +136,7 @@ h5 {font-size: 2vw !important;border-bottom: 1px solid;padding-left: 1em;}
</nav> </nav>
<div class="fixeddown"> <div class="fixeddown">
<div class="center small" style="margin: 0 4px 4px 2px;"> <div class="center small" style="margin: 0 4px 4px 2px;">
<p><a class="tag small indigo" href="run://jgwallpaperchanger -s"> Wybierz tapetę</a> <a class="tag small indigo" href="run://mbwallpaper -o"></a></p> <p><a class="tag small indigo" href="run://pcmanwp"> Wybierz tapetę</a> <a class="tag small indigo" href="run://mbwallpaper -o"></a></p>
<p><em>dynamiczne menu</em></p> <p><em>dynamiczne menu</em></p>
<p> <p>
<a class="tag small purple" href="run://colorizer -s"> Colorizer</a><br /> <a class="tag small purple" href="run://colorizer -s"> Colorizer</a><br />