diff options
author | noa@gaiwan.org | 2024-06-15 17:19:57 +0000 |
---|---|---|
committer | noa@gaiwan.org | 2024-06-15 17:19:57 +0000 |
commit | aac35cb96c337037a00c3677405c132b9e71e10d (patch) | |
tree | 9b3ee075b9f380eebc78ee74b1159010970300e9 /emacs/init.el | |
parent | ac075b19a32bfc6e592fcacf4c3bef91e0dc8bba (diff) |
Prefer columnar splits over a stack
Diffstat (limited to 'emacs/init.el')
-rw-r--r-- | emacs/init.el | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/emacs/init.el b/emacs/init.el index 76db306..5c6c293 100644 --- a/emacs/init.el +++ b/emacs/init.el @@ -877,6 +877,14 @@ The misspelled word is taken from OVERLAY. WORD is the corrected word." (global-set-key [remap query-replace] 'anzu-query-replace) (global-set-key [remap query-replace-regexp] 'anzu-query-replace-regexp) +;; My computer has a small screen, so i find that it's more beneficial for me to split the frame into columns, so i get more context. However, splitting in this way only gives me a (window-width) of 61, so emacs will always split into vertically stacked windows. By setting this to 80, the first split should always be vertical. +(setopt split-width-threshold 80) + +;; Define a handy function that allows me to do a full text search of every file in my home directory. For the most part, this works well; ripgrep avoids binary files. However, in some files with embedded images, it can add a lot of junk to the output. +(defun noa/consult-rg-home () + (interactive) + (consult-ripgrep "~/")) +(global-set-key (kbd "<f5>") #'noa/consult-rg-home) ;; Switch to new window on creation (defun noa/split-and-follow-horizontally () @@ -928,10 +936,5 @@ The misspelled word is taken from OVERLAY. WORD is the corrected word." (comment-region (mark) (point)) (buffer-substring (mark) (point))) "\n\n")) -;; Define a handy function that allows me to do a full text search of every file in my home directory. For the most part, this works well; ripgrep avoids binary files. However, in some files with embedded images, it can add a lot of junk to the output. -(defun noa/consult-rg-home () - (interactive) - (consult-ripgrep "~/")) -(global-set-key (kbd "<f5>") #'noa/consult-rg-home) (use-package i-ching :ensure t) |