![]() You might still find the "derived mode" improvement useful, but I suspect trying to make this particular mode 100% global is not going to work very well at all. If write-room mode is a globalized minor mode, then just turn it on in your init file. Whether you need to explicitly load/require the library depends on how you've installed it but as you're using the library already, that's presumably been taken care of, meaning it's then just a case of: (global-writeroom-mode 1)Īlternatively (to all of the above), you could ignore the global mode provided, and create your own alternative global minor mode, as described in How to enable a non-global minor mode by default, on emacs startup?Įdit: Well I've had a bit of a play with writeroom-mode, and it would seem there are very good reasons why its global mode was a bit conservative. All these effects can be disabled or customised. But ‘writeroom-mode’ is meant for distraction-free. entirely on the up and up, since minor modes aren’t supposed to have. (apply 'derived-mode-p writeroom-major-modes)) Because ‘writeroom-mode’ is a minor mode, this isn’t. If `writeroom-major-modes' is nil, activate `writeroom-mode' Vim can reproduce most of the features of WriteRoom, but the only one that prevents me to switch is the 'typewriter scrolling' mode. But since I recently decided to move to Vim (or more specifically, MacVim) Ive tried to reduce my usage of other text editors. This function activates `writeroom-mode' in a buffer if thatīuffer's major mode is a member of `writeroom-major-modes', 3 Ive been using WriteRoom for a while for all my distraction free writing needs. ![]() Not strictly relevant to your question, but perhaps useful if you find the "all modes" approach overkill. That way the default value of '(text-mode) would match not only text-mode, but every mode derived from text-mode. I also changed the existing test to check for a derived mode match, rather than simply an exact match. Unlike the cluttered word processors youre used to, WriteRoom lets you focus on writing. ‘writeroom-mode’ is meant for GNU Emacs 24, lower versions are not: actively supported. The following will redefine the function which makes that decision, so that if the writeroom-major-modes is nil (empty list), it will turn on for any major mode. WriteRoom is a full screen writing environment. ‘writeroom-mode’ is a minor mode for Emacs that implements a: distraction-free writing mode similar to the famous Writeroom editor for: OS X. So now that you've provided a link (albeit in your other question), I can see that the library provides a global minor mode which only turns itself on for a specific configurable set of major modes. Issue Trigger Highlight Text Should Use Terminal Theme or Customized Colors Issue Detached coloured tab is missing uncolouring Issue Support Fraktur ANSI.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |