Go to file
Victoria Nadasdi 84016ef70a
update version number, i forgot that
Signed-off-by: Victoria Nadasdi <victoria@efertone.me>
2024-02-17 18:16:30 +01:00
themes add emoji picker 2023-12-04 17:19:42 +01:00
LICENSE Squash to make the repo public 2023-08-17 19:34:27 +02:00
config.ron add emoji picker 2023-12-04 17:19:42 +01:00
readme.md update version number, i forgot that 2024-02-17 18:16:30 +01:00
up-hook.sh Squash to make the repo public 2023-08-17 19:34:27 +02:00

readme.md

Table of Contents

LeftWM Configuration

LeftWM: https://github.com/leftwm/leftwm

This configuration uses leftwm 0.5.1.

Hotkeys

Launchers

  • mod+shift+enter: open alacritty
  • mod+p: rofi run
  • mod+space: rofi drun
  • mod+shift+p: power menu
  • mod+/: tag selector
  • mod+shift+l: layout selector

Layouts

  • mod+[: decrease main width
  • mod+]: increase main width
  • mod+ctrl+j: next layout (cycle)
  • mod+ctrl+k: previous layout (cycle)

Windows

  • mod+j: focus window down / next
  • mod+k: focus window up / previous
  • mod+enter: move window to top
  • mod+shift+j: move window down
  • mod+shift+k: move window up
  • mod+f: toggle full screen mode
  • mod+shift+f: toggle floating mode
  • mod+shift+t: toggle sticky mode

mod+shift+f and mod+shift+t together is the perfect way to watch something in the background in the corner. It will be a floating window that follows you across tags.

Tags

  • mod+NUM: go to tag
  • mod+shift+NUM: move window to tag
  • mod+w: swap tags (between workspaces)
  • mod+grave: return to last tag

Workspaces

  • mod+l: next workspace
  • mod+h: previous workspace

Scratch Pads

  • mod+s: alacritty (mostly running mprocs with neomutt, iamb, spt, etc.)

Mouse Actions

Mouse key is mod.

  • mod+LMB: move window (activated floating mode)
  • mod+RMB: resize window (activated floating mode)

Screenshot

Clipboard:

  • mod+Print: selection to clipboard
  • shift+Print: window to clipboard
  • ctrl+shift+Print: delayed selection to clipboard

File:

Save location: ${HOME}/Sync/Photos/Screenshot/oooomen (defined in .efbin/screenshot)

  • Print: selection to file
  • ctrl+Print: window to file

Screenshot script:

#!/usr/bin/env zsh

screenshotDir="${HOME}/Sync/Photos/Screenshot/oooomen"

case $1 in
  selection-to-file)
    maim -s -u "${screenshotDir}/$(date '+%Y-%m-%d_%I%M%S%P').png"
    ;;
  window-to-file)
    winid=$(~/.efbin/current-window-id)
    maim -i "${winid}" -u "${screenshotDir}/asd-$(date '+%Y-%m-%d_%I%M%S%P').png"
    ;;
  selection-to-clipboard)
    maim -s -u | xclip -selection clipboard -t image/png -i
    ;;
  window-to-clipboard)
    winid=$(~/.efbin/current-window-id)
    maim -i "${winid}" -u | xclip -selection clipboard -t image/png -i
    ;;
  delayed-selection-to-clipboard)
    maim -d 5 -s -u \
      | xclip -selection clipboard -t image/png -i \
      && notify-send 'Screenshot is on clipboard'
    ;;
  *)
    list=$(cat $0 | grep '^  [a-z\-]*)$' | sed -e 's/^  //' -e 's/)$//')
    echo "$0 <${list//$'\n'/ | }>"
    exit 1;
    ;;
esac

Others

  • mod+shift+r: soft reload LeftWM
  • mod+shift+q: close window
  • mod+shift+x: logout / kill session (in case rofi power menu does not show up)
  • mod+ctrl+l: lock with slock

Special Configuration Options

Floating Alacritty

I use a special window to terminals in the middle of the screen for example open pacman updates.

The wrapper script:

#!/usr/bin/env bash

args=(
  --class="FloatingAlacritty"
  --option="window.dimensions.lines=38"
  --option="window.dimensions.columns=160"
)

for opt in "$@"; do
  case $opt in
    --hold)
      args+=(--hold)
      shift
      ;;
  esac
done

hlcolor=$(tput setaf 5)
reset=$(tput sgr0)

alacritty \
  ${args[*]} \
  --command $SHELL -c \
    "$*; echo -e '\n${hlcolor} -- Done --${reset}'"

Example:

$HOME/.efbin/open-floating-terminal --hold sudo pacman -Syu

Extra resources / credits

pink-sky.png

The Pink Sky background (used in rofi menus):

trans-background-by-efertone.png

This image is free to use, share, or do whatever you want, I made it with Krita. If you want I have the .kri file somewhere.

Theme

This theme is based on di-effe/catppuccin, but I change a lot of things over time, that's why I changed the name. It has still similarities, but as the project was not updated when LeftWM got new releases, I had to hack it, and over time, well with all the changes to make it more comfortable, it's not catppuccin anymore.