[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/olivetti bd672e5 052/134: Make it easier to adjust oliv
From: |
Stefan Monnier |
Subject: |
[elpa] externals/olivetti bd672e5 052/134: Make it easier to adjust olivetti-body-width |
Date: |
Thu, 25 Apr 2019 09:57:27 -0400 (EDT) |
branch: externals/olivetti
commit bd672e512f57962e59ff3d9fd2687e118b56ca54
Author: Lars Tveito <address@hidden>
Commit: Lars Tveito <address@hidden>
Make it easier to adjust olivetti-body-width
When invoking `olivetti-expand` let `[` and `]` be used to make further
adjustments (not unlike `text-scale-mode`).
---
olivetti.el | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/olivetti.el b/olivetti.el
index 809073b..e79f955 100644
--- a/olivetti.el
+++ b/olivetti.el
@@ -253,7 +253,11 @@ If prefixed with ARG, incrementally decrease."
(+ olivetti-body-width (* 0.01 p))))))
(setq olivetti-body-width (olivetti-safe-width n)))
(olivetti-set-environment)
- (message "Text body width set to %s" olivetti-body-width))
+ (message "Text body width set to %s" olivetti-body-width)
+ (set-temporary-overlay-map
+ (let ((map (make-sparse-keymap)))
+ (define-key map "]" 'olivetti-expand)
+ (define-key map "[" 'olivetti-shrink) map)))
(defun olivetti-shrink (&optional arg)
"incrementally decrease the value of `olivetti-body-width'.
- [elpa] externals/olivetti 7b215a7 037/134: Fixes #7, (continued)
- [elpa] externals/olivetti 7b215a7 037/134: Fixes #7, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 41c6642 039/134: Update MELPA URL, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 947b1c0 044/134: Custom option to recall visual-line-mode entry state, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 0653b07 043/134: Make olivetti-set-environment act on the list of all buffer windows, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 42d5822 048/134: Add keymap, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 6a8f400 021/134: Added set-width interactive fun, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 3c60908 023/134: Made set-environment use safe-width, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 4bec5f2 022/134: Added expand/shrink interactive funs, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti bd24fae 027/134: Removed erroneous mode-hook, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 99a8b3d 034/134: Changed email, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti bd672e5 052/134: Make it easier to adjust olivetti-body-width,
Stefan Monnier <=
- [elpa] externals/olivetti be11f32 055/134: Fixing typo, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti bb2e0cf 056/134: set-temporary-overlay-map -> set-transient-map, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 4a6197f 064/134: Merge branch 'master' of https://github.com/rnkn/olivetti, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti e7b7169 063/134: Using page delimiters, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 4095b76 053/134: Merge pull request #10 from larstvei/master, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 7f8e44b 061/134: Custom lighter, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 90cf062 065/134: Added C-c \, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti d0d2bc0 067/134: Attempt to patch known Emacs bugs., Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti 4c2ab02 070/134: Use version<, print patch message, cleanup docs, Stefan Monnier, 2019/04/25
- [elpa] externals/olivetti ee8f064 077/134: Removed 25.1 patch for split-window-right, Stefan Monnier, 2019/04/25