From b18f0da58efd1e7f6f9686ed9ae16b174de000fa Mon Sep 17 00:00:00 2001 From: "B. Stack" Date: Tue, 12 Dec 2023 21:12:17 -0500 Subject: v0.0.4 fix want#1,#2 --- src/etc/stackrpms-thinkpad-p50s/fluxbox.keys | 34 ++++++++++------ src/etc/stackrpms-thinkpad-p50s/fluxbox.startup | 45 ++++++++++++++++------ .../share/doc/stackrpms-thinkpad-p50s/README.md | 5 +++ 3 files changed, 60 insertions(+), 24 deletions(-) (limited to 'src') diff --git a/src/etc/stackrpms-thinkpad-p50s/fluxbox.keys b/src/etc/stackrpms-thinkpad-p50s/fluxbox.keys index be0c1a2..2ab169f 100644 --- a/src/etc/stackrpms-thinkpad-p50s/fluxbox.keys +++ b/src/etc/stackrpms-thinkpad-p50s/fluxbox.keys @@ -9,6 +9,7 @@ # History: # 2019-12-26 started on ltb-018 # 2022-11-03 adapted for this package +# 2023-12-12 revised to be identical for stackrpms-thinkpad-p50s and bgconf # Usage: # symlink your ~/.fluxbox/keys to this file with: # ln -sf /etc/stackrpms-thinkpad-p50s/fluxbox.keys ~/.fluxbox/keys @@ -16,7 +17,7 @@ # ltb-018:~/.fluxbox/keys # Improve: # Documentation: -# last modified: 2023-09-09-7 07:46 +# last modified: 2023-12-12-3 18:25 # click on the desktop to get menus OnDesktop Mouse1 :HideMenus @@ -35,10 +36,12 @@ OnDesktop Mouse5 :NextWorkspace #OnToolbar Mouse5 :NextWindow {static groups} (iconhidden=no) # alt + left/right click to move/resize a window -OnWindow Mod1 Mouse1 :MacroCmd {Raise} {Focus} {StartMoving} +#OnWindow Mod1 Mouse1 :MacroCmd {Raise} {Focus} {StartMoving} +OnWindow Mod1 Mouse1 :If {And {Matches (Fullscreen!=yes)} {Matches (@_NET_WM_STATE!=.*_FULLSCREEN.*)} } {MacroCmd {Raise} {Focus} {StartMoving}} OnWindowBorder Move1 :StartMoving -OnWindow Mod1 Mouse3 :MacroCmd {Raise} {Focus} {StartResizing NearestCorner} +#OnWindow Mod1 Mouse3 :MacroCmd {Raise} {Focus} {StartResizing NearestCorner} +OnWindow Mod1 Mouse3 :If {And {Matches (Fullscreen!=yes)} {Matches (@_NET_WM_STATE!=.*_FULLSCREEN.*)} } {MacroCmd {Raise} {Focus} {StartResizing NearestCorner}} OnLeftGrip Move1 :StartResizing bottomleft OnRightGrip Move1 :StartResizing bottomright @@ -90,11 +93,18 @@ Mod1 F2 :Exec fbrun # volume settings, using common keycodes # if these don't work, use xev to find out your real keycodes -# for Thinkpad P50s -123 :Exec amixer sset Master,0 1+ -122 :Exec amixer sset Master,0 1- -121 :Exec amixer sset Master,0 toggle -225 :Exec amixer sset Capture,0 toggle # use Fn+F10 magnifying glass because Fn+F4 mic-mute is blocked by firmware? +# alsa only, volume control +#123 :Exec amixer sset Master,0 1+ +#122 :Exec amixer sset Master,0 1- +#121 :Exec amixer sset Master,0 toggle +# pulseaudio, volume control +121 :Exec pulsemixer-notification toggle +122 :Exec pulsemixer-notification down +123 :Exec pulsemixer-notification up +# alsa or pulseaudio, mute mic, on Thinkpad P50s +# use Fn+F10 magnifying glass because Fn+F4 mic-mute is blocked by firmware? +225 :Exec amixer sset Capture,0 toggle + # screen brightness for Thinkpad P50s 232 :Exec /usr/bin/hwset-thinkpad-p50s bright down 85 233 :Exec /usr/bin/hwset-thinkpad-p50s bright up 85 @@ -164,14 +174,14 @@ Mod4 L :Exec xscreensaver-command -lock Mod4 O :Exec scite Mod4 R :Exec fbrun Mod4 Shift C :Exec x-terminal-emulator -Mod4 Shift D :Exec apulse discord -Mod4 Shift F :Exec apulse librewolf +# librewolf used to use apulse +Mod4 Shift F :Exec librewolf +#Mod4 Shift F :Exec newmoon Mod4 Shift G :Exec firefox Mod4 Shift H :Exec waterfox Mod4 Shift I :Exec irfanview Mod4 Shift L :Exec keepass2 -Mod4 Shift L :Exec telegram-desktop -Mod4 Shift V :Exec /usr/bin/vlc +Mod4 Shift V :Exec vlc Mod4 Shift W :Exec libreoffice --writer Mod4 Shift X :Exec libreoffice --calc diff --git a/src/etc/stackrpms-thinkpad-p50s/fluxbox.startup b/src/etc/stackrpms-thinkpad-p50s/fluxbox.startup index 7eef2bc..ca38336 100644 --- a/src/etc/stackrpms-thinkpad-p50s/fluxbox.startup +++ b/src/etc/stackrpms-thinkpad-p50s/fluxbox.startup @@ -10,6 +10,7 @@ # History: # 2019-12-26 started on ltb-018 from fluxbox startup example # 2022-11-03 adapted for this package +# 2023-12-12 revised to be consistent across bgconf and stackrpms-thinkpad-p50s # Usage: # symlink your ~/.fluxbox/startup to this file with: # ln -sf /etc/stackrpms-thinkpad-p50s/fluxbox.startup ~/.fluxbox/startup @@ -20,7 +21,10 @@ # last modified: 2022-11-03-5 14:28 # Change your keymap: -xmodmap /etc/stackrpms-thinkpad-p50s/Xmodmap +test -f /etc/stackrpms-thinkpad-p50s/Xmodmap && xmodmap /etc/stackrpms-thinkpad-p50s/Xmodmap +test -f .Xmodmap && xmodmap ".Xmodmap" + +echo "${PATH}" | grep -q "${HOME}/bin" 1>/dev/null 2>&1 && export PATH="${HOME}/bin:${PATH}" # for vlc on hidpi screens export QT_AUTO_SCREEN_SCALE_FACTOR=0 @@ -32,26 +36,38 @@ if [ $? -eq 0 ]; then fbautostart fi +# for desktop icons. Because I use xfe for a file manager, spacefm would only be installed for xdg desktop icons +spacefm --desktop & + +start-pulseaudio-x11 & volumeicon & copyq & xscreensaver -nosplash & +# This might be redundant if /usr/share/services/com.example.Notifications.service but will not hurt. /usr/lib/notification-daemon/notification-daemon & telegram-desktop & alttab -w 1 -s 1 -theme Numix-Circle & -powerkit & +# It is expected to only use one of: cbatticon powerkit +cbatticon -i symbolic & +DESKTOP_SESSION=gnome powerkit & sudo mount -a & -/usr/bin/xdgmenumaker -f fluxbox -i > ~/.fluxbox/xdg-menu & -/usr/bin/keyboard-leds-trayicons & -~/bin/xscreensaver-watch.sh & -/usr/bin/logout-manager-trayicon & +# Obviously should not be installed on physical systems +spice-vdagent 1>/dev/null 2>&1 & +# Fallback: +#xdgmenumaker -f fluxbox -i > ~/.fluxbox/xdg-menu & +xdgmenumaker-user fluxbox & +keyboard-leds-trayicons & +xscreensaver-watch & +logout-manager-trayicon & # probably only one of these will be used: wicd-client -t & -/usr/bin/connman-gtk & - -/usr/bin/myautomountd & -/usr/bin/myautomount-trayicon & -/usr/bin/netmounts-trayicon & +connman-gtk & +myautomountd & +myautomount-trayicon & +netmounts-trayicon & # vpn-trayicon is only useful on demand. +#vpn-trayicon & +# If fbxkb is installed, set up us(qwerty) and us(dvorak) which fbxkb 1>/dev/null 2>&1 && test -f /etc/use-fbxkb && { setxkbmap -option grp:switch,grp:shifts_toggle 'us,us(dvorak)' & fbxkb & @@ -63,9 +79,14 @@ KRB5_AUTH_DIALOG_DEBUG="no-persistence,no-app-menu,no-header-bar" gtk3-nocsd krb # use by symlinking /etc/wallpaper to whatever you want fbsetbg -a /etc/wallpaper +# Mask weird button presses 8, 9 on scroll-up, scroll-down +xinput set-button-map "$( xinput | awk -F'[=]' '/ouse/{print $2}' | awk '{print $1}' | head -n1 )" 1 2 3 4 5 6 7 0 0 & + +# Make this extensible so I do not have to customize ~/.fluxbox/startup on each system +test -f "${HOME}/.fluxbox/startup-local" && . "${HOME}/.fluxbox/startup-local" & + # And last but not least we start fluxbox. # Because it is the last app you have to run it with ''exec'' before it. - exec fluxbox # or if you want to keep a log: # exec fluxbox -log ~/fluxbox/log diff --git a/src/usr/share/doc/stackrpms-thinkpad-p50s/README.md b/src/usr/share/doc/stackrpms-thinkpad-p50s/README.md index 34f1e42..fe9f6a5 100644 --- a/src/usr/share/doc/stackrpms-thinkpad-p50s/README.md +++ b/src/usr/share/doc/stackrpms-thinkpad-p50s/README.md @@ -21,6 +21,7 @@ This project, `/mnt/public/Support/Platforms/stackrpms-thinkpad-p50s/` holds a g * ltb-020 Clone * ltb-021 Copy * ltb-022 Dupe +* ltb-023 Mundane Some configurations include: @@ -54,3 +55,7 @@ This project will be considered stable when the following are met: 2023-08-22 version 0.0.2 update fluxbox keys for Fn+F10 to toggle mic mute because Fn+F4 is blocked/used by something I cannot control. 2023-09-09 version 0.0.3 use correct amixer command for mic mute + +2023-12-12 version 0.0.4 +* Make fluxbox startup and keys files match bgconf (want#1) +* fluxbox.keys: use pulseaudio now on Devuan (want#2) -- cgit