Questions tagged [olivetti-mode]

A simple Emacs minor mode for a nice writing environment, allowing setting text width and margins easily.

A simple Emacs minor mode for a nice writing environment.

Features

  • Set a desired text body width to automatically resize window margins to keep the text comfortably in the middle of the window.

  • Text body width can be the number of characters (an integer), a fraction of the window width (a float between 0.0 and 1.0), or nil which uses the value of fill-column +2.

  • Interactively change body width with:

    • olivetti-shrink C-c { { { ...

    • olivetti-expand C-c } } } ...

    • olivetti-set-width C-c |

  • If olivetti-body-width is an integer, the text body width will scale with use of text-scale-mode, whereas if a fraction (float) then the text body width will remain at that fraction.

  • Change the way the text body margins look with option olivetti-style: use margins, fringes, or both for a fancy "page" look.

  • Customize olivetti-fringe face to affect only Olivetti buffers.

  • Optionally remember the state of visual-line-mode on entry and recall its state on exit.

Olivetti keeps everything it does buffer-local, so you can write prose in one buffer and code in another, side-by-side in the same frame.

[Cribbed from the Commentary section in olivetti.el]

2 questions
3
votes
1 answer

Move the fringe indicators close to the window text

When I use olivetti-mode I'd like to have grey margins and the fringe indicators close to the window text, like in this picture: The problem is that when the fringes are wide the indicators end up being far from the text Is there a way to move…
Arch Stanton
  • 1,525
  • 9
  • 22
1
vote
0 answers

olivetti misbehaving on save, in org buffers

I'm getting this very strange behavior while using olivetti: when calling save-buffer the display goes back to the left margin, as if olivetti has stopped working. If I call olivetti-mode, it shows that it's still enabled, and it stays to the left…