diff options
author | Samuel Fadel <samuel@nihil.ws> | 2022-12-08 18:25:18 +0100 |
---|---|---|
committer | Samuel Fadel <samuel@nihil.ws> | 2022-12-08 18:25:18 +0100 |
commit | 6f54084c0ee63f4b341f8f92efbc8b82d3dfa224 (patch) | |
tree | 454e8d7cf51aa4cded69535d60ec56a753325034 /wm.scm | |
parent | 6bdaee03c0fd3caac390dffdaaf52d54653b1430 (diff) |
Working example with keybindings done from Scheme.
* main.scm: Added utility and keybinding calls
* wm.scm: Added necessary bindings to C code
* schewm.c: Some utility functions for grabbing keys
Diffstat (limited to 'wm.scm')
-rw-r--r-- | wm.scm | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -1,7 +1,11 @@ (define-module (wm) #:use-module (system foreign) #:export (wm-init + key-from-str + wm-grab-key-with-mod + wm-grab-key-with-mod-shift wm-set-key-press-handler! + wm-focus-next wm-run wm-quit)) @@ -36,6 +40,17 @@ (define wm-run (schewm-func void "wm_run" '())) +(define wm-grab-key-with-mod + (schewm-func void "wm_grab_key_with_mod" + (list uint32))) + +(define wm-grab-key-with-mod-shift + (schewm-func void "wm_grab_key_with_mod_shift" + (list uint32))) + +(define (wm-focus-next) + '()) + (define c/wm-set-key-press-handler (schewm-func void "wm_set_key_press_handler" |