emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Orgmode] Re: `C-u 2 S-Tab' with `#+STARTUP: odd'


From: Michael Brand
Subject: [Orgmode] Re: `C-u 2 S-Tab' with `#+STARTUP: odd'
Date: Mon, 12 Oct 2009 22:00:33 +0200
User-agent: Thunderbird 2.0.0.23 (Windows/20090812)

I wonder how the function org-outline-level is intended to work. Should it show the outline level or count the stars like in org-version 6.31a and one has to take into account `odd' himself to get the outline level when implementing own stuff which use e. g. the function org-shifttab?

org-outline-level shows the number of stars, independently of org-odd-levels

Use

   (org-reduced-level (org-outline-level))

to get normalized levels.

Inside org, you need to check which function works with what kind
of level, this is unfortunately not entirely abstracted.

HTH

- Carsten

Thank you, exactly what I have missed. Allow me to mention that I would like 
this hint to be added to the Help documentation of org-outline-level where I 
looked before.

There is something more with org-outline-level in org-version 6.31a which I 
still don't understand because I am not aware of some functions used in its 
implementation. I drilled down the quite special situation to the following 
file content. I hope that the indentation of x by three spaces does not get 
lost in the mailing list archive:

-*- eval: (org-mode) -*-
  x

After opening this file and confirming `eval', org-outline-level reports `3' 
(changes when changing the indentation of x) but I expect it to report someting 
like `0', `1000' or `1001' or similar like it does with variations like e. g.

-*- mode: org -*-
  x




reply via email to

[Prev in Thread] Current Thread [Next in Thread]