branch: externals/olivetti
commit 751b90f947f624f688ce4680d77067ad491e8663
Author: Paul Rankin <[email protected]>
Commit: Paul Rankin <[email protected]>
Fixes #3
---
olivetti.el | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/olivetti.el b/olivetti.el
index 1287f57..63159fa 100644
--- a/olivetti.el
+++ b/olivetti.el
@@ -158,7 +158,9 @@ mode line. Finally redraw the frame."
(let* ((n (olivetti-safe-width olivetti-body-width))
(width (cond ((integerp n) n)
((floatp n) (* (window-total-width) n))))
- (margin (round (/ (- (window-total-width) width) 2))))
+ (margin (max (round (/ (- (window-total-width) width)
+ 2))
+ 0)))
(set-window-margins (selected-window) margin margin)))
(defun olivetti-toggle-hide-modeline ()