adding the leftwm config was probablyu not all I did
261
leftwm/.config/leftwm/config.toml
Normal file
@@ -0,0 +1,261 @@
|
||||
modkey = "Mod1"
|
||||
mousekey = "Mod1"
|
||||
workspaces = []
|
||||
tags = ["一", "二", "三", "四", "五", "六", "七", "八", "九"]
|
||||
layouts = ["MainAndVertStack", "MainAndHorizontalStack", "MainAndDeck", "GridHorizontal", "EvenHorizontal", "EvenVertical", "Fibonacci", "CenterMain", "CenterMainBalanced", "Monocle", "RightWiderLeftStack", "LeftWiderRightStack"]
|
||||
layout_mode = "Workspace"
|
||||
scratchpad = []
|
||||
disable_current_tag_swap = false
|
||||
focus_behaviour = "Sloppy"
|
||||
focus_new_windows = true
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "rofi -no-lazy-greb -show drun -icon-theme 'Papirus' -show-icons"
|
||||
modifier = ["modkey"]
|
||||
key = "d"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "qutebrowser"
|
||||
modifier = ["modkey"]
|
||||
key = "b"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "pcmanfm"
|
||||
modifier = ["modkey"]
|
||||
key = "f"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "pamixer --allow-boost -i 5"
|
||||
modifier = []
|
||||
key = "XF86AudioRaiseVolume"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "pamixer --allow-boost -d 5"
|
||||
modifier = []
|
||||
key = "XF86AudioLowerVolume"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "pamixer -t"
|
||||
modifier = []
|
||||
key = "XF86AudioMute"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "playerctl play-pause"
|
||||
modifier = []
|
||||
key = "XF86AudioPlay"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "playerctl previous"
|
||||
modifier = []
|
||||
key = "XF86AudioPrev"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "playerctl next"
|
||||
modifier = []
|
||||
key = "XF86AudioNext"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "flameshot gui"
|
||||
modifier = []
|
||||
key = "Print"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "kitty"
|
||||
modifier = ["modkey"]
|
||||
key = "Return"
|
||||
|
||||
[[keybind]]
|
||||
command = "CloseWindow"
|
||||
modifier = ["modkey"]
|
||||
key = "q"
|
||||
|
||||
[[keybind]]
|
||||
command = "SoftReload"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "r"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "loginctl kill-session $XDG_SESSION_ID"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "q"
|
||||
|
||||
[[keybind]]
|
||||
command = "Execute"
|
||||
value = "betterlockscreen"
|
||||
modifier = ["modkey", "Control"]
|
||||
key = "l"
|
||||
|
||||
[[keybind]]
|
||||
command = "ToggleFullScreen"
|
||||
modifier = ["modkey"]
|
||||
key = "t"
|
||||
|
||||
[[keybind]]
|
||||
command = "SwapTags"
|
||||
modifier = ["modkey"]
|
||||
key = "w"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveWindowUp"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "k"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveWindowDown"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "j"
|
||||
|
||||
[[keybind]]
|
||||
command = "FocusWindowUp"
|
||||
modifier = ["modkey"]
|
||||
key = "k"
|
||||
|
||||
[[keybind]]
|
||||
command = "FocusWindowDown"
|
||||
modifier = ["modkey"]
|
||||
key = "j"
|
||||
|
||||
[[keybind]]
|
||||
command = "NextLayout"
|
||||
modifier = ["modkey", "Control"]
|
||||
key = "k"
|
||||
|
||||
[[keybind]]
|
||||
command = "PreviousLayout"
|
||||
modifier = ["modkey", "Control"]
|
||||
key = "j"
|
||||
|
||||
[[keybind]]
|
||||
command = "FocusWorkspaceNext"
|
||||
modifier = ["modkey"]
|
||||
key = "l"
|
||||
|
||||
[[keybind]]
|
||||
command = "FocusWorkspacePrevious"
|
||||
modifier = ["modkey"]
|
||||
key = "h"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveWindowUp"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "Up"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "1"
|
||||
modifier = ["modkey"]
|
||||
key = "1"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "2"
|
||||
modifier = ["modkey"]
|
||||
key = "2"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "3"
|
||||
modifier = ["modkey"]
|
||||
key = "3"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "4"
|
||||
modifier = ["modkey"]
|
||||
key = "4"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "5"
|
||||
modifier = ["modkey"]
|
||||
key = "5"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "6"
|
||||
modifier = ["modkey"]
|
||||
key = "6"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "7"
|
||||
modifier = ["modkey"]
|
||||
key = "7"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "8"
|
||||
modifier = ["modkey"]
|
||||
key = "8"
|
||||
|
||||
[[keybind]]
|
||||
command = "GotoTag"
|
||||
value = "9"
|
||||
modifier = ["modkey"]
|
||||
key = "9"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "1"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "1"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "2"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "2"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "3"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "3"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "4"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "4"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "5"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "5"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "6"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "6"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "7"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "7"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "8"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "8"
|
||||
|
||||
[[keybind]]
|
||||
command = "MoveToTag"
|
||||
value = "9"
|
||||
modifier = ["modkey", "Shift"]
|
||||
key = "9"
|
||||
48
leftwm/.config/leftwm/themes/README.md
Normal file
@@ -0,0 +1,48 @@
|
||||
# Why have themes
|
||||
|
||||
With LeftWM, there are two types of configs:
|
||||
* **LeftWM Configuration files:** LeftWM configurations are specific to you and don’t change for different themes. These are settings like keybindings, workspace locations, and names of desktops/tags. These settings can be found in `~/.config/leftwm/config.toml`.
|
||||
|
||||
* **Theme Configuration files:** The appearance of your desktop is different. It’s fun to try new looks and feels. It’s fun to tweak and customize the appearance (AKA: [ricing](https://www.reddit.com/r/unixporn/comments/3iy3wd/stupid_question_what_is_ricing/)). It’s fun to share so others can experience your awesome desktop! LeftWM is built around this concept. By pulling all these settings out into themes, you can now easily tweak, switch, and share your experiences. This configuration is spread between `theme.toml` and related files contained within a theme's folder.
|
||||
|
||||
|
||||
# We want your themes
|
||||
|
||||
We are looking to expand the list of available themes for an upcoming release. If you enjoy making desktops look good please consider sharing by making a pull request on [the community themes repository](https://github.com/leftwm/leftwm-community-themes).
|
||||
|
||||
|
||||
# Requirements for a theme
|
||||
|
||||
A theme has only two requirements. An “up” and a “down” executable/script. They can be written in whatever makes you happy. The up script you guessed it starts up all the things that make your script unique and awesome. The down script restores the environment to an un-themes state. A theme should be self contained if possible so that it can be shared and doesn’t interfere with other themes. For example when booting an application with a config file, put the config file in the theme folder instead of ~/.config. This way other themes can use the same application
|
||||
|
||||
|
||||
# Setup / selection of theme
|
||||
|
||||
There are two ways to setup a theme: you can use [leftwm-theme](https://github.com/leftwm/leftwm-theme/) or you can set a symlink yourself.
|
||||
|
||||
## Using LeftWM-theme
|
||||
Install LeftWM-theme, as per the directions on [its Github](https://github.com/leftwm/leftwm-theme).
|
||||
|
||||
Update your list of themes:
|
||||
```bash
|
||||
leftwm-theme update
|
||||
```
|
||||
Install the theme you like:
|
||||
```bash
|
||||
leftwm-theme install "THEME NAME GOES HERE"
|
||||
```
|
||||
Apply the theme you like as the current theme:
|
||||
```bash
|
||||
leftwm-theme apply "THEME NAME GOES HERE"
|
||||
```
|
||||
|
||||
## Using symlinks
|
||||
|
||||
To select a theme all that is required is that it’s located at: `~/.config/leftwm/themes/current`
|
||||
It is strongly recommended that you do this with a symlink rather than creating a folder. Using a symlink makes it easy to save all your themes in the folder `~/.config/leftwm/themes` and switch between them using a symlink easily.
|
||||
|
||||
The following command would set the included basic_polybar to the current theme:
|
||||
|
||||
```bash
|
||||
ln -s ~/.config/leftwm/themes/basic_polybar ~/.config/leftwm/themes/current
|
||||
```
|
||||
16
leftwm/.config/leftwm/themes/basic_eww/README.md
Normal file
@@ -0,0 +1,16 @@
|
||||
This is a very basic README, merely containing a bunch of heads-up notes for using `eww` with `leftwm`
|
||||
|
||||
Important:
|
||||
Copy the `eww-bar` folder to `~/.config/eww/` otherwise every `eww` command needs to pass the path to the folder where the `eww.yuck` and `eww.scss` files are located.
|
||||
It is also possible to symlink instead of copy, though `eww` isn't to happy about this and will log some errors, even though working just fine.
|
||||
The previously used xml config is still included in this example in the `legacy_eww_xml_config` folder for reference.
|
||||
|
||||
Previously (legacy xml configured) `eww` and `leftwm` failed to properly negotiate the `reserved` space for the `bar` windows, this fixed now though. To prevent windows from overlapping your bar please use the `gutter` setting in `theme.toml` to force this reserved space.
|
||||
Here is a snippet of how such gutter configuration might look like, if your bar is 24px in height:
|
||||
```toml
|
||||
[[gutter]]
|
||||
side = "Top"
|
||||
value = 24
|
||||
```
|
||||
|
||||
Since `eww` is still rapidly changing, if stuff breaks please check their [github](https://github.com/elkowar/eww) for documentation on changes and existing issues.
|
||||
BIN
leftwm/.config/leftwm/themes/basic_eww/background.jpg
Normal file
|
After Width: | Height: | Size: 50 KiB |
18
leftwm/.config/leftwm/themes/basic_eww/down
Executable file
@@ -0,0 +1,18 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/down.jpg
|
||||
fi
|
||||
|
||||
leftwm-command "UnloadTheme"
|
||||
|
||||
pkill compton
|
||||
pkill picom
|
||||
pkill polybar
|
||||
pkill conky
|
||||
if [ -x "$(command -v eww)" ]; then
|
||||
eww kill
|
||||
fi
|
||||
BIN
leftwm/.config/leftwm/themes/basic_eww/down.jpg
Normal file
|
After Width: | Height: | Size: 539 B |
BIN
leftwm/.config/leftwm/themes/basic_eww/eww-bar/eww-bar.png
Normal file
|
After Width: | Height: | Size: 6.1 KiB |
68
leftwm/.config/leftwm/themes/basic_eww/eww-bar/eww.scss
Normal file
@@ -0,0 +1,68 @@
|
||||
* {
|
||||
all: unset; //Unsets everything so you can style everything from scratch
|
||||
}
|
||||
|
||||
//Global Styles
|
||||
.bar0 {
|
||||
background-color: #3a3a3a;
|
||||
color: #b0b4bc;
|
||||
padding: 10px;
|
||||
}
|
||||
|
||||
// Styles on classes (see eww.yuck for more information)
|
||||
|
||||
.sidestuff slider {
|
||||
all: unset;
|
||||
color: #ffd5cd;
|
||||
}
|
||||
|
||||
.metric scale trough highlight {
|
||||
all: unset;
|
||||
background-color: #D35D6E;
|
||||
color: #000000;
|
||||
border-radius: 10px;
|
||||
}
|
||||
.metric scale trough {
|
||||
all: unset;
|
||||
background-color: #4e4e4e;
|
||||
border-radius: 50px;
|
||||
min-height: 3px;
|
||||
min-width: 50px;
|
||||
margin-left: 10px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.metric scale trough highlight {
|
||||
all: unset;
|
||||
background-color: #D35D6E;
|
||||
color: #000000;
|
||||
border-radius: 10px;
|
||||
}
|
||||
.metric scale trough {
|
||||
all: unset;
|
||||
background-color: #4e4e4e;
|
||||
border-radius: 50px;
|
||||
min-height: 3px;
|
||||
min-width: 50px;
|
||||
margin-left: 10px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.label-ram {
|
||||
font-size: large;
|
||||
}
|
||||
.workspaces button:hover {
|
||||
color: #D35D6E;
|
||||
}
|
||||
.ws-button-mine {
|
||||
color: #4e4e4e;
|
||||
background-color: #ffd5ca;
|
||||
}
|
||||
.ws-button-visible {
|
||||
color: #D35D6E;
|
||||
background-color: #4e4e4e;
|
||||
}
|
||||
.ws-button-busy {
|
||||
color: #D35D6E;
|
||||
}
|
||||
.ws-button {
|
||||
color: #b0b4bc;
|
||||
}
|
||||
87
leftwm/.config/leftwm/themes/basic_eww/eww-bar/eww.yuck
Normal file
@@ -0,0 +1,87 @@
|
||||
(defwidget bar []
|
||||
(centerbox :orientation "h"
|
||||
(workspaces)
|
||||
(music)
|
||||
(sidestuff)))
|
||||
|
||||
(defwidget sidestuff []
|
||||
(box :class "sidestuff" :orientation "h" :space-evenly false :halign "end"
|
||||
(metric :label "🔊"
|
||||
:value volume
|
||||
:onchange "amixer -D pulse sset Master {}%")
|
||||
(metric :label ""
|
||||
:value EWW_RAM
|
||||
:onchange "")
|
||||
(metric :label "💾"
|
||||
:value {round((1 - (EWW_DISK["/"].free / EWW_DISK["/"].total)) * 100, 0)}
|
||||
:onchange "")
|
||||
time))
|
||||
|
||||
; Preview on how the workspaces widget will render:
|
||||
; (defwidget workspaces []
|
||||
; (box :class "workspaces"
|
||||
; :orientation "h"
|
||||
; :space-evenly true
|
||||
; :halign "start"
|
||||
; :spacing 10
|
||||
; (button :class "ws-button-mine" :onclick "leftwm-command \"SendWorkspaceToTag 0 0\"" `1`)
|
||||
; (button :class "ws-button-busy" :onclick "leftwm-command \"SendWorkspaceToTag 0 1\"" `2`)
|
||||
; (button :class "ws-button-busy" :onclick "leftwm-command \"SendWorkspaceToTag 0 2\"" `3`)
|
||||
; (button :class "ws-button" :onclick "leftwm-command \"SendWorkspaceToTag 0 3\"" `·`)
|
||||
; (button :class "ws-button" :onclick "leftwm-command \"SendWorkspaceToTag 0 4\"" `·`)
|
||||
; (button :class "ws-button" :onclick "leftwm-command \"SendWorkspaceToTag 0 5\"" `·`)
|
||||
; (button :class "ws-button" :onclick "leftwm-command \"SendWorkspaceToTag 0 6\"" `·`)
|
||||
; (button :class "ws-button" :onclick "leftwm-command \"SendWorkspaceToTag 0 7\"" `·`)
|
||||
; (button :class "ws-button" :onclick "leftwm-command \"SendWorkspaceToTag 0 8\"" `·`)))
|
||||
|
||||
(defwidget workspaces []
|
||||
(box :class "workspaces"
|
||||
:orientation "h"
|
||||
:space-evenly true
|
||||
:halign "start"
|
||||
:spacing 10
|
||||
(literal :content {wm-tags})))
|
||||
|
||||
(defwidget music []
|
||||
(box :class "music"
|
||||
:orientation "h"
|
||||
:space-evenly false
|
||||
:halign "center"
|
||||
{music != "" ? "🎵${music}" : ""}))
|
||||
|
||||
|
||||
(defwidget metric [label value onchange]
|
||||
(box :orientation "h"
|
||||
:class "metric"
|
||||
:space-evenly false
|
||||
(box :class "label" label)
|
||||
(scale :min 0
|
||||
:max 101
|
||||
:active {onchange != ""}
|
||||
:value value
|
||||
:onchange onchange)))
|
||||
|
||||
|
||||
|
||||
(deflisten music :initial ""
|
||||
"playerctl --follow metadata --format '{{ artist }} - {{ title }}' || true")
|
||||
|
||||
(defpoll volume :interval "1s"
|
||||
"scripts/getvol")
|
||||
|
||||
(defpoll time :interval "10s"
|
||||
"date '+%H:%M %b %d, %Y'")
|
||||
|
||||
(deflisten wm-tags
|
||||
"leftwm-state -w 0 -t ~/.config/leftwm/themes/current/template.liquid")
|
||||
|
||||
(defwindow bar0
|
||||
:monitor 0
|
||||
:windowtype "dock"
|
||||
:geometry (geometry :x "0%"
|
||||
:y "0%"
|
||||
:width "90%"
|
||||
:height "10px"
|
||||
:anchor "top center")
|
||||
:reserve (struts :side "top" :distance "4%")
|
||||
(bar))
|
||||
2
leftwm/.config/leftwm/themes/basic_eww/eww-bar/scripts/getram
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/bin/sh
|
||||
printf "%.0f\n" $(free -m | grep Mem | awk '{print ($3/$2)*100}')
|
||||
2
leftwm/.config/leftwm/themes/basic_eww/eww-bar/scripts/getvol
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/bin/sh
|
||||
amixer -D pulse sget Master | grep 'Left:' | awk -F'[][]' '{ print $2 }' | tr -d '%' | head -1
|
||||
|
After Width: | Height: | Size: 6.1 KiB |
@@ -0,0 +1,59 @@
|
||||
* {
|
||||
all: unset; //Unsets everything so you can style everything from scratch
|
||||
}
|
||||
|
||||
//Global Styles
|
||||
window {
|
||||
background-color: #3a3a3a;
|
||||
color: #b0b4bc;
|
||||
font-family: CascadiaCode;
|
||||
}
|
||||
|
||||
// Styles on classes (see eww.xml for more information)
|
||||
|
||||
.sidestuff slider {
|
||||
all: unset;
|
||||
color: #ffd5cd;
|
||||
}
|
||||
|
||||
.slider-vol scale trough highlight {
|
||||
all: unset;
|
||||
background-color: #D35D6E;
|
||||
color: #000000;
|
||||
border-radius: 10px;
|
||||
}
|
||||
.slider-vol scale trough {
|
||||
all: unset;
|
||||
background-color: #4e4e4e;
|
||||
border-radius: 50px;
|
||||
min-height: 3px;
|
||||
min-width: 50px;
|
||||
margin-left: 10px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.slider-ram scale trough highlight {
|
||||
all: unset;
|
||||
background-color: #D35D6E;
|
||||
color: #000000;
|
||||
border-radius: 10px;
|
||||
}
|
||||
.slider-ram scale trough {
|
||||
all: unset;
|
||||
background-color: #4e4e4e;
|
||||
border-radius: 50px;
|
||||
min-height: 3px;
|
||||
min-width: 50px;
|
||||
margin-left: 10px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
.label-ram {
|
||||
font-size: large;
|
||||
}
|
||||
.time {
|
||||
padding-right: 10px;
|
||||
}
|
||||
.workspaces button:hover {
|
||||
color: #D35D6E;
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,115 @@
|
||||
<!-- The main eww configuration file. This is where your widgets and how they appear on the screen and what they
|
||||
contain are defined. -->
|
||||
|
||||
<eww>
|
||||
<definitions>
|
||||
<!-- This is the place where you structure your widgets, align them and stuff. -->
|
||||
|
||||
<def name="bar"> <!-- Starts the definition of a widget named main -->
|
||||
<box orientation="h" hexpand="true">
|
||||
<workspaces/>
|
||||
<music/>
|
||||
<sidestuff/>
|
||||
</box>
|
||||
</def>
|
||||
<def name="sidestuff">
|
||||
<box class="sidestuff" orientation="h" space-evenly="false" halign="end">
|
||||
<slider-vol/>
|
||||
<slider-ram/>
|
||||
<time/>
|
||||
</box>
|
||||
</def>
|
||||
|
||||
<def name="workspaces">
|
||||
<box orientation="h" class="workspaces" space-evenly="true" halign="start"> <!-- Your workspaces.-->
|
||||
<!-- Attention a literal only takes one element as content, so if you need more elements put them in a <box> -->
|
||||
<literal content="{{leftwm-tags}}"/>
|
||||
</box>
|
||||
</def>
|
||||
<def name="music">
|
||||
<box orientation="h" class="music" halign="center" space-evenly="false">
|
||||
<!-- An image. We won't be using it, but it might be handy if you ever need it. -->
|
||||
<!-- <image path="/home/user/.config/eww/icons/music.svg"/> -->
|
||||
|
||||
{{music}} <!--This is how you use variables.-->
|
||||
</box>
|
||||
</def>
|
||||
<def name="slider-vol">
|
||||
<!--A basic volume slider-->
|
||||
<box orientation="h" class="slider-vol" space-evenly="false">
|
||||
<box class="label-vol"></box>
|
||||
<scale min="0" max="101" value="{{volume}}" onchange="amixer -D pulse sset Master {}%"/>
|
||||
</box>
|
||||
</def>
|
||||
<def name="slider-ram">
|
||||
<!--A basic RAM slider-->
|
||||
<box orientation="h" class="slider-ram" space-evenly="false">
|
||||
<box class="label-ram"></box>
|
||||
<scale min="0" active="false" max="101" value="{{ram-used}}"/>
|
||||
</box>
|
||||
</def>
|
||||
<def name="time">
|
||||
<!--Time-->
|
||||
<box class="time">{{hour}}:{{min}} {{month}} {{number_day}}, {{year_full}}</box>
|
||||
</def>
|
||||
</definitions>
|
||||
|
||||
<variables>
|
||||
|
||||
<!-- Music vars -->
|
||||
<!-- These are your variables. Like they say, they run a script, and then output that to the variable. In
|
||||
the following var, we get music info from playerctl. -->
|
||||
|
||||
<script-var name="music" interval="5s">playerctl metadata --format '{{ artist }} - {{ title }}'</script-var>
|
||||
|
||||
|
||||
<!--Volume var-->
|
||||
<!-- If your vars get too complex to write down here, you can use an external script and paste it's path here as well, as shown below.
|
||||
-->
|
||||
|
||||
<script-var name="volume" interval="16ms">~/.config/eww/scripts/getvol</script-var>
|
||||
|
||||
<!--Date vars-->
|
||||
<script-var name="number_day" interval="5h">date "+%d"</script-var>
|
||||
<script-var name="month" interval="10h">date "+%b"</script-var>
|
||||
<script-var name="min" interval="10s">date "+%M"</script-var>
|
||||
<script-var name="hour" interval="1m">date "+%H"</script-var>
|
||||
<script-var name="year_full" interval="15h">date "+%Y"</script-var>
|
||||
|
||||
<!--RAM var-->
|
||||
<script-var name="ram-used" interval="1s">~/.config/eww/scripts/getram</script-var>
|
||||
|
||||
<!--Battery charge var-->
|
||||
<script-var name="battery-remaining" interval="2m">cat /sys/class/power_supply/BAT0/capacity</script-var>
|
||||
|
||||
<!-- Get the Tags of LeftWM -->
|
||||
<!-- Note: a script-var without an interval takes the tail of the script command -->
|
||||
<script-var name="leftwm-tags">leftwm-state -w 0 -t ~/.config/leftwm/themes/current/template.liquid</script-var>
|
||||
|
||||
</variables>
|
||||
|
||||
<windows>
|
||||
<!-- These are the windows -->
|
||||
<window name="bar0" screen="0">
|
||||
<geometry x="0%" y="0%" width="100%" height="24px"/> <!--Specifies geometry-->
|
||||
<reserve side="top" distance="4%" layer="top"/>
|
||||
<widget>
|
||||
<bar/> <!--This is the def we created earlier-->
|
||||
</widget>
|
||||
</window>
|
||||
<window name="bar1" screen="1">
|
||||
<geometry x="0%" y="0%" width="100%" height="24px"/> <!--Specifies geometry-->
|
||||
<reserve side="top" distance="4%" layer="top"/>
|
||||
<widget>
|
||||
<bar/> <!--This is the def we created earlier-->
|
||||
</widget>
|
||||
</window>
|
||||
<window name="bar2" screen="2">
|
||||
<geometry x="0%" y="0%" width="100%" height="24px"/> <!--Specifies geometry-->
|
||||
<reserve side="top" distance="4%" layer="top"/>
|
||||
<widget>
|
||||
<bar/> <!--This is the def we created earlier-->
|
||||
</widget>
|
||||
</window>
|
||||
</windows>
|
||||
</eww>
|
||||
@@ -0,0 +1,2 @@
|
||||
#!/bin/sh
|
||||
printf "%.0f\n" $(free -m | grep Mem | awk '{print ($3/$2)*100}')
|
||||
@@ -0,0 +1,2 @@
|
||||
#!/bin/sh
|
||||
amixer -D pulse sget Master | grep 'Left:' | awk -F'[][]' '{ print $2 }' | tr -d '%'
|
||||
@@ -0,0 +1,20 @@
|
||||
{% assign mine_open = '<button onclick="wmctrl -s ' %}
|
||||
{% assign visible_open = '<button onclick="wmctrl -s ' %}
|
||||
{% assign busy_open = '<button onclick="wmctrl -s ' %}
|
||||
{% assign close = '</button>' %}
|
||||
{% assign middle = '">' %}
|
||||
{% assign unoccupied = '<button onclick="wmctrl -s ' %}
|
||||
|
||||
{{'<box>'}}
|
||||
{% for tag in workspace.tags %}
|
||||
{% if tag.mine %}
|
||||
{{mine_open}}{{tag.index}}{{middle}} {{ tag.name }} {{close}}
|
||||
{% elsif tag.visible %}
|
||||
{{visible_open}}{{tag.index}}{{middle}} {{ tag.name }} {{close}}
|
||||
{% elsif tag.busy %}
|
||||
{{busy_open}}{{tag.index}}{{middle}} {{ tag.name }} {{close}}
|
||||
{% else tag.visible %}
|
||||
{{unoccupied}}{{tag.index}}{{middle}} {{ tag.name }} {{close}}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{{"</box>"}}
|
||||
3
leftwm/.config/leftwm/themes/basic_eww/sizes.liquid
Normal file
@@ -0,0 +1,3 @@
|
||||
{% for workspace in workspaces %}
|
||||
{{workspace.w}}x{{workspace.h}}+{{workspace.x}}+{{workspace.y}}
|
||||
{% endfor %}
|
||||
19
leftwm/.config/leftwm/themes/basic_eww/template.liquid
Normal file
@@ -0,0 +1,19 @@
|
||||
{% assign mine_open = ' (button :class "ws-button-mine" :onclick "leftwm-command \"SendWorkspaceToTag ' %}
|
||||
{% assign visible_open = ' (button :class "ws-button-visible" :onclick "leftwm-command \"SendWorkspaceToTag ' %}
|
||||
{% assign busy_open = ' (button :class "ws-button-busy" :onclick "leftwm-command \"SendWorkspaceToTag ' %}
|
||||
{% assign close = '`)' %}
|
||||
{% assign unoccupied = ' (button :class "ws-button" :onclick "leftwm-command \"SendWorkspaceToTag ' %}
|
||||
|
||||
{{'(box :class "workspaces" :orientation "h" :space-evenly true :halign "start" :spacing 10'}}
|
||||
{% for tag in workspace.tags %}
|
||||
{% if tag.mine %}
|
||||
{{mine_open}}{{workspace.index | append: ' ' | append: tag.index | append: '\"" `'}}{{ tag.name }}{{close}}
|
||||
{% elsif tag.visible %}
|
||||
{{visible_open}}{{workspace.index | append: ' ' | append: tag.index | append: '\"" `'}}{{ tag.name }}{{close}}
|
||||
{% elsif tag.busy %}
|
||||
{{busy_open}}{{workspace.index | append: ' ' | append: tag.index | append: '\"" `'}}{{ tag.name }}{{close}}
|
||||
{% else %}
|
||||
{{unoccupied}}{{workspace.index | append: ' ' | append: tag.index | append: '\"" `'}}{{ "·" }}{{close}}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{{")"}}
|
||||
5
leftwm/.config/leftwm/themes/basic_eww/theme.toml
Normal file
@@ -0,0 +1,5 @@
|
||||
border_width = 1
|
||||
margin = 5
|
||||
default_border_color = "#37474F"
|
||||
floating_border_color = "#225588"
|
||||
focused_border_color = "#885522"
|
||||
44
leftwm/.config/leftwm/themes/basic_eww/up
Executable file
@@ -0,0 +1,44 @@
|
||||
#!/usr/bin/env bash
|
||||
export SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
#if path to liblinkt is not not exported do so:
|
||||
if [ -z "$LD_LIBRARY_PATH" ]; then
|
||||
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/usr/local/lib"
|
||||
fi
|
||||
|
||||
# Down the last running theme
|
||||
if [ -f "/tmp/leftwm-theme-down" ]; then
|
||||
/tmp/leftwm-theme-down
|
||||
rm /tmp/leftwm-theme-down
|
||||
fi
|
||||
ln -s $SCRIPTPATH/down /tmp/leftwm-theme-down
|
||||
|
||||
# start eww daemon
|
||||
eww daemon &
|
||||
|
||||
# Boot picom or compton if it exists
|
||||
if [ -x "$(command -v picom)" ]; then
|
||||
picom --experimental-backends &> /dev/null &
|
||||
# picom &> /dev/null &
|
||||
elif [ -x "$(command -v compton)" ]; then
|
||||
compton &> /dev/null &
|
||||
fi
|
||||
|
||||
# Set the theme.toml config
|
||||
leftwm-command "LoadTheme $SCRIPTPATH/theme.toml"
|
||||
|
||||
# Set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/background.jpg
|
||||
fi
|
||||
|
||||
#open eww 'bar' windows
|
||||
#this is a bit of an uggly hack, a more elegant way will hopefully be possible with a future `eww` version
|
||||
sleep 1
|
||||
index=0
|
||||
sizes=( $(leftwm-state -q -n -t $SCRIPTPATH/sizes.liquid | sed -r '/^\s*$/d' ) )
|
||||
for size in "${sizes[@]}"
|
||||
do
|
||||
eww open bar$index
|
||||
let index=index+1
|
||||
done
|
||||
BIN
leftwm/.config/leftwm/themes/basic_lemonbar/background.jpg
Normal file
|
After Width: | Height: | Size: 288 KiB |
2
leftwm/.config/leftwm/themes/basic_lemonbar/change_to_tag
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env bash
|
||||
leftwm-command "SendWorkspaceToTag $1 $2"
|
||||
16
leftwm/.config/leftwm/themes/basic_lemonbar/down
Executable file
@@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/down.jpg
|
||||
fi
|
||||
|
||||
leftwm-command "UnloadTheme"
|
||||
|
||||
pkill lemonbar
|
||||
pkill compton
|
||||
pkill picom
|
||||
pkill lemonbar
|
||||
|
||||
BIN
leftwm/.config/leftwm/themes/basic_lemonbar/down.jpg
Normal file
|
After Width: | Height: | Size: 539 B |
3
leftwm/.config/leftwm/themes/basic_lemonbar/sizes.liquid
Normal file
@@ -0,0 +1,3 @@
|
||||
{% for workspace in workspaces %}
|
||||
{{workspace.w}}x{{34}}+{{workspace.x}}+{{workspace.y}}
|
||||
{% endfor %}
|
||||
22
leftwm/.config/leftwm/themes/basic_lemonbar/template.liquid
Normal file
@@ -0,0 +1,22 @@
|
||||
{% assign mine_open = '%{F#000000}%{B#FFFFFF}' %}
|
||||
{% assign mine_close = '%{B-}%{F-}' %}
|
||||
{% assign visible_open = '%{F#000000}%{B#999999}' %}
|
||||
{% assign visible_close = '%{B-}%{F-}' %}
|
||||
{% assign busy_open = '%{F#999999}%{B#333333}' %}
|
||||
{% assign busy_close = '%{B-}%{F-}' %}
|
||||
|
||||
{% for tag in workspace.tags %}
|
||||
{% if tag.mine %}
|
||||
{{mine_open}} {{ tag.name }} {{mine_close}}
|
||||
{% elsif tag.visible %}
|
||||
{{visible_open}} {{ tag.name }} {{visible_close}}
|
||||
{% elsif tag.busy %}
|
||||
{{busy_open}} {{ tag.name }} {{busy_close}}
|
||||
{% else %}
|
||||
{{ tag.name }}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
%{c}
|
||||
{{ window_title }}
|
||||
%{r}
|
||||
{{ localtime }}
|
||||
5
leftwm/.config/leftwm/themes/basic_lemonbar/theme.toml
Normal file
@@ -0,0 +1,5 @@
|
||||
border_width = 1
|
||||
margin = 10
|
||||
default_border_color = "#222222"
|
||||
floating_border_color = "#555555"
|
||||
focused_border_color = "#AAAAAA"
|
||||
39
leftwm/.config/leftwm/themes/basic_lemonbar/up
Executable file
@@ -0,0 +1,39 @@
|
||||
#!/usr/bin/env bash
|
||||
SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
|
||||
#down the last running theme
|
||||
if [ -f "/tmp/leftwm-theme-down" ]; then
|
||||
/tmp/leftwm-theme-down
|
||||
rm /tmp/leftwm-theme-down
|
||||
fi
|
||||
ln -s $SCRIPTPATH/down /tmp/leftwm-theme-down
|
||||
|
||||
|
||||
#boot compton or picom if it exists
|
||||
if [ -x "$(command -v compton)" ]; then
|
||||
compton &> /dev/null &
|
||||
elif [ -x "$(command -v picom)" ]; then
|
||||
picom &> /dev/null &
|
||||
fi
|
||||
|
||||
#set the theme.toml config
|
||||
leftwm-command "LoadTheme $SCRIPTPATH/theme.toml"
|
||||
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/background.jpg
|
||||
fi
|
||||
|
||||
|
||||
#boot lemonbar and pipe the status of left into it
|
||||
sizes=( $(leftwm-state -q -n -t $SCRIPTPATH/sizes.liquid | sed -r '/^\s*$/d') )
|
||||
|
||||
index=0
|
||||
for size in "${sizes[@]}"
|
||||
do
|
||||
leftwm-state -w $index -t $SCRIPTPATH/template.liquid | lemonbar -g $size -F#FFFFFFFF -B#AA222222&
|
||||
let index=index+1
|
||||
done
|
||||
|
||||
1
leftwm/.config/leftwm/themes/basic_polybar/README.md
Normal file
@@ -0,0 +1 @@
|
||||
I changed the pre-loop section to instead of getting a single monitor, to get all the monitors by removing the grep and tac (which caused monitors to be in reverse order compared to leftwm-state -q -n -t $SCRIPTPATH/sizes.liquid). This is so I can set the monitor variable that's passed to the polybar command to the correct monitor (previously, it only got the first monitor and sent that to each). This fixes the highlighted tag being wrong. I got the correct monitor in-loop by using sed which was already a dependent of this script. However, sed expects it to be indexed at one so I created a new variable for that. I then set the 0-indexed variable at the end to that variable instead of recalculating index+1 (don't know if that's actually faster though). I also changed offsetx=$x to offset=$x since offsetx didn't work for my middle monitor which is index0 and a different size than the others. As far as I know, these changes are only an improvement and shouldn't break old setups.
|
||||
BIN
leftwm/.config/leftwm/themes/basic_polybar/background.jpg
Normal file
|
After Width: | Height: | Size: 619 KiB |
2
leftwm/.config/leftwm/themes/basic_polybar/change_to_tag
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env bash
|
||||
leftwm-command "SendWorkspaceToTag $1 $2"
|
||||
15
leftwm/.config/leftwm/themes/basic_polybar/down
Executable file
@@ -0,0 +1,15 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/down.jpg
|
||||
fi
|
||||
|
||||
leftwm-command "UnloadTheme"
|
||||
|
||||
pkill compton
|
||||
pkill picom
|
||||
pkill polybar
|
||||
|
||||
BIN
leftwm/.config/leftwm/themes/basic_polybar/down.jpg
Normal file
|
After Width: | Height: | Size: 539 B |
@@ -0,0 +1 @@
|
||||
/home/mrfluffy/.config/leftwm/themes/leftwm-theme-dracula-rounded
|
||||
447
leftwm/.config/leftwm/themes/basic_polybar/polybar.config
Normal file
@@ -0,0 +1,447 @@
|
||||
;==========================================================
|
||||
;
|
||||
;
|
||||
; ██████╗ ██████╗ ██╗ ██╗ ██╗██████╗ █████╗ ██████╗
|
||||
; ██╔══██╗██╔═══██╗██║ ╚██╗ ██╔╝██╔══██╗██╔══██╗██╔══██╗
|
||||
; ██████╔╝██║ ██║██║ ╚████╔╝ ██████╔╝███████║██████╔╝
|
||||
; ██╔═══╝ ██║ ██║██║ ╚██╔╝ ██╔══██╗██╔══██║██╔══██╗
|
||||
; ██║ ╚██████╔╝███████╗██║ ██████╔╝██║ ██║██║ ██║
|
||||
; ╚═╝ ╚═════╝ ╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝
|
||||
;
|
||||
;
|
||||
; To learn more about how to configure Polybar
|
||||
; go to https://github.com/jaagr/polybar
|
||||
;
|
||||
; The README contains a lot of information
|
||||
;
|
||||
;==========================================================
|
||||
|
||||
[colors]
|
||||
background = #99222222
|
||||
foreground = #dfdfdf
|
||||
background-alt = #99444444
|
||||
foreground-alt = #FFFFFF
|
||||
primary = #ffb52a
|
||||
secondary = #e60053
|
||||
alert = #bd2c40
|
||||
|
||||
|
||||
[bar/mainbar0]
|
||||
inherit = bar/barbase
|
||||
modules-left = workspace0
|
||||
[module/workspace0]
|
||||
type = custom/script
|
||||
exec = leftwm-state -w 0 -t $SCRIPTPATH/template.liquid
|
||||
tail = true
|
||||
|
||||
[bar/mainbar1]
|
||||
inherit = bar/barbase
|
||||
modules-left = workspace1
|
||||
[module/workspace1]
|
||||
type = custom/script
|
||||
exec = leftwm-state -w 1 -t $SCRIPTPATH/template.liquid
|
||||
tail = true
|
||||
|
||||
[bar/mainbar2]
|
||||
inherit = bar/barbase
|
||||
modules-left = workspace2
|
||||
[module/workspace2]
|
||||
type = custom/script
|
||||
exec = leftwm-state -w 2 -t $SCRIPTPATH/template.liquid
|
||||
tail = true
|
||||
|
||||
[bar/mainbar3]
|
||||
inherit = bar/barbase
|
||||
modules-left = workspace3
|
||||
[module/workspace3]
|
||||
type = custom/script
|
||||
exec = leftwm-state -w 3 -t $SCRIPTPATH/template.liquid
|
||||
tail = true
|
||||
|
||||
|
||||
[bar/barbase]
|
||||
width = ${env:width}
|
||||
offset-x = ${env:offsetx}
|
||||
monitor = ${env:monitor}
|
||||
;offset-y = ${env:y}
|
||||
;width = 100%
|
||||
height = 27
|
||||
fixed-center = false
|
||||
background = ${colors.background}
|
||||
foreground = ${colors.foreground}
|
||||
line-size = 3
|
||||
line-color = #f00
|
||||
border-size = 0
|
||||
border-color = #00000000
|
||||
padding-left = 0
|
||||
padding-right = 2
|
||||
module-margin-left = 1
|
||||
module-margin-right = 2
|
||||
font-0 = misc fixed:pixelsize=10;1
|
||||
font-1 = unifont:fontformat=truetype:size=8:antialias=false;0
|
||||
font-2 = wuncon siji:pixelsize=10;1
|
||||
modules-center =
|
||||
modules-right = filesystem xbacklight pulseaudio xkeyboard memory cpu wlan eth battery temperature date powermenu
|
||||
tray-position = right
|
||||
tray-padding = 2
|
||||
cursor-click = pointer
|
||||
cursor-scroll = ns-resize
|
||||
|
||||
[module/ewmh]
|
||||
type = internal/xworkspaces
|
||||
label-active = " %icon% %name% "
|
||||
label-active-foreground = ${colors.foreground-alt}
|
||||
label-active-background = ${colors.background-alt}
|
||||
label-active-underline = ${colors.primary}
|
||||
label-occupied = " %icon% %name% "
|
||||
label-occupied-underline = ${colors.secondary}
|
||||
label-urgent = " %icon% %name% "
|
||||
label-urgent-foreground = ${colors.foreground}
|
||||
label-urgent-background = ${colors.background}
|
||||
label-urgent-underline = ${colors.alert}
|
||||
label-empty = " %icon% %name% "
|
||||
label-empty-foreground = ${colors.foreground}
|
||||
|
||||
|
||||
[module/xwindow]
|
||||
type = internal/xwindow
|
||||
label = %title:0:30:...%
|
||||
|
||||
[module/xkeyboard]
|
||||
type = internal/xkeyboard
|
||||
blacklist-0 = num lock
|
||||
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-prefix-underline = ${colors.secondary}
|
||||
|
||||
label-layout = %layout%
|
||||
label-layout-underline = ${colors.secondary}
|
||||
|
||||
label-indicator-padding = 2
|
||||
label-indicator-margin = 1
|
||||
label-indicator-background = ${colors.secondary}
|
||||
label-indicator-underline = ${colors.secondary}
|
||||
|
||||
[module/filesystem]
|
||||
type = internal/fs
|
||||
interval = 25
|
||||
|
||||
mount-0 = /
|
||||
|
||||
label-mounted = %{F#0a81f5}%mountpoint%%{F-}: %percentage_used%%
|
||||
label-unmounted = %mountpoint% not mounted
|
||||
label-unmounted-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/bspwm]
|
||||
type = internal/bspwm
|
||||
|
||||
label-focused = %index%
|
||||
label-focused-background = ${colors.background-alt}
|
||||
label-focused-underline= ${colors.primary}
|
||||
label-focused-padding = 2
|
||||
|
||||
label-occupied = %index%
|
||||
label-occupied-padding = 2
|
||||
|
||||
label-urgent = %index%!
|
||||
label-urgent-background = ${colors.alert}
|
||||
label-urgent-padding = 2
|
||||
|
||||
label-empty = %index%
|
||||
label-empty-foreground = ${colors.foreground-alt}
|
||||
label-empty-padding = 2
|
||||
|
||||
; Separator in between workspaces
|
||||
; label-separator = |
|
||||
|
||||
[module/i3]
|
||||
type = internal/i3
|
||||
format = <label-state> <label-mode>
|
||||
index-sort = true
|
||||
wrapping-scroll = false
|
||||
|
||||
; Only show workspaces on the same output as the bar
|
||||
;pin-workspaces = true
|
||||
|
||||
label-mode-padding = 2
|
||||
label-mode-foreground = #000
|
||||
label-mode-background = ${colors.primary}
|
||||
|
||||
; focused = Active workspace on focused monitor
|
||||
label-focused = %index%
|
||||
label-focused-background = ${module/bspwm.label-focused-background}
|
||||
label-focused-underline = ${module/bspwm.label-focused-underline}
|
||||
label-focused-padding = ${module/bspwm.label-focused-padding}
|
||||
|
||||
; unfocused = Inactive workspace on any monitor
|
||||
label-unfocused = %index%
|
||||
label-unfocused-padding = ${module/bspwm.label-occupied-padding}
|
||||
|
||||
; visible = Active workspace on unfocused monitor
|
||||
label-visible = %index%
|
||||
label-visible-background = ${self.label-focused-background}
|
||||
label-visible-underline = ${self.label-focused-underline}
|
||||
label-visible-padding = ${self.label-focused-padding}
|
||||
|
||||
; urgent = Workspace with urgency hint set
|
||||
label-urgent = %index%
|
||||
label-urgent-background = ${module/bspwm.label-urgent-background}
|
||||
label-urgent-padding = ${module/bspwm.label-urgent-padding}
|
||||
|
||||
; Separator in between workspaces
|
||||
; label-separator = |
|
||||
|
||||
|
||||
[module/mpd]
|
||||
type = internal/mpd
|
||||
format-online = <label-song> <icon-prev> <icon-stop> <toggle> <icon-next>
|
||||
|
||||
icon-prev =
|
||||
icon-stop =
|
||||
icon-play =
|
||||
icon-pause =
|
||||
icon-next =
|
||||
|
||||
label-song-maxlen = 25
|
||||
label-song-ellipsis = true
|
||||
|
||||
[module/xbacklight]
|
||||
type = internal/xbacklight
|
||||
|
||||
format = <label> <bar>
|
||||
label = BL
|
||||
|
||||
bar-width = 10
|
||||
bar-indicator = |
|
||||
bar-indicator-foreground = #fff
|
||||
bar-indicator-font = 2
|
||||
bar-fill = ─
|
||||
bar-fill-font = 2
|
||||
bar-fill-foreground = #9f78e1
|
||||
bar-empty = ─
|
||||
bar-empty-font = 2
|
||||
bar-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/backlight-acpi]
|
||||
inherit = module/xbacklight
|
||||
type = internal/backlight
|
||||
card = intel_backlight
|
||||
|
||||
[module/cpu]
|
||||
type = internal/cpu
|
||||
interval = 2
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-underline = #f90000
|
||||
label = %percentage:2%%
|
||||
|
||||
[module/memory]
|
||||
type = internal/memory
|
||||
interval = 2
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-underline = #4bffdc
|
||||
label = %percentage_used%%
|
||||
|
||||
[module/wlan]
|
||||
type = internal/network
|
||||
interface = wlp3s0
|
||||
interval = 3.0
|
||||
|
||||
format-connected = <ramp-signal> <label-connected>
|
||||
format-connected-underline = #9f78e1
|
||||
label-connected = %essid%
|
||||
|
||||
format-disconnected =
|
||||
;format-disconnected = <label-disconnected>
|
||||
;format-disconnected-underline = ${self.format-connected-underline}
|
||||
;label-disconnected = %ifname% disconnected
|
||||
;label-disconnected-foreground = ${colors.foreground-alt}
|
||||
|
||||
ramp-signal-0 =
|
||||
ramp-signal-1 =
|
||||
ramp-signal-2 =
|
||||
ramp-signal-3 =
|
||||
ramp-signal-4 =
|
||||
ramp-signal-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/eth]
|
||||
type = internal/network
|
||||
interface = enp0s25
|
||||
interval = 3.0
|
||||
|
||||
format-connected-underline = #55aa55
|
||||
format-connected-prefix = " "
|
||||
format-connected-prefix-foreground = ${colors.foreground-alt}
|
||||
label-connected = %local_ip%
|
||||
|
||||
format-disconnected =
|
||||
;format-disconnected = <label-disconnected>
|
||||
;format-disconnected-underline = ${self.format-connected-underline}
|
||||
;label-disconnected = %ifname% disconnected
|
||||
;label-disconnected-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/date]
|
||||
type = internal/date
|
||||
date = %%{F#99}%m/%d/%Y%%{F-} %%{F#fff}%I:%M %p%{F-}
|
||||
date-alt = %%{F#fff}%A, %B %d, %Y %%{F#fff}%I:%M:%{F#666}%%{F#fba922}%S%%{F-} %p
|
||||
;interval = 5
|
||||
;date =
|
||||
;date-alt = " %Y-%m-%d"
|
||||
;time = %H:%M
|
||||
;time-alt = %H:%M:%S
|
||||
;format-prefix =
|
||||
;format-prefix-foreground = ${colors.foreground-alt}
|
||||
;format-underline = #0a6cf5
|
||||
;label = %date% %time%
|
||||
|
||||
[module/pulseaudio]
|
||||
type = internal/pulseaudio
|
||||
|
||||
format-volume = <label-volume> <bar-volume>
|
||||
label-volume = VOL %percentage%%
|
||||
label-volume-foreground = ${root.foreground}
|
||||
|
||||
label-muted = 🔇 muted
|
||||
label-muted-foreground = #666
|
||||
|
||||
bar-volume-width = 10
|
||||
bar-volume-foreground-0 = #55aa55
|
||||
bar-volume-foreground-1 = #55aa55
|
||||
bar-volume-foreground-2 = #55aa55
|
||||
bar-volume-foreground-3 = #55aa55
|
||||
bar-volume-foreground-4 = #55aa55
|
||||
bar-volume-foreground-5 = #f5a70a
|
||||
bar-volume-foreground-6 = #ff5555
|
||||
bar-volume-gradient = false
|
||||
bar-volume-indicator = |
|
||||
bar-volume-indicator-font = 2
|
||||
bar-volume-fill = ─
|
||||
bar-volume-fill-font = 2
|
||||
bar-volume-empty = ─
|
||||
bar-volume-empty-font = 2
|
||||
bar-volume-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/alsa]
|
||||
type = internal/alsa
|
||||
|
||||
format-volume = <label-volume> <bar-volume>
|
||||
label-volume = VOL
|
||||
label-volume-foreground = ${root.foreground}
|
||||
|
||||
format-muted-prefix = " "
|
||||
format-muted-foreground = ${colors.foreground-alt}
|
||||
label-muted = sound muted
|
||||
|
||||
bar-volume-width = 10
|
||||
bar-volume-foreground-0 = #55aa55
|
||||
bar-volume-foreground-1 = #55aa55
|
||||
bar-volume-foreground-2 = #55aa55
|
||||
bar-volume-foreground-3 = #55aa55
|
||||
bar-volume-foreground-4 = #55aa55
|
||||
bar-volume-foreground-5 = #f5a70a
|
||||
bar-volume-foreground-6 = #ff5555
|
||||
bar-volume-gradient = false
|
||||
bar-volume-indicator = |
|
||||
bar-volume-indicator-font = 2
|
||||
bar-volume-fill = ─
|
||||
bar-volume-fill-font = 2
|
||||
bar-volume-empty = ─
|
||||
bar-volume-empty-font = 2
|
||||
bar-volume-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/battery]
|
||||
type = internal/battery
|
||||
battery = BAT0
|
||||
adapter = AC
|
||||
full-at = 98
|
||||
|
||||
format-charging = <animation-charging> <label-charging>
|
||||
format-charging-underline = #ffb52a
|
||||
|
||||
format-discharging = <animation-discharging> <label-discharging>
|
||||
format-discharging-underline = ${self.format-charging-underline}
|
||||
|
||||
format-full-prefix = " "
|
||||
format-full-prefix-foreground = ${colors.foreground-alt}
|
||||
format-full-underline = ${self.format-charging-underline}
|
||||
|
||||
ramp-capacity-0 =
|
||||
ramp-capacity-1 =
|
||||
ramp-capacity-2 =
|
||||
ramp-capacity-foreground = ${colors.foreground-alt}
|
||||
|
||||
animation-charging-0 =
|
||||
animation-charging-1 =
|
||||
animation-charging-2 =
|
||||
animation-charging-foreground = ${colors.foreground-alt}
|
||||
animation-charging-framerate = 750
|
||||
|
||||
animation-discharging-0 =
|
||||
animation-discharging-1 =
|
||||
animation-discharging-2 =
|
||||
animation-discharging-foreground = ${colors.foreground-alt}
|
||||
animation-discharging-framerate = 750
|
||||
|
||||
[module/temperature]
|
||||
type = internal/temperature
|
||||
thermal-zone = 0
|
||||
warn-temperature = 60
|
||||
|
||||
format = <ramp> <label>
|
||||
format-underline = #f50a4d
|
||||
format-warn = <ramp> <label-warn>
|
||||
format-warn-underline = ${self.format-underline}
|
||||
|
||||
label = %temperature-c%
|
||||
label-warn = %temperature-c%
|
||||
label-warn-foreground = ${colors.secondary}
|
||||
|
||||
ramp-0 =
|
||||
ramp-1 =
|
||||
ramp-2 =
|
||||
ramp-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/powermenu]
|
||||
type = custom/menu
|
||||
|
||||
expand-right = true
|
||||
|
||||
format-spacing = 1
|
||||
|
||||
label-open =
|
||||
label-open-foreground = ${colors.secondary}
|
||||
label-close = cancel
|
||||
label-close-foreground = ${colors.secondary}
|
||||
label-separator = |
|
||||
label-separator-foreground = ${colors.foreground-alt}
|
||||
|
||||
menu-0-0 = reboot
|
||||
menu-0-0-exec = menu-open-1
|
||||
menu-0-1 = power off
|
||||
menu-0-1-exec = menu-open-2
|
||||
|
||||
menu-1-0 = cancel
|
||||
menu-1-0-exec = menu-open-0
|
||||
menu-1-1 = reboot
|
||||
menu-1-1-exec = sudo reboot
|
||||
|
||||
menu-2-0 = power off
|
||||
menu-2-0-exec = sudo poweroff
|
||||
menu-2-1 = cancel
|
||||
menu-2-1-exec = menu-open-0
|
||||
|
||||
[settings]
|
||||
screenchange-reload = true
|
||||
;compositing-background = xor
|
||||
;compositing-background = screen
|
||||
;compositing-foreground = source
|
||||
;compositing-border = over
|
||||
;pseudo-transparency = false
|
||||
|
||||
;[global/wm]
|
||||
;margin-top = 5
|
||||
;margin-bottom = 5
|
||||
|
||||
; vim:ft=dosini
|
||||
3
leftwm/.config/leftwm/themes/basic_polybar/sizes.liquid
Normal file
@@ -0,0 +1,3 @@
|
||||
{% for workspace in workspaces %}
|
||||
{{workspace.w}} {{workspace.x}} {{workspace.y}}
|
||||
{% endfor %}
|
||||
21
leftwm/.config/leftwm/themes/basic_polybar/template.liquid
Normal file
@@ -0,0 +1,21 @@
|
||||
{% for tag in workspace.tags %}
|
||||
{% if tag.mine %}
|
||||
%{A1:$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}:}
|
||||
%{F#000000}%{B#FFB52A} {{tag.name}} %{B-}%{F-}
|
||||
%{A}
|
||||
{% elsif tag.visible %}
|
||||
%{A1:$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}:}
|
||||
%{F#000000}%{B#E60053} {{tag.name}} %{B-}%{F-}
|
||||
%{A}
|
||||
{% elsif tag.busy %}
|
||||
%{A1:$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}:}
|
||||
%{F#FFB52A} {{tag.name}} %{F-}
|
||||
%{A}
|
||||
{% else %}
|
||||
%{A1:$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}:}
|
||||
%{F#FFFFFF} {{tag.name}} %{F-}
|
||||
%{A}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
%{c}
|
||||
{{ window_title }}
|
||||
5
leftwm/.config/leftwm/themes/basic_polybar/theme.toml
Normal file
@@ -0,0 +1,5 @@
|
||||
border_width = 1
|
||||
margin = 20
|
||||
default_border_color = "#222222"
|
||||
floating_border_color = "#005500"
|
||||
focused_border_color = "#FFB53A"
|
||||
39
leftwm/.config/leftwm/themes/basic_polybar/up
Executable file
@@ -0,0 +1,39 @@
|
||||
#!/usr/bin/env bash
|
||||
export SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
|
||||
#down the last running theme
|
||||
if [ -f "/tmp/leftwm-theme-down" ]; then
|
||||
/tmp/leftwm-theme-down
|
||||
rm /tmp/leftwm-theme-down
|
||||
fi
|
||||
ln -s $SCRIPTPATH/down /tmp/leftwm-theme-down
|
||||
|
||||
|
||||
#boot picom or compton if it exists
|
||||
if [ -x "$(command -v picom)" ]; then
|
||||
picom &> /dev/null &
|
||||
elif [ -x "$(command -v compton)" ]; then
|
||||
compton &> /dev/null &
|
||||
fi
|
||||
|
||||
#set the theme.toml config
|
||||
leftwm-command "LoadTheme $SCRIPTPATH/theme.toml"
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/background.jpg
|
||||
fi
|
||||
|
||||
|
||||
index=0
|
||||
monitors="$(polybar -m | sed s/:.*//)"
|
||||
leftwm-state -q -n -t $SCRIPTPATH/sizes.liquid | sed -r '/^\s*$/d' | while read -r width x y
|
||||
do
|
||||
let indextemp=index+1
|
||||
monitor=$(sed "$indextemp!d" <<<"$monitors")
|
||||
barname="mainbar$index"
|
||||
monitor=$monitor offset=$x width=$width polybar -c $SCRIPTPATH/polybar.config $barname &> /dev/null &
|
||||
let index=indextemp
|
||||
done
|
||||
|
||||
BIN
leftwm/.config/leftwm/themes/basic_xmobar/background.jpg
Normal file
|
After Width: | Height: | Size: 4.2 MiB |
2
leftwm/.config/leftwm/themes/basic_xmobar/change_to_tag
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env bash
|
||||
leftwm-command "SendWorkspaceToTag $1 $2"
|
||||
19
leftwm/.config/leftwm/themes/basic_xmobar/down
Executable file
@@ -0,0 +1,19 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/reset.jpg
|
||||
fi
|
||||
|
||||
leftwm-command "UnloadTheme"
|
||||
|
||||
|
||||
ps -alh | grep xmobar_control_script | awk '{print $3}' | xargs kill
|
||||
|
||||
pkill compton
|
||||
pkill picom
|
||||
pkill xmobar
|
||||
pkill xmobar
|
||||
|
||||
BIN
leftwm/.config/leftwm/themes/basic_xmobar/reset.jpg
Normal file
|
After Width: | Height: | Size: 539 B |
3
leftwm/.config/leftwm/themes/basic_xmobar/sizes.liquid
Normal file
@@ -0,0 +1,3 @@
|
||||
{% for w in workspaces %}
|
||||
Static { xpos = {{w.x}} , ypos = {{w.y}}, width = {{w.w}}, height = 24 }
|
||||
{% endfor %}
|
||||
12
leftwm/.config/leftwm/themes/basic_xmobar/template.liquid
Normal file
@@ -0,0 +1,12 @@
|
||||
{% for tag in workspace.tags %}
|
||||
{% if tag.mine %}
|
||||
<action=`$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}`><fc=#FF0000> {{tag.name}} </fc></action>
|
||||
{% elsif tag.visible %}
|
||||
<action=`$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}`><fc=#FF9999> {{tag.name}} </fc></action>
|
||||
{% elsif tag.busy %}
|
||||
<action=`$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}`> {{tag.name}}* </action>
|
||||
{% else %}
|
||||
<action=`$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}`><fc=#FFFFFF> {{tag.name}} </fc></action>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
<fc=#555555> {{ window_title }}</fc>
|
||||
5
leftwm/.config/leftwm/themes/basic_xmobar/theme.toml
Normal file
@@ -0,0 +1,5 @@
|
||||
border_width = 2
|
||||
margin = 12
|
||||
default_border_color = "#222222"
|
||||
floating_border_color = "#555555"
|
||||
focused_border_color = "#FF3333"
|
||||
35
leftwm/.config/leftwm/themes/basic_xmobar/up
Executable file
@@ -0,0 +1,35 @@
|
||||
#!/usr/bin/env bash
|
||||
export SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
|
||||
#down the last running theme
|
||||
if [ -f "/tmp/leftwm-theme-down" ]; then
|
||||
/tmp/leftwm-theme-down
|
||||
rm /tmp/leftwm-theme-down
|
||||
fi
|
||||
ln -s $SCRIPTPATH/down /tmp/leftwm-theme-down
|
||||
|
||||
|
||||
#boot compton or picom if it exists
|
||||
if [ -x "$(command -v compton)" ]; then
|
||||
compton &> /dev/null &
|
||||
elif [ -x "$(command -v picom)" ]; then
|
||||
picom &> /dev/null &
|
||||
fi
|
||||
|
||||
#set the theme.toml config
|
||||
leftwm-command "LoadTheme $SCRIPTPATH/theme.toml"
|
||||
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/background.jpg
|
||||
fi
|
||||
|
||||
index=0
|
||||
leftwm-state -q -n -t $SCRIPTPATH/sizes.liquid | sed -r '/^\s*$/d' | while read size
|
||||
do
|
||||
leftwm-state -w $index -t $SCRIPTPATH/template.liquid | xmobar -p "$size" $SCRIPTPATH/xmobar-config.hs &
|
||||
let index=index+1
|
||||
done
|
||||
|
||||
23
leftwm/.config/leftwm/themes/basic_xmobar/xmobar-config.hs
Normal file
@@ -0,0 +1,23 @@
|
||||
|
||||
|
||||
Config { font = "-misc-fixed-*-*-*-*-13-*-*-*-*-*-*-*"
|
||||
, bgColor = "black"
|
||||
, fgColor = "grey"
|
||||
, position = Top
|
||||
, lowerOnStart = True
|
||||
, allDesktops = True
|
||||
, pickBroadest = False
|
||||
, overrideRedirect = False
|
||||
, commands = [ Run Weather "KSHV" ["-t"," <tempF>F","-L","64","-H","77","--normal","green","--high","red","--low","lightblue"] 36000
|
||||
, Run Network "eno1" ["-L","0","-H","32","--normal","green","--high","red"] 10
|
||||
, Run MultiCpu ["-L","15","-H","50","--normal","green","--high","red"] 10
|
||||
, Run Memory [] 10
|
||||
, Run Swap [] 10
|
||||
, Run TopProc [] 10
|
||||
, Run Date "%a %b %_d %Y %H:%M:%S" "date" 10
|
||||
, Run UnsafeStdinReader
|
||||
]
|
||||
, sepChar = "%"
|
||||
, alignSep = "}{"
|
||||
, template = "%UnsafeStdinReader% }{ %top% | %multicpu% | %memory% * %swap% | %eno1% | %date% | %KSHV%"
|
||||
}
|
||||
30
leftwm/.config/leftwm/themes/controlling_leftwm/README.md
Normal file
@@ -0,0 +1,30 @@
|
||||
# How to control LeftWM from an external proccess
|
||||
|
||||
LeftWM supports being controlled using EWMH calls and from an external pipe
|
||||
file.
|
||||
|
||||
This folder has example of how to send commands to LeftWM using its external pipe
|
||||
file.
|
||||
|
||||
A full list of supported commands can be found here:
|
||||
|
||||
```
|
||||
LoadTheme PATH_TO_THEME
|
||||
UnloadTheme
|
||||
Reload
|
||||
SendWorkspaceToTag INDEX_OF_WORKSPACE, INDEX_OF_TAG
|
||||
SendWindowToTag INDEX_OF_TAG
|
||||
SwapScreens
|
||||
MoveWindowToLastWorkspace
|
||||
MoveWindowUp
|
||||
MoveWindowDown
|
||||
FocusWindowUp
|
||||
FocusWindowDown
|
||||
FocusWorkspaceNext
|
||||
FocusWorkspacePrevious
|
||||
CloseWindow
|
||||
NextLayout
|
||||
PreviousLayout
|
||||
```
|
||||
|
||||
|
||||
2
leftwm/.config/leftwm/themes/controlling_leftwm/change_to_tag
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env bash
|
||||
leftwm-command "SendWorkspaceToTag $1 $2"
|
||||
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env bash
|
||||
leftwm-command "MoveWindowToLastWorkspace"
|
||||
2
leftwm/.config/leftwm/themes/controlling_leftwm/move_window_to_tag
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env bash
|
||||
leftwm-command "SendWindowToTag $1"
|
||||
2
leftwm/.config/leftwm/themes/controlling_leftwm/swap_screens
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env bash
|
||||
leftwm-command "SwapScreens"
|
||||
1
leftwm/.config/leftwm/themes/current
Symbolic link
@@ -0,0 +1 @@
|
||||
/home/mrfluffy/.config/leftwm/themes/dracula_polybar
|
||||
1
leftwm/.config/leftwm/themes/dracula_polybar/README.md
Normal file
@@ -0,0 +1 @@
|
||||
I changed the pre-loop section to instead of getting a single monitor, to get all the monitors by removing the grep and tac (which caused monitors to be in reverse order compared to leftwm-state -q -n -t $SCRIPTPATH/sizes.liquid). This is so I can set the monitor variable that's passed to the polybar command to the correct monitor (previously, it only got the first monitor and sent that to each). This fixes the highlighted tag being wrong. I got the correct monitor in-loop by using sed which was already a dependent of this script. However, sed expects it to be indexed at one so I created a new variable for that. I then set the 0-indexed variable at the end to that variable instead of recalculating index+1 (don't know if that's actually faster though). I also changed offsetx=$x to offset=$x since offsetx didn't work for my middle monitor which is index0 and a different size than the others. As far as I know, these changes are only an improvement and shouldn't break old setups.
|
||||
BIN
leftwm/.config/leftwm/themes/dracula_polybar/background.jpg
Normal file
|
After Width: | Height: | Size: 619 KiB |
2
leftwm/.config/leftwm/themes/dracula_polybar/change_to_tag
Executable file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env bash
|
||||
leftwm-command "SendWorkspaceToTag $1 $2"
|
||||
15
leftwm/.config/leftwm/themes/dracula_polybar/down
Executable file
@@ -0,0 +1,15 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/down.jpg
|
||||
fi
|
||||
|
||||
leftwm-command "UnloadTheme"
|
||||
|
||||
pkill compton
|
||||
pkill picom
|
||||
pkill polybar
|
||||
|
||||
BIN
leftwm/.config/leftwm/themes/dracula_polybar/down.jpg
Normal file
|
After Width: | Height: | Size: 539 B |
@@ -0,0 +1 @@
|
||||
/home/mrfluffy/.config/leftwm/themes/leftwm-theme-dracula-rounded
|
||||
447
leftwm/.config/leftwm/themes/dracula_polybar/polybar.config
Normal file
@@ -0,0 +1,447 @@
|
||||
;==========================================================
|
||||
;
|
||||
;
|
||||
; ██████╗ ██████╗ ██╗ ██╗ ██╗██████╗ █████╗ ██████╗
|
||||
; ██╔══██╗██╔═══██╗██║ ╚██╗ ██╔╝██╔══██╗██╔══██╗██╔══██╗
|
||||
; ██████╔╝██║ ██║██║ ╚████╔╝ ██████╔╝███████║██████╔╝
|
||||
; ██╔═══╝ ██║ ██║██║ ╚██╔╝ ██╔══██╗██╔══██║██╔══██╗
|
||||
; ██║ ╚██████╔╝███████╗██║ ██████╔╝██║ ██║██║ ██║
|
||||
; ╚═╝ ╚═════╝ ╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝
|
||||
;
|
||||
;
|
||||
; To learn more about how to configure Polybar
|
||||
; go to https://github.com/jaagr/polybar
|
||||
;
|
||||
; The README contains a lot of information
|
||||
;
|
||||
;==========================================================
|
||||
|
||||
[colors]
|
||||
background = #282a36
|
||||
foreground = #f8f8f2
|
||||
background-alt = #99444444
|
||||
foreground-alt = #2a2a2a
|
||||
primary = #6e5991
|
||||
secondary = #363949
|
||||
alert = #bd2c40
|
||||
|
||||
|
||||
[bar/mainbar0]
|
||||
inherit = bar/barbase
|
||||
modules-left = workspace0
|
||||
[module/workspace0]
|
||||
type = custom/script
|
||||
exec = leftwm-state -w 0 -t $SCRIPTPATH/template.liquid
|
||||
tail = true
|
||||
|
||||
[bar/mainbar1]
|
||||
inherit = bar/barbase
|
||||
modules-left = workspace1
|
||||
[module/workspace1]
|
||||
type = custom/script
|
||||
exec = leftwm-state -w 1 -t $SCRIPTPATH/template.liquid
|
||||
tail = true
|
||||
|
||||
[bar/mainbar2]
|
||||
inherit = bar/barbase
|
||||
modules-left = workspace2
|
||||
[module/workspace2]
|
||||
type = custom/script
|
||||
exec = leftwm-state -w 2 -t $SCRIPTPATH/template.liquid
|
||||
tail = true
|
||||
|
||||
[bar/mainbar3]
|
||||
inherit = bar/barbase
|
||||
modules-left = workspace3
|
||||
[module/workspace3]
|
||||
type = custom/script
|
||||
exec = leftwm-state -w 3 -t $SCRIPTPATH/template.liquid
|
||||
tail = true
|
||||
|
||||
|
||||
[bar/barbase]
|
||||
width = ${env:width}
|
||||
offset-x = ${env:offsetx}
|
||||
monitor = ${env:monitor}
|
||||
;offset-y = ${env:y}
|
||||
;width = 100%
|
||||
height = 27
|
||||
fixed-center = false
|
||||
background = ${colors.background}
|
||||
foreground = ${colors.foreground}
|
||||
line-size = 3
|
||||
line-color = #f00
|
||||
border-size = 0
|
||||
border-color = #00000000
|
||||
padding-left = 0
|
||||
padding-right = 2
|
||||
module-margin-left = 1
|
||||
module-margin-right = 2
|
||||
font-0 = misc fixed:pixelsize=10;1
|
||||
font-1 = unifont:fontformat=truetype:size=8:antialias=false;0
|
||||
font-2 = wuncon siji:pixelsize=10;1
|
||||
modules-center =
|
||||
modules-right = filesystem pulseaudio xkeyboard memory cpu wlan eth battery date powermenu
|
||||
tray-position = right
|
||||
tray-padding = 2
|
||||
cursor-click = pointer
|
||||
cursor-scroll = ns-resize
|
||||
|
||||
[module/ewmh]
|
||||
type = internal/xworkspaces
|
||||
label-active = " %icon% %name% "
|
||||
label-active-foreground = ${colors.foreground-alt}
|
||||
label-active-background = ${colors.background-alt}
|
||||
label-active-underline = ${colors.primary}
|
||||
label-occupied = " %icon% %name% "
|
||||
label-occupied-underline = ${colors.secondary}
|
||||
label-urgent = " %icon% %name% "
|
||||
label-urgent-foreground = ${colors.foreground}
|
||||
label-urgent-background = ${colors.background}
|
||||
label-urgent-underline = ${colors.alert}
|
||||
label-empty = " %icon% %name% "
|
||||
label-empty-foreground = ${colors.foreground}
|
||||
|
||||
|
||||
[module/xwindow]
|
||||
type = internal/xwindow
|
||||
label = %title:0:30:...%
|
||||
|
||||
[module/xkeyboard]
|
||||
type = internal/xkeyboard
|
||||
blacklist-0 = num lock
|
||||
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-prefix-underline = ${colors.secondary}
|
||||
|
||||
label-layout = %layout%
|
||||
label-layout-underline = ${colors.secondary}
|
||||
|
||||
label-indicator-padding = 2
|
||||
label-indicator-margin = 1
|
||||
label-indicator-background = ${colors.secondary}
|
||||
label-indicator-underline = ${colors.secondary}
|
||||
|
||||
[module/filesystem]
|
||||
type = internal/fs
|
||||
interval = 25
|
||||
|
||||
mount-0 = /
|
||||
|
||||
label-mounted = %{F#0a81f5}%mountpoint%%{F-}: %percentage_used%%
|
||||
label-unmounted = %mountpoint% not mounted
|
||||
label-unmounted-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/bspwm]
|
||||
type = internal/bspwm
|
||||
|
||||
label-focused = %index%
|
||||
label-focused-background = ${colors.background-alt}
|
||||
label-focused-underline= ${colors.primary}
|
||||
label-focused-padding = 2
|
||||
|
||||
label-occupied = %index%
|
||||
label-occupied-padding = 2
|
||||
|
||||
label-urgent = %index%!
|
||||
label-urgent-background = ${colors.alert}
|
||||
label-urgent-padding = 2
|
||||
|
||||
label-empty = %index%
|
||||
label-empty-foreground = ${colors.foreground-alt}
|
||||
label-empty-padding = 2
|
||||
|
||||
; Separator in between workspaces
|
||||
; label-separator = |
|
||||
|
||||
[module/i3]
|
||||
type = internal/i3
|
||||
format = <label-state> <label-mode>
|
||||
index-sort = true
|
||||
wrapping-scroll = false
|
||||
|
||||
; Only show workspaces on the same output as the bar
|
||||
;pin-workspaces = true
|
||||
|
||||
label-mode-padding = 2
|
||||
label-mode-foreground = #000
|
||||
label-mode-background = ${colors.primary}
|
||||
|
||||
; focused = Active workspace on focused monitor
|
||||
label-focused = %index%
|
||||
label-focused-background = ${module/bspwm.label-focused-background}
|
||||
label-focused-underline = ${module/bspwm.label-focused-underline}
|
||||
label-focused-padding = ${module/bspwm.label-focused-padding}
|
||||
|
||||
; unfocused = Inactive workspace on any monitor
|
||||
label-unfocused = %index%
|
||||
label-unfocused-padding = ${module/bspwm.label-occupied-padding}
|
||||
|
||||
; visible = Active workspace on unfocused monitor
|
||||
label-visible = %index%
|
||||
label-visible-background = ${self.label-focused-background}
|
||||
label-visible-underline = ${self.label-focused-underline}
|
||||
label-visible-padding = ${self.label-focused-padding}
|
||||
|
||||
; urgent = Workspace with urgency hint set
|
||||
label-urgent = %index%
|
||||
label-urgent-background = ${module/bspwm.label-urgent-background}
|
||||
label-urgent-padding = ${module/bspwm.label-urgent-padding}
|
||||
|
||||
; Separator in between workspaces
|
||||
; label-separator = |
|
||||
|
||||
|
||||
[module/mpd]
|
||||
type = internal/mpd
|
||||
format-online = <label-song> <icon-prev> <icon-stop> <toggle> <icon-next>
|
||||
|
||||
icon-prev =
|
||||
icon-stop =
|
||||
icon-play =
|
||||
icon-pause =
|
||||
icon-next =
|
||||
|
||||
label-song-maxlen = 25
|
||||
label-song-ellipsis = true
|
||||
|
||||
[module/xbacklight]
|
||||
type = internal/xbacklight
|
||||
|
||||
format = <label> <bar>
|
||||
label = BL
|
||||
|
||||
bar-width = 10
|
||||
bar-indicator = |
|
||||
bar-indicator-foreground = #fff
|
||||
bar-indicator-font = 2
|
||||
bar-fill = ─
|
||||
bar-fill-font = 2
|
||||
bar-fill-foreground = #9f78e1
|
||||
bar-empty = ─
|
||||
bar-empty-font = 2
|
||||
bar-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/backlight-acpi]
|
||||
inherit = module/xbacklight
|
||||
type = internal/backlight
|
||||
card = intel_backlight
|
||||
|
||||
[module/cpu]
|
||||
type = internal/cpu
|
||||
interval = 2
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-underline = #f90000
|
||||
label = %percentage:2%%
|
||||
|
||||
[module/memory]
|
||||
type = internal/memory
|
||||
interval = 2
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-underline = #4bffdc
|
||||
label = %percentage_used%%
|
||||
|
||||
[module/wlan]
|
||||
type = internal/network
|
||||
interface = wlp3s0
|
||||
interval = 3.0
|
||||
|
||||
format-connected = <ramp-signal> <label-connected>
|
||||
format-connected-underline = #9f78e1
|
||||
label-connected = %essid%
|
||||
|
||||
format-disconnected =
|
||||
;format-disconnected = <label-disconnected>
|
||||
;format-disconnected-underline = ${self.format-connected-underline}
|
||||
;label-disconnected = %ifname% disconnected
|
||||
;label-disconnected-foreground = ${colors.foreground-alt}
|
||||
|
||||
ramp-signal-0 =
|
||||
ramp-signal-1 =
|
||||
ramp-signal-2 =
|
||||
ramp-signal-3 =
|
||||
ramp-signal-4 =
|
||||
ramp-signal-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/eth]
|
||||
type = internal/network
|
||||
interface = enp0s25
|
||||
interval = 3.0
|
||||
|
||||
format-connected-underline = #55aa55
|
||||
format-connected-prefix = " "
|
||||
format-connected-prefix-foreground = ${colors.foreground-alt}
|
||||
label-connected = %local_ip%
|
||||
|
||||
format-disconnected =
|
||||
;format-disconnected = <label-disconnected>
|
||||
;format-disconnected-underline = ${self.format-connected-underline}
|
||||
;label-disconnected = %ifname% disconnected
|
||||
;label-disconnected-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/date]
|
||||
type = internal/date
|
||||
date = %%{F#fff}%m/%d/%Y%%{F-} %%{F#fff}%I:%M %p%{F-}
|
||||
date-alt = %%{F#fff}%A, %B %d, %Y %%{F#fff}%I:%M:%{F#666}%%{F#fba922}%S%%{F-} %p
|
||||
;interval = 5
|
||||
;date =
|
||||
;date-alt = " %Y-%m-%d"
|
||||
;time = %H:%M
|
||||
;time-alt = %H:%M:%S
|
||||
;format-prefix =
|
||||
;format-prefix-foreground = ${colors.foreground-alt}
|
||||
;format-underline = #0a6cf5
|
||||
;label = %date% %time%
|
||||
|
||||
[module/pulseaudio]
|
||||
type = internal/pulseaudio
|
||||
|
||||
format-volume = <label-volume> <bar-volume>
|
||||
label-volume = VOL %percentage%%
|
||||
label-volume-foreground = ${root.foreground}
|
||||
|
||||
label-muted = 🔇 muted
|
||||
label-muted-foreground = #666
|
||||
|
||||
bar-volume-width = 10
|
||||
bar-volume-foreground-0 = #55aa55
|
||||
bar-volume-foreground-1 = #55aa55
|
||||
bar-volume-foreground-2 = #55aa55
|
||||
bar-volume-foreground-3 = #55aa55
|
||||
bar-volume-foreground-4 = #55aa55
|
||||
bar-volume-foreground-5 = #f5a70a
|
||||
bar-volume-foreground-6 = #ff5555
|
||||
bar-volume-gradient = false
|
||||
bar-volume-indicator = |
|
||||
bar-volume-indicator-font = 2
|
||||
bar-volume-fill = ─
|
||||
bar-volume-fill-font = 2
|
||||
bar-volume-empty = ─
|
||||
bar-volume-empty-font = 2
|
||||
bar-volume-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/alsa]
|
||||
type = internal/alsa
|
||||
|
||||
format-volume = <label-volume> <bar-volume>
|
||||
label-volume = VOL
|
||||
label-volume-foreground = ${root.foreground}
|
||||
|
||||
format-muted-prefix = " "
|
||||
format-muted-foreground = ${colors.foreground-alt}
|
||||
label-muted = sound muted
|
||||
|
||||
bar-volume-width = 10
|
||||
bar-volume-foreground-0 = #55aa55
|
||||
bar-volume-foreground-1 = #55aa55
|
||||
bar-volume-foreground-2 = #55aa55
|
||||
bar-volume-foreground-3 = #55aa55
|
||||
bar-volume-foreground-4 = #55aa55
|
||||
bar-volume-foreground-5 = #f5a70a
|
||||
bar-volume-foreground-6 = #ff5555
|
||||
bar-volume-gradient = false
|
||||
bar-volume-indicator = |
|
||||
bar-volume-indicator-font = 2
|
||||
bar-volume-fill = ─
|
||||
bar-volume-fill-font = 2
|
||||
bar-volume-empty = ─
|
||||
bar-volume-empty-font = 2
|
||||
bar-volume-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/battery]
|
||||
type = internal/battery
|
||||
battery = BAT0
|
||||
adapter = AC
|
||||
full-at = 98
|
||||
|
||||
format-charging = <animation-charging> <label-charging>
|
||||
format-charging-underline = #ffb52a
|
||||
|
||||
format-discharging = <animation-discharging> <label-discharging>
|
||||
format-discharging-underline = ${self.format-charging-underline}
|
||||
|
||||
format-full-prefix = " "
|
||||
format-full-prefix-foreground = ${colors.foreground-alt}
|
||||
format-full-underline = ${self.format-charging-underline}
|
||||
|
||||
ramp-capacity-0 =
|
||||
ramp-capacity-1 =
|
||||
ramp-capacity-2 =
|
||||
ramp-capacity-foreground = ${colors.foreground-alt}
|
||||
|
||||
animation-charging-0 =
|
||||
animation-charging-1 =
|
||||
animation-charging-2 =
|
||||
animation-charging-foreground = ${colors.foreground-alt}
|
||||
animation-charging-framerate = 750
|
||||
|
||||
animation-discharging-0 =
|
||||
animation-discharging-1 =
|
||||
animation-discharging-2 =
|
||||
animation-discharging-foreground = ${colors.foreground-alt}
|
||||
animation-discharging-framerate = 750
|
||||
|
||||
[module/temperature]
|
||||
type = internal/temperature
|
||||
thermal-zone = 0
|
||||
warn-temperature = 60
|
||||
|
||||
format = <ramp> <label>
|
||||
format-underline = #f50a4d
|
||||
format-warn = <ramp> <label-warn>
|
||||
format-warn-underline = ${self.format-underline}
|
||||
|
||||
label = %temperature-c%
|
||||
label-warn = %temperature-c%
|
||||
label-warn-foreground = ${colors.secondary}
|
||||
|
||||
ramp-0 =
|
||||
ramp-1 =
|
||||
ramp-2 =
|
||||
ramp-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/powermenu]
|
||||
type = custom/menu
|
||||
|
||||
expand-right = true
|
||||
|
||||
format-spacing = 1
|
||||
|
||||
label-open =
|
||||
label-open-foreground = ${colors.secondary}
|
||||
label-close = cancel
|
||||
label-close-foreground = ${colors.secondary}
|
||||
label-separator = |
|
||||
label-separator-foreground = ${colors.foreground-alt}
|
||||
|
||||
menu-0-0 = reboot
|
||||
menu-0-0-exec = menu-open-1
|
||||
menu-0-1 = power off
|
||||
menu-0-1-exec = menu-open-2
|
||||
|
||||
menu-1-0 = cancel
|
||||
menu-1-0-exec = menu-open-0
|
||||
menu-1-1 = reboot
|
||||
menu-1-1-exec = sudo reboot
|
||||
|
||||
menu-2-0 = power off
|
||||
menu-2-0-exec = sudo poweroff
|
||||
menu-2-1 = cancel
|
||||
menu-2-1-exec = menu-open-0
|
||||
|
||||
[settings]
|
||||
screenchange-reload = true
|
||||
;compositing-background = xor
|
||||
;compositing-background = screen
|
||||
;compositing-foreground = source
|
||||
;compositing-border = over
|
||||
;pseudo-transparency = false
|
||||
|
||||
;[global/wm]
|
||||
;margin-top = 5
|
||||
;margin-bottom = 5
|
||||
|
||||
; vim:ft=dosini
|
||||
@@ -0,0 +1,3 @@
|
||||
{% for workspace in workspaces %}
|
||||
{{workspace.w}} {{workspace.x}} {{workspace.y}}
|
||||
{% endfor %}
|
||||
21
leftwm/.config/leftwm/themes/dracula_polybar/template.liquid
Normal file
@@ -0,0 +1,21 @@
|
||||
{% for tag in workspace.tags %}
|
||||
{% if tag.mine %}
|
||||
%{A1:$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}:}
|
||||
%{F#000000}%{B#6e5991} {{tag.name}} %{B-}%{F-}
|
||||
%{A}
|
||||
{% elsif tag.visible %}
|
||||
%{A1:$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}:}
|
||||
%{F#000000}%{B#363949} {{tag.name}} %{B-}%{F-}
|
||||
%{A}
|
||||
{% elsif tag.busy %}
|
||||
%{A1:$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}:}
|
||||
%{F#6e5991} {{tag.name}} %{F-}
|
||||
%{A}
|
||||
{% else %}
|
||||
%{A1:$SCRIPTPATH/change_to_tag {{workspace.index}} {{tag.index}}:}
|
||||
%{F#FFFFFF} {{tag.name}} %{F-}
|
||||
%{A}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
%{c}
|
||||
{{ window_title }}
|
||||
5
leftwm/.config/leftwm/themes/dracula_polybar/theme.toml
Normal file
@@ -0,0 +1,5 @@
|
||||
border_width = 3
|
||||
margin = 5
|
||||
default_border_color = "#222222"
|
||||
floating_border_color = "#005500"
|
||||
focused_border_color = "#6e5991"
|
||||
39
leftwm/.config/leftwm/themes/dracula_polybar/up
Executable file
@@ -0,0 +1,39 @@
|
||||
#!/usr/bin/env bash
|
||||
export SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
|
||||
|
||||
|
||||
#down the last running theme
|
||||
if [ -f "/tmp/leftwm-theme-down" ]; then
|
||||
/tmp/leftwm-theme-down
|
||||
rm /tmp/leftwm-theme-down
|
||||
fi
|
||||
ln -s $SCRIPTPATH/down /tmp/leftwm-theme-down
|
||||
|
||||
|
||||
#boot picom or compton if it exists
|
||||
if [ -x "$(command -v picom)" ]; then
|
||||
picom &> /dev/null &
|
||||
elif [ -x "$(command -v compton)" ]; then
|
||||
compton &> /dev/null &
|
||||
fi
|
||||
|
||||
#set the theme.toml config
|
||||
leftwm-command "LoadTheme $SCRIPTPATH/theme.toml"
|
||||
|
||||
#set background
|
||||
if [ -x "$(command -v feh)" ]; then
|
||||
feh --bg-scale $SCRIPTPATH/background.jpg
|
||||
fi
|
||||
|
||||
|
||||
index=0
|
||||
monitors="$(polybar -m | sed s/:.*//)"
|
||||
leftwm-state -q -n -t $SCRIPTPATH/sizes.liquid | sed -r '/^\s*$/d' | while read -r width x y
|
||||
do
|
||||
let indextemp=index+1
|
||||
monitor=$(sed "$indextemp!d" <<<"$monitors")
|
||||
barname="mainbar$index"
|
||||
monitor=$monitor offset=$x width=$width polybar -c $SCRIPTPATH/polybar.config $barname &> /dev/null &
|
||||
let index=indextemp
|
||||
done
|
||||
|
||||
7
leftwm/.config/leftwm/up
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
xss-lock /home/$USER/.config/script/betterlockscreen.sh &
|
||||
fcitx -d &
|
||||
/usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1 &
|
||||
picom --backend glx &
|
||||
nitrogen --restore &
|
||||