emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* org-cycle hook recenter question
@ 2013-02-24  0:26 Arun Persaud
  2013-02-24  1:04 ` Samuel Wales
  0 siblings, 1 reply; 12+ messages in thread
From: Arun Persaud @ 2013-02-24  0:26 UTC (permalink / raw)
  To: emacs-orgmode

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

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2013-02-26 22:45 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-24  0:26 org-cycle hook recenter question Arun Persaud
2013-02-24  1:04 ` Samuel Wales
2013-02-24  1:19   ` Arun Persaud
2013-02-24  3:06     ` Suvayu Ali
2013-02-24  3:39       ` Nick Dokos
2013-02-24  4:25       ` Arun Persaud
2013-02-24 13:23         ` Achim Gratz
2013-02-26 15:29   ` Bastien
2013-02-26 17:59     ` Arun Persaud
2013-02-26 18:15     ` Samuel Wales
2013-02-26 22:19       ` Bastien
2013-02-26 22:40         ` Samuel Wales

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).