This commit is contained in:
2021-01-27 21:50:40 +01:00
parent d8336fbbae
commit 34f76c13d8
25 changed files with 109 additions and 159 deletions

View File

@@ -207,8 +207,7 @@ with a drive letter and a colon.")
(use-package paren
:defer 0.1
:config
(show-paren-mode t)
)
(show-paren-mode t))
;; emacs warning:
;; ad-handle-definition: `text-scale-increase' got redefined
@@ -231,8 +230,7 @@ with a drive letter and a colon.")
:config
(setq transient-levels-file (concat user-cache-directory "transient/levels.el"))
(setq transient-values-file (concat user-cache-directory "transient/values.el"))
(setq transient-history-file (concat user-cache-directory "transient/history.el"))
)
(setq transient-history-file (concat user-cache-directory "transient/history.el")))
;;
;; keyboard
@@ -306,6 +304,7 @@ with a drive letter and a colon.")
(global-set-key (kbd "M-m j S") 'split-line)
;; navigation/jumping
(global-set-key (kbd "M-m j f") 'find-function)
(global-set-key (kbd "M-m j l") 'find-library)
(global-set-key (kbd "M-m j v") 'find-variable)
;; narrow & widen
(global-set-key (kbd "M-m n r") 'narrow-to-region)
@@ -347,8 +346,7 @@ with a drive letter and a colon.")
(global-set-key (kbd "M-m w s") 'split-window-below)
(with-eval-after-load 'winner-mode
(global-set-key (kbd "M-m w u") 'winner-undo)
(global-set-key (kbd "M-m w U") 'winner-redo)
)
(global-set-key (kbd "M-m w U") 'winner-redo))
(global-set-key (kbd "M-m w v") 'split-window-right)
(global-set-key (kbd "M-m w w") 'other-window)
(global-set-key (kbd "M-m w W") 'ace-window) ;; same as ace-selct-window
@@ -423,14 +421,14 @@ with a drive letter and a colon.")
(global-set-key [mouse-4] (lambda () (interactive) (scroll-down 1)))
(global-set-key [mouse-5] (lambda () (interactive) (scroll-up 1)))
(defun track-mouse (e))
(setq mouse-sel-mode t)
)
(setq mouse-wheel-progressive-speed nil)
;; Turn on horizontal scrolling with mouse wheel
(global-set-key (kbd "<mouse-6>") (lambda () (interactive) (scroll-right 1)))
(global-set-key (kbd "<mouse-7>") (lambda () (interactive) (scroll-left 1)))
(setq mouse-sel-mode t))
(global-set-key (kbd "<mouse-8>") (lambda () (interactive) (previous-buffer)))
(global-set-key (kbd "<mouse-9>") (lambda () (interactive) (next-buffer)))
;;; Scrolling
;;(setq mouse-wheel-scroll-amount '(1)) ; Distance in pixel-resolution to scroll each mouse wheel event.
(setq mouse-wheel-progressive-speed nil) ; Progressive speed is too fast for me.
(setq mouse-wheel-tilt-scroll t) ; Turn on horizontal scrolling with mouse wheel
(setq mouse-wheel-flip-direction t) ; Swap direction of `wheel-right' and `wheel-left'
;; for scroll-all-mode add mouse wheel support
;; https://www.emacswiki.org/emacs/ScrollAllMode
(defun my-mwheel-scroll-all-function (func &optional arg)
@@ -450,19 +448,19 @@ with a drive letter and a colon.")
(setq mwheel-scroll-up-function 'my-mwheel-scroll-all-scroll-up)
(setq mwheel-scroll-down-function 'my-mwheel-scroll-all-scroll-down)
;;; Scrolling.
;; https://www.reddit.com/r/emacs/comments/8sw3r0/finally_scrolling_over_large_images_with_pixel/
;; Good speed and allow scrolling through large images (pixel-scroll).
;; Note: Scroll lags when point must be moved but increasing the number
;; of lines that point moves in pixel-scroll.el ruins large image
;; scrolling. So unfortunately I think we'll just have to live with
;; this.
;;(pixel-scroll-mode) ;; default off
(setq pixel-dead-time 0) ; Never go back to the old scrolling behaviour.
(setq pixel-resolution-fine-flag t) ; Scroll by number of pixels instead of lines (t = frame-char-height pixels).
(setq mouse-wheel-scroll-amount '(1)) ; Distance in pixel-resolution to scroll each mouse wheel event.
(setq mouse-wheel-progressive-speed nil) ; Progressive speed is too fast for me.
(use-package pixel-scroll
:defer t
:config
(setq pixel-dead-time 0) ; Never go back to the old scrolling behaviour.
(setq pixel-resolution-fine-flag t) ; Scroll by number of pixels instead of lines (t = frame-char-height pixels).
;;(pixel-scroll-mode) ;; default off
)
;;
;; Menu