* imenu predefined structures
@ 2024-08-14 21:19 Heime
2024-08-15 5:28 ` Joel Reicher
0 siblings, 1 reply; 4+ messages in thread
From: Heime @ 2024-08-14 21:19 UTC (permalink / raw)
To: Heime via Users list for the GNU Emacs text editor
Does imenu have predefined search structures when calling imenu
when in some major mode ?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: imenu predefined structures
2024-08-14 21:19 imenu predefined structures Heime
@ 2024-08-15 5:28 ` Joel Reicher
2024-08-15 12:11 ` Heime
0 siblings, 1 reply; 4+ messages in thread
From: Joel Reicher @ 2024-08-15 5:28 UTC (permalink / raw)
To: Heime; +Cc: Heime via Users list for the GNU Emacs text editor
Heime <heimeborgia@protonmail.com> writes:
> Does imenu have predefined search structures when calling imenu
> when in some major mode ?
If you mean does imenu have search functions that it uses to
compile its index, then yes, but if you mean does imenu provide
search functions for a user to use, then no.
Cheers,
- Joel
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: imenu predefined structures
2024-08-15 5:28 ` Joel Reicher
@ 2024-08-15 12:11 ` Heime
2024-08-17 13:45 ` Joel Reicher
0 siblings, 1 reply; 4+ messages in thread
From: Heime @ 2024-08-15 12:11 UTC (permalink / raw)
To: Joel Reicher; +Cc: Heime via Users list for the GNU Emacs text editor
Sent with Proton Mail secure email.
On Thursday, August 15th, 2024 at 5:28 PM, Joel Reicher <joel.reicher@gmail.com> wrote:
> Heime heimeborgia@protonmail.com writes:
>
> > Does imenu have predefined search structures when calling imenu
> > when in some major mode ?
>
>
> If you mean does imenu have search functions that it uses to
> compile its index, then yes, but if you mean does imenu provide
> search functions for a user to use, then no. - Joel
If I do "emacs -Q", load an elisp file and call "M-x imenu", One
gets a list of the functions present in the file. Meaning that
"imenu-generic-expression" is defined for some modes.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: imenu predefined structures
2024-08-15 12:11 ` Heime
@ 2024-08-17 13:45 ` Joel Reicher
0 siblings, 0 replies; 4+ messages in thread
From: Joel Reicher @ 2024-08-17 13:45 UTC (permalink / raw)
To: Heime; +Cc: Heime via Users list for the GNU Emacs text editor
Heime <heimeborgia@protonmail.com> writes:
> On Thursday, August 15th, 2024 at 5:28 PM, Joel Reicher
> <joel.reicher@gmail.com> wrote:
>
>> Heime heimeborgia@protonmail.com writes:
>>
>>> Does imenu have predefined search structures when calling
>>> imenu when in some major mode ?
>>
>> If you mean does imenu have search functions that it uses to
>> compile its index, then yes, but if you mean does imenu provide
>> search functions for a user to use, then no.
>
> If I do "emacs -Q", load an elisp file and call "M-x imenu", One
> gets a list of the functions present in the file. Meaning that
> "imenu-generic-expression" is defined for some modes.
I think you are asking about the logic imenu uses when compiling
its index.
It will call imenu-create-index-function, which can be defined by
the major mode.
In the absence of that definition, the default is
imenu-default-create-index-function. This default function, under
*some* conditions (not all), will use imenu-generic-expression.
Similar to what I said on another thread, the model here is for
imenu to index by calling an abstraction that can be implemented
by a major mode. If the implementation is missing, it's missing.
Cheers,
- Joel
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-08-17 13:45 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-14 21:19 imenu predefined structures Heime
2024-08-15 5:28 ` Joel Reicher
2024-08-15 12:11 ` Heime
2024-08-17 13:45 ` Joel Reicher
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).