[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master a39ab2e 15/26: Minor tweaks
From: |
João Távora |
Subject: |
[elpa] master a39ab2e 15/26: Minor tweaks |
Date: |
Fri, 19 Dec 2014 19:07:28 +0000 |
branch: master
commit a39ab2e02691e3d6f43c0d1e5133e14eab24e8e2
Author: João Távora <address@hidden>
Commit: João Távora <address@hidden>
Minor tweaks
* darkroom.el: Rewrite "Commentary" section
(darkroom-margins): Don't mention `darkroom--set-margins'.
(darkroom-guess-margins): Use `truncate', not `round'
---
darkroom.el | 25 ++++++++++++-------------
1 files changed, 12 insertions(+), 13 deletions(-)
diff --git a/darkroom.el b/darkroom.el
index 7d707f7..2c08440 100644
--- a/darkroom.el
+++ b/darkroom.el
@@ -22,21 +22,21 @@
;;; Commentary:
-;; The main entrypoints to this extension are two minor modes
+;; The main entrypoints to this extension are two minor modes:
;;
;; M-x darkroom-mode
;; M-x darkroom-tentative-mode
;;
-;; The first makes current buffer to enter `darkroom-mode'
-;; immediately: keeping the window configuration untouched, text is
-;; enlarged, centered on the window with margins, and the modeline is
-;; elided.
+;; `darkroom-mode' makes visual distractions disappear: the
+;; mode-line is temporarily elided, text is enlarged and margins are
+;; adjusted so that it's centered on the window.
;;
-;; The second, `darkroom-tentative-mode', makes the current buffer
-;; turn on `darkroom-mode' whenever all other windows are deleted,
-;; i.e. the buffer is solo on the current Emacs frame. Whenever the
-;; window is split to display some other buffer, the original buffer's
-;; configuration is reset.
+;; `darkroom-tentative-mode' is similar, but it doesn't immediately
+;; turn-on `darkroom-mode', unless the current buffer lives in the
+;; sole window of the Emacs frame (i.e. all other windows are
+;; deleted). Whenever the frame is split to display more windows and
+;; more buffers, the buffer exits `darkroom-mode'. Whenever they are
+;; deleted, the buffer re-enters `darkroom-mode'.
;;
;; Personally, I always use `darkroom-tentative-mode'.
;;
@@ -64,8 +64,7 @@ Its value can be:
- a function of no arguments that returns a cons cell interpreted
like the previous option.
-Value is effective when `darkroom-mode' is toggled, when
-changing window or by calling `darkroom--set-margins'"
+Value is effective when `darkroom-mode' is toggled."
:type 'float
:group 'darkroom)
@@ -130,7 +129,7 @@ margins should center it on the window, otherwise, margins
of
(visual-line-mode 1))
0.15)
((> top-quartile-avg (* 0.9 fill-column))
- (let ((margin (round (/ (- window-width top-quartile-avg) 2))))
+ (let ((margin (truncate (/ (- window-width top-quartile-avg) 2))))
(cons margin margin)))
(t
0.15)))))
- [elpa] master 21a7919 04/26: first commit, (continued)
- [elpa] master 21a7919 04/26: first commit, João Távora, 2014/12/19
- [elpa] master 4dc83ad 05/26: darkroom-mode added, João Távora, 2014/12/19
- [elpa] master c6e0c3a 07/26: Leave darkroom-mode when leaving tentative-mode, João Távora, 2014/12/19
- [elpa] master 744d72a 08/26: Add .gitignore, João Távora, 2014/12/19
- [elpa] master 9cd8dfd 06/26: Now works with multiple windows for same darkroom buffer, João Távora, 2014/12/19
- [elpa] master 786b5a3 10/26: Integrate another comment from Rasmus, João Távora, 2014/12/19
- [elpa] master 6cbfebe 09/26: Integrate some comments from Rasmus, João Távora, 2014/12/19
- [elpa] master b36123e 11/26: Tidy up margin calculation, João Távora, 2014/12/19
- [elpa] master a16a665 01/26: Initial commit, João Távora, 2014/12/19
- [elpa] master 3a1db96 13/26: Add some docstrings, João Távora, 2014/12/19
- [elpa] master a39ab2e 15/26: Minor tweaks,
João Távora <=
- [elpa] master 90f5299 14/26: Prefix internal symbols with "darkroom--", João Távora, 2014/12/19
- [elpa] master 8b0daf6 12/26: Add (still non-functioning) `darkroom-compute-margins', João Távora, 2014/12/19
- [elpa] master 13717fb 17/26: Attempt a clearer design of modes, João Távora, 2014/12/19
- [elpa] master 20d5539 21/26: load cl-lib, João Távora, 2014/12/19
- [elpa] master 4bf9c10 19/26: Fix `darkroom-tentative-mode', João Távora, 2014/12/19
- [elpa] master 1e68955 16/26: Corrections after another review iteration with Rasmus, João Távora, 2014/12/19
- [elpa] master 15e976b 22/26: Merge pull request #1 from syohex/require-cl-lib, João Távora, 2014/12/19
- [elpa] master 9674d79 20/26: Fix automatic margin calculation, João Távora, 2014/12/19
- [elpa] master 2887b5e 18/26: Redesign setting of margins, which now works per-window, João Távora, 2014/12/19
- [elpa] master 96e61a9 26/26: Add packages/darkroom by merging its upstream subtree, João Távora, 2014/12/19