File: org-num.el.html
This library provides dynamic numbering for Org headlines. Use
<M-x org-num-mode>
to toggle it.
You can select what is numbered according to level, tags, COMMENT
keyword, or UNNUMBERED property. You can also skip footnotes
sections. See org-num-max-level, org-num-skip-tags,
org-num-skip-commented, org-num-skip-unnumbered, and
org-num-skip-footnotes for details.
You can also control how the numbering is displayed by setting
org-num-face and org-num-format-function.
Internally, the library handles an ordered list, per buffer
position, of overlays in org-num--overlays. These overlays are
marked with the org-num property set to a non-nil value.
Overlays store the level of the headline in the level property,
and the face used for the numbering in numbering-face.
The skip property is set to t when the corresponding headline has
some characteristic -- e.g., a node property, or a tag -- that
prevents it from being numbered.
An overlay with org-num property set to invalid is called an
invalid overlay. Modified overlays automatically become invalid
and set org-num--invalid-flag to a non-nil value. After
a change, org-num--invalid-flag indicates numbering needs to be
updated and invalid overlays indicate where the buffer needs to be
parsed. So does org-num--missing-overlay variable. See
org-num--verify function for details.
Numbering display is done through the after-string property.
Defined variables (15)
org-num--comment-re | Regexp matching a COMMENT keyword at headline beginning. |
org-num--invalid-flag | Non-nil means an overlay became invalid since last update. |
org-num--missing-overlay | Buffer position signaling a headline without an overlay. |
org-num--numbering | Current headline numbering. |
org-num--overlays | Ordered list of overlays used for numbering outlines. |
org-num--skip-level | Level below which headlines from current tree are not numbered. |
org-num-face | Face to use for numbering. |
org-num-format-function | Function used to display numbering. |
org-num-max-level | Level below which headlines are not numbered. |
org-num-mode | Non-nil if Org-Num mode is enabled. |
org-num-mode-hook | Hook run after entering or leaving ‘org-num-mode’. |
org-num-skip-commented | Non-nil means commented sub-trees are not numbered. |
org-num-skip-footnotes | Non-nil means footnotes sections are not numbered. |
org-num-skip-tags | List of tags preventing the numbering of sub-trees. |
org-num-skip-unnumbered | Non-nil means numbering obeys to UNNUMBERED property. |
Defined functions (14)
org-num--clear | () |
org-num--current-numbering | (LEVEL SKIP) |
org-num--headline-regexp | () |
org-num--invalidate-overlay | (O) |
org-num--make-overlay | (NUMBERING LEVEL SKIP) |
org-num--number-region | (START END) |
org-num--overlay-p | (O) |
org-num--refresh-display | (OVERLAY NUMBERING) |
org-num--skip-value | () |
org-num--update | () |
org-num--valid-overlay-p | (O) |
org-num--verify | (BEG END _) |
org-num-default-format | (NUMBERING) |
org-num-mode | (&optional ARG) |