fix replacing key in kbd

This commit is contained in:
Almarhoon Ibraheem 2024-06-16 07:44:40 +03:00
parent 73a7053427
commit 479239a806

View file

@ -51,15 +51,11 @@
(else (list translation key))))
(define* (replace-key-symbols key)
(if
(and (equal? #\< (string-ref key 0))
(equal? #\> (string-ref key (- (string-length key) 1))))
(let* ((lkey (keysym-clean (substring key 1 (- (string-length key) 1))))
(let* ((lkey (keysym-clean key))
(translation (hash-get-handle keysym-translations lkey)))
(if (pair? translation)
(cdr translation)
key))
key))
key)))
(define (sway-key key)
(let* ((modifier (replace-modifiers key))