chore: migrate to unique git repo
This commit is contained in:
17
conf/client/buttons.fnl
Normal file
17
conf/client/buttons.fnl
Normal file
@@ -0,0 +1,17 @@
|
||||
;;; buttons.fnl --- Client buttons
|
||||
|
||||
;;; Code:
|
||||
|
||||
(var buttons {})
|
||||
|
||||
(local awful (require :awful))
|
||||
(local gears (require :gears))
|
||||
|
||||
(local button (. (require :lib.keys) :button))
|
||||
|
||||
(gears.table.join
|
||||
(button [] 1 (lambda [c] (set client.focus c) (: c :raise)))
|
||||
(button [:mod] 1 awful.mouse.client.move)
|
||||
(button [:mod] 3 awful.mouse.client.resize))
|
||||
|
||||
;;; buttons.fnl ends here
|
45
conf/client/keys.fnl
Normal file
45
conf/client/keys.fnl
Normal file
@@ -0,0 +1,45 @@
|
||||
;;; conf/client/keys.fnl --- Client keys
|
||||
|
||||
;;; Code:
|
||||
|
||||
(var keys {})
|
||||
|
||||
(local awful (require :awful))
|
||||
(local beautiful (require :beautiful))
|
||||
(local gears (require :gears))
|
||||
|
||||
(local key (. (require :lib.keys) :key))
|
||||
|
||||
;;;
|
||||
;; Functions
|
||||
|
||||
(fn register [field ...]
|
||||
(tset keys field (gears.table.join ...)))
|
||||
|
||||
(fn cinv [k]
|
||||
(fn [c]
|
||||
(let [v (. c k)]
|
||||
(tset c k (not v)))))
|
||||
|
||||
;;;
|
||||
;; Configuration
|
||||
|
||||
(register :client
|
||||
(key [:mod] :q (lambda [c] (: c :kill)))
|
||||
(key [:mod] :w (lambda [c] (set c.minimized true)))
|
||||
|
||||
(key [:mod] :t (lambda [c] (awful.titlebar.toggle c beautiful.titlebar_position)))
|
||||
(key [:mod :shift] :t (lambda [c] (awful.titlebar.toggle c :left)))
|
||||
(key [:mod :ctrl] :t (lambda [c] (awful.titlebar.toggle c)))
|
||||
|
||||
(key [:mod] :a (cinv :floating))
|
||||
(key [:mod] :f (cinv :fullscreen))
|
||||
(key [:mod] :m (cinv :maximized)) ;; FIXME behaves weird
|
||||
(key [:mod] :s (cinv :sticky)))
|
||||
|
||||
(register :floating
|
||||
(. keys :client)
|
||||
(key [:alt :shift] :h (lambda [c] (: c :relative_move {:x -100}))))
|
||||
|
||||
keys
|
||||
;;; conf/client/keys.fnl ends here
|
51
conf/client/rules.fnl
Normal file
51
conf/client/rules.fnl
Normal file
@@ -0,0 +1,51 @@
|
||||
;;; conf/client/rules.fnl --- Client placement rules
|
||||
|
||||
;;; Code:
|
||||
|
||||
(local awful (require :awful))
|
||||
(local beautiful (require :beautiful))
|
||||
|
||||
(local keys (require :conf.client.keys))
|
||||
(local buttons (require :conf.client.buttons))
|
||||
|
||||
;;;
|
||||
;; Functions
|
||||
|
||||
(local
|
||||
rules
|
||||
[{:rule {}
|
||||
:properties {:border_width beautiful.border_width
|
||||
:border_color beautiful.border_normal
|
||||
:focus true
|
||||
:keys (. keys :client)
|
||||
:buttons buttons
|
||||
:placement (+ awful.placement.no_overlap
|
||||
awful.placement.no_offscreen)}}
|
||||
|
||||
{:rule {:floating true}
|
||||
:properties {:keys (. keys :floating)}}
|
||||
|
||||
;; Floating clients.
|
||||
{:rule_any {:class ["Gpick"]
|
||||
:name ["Event Tester"] ;; xev
|
||||
:role ["pop-up"
|
||||
"xfce4-terminal-dropdown"]}
|
||||
:properties {:floating true}}
|
||||
|
||||
;; Add titlebars to normal clients and dialogs.
|
||||
{:rule_any {:type ["normal" "dialog"]}
|
||||
:properties {:titlebars_enabled true}}
|
||||
|
||||
;; Awesome reserves space for tint2, but doesn't actually fucking place it.
|
||||
{:rule {:class "Tint2"}
|
||||
:properties {:x 0 :y 0}}
|
||||
|
||||
;; Set Firefox to always map on the tag named "2" on screen 1.
|
||||
;; {:rule {:class "Firefox"}
|
||||
;; :properties {:screen 1 :tag "2"}}
|
||||
])
|
||||
|
||||
(tset awful.rules :rules rules)
|
||||
|
||||
{}
|
||||
;;; conf/client/rules.fnl ends here
|
Reference in New Issue
Block a user