218 lines
7.9 KiB
Fennel
218 lines
7.9 KiB
Fennel
(local awful (require "awful"))
|
|
(local gears (require "gears"))
|
|
(local beautiful (require "beautiful"))
|
|
(local keybindings (require "keybindings"))
|
|
(local xresources (require "beautiful.xresources"))
|
|
(local dpi xresources.apply_dpi)
|
|
|
|
(local rules [
|
|
;; All clients match this rule
|
|
{
|
|
:rule { }
|
|
:propertites {
|
|
:border_width beautiful.border_width
|
|
:border_color beautiful.border_normal
|
|
:focus awful.client.focus.filter
|
|
:raise true
|
|
;; :keys keys
|
|
;; :buttons clientbuttons
|
|
:screen awful.screen.preferred
|
|
:size_hints_honor false
|
|
;; :placement awful.placement.no_overlap
|
|
:shape_clip gears.shape.rounded_rect
|
|
:shape_bounding gears.shape.rounded_rect
|
|
}
|
|
}
|
|
|
|
;; floating and centered videos from mpv or firefox pnp
|
|
{
|
|
:rule_any {
|
|
:class [
|
|
"mpv"
|
|
]
|
|
:name [
|
|
"Picture-in-Picture"
|
|
]
|
|
}
|
|
:properties {
|
|
:floating true
|
|
:raise true
|
|
:height (dpi 800)
|
|
:screen (screen.count)
|
|
:placement (+ awful.placement.no_offscreen awful.placement.centered)
|
|
}
|
|
}
|
|
;; Davinci Resolve is fullscreen
|
|
{
|
|
:rule_any {
|
|
:instance [
|
|
"resolve"
|
|
]
|
|
:class [
|
|
"resolve"
|
|
]
|
|
}
|
|
:properties {
|
|
:floating true
|
|
:fullscreen true
|
|
|
|
}
|
|
}
|
|
{
|
|
:rule_any {
|
|
:name [
|
|
"Secondary Screen"
|
|
]
|
|
}
|
|
:properties {
|
|
:screen 2
|
|
:floating true
|
|
:fullscreen true
|
|
:size_hints_honor false
|
|
}
|
|
}
|
|
;; sxiv floating on main screen for quick picture viewing
|
|
{
|
|
:rule_any {
|
|
:class [
|
|
"sxiv"
|
|
"Sxiv"
|
|
"imv"
|
|
"Imv"
|
|
]
|
|
}
|
|
:properties {
|
|
:floating true
|
|
:raise true
|
|
:height (dpi 800)
|
|
:width (dpi 1200)
|
|
:placement awful.placement.centered
|
|
}
|
|
}
|
|
;; Emacs
|
|
{
|
|
:rule_any {
|
|
:instance [
|
|
"emacs"
|
|
]
|
|
}
|
|
:properties {
|
|
:size_hints_honor false
|
|
}
|
|
}
|
|
;; Org-Agenda
|
|
{
|
|
:rule_any {
|
|
:name [
|
|
"org-agenda"
|
|
]
|
|
:class [
|
|
"org-agenda"
|
|
]
|
|
:instance [
|
|
"org-agenda"
|
|
]
|
|
}
|
|
:properties {
|
|
:floating true
|
|
:raise true
|
|
:sticky true
|
|
:placement (+ awful.placement.no_offscreen awful.placement.centered)
|
|
}
|
|
}
|
|
;; Org Capture
|
|
{
|
|
:rule_any {
|
|
:name [
|
|
"org-capture"
|
|
]
|
|
}
|
|
:properties {
|
|
:floating true
|
|
:raise true
|
|
:screen 1
|
|
:placement (+ awful.placement.no_offscreen awful.placement.centered)
|
|
}
|
|
}
|
|
;; Pulsemixer center and smaller
|
|
{
|
|
:rule_any {
|
|
:instance [
|
|
"pulsemixer"
|
|
]
|
|
}
|
|
:properties {
|
|
:floating true
|
|
:raise true
|
|
:ontop true
|
|
:screen awful.screen.preferred
|
|
;; :width (dpi 600)
|
|
;; :height (dpi 200)
|
|
:placement awful.placement.centered
|
|
}
|
|
}
|
|
;; Tell qb to open primarily on the secondary monitor
|
|
{
|
|
:rule_any {
|
|
:class [
|
|
"qutebrowser"
|
|
"nyxt"
|
|
]
|
|
:instance [
|
|
"nyxt"
|
|
]
|
|
}
|
|
:properties {
|
|
:screen (screen.count)
|
|
:focus awful.client.focus.filter
|
|
:raise true
|
|
}
|
|
}
|
|
;; floating windows
|
|
{
|
|
:rule_any {
|
|
:class [
|
|
"dolphin"
|
|
"feh"
|
|
"Arandr"
|
|
"gcr-prompter"
|
|
"ffplay"
|
|
]
|
|
:name [
|
|
"Event Tester"
|
|
"remove images?"
|
|
"Blender Preferences"
|
|
"Unlock Login Keyring"
|
|
]
|
|
:role [
|
|
"pop-up"
|
|
"GtkFileChooserDialog"
|
|
]}
|
|
:properties {
|
|
:floating true
|
|
:raise true
|
|
:placement awful.placement.centered
|
|
}
|
|
}
|
|
{
|
|
:rule_any {
|
|
:class [
|
|
"fp64"
|
|
]
|
|
:instance [
|
|
"fp64"
|
|
]
|
|
:name [
|
|
"Projection Window"
|
|
]
|
|
}
|
|
:properties {
|
|
:fullscreen true
|
|
:raise true
|
|
:placement (+ awful.placement.no_offscreen awful.placement.centered)
|
|
}
|
|
}
|
|
])
|
|
|
|
rules
|