diff --git a/init.el b/init.el index b655b25..07ea54c 100644 --- a/init.el +++ b/init.el @@ -73,6 +73,8 @@ (setq custom-file (concat user-emacs-directory "custom.el")) (when (file-exists-p custom-file) (load custom-file)) +;; Performance improvements +(load (concat user-emacs-directory "performance.el")) ;; Writing behavior and packages (load (concat user-emacs-directory "writing.el")) ;; Navigation behavior and packages diff --git a/navigation.el b/navigation.el index df39764..e556161 100644 --- a/navigation.el +++ b/navigation.el @@ -23,7 +23,8 @@ ;;; Code: ;; Smooth scrolling -(setq bidi-paragraph-direction 'left-to-right +(setq bidi-display-reordering 'left-to-right + bidi-paragraph-direction 'left-to-right bidi-inhibit-bpa t bidi-display-reordering nil) diff --git a/performance.el b/performance.el new file mode 100644 index 0000000..4edfba0 --- /dev/null +++ b/performance.el @@ -0,0 +1,29 @@ +;;; performance.el --- Performance tweaks -*- lexical-binding: t -*- + +;; This file is not part of GNU Emacs + +;; This program is free software: you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option) any later version. + +;; This program is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with this program. If not, see . + + +;;; Commentary: + +;; commentary + +;;; Code: + +(setq read-process-output-max (* 4 1024 1024)) + +(provide 'performance) + +;;; performance.el ends here diff --git a/writing.el b/writing.el index 10840ef..4cb8c39 100644 --- a/writing.el +++ b/writing.el @@ -22,6 +22,23 @@ ;;; Code: +;; Save interprogram copies +(setq save-interprogram-paste-before-kill t) + +;; Prevent duplicates in the kill ring +(setq kill-do-not-save-duplicates t) + +;; Save kill ring between sessions +(setq savehist-additional-variables + '(search-ring regexp-search-ring kill-ring)) + +;; Remove text properties from the saved killring +(add-hook 'savehist-save-hook + (lambda () + (setq kill-ring + (mapcar #'substring-no-properties + (cl-remove-if-not #'stringp kill-ring))))) + ;; Save place in file (save-place-mode 1)