/writer-mode

A GNU Emacs minor mode for writers.

Primary LanguageEmacs LispGNU General Public License v3.0GPL-3.0

https://travis-ci.org/mssola/writer-mode.svg?branch=master

writer-mode

THIS IS UNDER DEVELOPMENT AND EXPERIMENTAL

This is a simple and convenient minor mode that might be useful for writers.

Usage

TODO: describe workflow, ideas and shortcuts

Configuration

there are some variables and hooks which are not documented here. This will be done whenever I have something releaseable

  • writer-jump-to-first-headline (default: t): it tells writer-jump-to-outline to jump into the closest first level headline. If you want to jump into the closest headline (even if it’s deeper), then set this to nil. You can trust this default unless you are doing really weird things with headlines.
  • writer-forced (default nil): this mode is disruptive, since it will attempt to delete the rest of the windows. By setting this to nil, it will ask the user whether this is really what they want before doing anything at all. If this is set to t, then it will always try to start this mode with the currently selected window and buffer without asking. It’s recommended to set it to t, but since it’s disruptive it doesn’t take this value by default.
  • writer-pre-hook (default nil): hook to be run before setting up the environment. Use this to add some special values before this mode does anything at all (e.g. line-spacing).
  • writer-notes-post-hook (default nil): hook to be run after setting up the the right pane (notes section). Use this to further tune the right section of the workspace (e.g. creating a new window with dired mode in it).

Dependencies

There are two optional dependencies:

  • olivetti: when installed, it will be enabled automatically by this mode.
  • writeroom-mode: when installed, it will be available by calling its related functions (e.g. writer-room).

Contributing

Read the CONTRIBUTING.org file.

Read the CHANGELOG.org file.

Appreciation

Thanks to @frankjonen for working on Emacs for Writers. This mode was developed before he released his code, but out of frustration I abandoned this project before it was finished. I retook the development for this project after he submitted his code, after reconsidering some doubts that I was having. Moreover, I also took some ideas from him (e.g. notes section).

Finally, thank you to all the GNU Emacs developers for providing such a wonderful tool, and its ecosystem for providing useful packages such as olivetti or writeroom-mode. Last but not least, the project structure is heavily influenced by mature projects such as projectile, magit and org mode. Thanks a bunch for doing such a remarkable job!

License

Copyright (C) 2019-2020 Miquel Sabaté Solà <mikisabate@gmail.com>

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.