Function: org-outline-level
org-outline-level is a byte-compiled function defined in org.el.gz.
Signature
(org-outline-level)
Documentation
Compute the outline level of the heading at point.
If this is called at a normal headline, the level is the number
of stars. Use org-reduced-level to remove the effect of
org-odd-levels-only. Unlike org-current-level, this function
takes into consideration inlinetasks.
Source Code
;; Defined in /usr/src/emacs/lisp/org/org.el.gz
(defun org-outline-level ()
"Compute the outline level of the heading at point.
If this is called at a normal headline, the level is the number
of stars. Use `org-reduced-level' to remove the effect of
`org-odd-levels-only'. Unlike `org-current-level', this function
takes into consideration inlinetasks."
(org-with-wide-buffer
(end-of-line)
(if (re-search-backward org-outline-regexp-bol nil t)
(1- (- (match-end 0) (match-beginning 0)))
0)))