add fez/man-at-point, hl-sexp-mode, exwm multiscreen

This commit is contained in:
opfez 2021-08-15 00:44:51 +02:00
parent 87e774c516
commit 6ddfbead98
3 changed files with 31 additions and 8 deletions

View File

@ -196,6 +196,13 @@
(t (setq current-layout "nous")))
(shell-command (concat "setxkbmap " current-layout)))
(defun fez/man-at-point ()
(interactive)
(let ((word (current-word)))
(if word
(man word)
"Not a word.")))
;; Eshell convinience commands.
(defalias 'open 'find-file-other-window)
(defalias 'clean 'eshell/clear-scrollback)
@ -216,6 +223,8 @@
(global-set-key (kbd "C-c t") 'fez/time-stamp)
(global-set-key (kbd "C-z C-m") 'fez/man-at-point)
;; zap-up-to-char > zap-to-char
(global-set-key (kbd "M-z") 'zap-up-to-char)
@ -229,6 +238,5 @@
(global-set-key [f5] (fez/switch-theme 'magik))
(global-set-key [f6] (fez/switch-theme 'basic))
(add-hook 'emacs-lisp-mode-hook
(lambda () (local-set-key (kbd "C-c k") #'fez/insert-keybind)))

View File

@ -26,9 +26,6 @@
(set-frame-font "monospace 12")
(setq default-frame-alist '((font . "monospace 12")))
;; Highlight current line.
(when window-system (global-hl-line-mode t))
;; Highlight matching parentheses.
(show-paren-mode t)
@ -71,7 +68,11 @@
;; for ncurses development, uncomment this:
;; (setq geiser-guile-binary "/usr/local/bin/guile-ncurses-shell")
(setq geiser-active-implementations '(chez guile))
(setq geiser-active-implementations '(chez))
(add-hook 'scheme-mode-hook 'hl-sexp-mode)
(add-hook 'lisp-mode-hook 'hl-sexp-mode)
(add-hook 'emacs-lisp-mode-hook 'hl-sexp-mode)
;; I use emacs as my window manager.
(exwm-config)

View File

@ -106,9 +106,9 @@
(setq mc/always-run-for-all t))
;; avy - jump around files more easily
(use-package avy
:ensure t
:bind ("M-s" . avy-goto-char))
;; (use-package avy
;; :ensure t
;; :bind ("M-s" . avy-goto-char))
;; Amazing git porcelain.
(use-package magit
@ -202,6 +202,18 @@
(use-package exwm
:init
(defun fez/exwm-init-hook ()
(exwm-workspace-switch-create 1))
(require 'exwm-randr)
(setq exwm-randr-workspace-output-plist '(0 "HDMI-0"))
(add-hook 'exwm-randr-screen-change-hook
(lambda ()
(start-process-shell-command
"xrandr" nil "xrandr --output HDMI-0 --left-of DVI-D-0 --auto")))
(exwm-randr-enable)
(defun exwm-config ()
"EXWM configuration."
;; Set the initial workspace number.
@ -232,6 +244,8 @@
(number-sequence 0 9)))
;; 's-a': Toggle X mouse
([?\s-a] . fez/toggle-x-mouse)
;; 's-<space>': Toggle keyboard layouts
([?\s-\ ] . fez/swap-keyboard)
;; 's-l': Toggle line-mode and char-mode for the current window.
([?\s-l] . exwm-input-toggle-keyboard)
;; windmove movement commands