doomemacs/modules/editor/rotate-text
Henrik Lissner 057e6c531c
refactor: replace doom-enlist with ensure-list
doom-enlist is now a deprecated alias for ensure-list, which is built
into Emacs 28.1+ and is its drop-in replacement. We've already
backported it for 27.x users in doom-lib (in 4bf4978).

Ref: 4bf49785fd
2022-08-07 19:43:13 +02:00
..
autoload.el refactor: replace doom-enlist with ensure-list 2022-08-07 19:43:13 +02:00
packages.el Minor refactoring across the board 2021-05-23 22:09:07 -04:00
README.org revert: fix(docs): set mode in file-local vars 2022-08-07 19:08:07 +02:00

:editor rotate-text

Description   unfold

This module adds text rotation to Doom Emacs. I.e. The ability to cycle through keywords or text patterns at point, like true and false, or public, protected, and private (in c++-mode).

Module flags

This module has no flags.

Packages

Hacks

No hacks documented for this module.

TODO Changelog

This module does not have a changelog yet.

Installation

Enable this module in your doom! block.

This module has no external requirements.

TODO Usage

🔨 This module's usage documentation is incomplete. Complete it?

For evil users: [r and ]r will cycle back and forward (respectively) through specified patterns for the text at point. Patterns will wrap around as you cycle through them.

TODO Configuration

🔨 This module's configuration documentation is incomplete. Complete it?

To enable a set of items to cycle through globally:

;; in $DOOMDIR/config.el
(after! rotate-text
  (add-to-list 'rotate-text-words '("small" "medium" "large")))

To add a sequence to a specific mode:

;; in $DOOMDIR/config.el
(set-rotate-patterns! 'c++-mode
    :words '(("float" "double")))

When configuring a sequence of words or symbols that should be rotated through, it is important that all items are all lower case. The casing will be determined by the item that initiated the rotation. For example, Small will be replaced with Medium and SMALL will be replaced with MEDIUM using the example described above.

Troubleshooting

There are no known problems with this module. Report one?

Frequently asked questions

This module has no FAQs yet. Ask one?

Appendix

🔨 This module has no appendix yet. Write one?