diff --git a/bin/mb-jgtools b/bin/mb-jgtools index 58f362b..d2e7938 100755 --- a/bin/mb-jgtools +++ b/bin/mb-jgtools @@ -21,7 +21,7 @@ case $jgmenu_theme in export color_norm_fg="#FFFFFF " ;; esac - +. $HOME/.config/mabox/jgmenusize.conf gtkbookmarks() { BOOKMARKS="$HOME/.gtk-bookmarks" @@ -44,18 +44,14 @@ esac fi } - -JGWIDTH="280" WEBBROWSER="exo-open --launch WebBrowser" [ $(pidof picom) ] && RADIUS="4" #SCREENWIDTH=$(xdpyinfo | awk '/^ +dimensions/ {print $2}' | cut -d 'x' -f1) -#Poniższe, wywalić do mabox.conf który i tak jest wczytywany - uaktualiać przez usługę z autostartu + sponge z moreutils OSNAME=$(lsb_release -d | awk '{print $2}') OSVERSION=$(lsb_release -r | awk '{print $2}') OSCODE=$(lsb_release -c | awk '{print $2}') -#KERNEL=$(uname -r) mkconfigfile() { @@ -72,7 +68,7 @@ menu_margin_y = 0 menu_width = $JGWIDTH menu_height_min = ${MENU_HEIGHT_MIN:-0} menu_height_max = ${MENU_HEIGHT_MAX:-0} -menu_padding_top = ${MENU_PADDING_TOP:-90} +menu_padding_top = ${MENU_PADDING_TOP:-70} menu_padding_right = ${MENU_PADDING_RIGHT:-10} menu_padding_bottom = ${MENU_PADDING_BOTTOM:-10} menu_padding_left = ${MENU_PADDING_LEFT:-10} @@ -80,9 +76,10 @@ menu_radius = ${MENU_RADIUS:-0} menu_valign = ${MENU_VALIGN:-top} menu_halign = ${MENU_HALIGN:-left} -item_height = ${ITEM_HEIGHT:-20} +item_height = ${jgmenu_item_height:-20} item_halign = ${ITEM_HALIGN:-left} item_padding = 4 +item_margin_y = ${item_margin_y:-3} item_radius = ${item_radius:-2} item_border = ${item_border:-0} arrow_string = ${ARROW_STRING:-⮞} @@ -105,9 +102,10 @@ color_scroll_ind = ${COLOR_SCROLL_IND:-#504e65 100} sep_markup = weight="bold" foreground="${color_title_fg% *}" +sep_height = ${sep_height:-5} font = ${jgmenu_font:-Noto Sans Medium 9} -icon_size = ${ICON_SIZE:-0} -icon_theme = ${jgmenu_icon_theme:-Numix-Square} +icon_size = ${jgmenu_icon_size:-0} +icon_theme = ${jgmenu_icon_theme:-Numix-Circle} EOF unset font @@ -126,13 +124,11 @@ MENU_PADDING_TOP=30 MENU_PADDING_RIGHT=0 MENU_PADDING_BOTTOM=0 MENU_PADDING_LEFT=0 -JGWIDTH=0 -ITEM_HEIGHT=20 -[ $jgmenu_use_icons == true ] && ICON_SIZE=16 + MENU_RADIUS=${RADIUS:-0} mkconfigfile -#jgmenu --config-file=${CONFIG_FILE} --csv-file=${MENU_ITEMS} 2>/dev/null + jgmenu --config-file=${CONFIG_FILE} 2>/dev/null } @@ -145,7 +141,6 @@ trap "rm -f ${CONFIG_FILE} ${MENU_ITEMS}" EXIT MENU_HALIGN="right" ITEM_HALIGN="left" ARROW_STRING=" ⮜ " -[ $jgmenu_use_icons == true ] && ICON_SIZE=18 TABS="100" MENU_HEIGHT_MIN=$(xdpyinfo | awk '/^ +dimensions/ {print $2}' | cut -d 'x' -f2) @@ -190,6 +185,12 @@ case $LANG in COMPOSER="Kompozytor" MABOX_THEMES="Predefiniowane konfiguracje pulpitu" THEME_MNGR="Menadżer schematów" + SIZE="Rozmiar Menu i Paneli" + TINY="malutki" + SMALL="mały" + NORMAL="normalny" + BIG="duży" + HUGE="wielki" ;; *) TYPE_TO_SEARCH="type to search" @@ -231,6 +232,12 @@ case $LANG in COMPOSER="Composer" MABOX_THEMES="Mabox Themes" THEME_MNGR="Theme Manager" + SIZE="Menu/Sidepanels Size" + TINY="tiny" + SMALL="small" + NORMAL="normal" + BIG="big" + HUGE="huge" ;; esac @@ -238,13 +245,13 @@ esac mkconfigfile cat < ${MENU_ITEMS} -@icon,,225,10,48,48,4,left,top,,,/usr/share/icons/hicolor/48x48/apps/distributor-logo-mabox.png -@text,,20,10,200,20,4,left,top,${color_title_fg% *},#111111,$OSNAME $OSVERSION $OSCODE -@text,,20,30,200,20,4,left,top,#666666,#444444,$USER@$HOSTNAME +@icon,,15,10,48,48,4,left,top,,,/usr/share/icons/hicolor/48x48/apps/distributor-logo-mabox.png +@text,,70,10,200,20,4,left,top,${color_title_fg% *},#111111,$OSNAME $OSVERSION $OSCODE +@text,,70,30,200,20,4,left,top,#666666,#444444,$USER@$HOSTNAME @text,,20,50,200,20,4,left,top,#666666,#444444, #@rect,,40,70,262,20,0,left,top,#666666,#262626, -@text,,74,70,20,20,0,left,top,auto,#222222, -@search,,90,70,292,20,4,left,top,auto,#262626,""" $TYPE_TO_SEARCH""" +@text,,84,50,20,20,0,left,top,auto,#222222, +@search,,100,50,292,20,4,left,top,auto,#262626,""" $TYPE_TO_SEARCH""" . $HOME/.config/mabox/right-prepend.csv @@ -259,7 +266,7 @@ $MIRROR_RANK,^root(mirrory),download $MCC,mcc,distributor-logo-mabox $SYS_AND_HARDWARE,^root(system),audiocard $LOOK_AND_FEEL,^root(wyglad),preferences-color - +$SIZE,^checkout(menusize),applications-development ^sep($HELP) $SHORTCUTS,mb-kb --gui &>/dev/null,key_bindings $ONLINE_RES,^root(weblinks),web-browser @@ -269,6 +276,13 @@ $SCREENSHOT,mb-jgtools screenshot,emblem-photos . $HOME/.config/mabox/right-append.csv . $HOME/.config/mabox/exit.csv +^tag(menusize) +^sep($SIZE) +$TINY,cat /usr/share/mb-jgtools/tiny > ~/.config/mabox/jgmenusize.conf && mb-jgtools right +$SMALL,cat /usr/share/mb-jgtools/small > ~/.config/mabox/jgmenusize.conf && mb-jgtools right +$NORMAL,cat /usr/share/mb-jgtools/normal > ~/.config/mabox/jgmenusize.conf && mb-jgtools right +$BIG,cat /usr/share/mb-jgtools/big > ~/.config/mabox/jgmenusize.conf && mb-jgtools right +$HUGE,cat /usr/share/mb-jgtools/huge > ~/.config/mabox/jgmenusize.conf && mb-jgtools right ^tag(system) ^sep($SYS_AND_HARDWARE) @@ -313,6 +327,7 @@ $THEME_MNGR,mb-obthemes,preferences-desktop-theme Mabox - pierwsze kroki,exo-open --launch WebBrowser https://pl.maboxlinux.org/przewodnik-uzytkownika/,distributor-logo-mabox Forum Mabox,exo-open --launch WebBrowser https://forum.maboxlinux.org/,distributor-logo-mabox ^sep(Manjaro) +Stable Updates,exo-open --launch WebBrowser https://forum.manjaro.org/c/announcements/stable-updates/,distributor-logo-manjaro Home site,exo-open --launch WebBrowser https://manjaro.org,distributor-logo-manjaro Wiki,exo-open --launch WebBrowser https://wiki.manjaro.org,distributor-logo-manjaro Forum,exo-open --launch WebBrowser https://forum.manjaro.org,distributor-logo-manjaro @@ -356,8 +371,8 @@ case $LANG in esac MENU_HEIGHT_MIN=$(xdpyinfo | awk '/^ +dimensions/ {print $2}' | cut -d 'x' -f2) -JGWIDTH=250 -ITEM_HEIGHT=20 +JGWIDTH=220 +jgmenu_icon_size=0 MENU_PADDING_TOP=70 mkconfigfile @@ -411,8 +426,8 @@ MENU_HALIGN="center" MENU_VALIGN="center" MENU_PADDING_TOP=221 TABS="250" -ITEM_HEIGHT="30" -ICON_SIZE="24" +jgmenu_item_height=30 +jgmenu_icon_size=26 font="Noto Sans Medium 11" MENU_RADIUS=${RADIUS:-0} @@ -473,6 +488,7 @@ MENU_HALIGN="center" MENU_VALIGN="center" TABS="280" ITEM_HEIGHT=25 +jgmenu_icon_size=0 font='Noto Sans Medium 10' MENU_RADIUS=${RADIUS:-0} diff --git a/mb-jgtools/big b/mb-jgtools/big new file mode 100644 index 0000000..8e4fd0b --- /dev/null +++ b/mb-jgtools/big @@ -0,0 +1,3 @@ +jgmenu_font="Noto Sans Medium 10" +jgmenu_item_height=20 +jgmenu_icon_size=18 diff --git a/mb-jgtools/huge b/mb-jgtools/huge new file mode 100644 index 0000000..f0042e6 --- /dev/null +++ b/mb-jgtools/huge @@ -0,0 +1,3 @@ +jgmenu_font="Noto Sans Medium 11" +jgmenu_item_height=22 +jgmenu_icon_size=20 diff --git a/mb-jgtools/normal b/mb-jgtools/normal new file mode 100644 index 0000000..783d622 --- /dev/null +++ b/mb-jgtools/normal @@ -0,0 +1,3 @@ +jgmenu_font="Noto Sans Medium 9" +jgmenu_item_height=18 +jgmenu_icon_size=16 diff --git a/mb-jgtools/small b/mb-jgtools/small new file mode 100644 index 0000000..85156fc --- /dev/null +++ b/mb-jgtools/small @@ -0,0 +1,5 @@ +jgmenu_font="Noto Sans Medium 8" +jgmenu_item_height=16 +jgmenu_icon_size=12 +sep_height=2 +item_margin_y=2 diff --git a/mb-jgtools/tiny b/mb-jgtools/tiny new file mode 100644 index 0000000..906f5b8 --- /dev/null +++ b/mb-jgtools/tiny @@ -0,0 +1,5 @@ +jgmenu_font="Noto Sans Medium 7" +jgmenu_item_height=14 +jgmenu_icon_size=8 +sep_height=1 +item_margin_y=1