emacs-orgmode
[Top][All Lists]
Advanced

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

[O] org-cycle hook recenter question


From: Arun Persaud
Subject: [O] org-cycle hook recenter question
Date: Sat, 23 Feb 2013 16:26:10 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130215 Thunderbird/17.0.3

Hi

when I cycle using <shift>-TAB and I go from all->content, that is just
the headlines, I often don't see the top headlines in the buffer,
although there would be enough space to show them. The top is truncated
and a "..." is shown and I need to do a ctrl-l or scroll upward to see
everything.

I was wondering if it would be possible to automatically recenter when
the cycle goes from all->content?

I tried to change the org-cycle-hook to include a line like:

 ((eq state 'content)  (recenter 1))

and I also tried to add a (recenter-top-bottom) in org.el where
org-cycle-global-status is being set to 'contents. But couldn't get it
to work... what's the correct place to do this and is there a reason not
to recenter by default during this cycle operation?

NB: in org-cycle-hook state is tested for 'content, should it be
'contents? org-cycle-hook and org-pre-cycle-hook list both content and
contents and both show up in org.el, but org-cycle-global-state seems to
be only set to 'contents

Arun



reply via email to

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