mirror of
https://git.sr.ht/~coasteen/dotfiles
synced 2025-11-04 14:47:38 +01:00
updates on eww and qtile
This commit is contained in:
parent
542591eb33
commit
77790da38f
10 changed files with 95 additions and 97 deletions
|
|
@ -1,11 +1,7 @@
|
|||
* {
|
||||
all: unset;
|
||||
background: transparent;
|
||||
font-family: "Ubuntu Mono";
|
||||
}
|
||||
|
||||
window {
|
||||
background: transparent;
|
||||
font-family: "MapleMono";
|
||||
}
|
||||
|
||||
.container {
|
||||
|
|
@ -13,21 +9,43 @@ window {
|
|||
border-width: 1px;
|
||||
border-style: solid;
|
||||
border-color: #454545;
|
||||
color: #aeaeae;
|
||||
color: #ffffff;
|
||||
}
|
||||
|
||||
.label {
|
||||
.button-label {
|
||||
font-size: 24px;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.button-label {
|
||||
.completelytrans {
|
||||
background: none;
|
||||
}
|
||||
.label {
|
||||
font-size: 24px;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
}
|
||||
.calendar-label {
|
||||
font-size: 16px;
|
||||
font-weight: bold;
|
||||
color: #ffffff;
|
||||
}
|
||||
|
||||
.completelytrans {
|
||||
background: none;
|
||||
window, calendar, calendar.view, calendar.header {
|
||||
all: unset;
|
||||
background-color: #000000;
|
||||
color: #cccccc;
|
||||
border: none;
|
||||
box-shadow: none;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
calendar:indeterminate {
|
||||
color: #555555;
|
||||
}
|
||||
|
||||
calendar:selected {
|
||||
background-color: #1e1e1e;
|
||||
border: 1px solid #ffffff;
|
||||
color: #ffffff;
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,41 +1,25 @@
|
|||
(include "eww_widgets.yuck")
|
||||
|
||||
(defwindow calendar
|
||||
:monitor 'HDMI-A-1'
|
||||
:stacking "bg"
|
||||
:geometry (geometry :x "1600" :y "830" :width "320" :height "250" :anchor "top left")
|
||||
(calendar))
|
||||
(defwindow year
|
||||
:monitor 'HDMI-A-1'
|
||||
:stacking "bg"
|
||||
:namespace "eww"
|
||||
:geometry (geometry
|
||||
:x "15"
|
||||
:y "965"
|
||||
:width "100"
|
||||
:height "100"
|
||||
:anchor "top left")
|
||||
(year)
|
||||
)
|
||||
|
||||
:stacking "bg"
|
||||
:geometry (geometry :x "15" :y "745" :width "100" :height "100" :anchor "top left")
|
||||
(year))
|
||||
(defwindow month
|
||||
:monitor 'HDMI-A-1'
|
||||
:stacking "bg"
|
||||
:namespace "eww"
|
||||
:geometry (geometry
|
||||
:x "125"
|
||||
:y "965"
|
||||
:width "100"
|
||||
:height "100"
|
||||
:anchor "top left")
|
||||
(month)
|
||||
)
|
||||
|
||||
:stacking "bg"
|
||||
:geometry (geometry :x "15" :y "855" :width "100" :height "100" :anchor "top left")
|
||||
(month))
|
||||
(defwindow day
|
||||
:monitor 'HDMI-A-1'
|
||||
:stacking "bg"
|
||||
:namespace "eww"
|
||||
:geometry (geometry
|
||||
:x "235"
|
||||
:y "965"
|
||||
:width "100"
|
||||
:height "100"
|
||||
:anchor "top left")
|
||||
(day)
|
||||
)
|
||||
|
||||
:stacking "bg"
|
||||
:geometry (geometry :x "15" :y "965" :width "100" :height "100" :anchor "top left")
|
||||
(day))
|
||||
|
|
|
|||
|
|
@ -2,18 +2,10 @@
|
|||
|
||||
(defwidget day []
|
||||
(box :height "100" :width "100" :halign "center" :valign "center" :class "container"
|
||||
(label :class "label" :text DAY)
|
||||
)
|
||||
)
|
||||
|
||||
(label :class "label" :text DAY)))
|
||||
(defwidget month []
|
||||
(box :height "100" :width "100" :halign "center" :valign "center" :class "container"
|
||||
(label :class "label" :text MONTH)
|
||||
)
|
||||
)
|
||||
|
||||
(label :class "label" :text MONTH)))
|
||||
(defwidget year []
|
||||
(box :height "100" :width "100" :halign "center" :valign "center" :class "container"
|
||||
(label :class "label" :text YEAR)
|
||||
)
|
||||
)
|
||||
(label :class "label" :text YEAR)))
|
||||
|
|
|
|||
2
config/eww/scripts/calendar.sh
Executable file
2
config/eww/scripts/calendar.sh
Executable file
|
|
@ -0,0 +1,2 @@
|
|||
#!/bin/sh
|
||||
cal -m
|
||||
|
|
@ -5,10 +5,10 @@ if [[ $day_of_month -ge 11 && $day_of_month -le 13 ]]; then
|
|||
suffix="th"
|
||||
else
|
||||
case $((day_of_month % 10)) in
|
||||
1) suffix="st" ;;
|
||||
2) suffix="nd" ;;
|
||||
3) suffix="rd" ;;
|
||||
*) suffix="th" ;;
|
||||
1) suffix="ST" ;;
|
||||
2) suffix="ND" ;;
|
||||
3) suffix="RD" ;;
|
||||
*) suffix="TH" ;;
|
||||
esac
|
||||
fi
|
||||
echo "${day_of_month}${suffix}"
|
||||
|
|
|
|||
|
|
@ -1,3 +1,3 @@
|
|||
#!/bin/bash
|
||||
month=$(date +"%b")
|
||||
month=$(date +"%b" | tr '[:lower:]' '[:upper:]')
|
||||
echo "$month"
|
||||
|
|
|
|||
|
|
@ -7,3 +7,4 @@ eww daemon
|
|||
eww open year
|
||||
eww open month
|
||||
eww open day
|
||||
eww open calendar
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
font=UbuntuMono Nerd Font:size=14
|
||||
font=Maple Mono:size=14
|
||||
pad=8x8
|
||||
|
||||
[colors]
|
||||
|
|
|
|||
|
|
@ -4,6 +4,8 @@ from libqtile.lazy import lazy
|
|||
from libqtile.utils import guess_terminal
|
||||
from libqtile.bar import Bar, Gap
|
||||
import subprocess
|
||||
from libqtile.widget.cpu import CPU
|
||||
from libqtile.widget.memory import Memory
|
||||
|
||||
subprocess.run("/home/coast/.local/src/local/bin/start_qtile.sh")
|
||||
|
||||
|
|
@ -33,7 +35,7 @@ keys = [
|
|||
Key([mod], "space", lazy.window.toggle_floating(), desc="Toggle floating on the focused window"),
|
||||
Key([mod, "control"], "r", lazy.reload_config(), desc="Reload the config"),
|
||||
Key([mod, "shift"], "q", lazy.shutdown(), desc="Shutdown Qtile"),
|
||||
Key([mod], "r", lazy.spawn("wmenu-run -f \"Ubuntu Mono Nerd Font 14\" -N #000000 -n #aeaeae -M #aeaeae -S #aeaeae -s #000000"), desc="Spawn a command using wmenu"),
|
||||
Key([mod], "r", lazy.spawn("wmenu-run -f \"Maple Mono 10\" -N #000000 -n #ffffff -M #aeaeae -S #aeaeae -s #000000"), desc="Spawn a command using wmenu"),
|
||||
Key([mod], "Print", lazy.spawn("/home/coast/.local/src/local/bin/screenie-wlr")),
|
||||
Key([mod, "shift"], "Print", lazy.spawn("/usr/bin/grim")),
|
||||
Key([mod], "Left", lazy.window.move_floating(-20, 0)),
|
||||
|
|
@ -73,53 +75,56 @@ for i in groups:
|
|||
)
|
||||
|
||||
layouts = [
|
||||
layout.MonadTall(font = "Ubuntu Mono Nerd Font", margin = 8, border_focus=["#454545"], border_width=4, border_normal=["#1c1c1c"]),
|
||||
layout.MonadTall(font = "Maple Mono", margin = 8, border_focus=["#454545"], border_width=4, border_normal=["#1c1c1c"]),
|
||||
# Try more layouts by unleashing below layouts.
|
||||
# layout.Stack(num_stacks=2),
|
||||
# layout.Bsp(),
|
||||
# layout.Matrix(),
|
||||
layout.MonadWide(font = "Ubuntu Mono Nerd Font", margin = 8, border_focus=["#454545"], border_width=4, border_normal=["#1c1c1c"]),
|
||||
layout.RatioTile(font = "Ubuntu Mono Nerd Font", margin = 8, border_focus=["#454545"], border_width=4, border_normal=["#1c1c1c"]),
|
||||
#layout.MonadWide(font = "Maple Mono", margin = 8, border_focus=["#454545"], border_width=4, border_normal=["#1c1c1c"]),
|
||||
#layout.RatioTile(font = "Maple Mono", margin = 8, border_focus=["#454545"], border_width=4, border_normal=["#1c1c1c"]),
|
||||
# layout.Tile(),
|
||||
# layout.TreeTab(),
|
||||
# layout.VerticalTile(),
|
||||
# layout.Zoomy(),
|
||||
]
|
||||
|
||||
widget_defaults = dict(font="sans", fontsize=14, padding=3)
|
||||
widget_defaults = dict(font="sans", fontsize=20, padding=3)
|
||||
extension_defaults = widget_defaults.copy()
|
||||
|
||||
class CenteredWindowName(widget.WindowName):
|
||||
def draw(self):
|
||||
self.layout.text = self.text
|
||||
text_width, _ = self.layout.size
|
||||
x = (self.bar.width - text_width) / 2
|
||||
y = (self.bar.height - self.layout.height) / 2
|
||||
self.drawer.clear(self.background or self.bar.background)
|
||||
self.layout.draw(int(x), int(y))
|
||||
self.drawer.draw(offsetx=0, width=self.bar.width)
|
||||
|
||||
screens = [
|
||||
Screen(
|
||||
top=bar.Bar(
|
||||
[
|
||||
widget.Prompt(),
|
||||
widget.GroupBox(font="Ubuntu Mono Nerd Font", borderwidth=1, padding=6, rounded=False, highlight_method="line", this_current_screen_border="#1e1e1e", foreground=["#aeaeae"], active=["#aeaeae"], inactive=["#454545"], fontsize=16),
|
||||
widget.TextBox(text = '|', font = "Ubuntu Mono Nerd Font", padding = 2, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.CurrentLayout(font = "Ubuntu Mono Nerd Font", foreground=["#aeaeae"], fontsize=16),
|
||||
widget.TextBox(text = '|', font = "Ubuntu Mono Nerd Font", padding = 2, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.WindowName(font = "Ubuntu Mono Nerd Font", foreground=["#aeaeae"], fontsize=16),
|
||||
widget.Chord(
|
||||
chords_colors={
|
||||
"launch": ("#ff0000", "#aeaeae"),
|
||||
},
|
||||
name_transform=lambda name: name.upper()),
|
||||
# widget.StatusNotifier(),
|
||||
# widget.TextBox(text = '|', font = "Ubuntu Mono Nerd Font", padding = 2,),
|
||||
widget.Clock(format="%I:%M %p", font = "Ubuntu Mono Nerd Font", padding = 2, foreground=["#aeaeae"], fontsize=16) ,
|
||||
widget.QuickExit(font = "Ubuntu Mono Nerd Font", padding = 2, rounded = False, foreground=["#aeaeae"], fontsize=16 ),
|
||||
],
|
||||
28,
|
||||
),
|
||||
),
|
||||
]
|
||||
top=bar.Bar
|
||||
([widget.Spacer(length=3),
|
||||
widget.TextBox(text="", fontsize=16),
|
||||
widget.Spacer(length=3),
|
||||
widget.GroupBox(font='MapleMono', borderwidth=1, padding=6, rounded=False, highlight_method='block', this_current_screen_border='#3a3a3a', foreground='#ffffff', active='#ffffff', inactive='#ffffff', hide_unused=True, fontsize=16),
|
||||
widget.TextBox(text='[', font="Maple Mono", padding=1, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.WindowName(font="Maple Mono", foreground=["#ffffff"], fontsize=16,),
|
||||
widget.TextBox(text=']', font="Maple Mono", padding=1, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.TextBox(text='[', font="Maple Mono", padding=1, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.Memory(foreground="#ffffff", font="MapleMono", fontsize=16, padding=1, mouse_callbacks = {'Button1': lambda: qtile.cmd_spawn(terminal + ' -e htop')}, format = ' {MemPercent}%'),
|
||||
widget.TextBox(text=']', font="Maple Mono", padding=1, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.TextBox(text='[', font="Maple Mono", padding=1, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.CPU(font="MapleMono", fontsize=16, foreground="#ffffff", padding=1, mouse_callbacks = {'Button1': lambda: qtile.cmd_spawn(terminal + ' -e htop')}, format = ' {load_percent}%'),
|
||||
widget.TextBox(text=']', font="Maple Mono", padding=1, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.TextBox(text='[', font="Maple Mono", padding=1, foreground=["#1e1e1e"], fontsize=16),
|
||||
widget.Clock(format=" %I:%M %p", font="Maple Mono", padding=1, foreground=["#ffffff"], fontsize=16, mouse_callbacks={'Button1': lambda: qtile.cmd_spawn('eww open calendar'), 'Button3': lambda: qtile.cmd_spawn('eww close calendar')}),
|
||||
widget.TextBox(text=']', font="Maple Mono", padding=1, foreground=["#1e1e1e"], fontsize=16)],
|
||||
24))]
|
||||
|
||||
mouse = [
|
||||
Drag([mod], "Button1", lazy.window.set_position_floating(), start=lazy.window.get_position()),
|
||||
Drag([mod], "Button3", lazy.window.set_size_floating(), start=lazy.window.get_size()),
|
||||
Click([mod], "Button2", lazy.window.bring_to_front()),
|
||||
]
|
||||
|
||||
Drag([mod], "Button3", lazy.window.set_size_floating(), start=lazy.window.get_size())]
|
||||
dgroups_key_binder = None
|
||||
dgroups_app_rules = []
|
||||
follow_mouse_focus = True
|
||||
|
|
@ -137,18 +142,12 @@ floating_layout = layout.Floating(
|
|||
Match(wm_class="maketag"),
|
||||
Match(wm_class="ssh-askpass"),
|
||||
Match(title="branchdialog"),
|
||||
Match(title="pinentry"),
|
||||
]
|
||||
)
|
||||
Match(title="pinentry")])
|
||||
auto_fullscreen = True
|
||||
focus_on_window_activation = "smart"
|
||||
reconfigure_screens = True
|
||||
|
||||
auto_minimize = True
|
||||
|
||||
wl_input_rules = None
|
||||
|
||||
wl_xcursor_theme = "Adwaita"
|
||||
wl_xcursor_size = 24
|
||||
|
||||
wmname = "LG3D"
|
||||
|
|
|
|||
|
|
@ -2,7 +2,9 @@
|
|||
|
||||
wlr-randr --output eDP-1 --off &
|
||||
|
||||
swaybg -i "/home/coast/.local/src/wall/landscapes/1685467042941515.jpg" &
|
||||
foot -s &
|
||||
|
||||
swaybg -i "/home/coast/.local/src/wall/art/517525ldsdl.jpg" &
|
||||
|
||||
/usr/libexec/polkit-gnome-authentication-agent-1 &
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue