emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: pinkanon pinkanon <pinkanon.pinkanon@yandex.ru>
To: Nicolas Goaziou <mail@nicolasgoaziou.fr>
Cc: "emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: Re: org-show-context-detail and tree expansion
Date: Wed, 27 Mar 2019 19:10:02 +0200	[thread overview]
Message-ID: <4481741553706602@iva5-be053096037b.qloud-c.yandex.net> (raw)
In-Reply-To: <87d0mcz8ys.fsf@nicolasgoaziou.fr>

OK, problem found.

The helm code is this:

(defun helm-org-goto-marker (marker)
  (switch-to-buffer (marker-buffer marker))
  (goto-char (marker-position marker))
  (org-show-context)
  (re-search-backward "^\\*+ " nil t)
  (org-show-entry))

So, org-show-entry is called and it results in ellipsis instead of children.

> org-show-entry
> Show the body directly following this heading.
> Show the heading too, if it is currently invisible.

Fair to say, it does what it says.

I will go w/ custom a function which uses org-cycle for now,
though the helm implementation would probably be better off
having some general org-show function which works like org-show-context
(i.e. refers to some list of customizable defaults + takes an argument)
 but for headings. Is there such function?


27.03.2019, 16:29, "Nicolas Goaziou" <mail@nicolasgoaziou.fr>:
> Hello,
>
> pinkanon pinkanon <pinkanon.pinkanon@yandex.ru> writes:
>
>>  Hi! I use helm, which can list all headings using helm-org-in-buffer-headings,
>>  and lets you choose one to jump to.
>>  When I jump to a heading, the tree is expanded.
>>
>>  My problem is as follows.
>>
>>  When I expand this tree on "(2) Downers" (when it is collapsed):
>>
>>  * (1) Uppers
>>  ** (2) Downers
>>     screamers
>>  *** laughers
>>      ...and also a quart of tequila
>>  ** (3) a quart of rum,
>>     a case of Budweiser,
>>  ** (4) a pint of raw ether and two dozen amyls.
>>
>>  I get:
>>
>>  * (1) Uppers
>>  ** (2) Downers
>>     screamers
>>  ...
>>  ** (3) a quart of rum,...
>>  ** (4) a pint of raw ether and two dozen amyls....
>>
>>  Instead of:
>>
>>  * (1) Uppers
>>  ** (2) Downers
>>     screamers
>>  *** laughers...
>>  ** (3) a quart of rum,...
>>  ** (4) a pint of raw ether and two dozen amyls.
>>
>>  I was advised to modify 'org-show-context-detail, as helm uses org-show-context function.
>>  But none of the possible values fixed the behaviour for me.
>>  I used 'canonical for the example above:
>>  (setf (alist-get 'default org-show-context-detail) 'canonical)
>
> You may want to debug `org-show-set-visibility' first. If it gives no
> clue, you may want to report it to Helm.
>
> Regards,
>
> --
> Nicolas Goaziou

      reply	other threads:[~2019-03-27 17:10 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-26 20:01 org-show-context-detail and tree expansion pinkanon pinkanon
2019-03-27 14:29 ` Nicolas Goaziou
2019-03-27 17:10   ` pinkanon pinkanon [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4481741553706602@iva5-be053096037b.qloud-c.yandex.net \
    --to=pinkanon.pinkanon@yandex.ru \
    --cc=emacs-orgmode@gnu.org \
    --cc=mail@nicolasgoaziou.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).