Closed IceAsteroid closed 1 month ago
@minad The issue of what it's described, is not exactly duplicated with #862
Duplicate #862
Not exactly duplicate though, the implementations are different. Here I just want consult to be able to display the searched heading and also its sub-headings as candidates, nothing else. No nesting "nested parent titles" like "parent1/parent2/the_subheading" etc
Let's be clear, this is actually very useful and intuitive. The operational logic in emacs, especially org-mode combined with consult, is very different from other GUI programs.
By default, headings in org-mode don't show what, and how many sub headings they have when collapsed. This is why I was urged to have a way to solve this
You can see the following pictures, I managed to implement it with a big help by dalanicolai
So when headings are collapsed, I know what headings exactly have sub-headings, and where to expand to take a look.
It barely solves this at least for the navigation in the buffer.
But when an org file is too big, I gotta use consult for quicker navigation across the file.
Now, with consult-org-heading
or consult-oultine
, the operational logic is strongly incomplete and discouraging.
Say if I search for a heading, its sub-headings are no way or configured to be shown as candidates, why?
It's ok if an org file is small, but when getting bigger, this problem is gonna be increasingly annoying.
consult-org-heading
can theoretically do this, but when a heading's title or its parents' titles are getting longer, it's barely unusable, especially in smaller screened devices like a 13-inch laptop, which the heading's title is exceeded and truncated at the edge by its too long parent titles
Is it possible to display the matched heading and plus its sub-headdings as candidates in
consult-outline
?For example:
Say if I search for
Colors
, the minibufer's candidates would be:If heading level is triggerd, say Level 2, the candidates would be:
The reason why not to use
consult-org-heading
instead, is because it displays subheadings preceded by its parent headings.When a subheading is deeply nested, the heading can't be displayed correctly as it's truncated at the edge, except its parent headings are shown.
It would however be:
Edit: In conclusion, if to search a heading would also produce its sub-headings as candidates below it, it'd still be clear of the levels of each heading, with even only asterisks in org, or semi-colons in elisp, etc,