diff options
Diffstat (limited to 'init.el')
-rw-r--r-- | init.el | 29 |
1 files changed, 12 insertions, 17 deletions
@@ -176,9 +176,10 @@ (jao-bright-show)) ;;;; keyboard -(use-package repeat - :config (setq repeat-echo-function #'repeat-echo-mode-line)) -(when (> emacs-major-version 27) (repeat-mode)) +(when (> emacs-major-version 27) + (use-package repeat + :config (setq repeat-echo-function 'repeat-echo-mode-line)) + (repeat-mode)) (defun jao-kb-toggle (&optional lyt) (interactive) @@ -191,19 +192,10 @@ (not (string-empty-p (shell-command-to-string "setxkbmap -query|grep variant")))) -;; (set-keyboard-coding-system 'latin-1) -;; (set-language-environment "UTF-8") -;; must be set after current-language-environment (customize-set-variable 'default-input-method "catalan-prefix") ;; http://mbork.pl/2022-03-07_Transient_input_method (customize-set-variable 'default-transient-input-method "TeX") -;; (defun jao--set-kb-system (frame) -;; (select-frame frame) -;; (set-keyboard-coding-system 'utf-8) -;; t) -;; (add-to-list 'after-make-frame-functions 'jao--set-kb-system) - (setq echo-keystrokes 1 suggest-key-bindings nil) @@ -435,7 +427,9 @@ (setq jao-frames-default-alpha 88) (jao-set-transparency) (x-change-window-property "_XMONAD_TRAYPAD" "" nil nil nil nil 0) - (xmobar-mode 1) + (if (> emacs-major-version 28) + (xmobar-mode 1) + (jao-xmobar-restart)) (jao-trisect t)) ;;;; xmonad @@ -445,6 +439,7 @@ (defun jao-xmonad-enable () (setq jao-browse-doc-use-emacs-p t) (setq jao-wallpaper-random-wake t) + (display-battery-mode 1) (jao-set-transparency) (jao-trisect) (message "Welcome to xmonad")) @@ -565,16 +560,16 @@ ;;;; xmobar (defun jao-xmobar-kill () (interactive) - (shell-command "killall xmobar-exwm")) + (shell-command "killall xmobar-single")) (defun jao-xmobar-restart () (interactive) (jao-xmobar-kill) - (start-process "" nil "xmobar-exwm" "-d")) + (start-process "" nil "xmobar-single" "-d")) (use-package tab-bar :init (setq tab-bar-close-button-show nil - tab-bar-show t + tab-bar-show (> emacs-major-version 28) tab-bar-format ())) (use-package xmobar @@ -664,7 +659,7 @@ battery-echo-area-format "%L %r %B (%p%% load, remaining time %t)" battery-mode-line-format " 🔋%b%p% ")) -(display-battery-mode 1) + (with-eval-after-load "jao-minibuffer" (unless jao-modeline-in-minibuffer (jao-minibuffer-add-variable 'battery-mode-line-string 80))) |