Hi all, I have a document with lots of inline tasks scattered throughout it. I want to get an overview of the document so I use S-<TAB> to cycle to CONTENTS, when I do that all of the inline tasks are displayed like this: * 1 ** 2 *************** TODO 4 *************** END *************** TODO 5 *************** END *************** TODO 6 *************** END *************** TODO 7 *************** END *************** TODO 8 *************** END ** 3 this makes getting an overview of the document very difficult (it is hard to tell that 2 and 3 are at the same level). By using a numeric prefix that is less than the level of inline tasks but more than the highest level used in the document (for instance M-5 S-<TAB>) I can get the result I would expect: * 1 ** 2... ** 3 Should this be the default? Is this also the behaviour that other people expect? Cheers, Chris Witte.
Hi Christopher, Christopher Witte <chris@witte.net.au> writes: > I have a document with lots of inline tasks scattered throughout it. I > want to get an overview of the document so I use S-<TAB> to cycle to > CONTENTS, when I do that all of the inline tasks are displayed like > this: You can add this hook: (add-hook 'org-cycle-hook (lambda (state) (when (eq state 'contents) (hide-sublevels 6)))) > Should this be the default? Is this also the behaviour that other > people expect? I tend to think this should be the default but I'm not using inline tasks at all, so I'll wait other users' feedback on this. HTH, -- Bastien
On 19 sep. 2012, at 12:34, Bastien <bzg@altern.org> wrote:
> Hi Christopher,
>
> Christopher Witte <chris@witte.net.au> writes:
>
>> I have a document with lots of inline tasks scattered throughout it. I
>> want to get an overview of the document so I use S-<TAB> to cycle to
>> CONTENTS, when I do that all of the inline tasks are displayed like
>> this:
>
> You can add this hook:
>
> (add-hook 'org-cycle-hook
> (lambda (state) (when (eq state 'contents) (hide-sublevels 6))))
>
>> Should this be the default? Is this also the behaviour that other
>> people expect?
>
> I tend to think this should be the default but I'm not using inline
> tasks at all, so I'll wait other users' feedback on this.
I agree that this would be a good default, but not with a hard-coded 6.
(add-hook 'org-cycle-hook
(lambda (state) (when (eq state 'contents)
(and (boundp 'org-inlinetask-min-level)
org-inlinetask-min-level
(hide-sublevels (1- org-inlinetask-min-level))))))
And it is probably better to wrap this into a function and add that function
to the default value of org-cycle-hook, after org-cucle-hide-drawers
- Carsten
Hi Carsten,
Carsten Dominik <carsten.dominik@gmail.com> writes:
> I agree that this would be a good default, but not with a hard-coded 6.
>
> (add-hook 'org-cycle-hook
> (lambda (state) (when (eq state 'contents)
> (and (boundp 'org-inlinetask-min-level)
> org-inlinetask-min-level
> (hide-sublevels (1- org-inlinetask-min-level))))))
>
>
> And it is probably better to wrap this into a function and add that function
> to the default value of org-cycle-hook, after org-cucle-hide-drawers
Done in master. Thanks!
--
Bastien
GReat, thanks!
- Carsten
On 22.9.2012, at 11:02, Bastien wrote:
> Hi Carsten,
>
> Carsten Dominik <carsten.dominik@gmail.com> writes:
>
>> I agree that this would be a good default, but not with a hard-coded 6.
>>
>> (add-hook 'org-cycle-hook
>> (lambda (state) (when (eq state 'contents)
>> (and (boundp 'org-inlinetask-min-level)
>> org-inlinetask-min-level
>> (hide-sublevels (1- org-inlinetask-min-level))))))
>>
>>
>> And it is probably better to wrap this into a function and add that function
>> to the default value of org-cycle-hook, after org-cucle-hide-drawers
>
> Done in master. Thanks!
>
> --
> Bastien
Thanks Carsten and Bastien!
On 22 September 2012 11:03, Carsten Dominik <carsten.dominik@gmail.com> wrote:
> GReat, thanks!
>
> - Carsten
>
> On 22.9.2012, at 11:02, Bastien wrote:
>
>> Hi Carsten,
>>
>> Carsten Dominik <carsten.dominik@gmail.com> writes:
>>
>>> I agree that this would be a good default, but not with a hard-coded 6.
>>>
>>> (add-hook 'org-cycle-hook
>>> (lambda (state) (when (eq state 'contents)
>>> (and (boundp 'org-inlinetask-min-level)
>>> org-inlinetask-min-level
>>> (hide-sublevels (1- org-inlinetask-min-level))))))
>>>
>>>
>>> And it is probably better to wrap this into a function and add that function
>>> to the default value of org-cycle-hook, after org-cucle-hide-drawers
>>
>> Done in master. Thanks!
>>
>> --
>> Bastien
>