Skip to content

Commit 8dd1e56

Browse files
committed
Fix README
Minor readability fixes and clarification of #45
1 parent 89e25b8 commit 8dd1e56

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

README.org

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ Alternatively, git clone this repository and point Emacs to it using the ~:load-
2929

3030
** Usage
3131

32-
The package can be enabled interactively or automatically on org-mode start-up:
32+
The package can be enabled interactively or automatically on Org mode start-up:
3333

3434
#+begin_src emacs-lisp
3535

@@ -43,21 +43,28 @@ By default, toggling is instantaneous and only emphasis markers are toggled. The
4343
- org-appear-autosubmarkers :: if non-nil, toggle subscripts and superscripts
4444
- org-appear-autoentities :: if non-nil, toggle Org entitites
4545
- org-appear-autokeywords :: if non-nil, toggle keywords in ~org-hidden-keywords~
46-
- org-appear-inside-latex :: if non-nil, also toggle entities and subscripts / superscripts in Latex fragments
46+
- org-appear-inside-latex :: if non-nil, toggle entities and sub/superscripts in LaTeX fragments
4747
- org-appear-delay :: seconds of delay before toggling
4848
- org-appear-trigger :: when to toggle elements
4949

5050
If Org mode custom variables that control visibility of elements are configured to show hidden parts, the respective ~org-appear~ settings do not have an effect.
5151

5252
~org-appear-trigger~ can be set to ~always~, ~on-change~, or ~manual~. With ~on-change~, elements will be toggled only when the buffer is modified or on mouse click. This option disables delayed toggling. With ~manual~, toggling must be enabled by calling ~org-appear-manual-start~. ~org-appear-manual-stop~ is used to disable toggling with this option.
5353

54-
The ~manual~ option is useful for, e.g., integrating ~org-appear~ with ~evil-mode~. Below is an example configuration for toggling elements in Insert mode only.
54+
The ~manual~ option is useful for, e.g., integrating ~org-appear~ with ~evil-mode~. Below is an example configuration for toggling elements in Insert mode only. Note that ~org-appear~ expects to be enabled in Org mode buffers only, which is why the example attaches ~evil-mode~ hooks to the Org mode startup hook.
5555

5656
#+begin_src emacs-lisp
5757

5858
(setq org-appear-trigger 'manual)
59-
(add-hook 'evil-insert-state-entry-hook #'org-appear-manual-start nil t)
60-
(add-hook 'evil-insert-state-exit-hook #'org-appear-manual-stop nil t)
59+
(add-hook 'org-mode-hook (lambda ()
60+
(add-hook 'evil-insert-state-entry-hook
61+
#'org-appear-manual-start
62+
nil
63+
t)
64+
(add-hook 'evil-insert-state-exit-hook
65+
#'org-appear-manual-stop
66+
nil
67+
t)))
6168

6269
#+end_src
6370

0 commit comments

Comments
 (0)