From: Christopher Dimech <dimech@gmx.com>
To: Juri Linkov <juri@linkov.net>
Cc: 48724@debbugs.gnu.org
Subject: bug#48724: Code collapsing and outline headings for elisp
Date: Tue, 1 Jun 2021 13:24:42 +0200 [thread overview]
Message-ID: <trinity-e5a3f933-0d03-4e46-968d-54931397c9ad-1622546682659@3c-app-mailcom-bs01> (raw)
In-Reply-To: <87a6obzxao.fsf@mail.linkov.net>
> Sent: Monday, May 31, 2021 at 10:15 AM
> From: "Juri Linkov" <juri@linkov.net>
> To: "Christopher Dimech" <dimech@gmx.com>
> Cc: 48724@debbugs.gnu.org
> Subject: Re: bug#48724: Code collapsing and outline headings for elisp
>
> > Serious problem is that the two important variables: `outline-regexp' and
> > `outline-heading-alist' are not customizable by using "M-x customize-group".
> >
> > Additionally both of them should be customizable per mode. Don't you think so?
>
> I think that modes should set `outline-regexp' and `outline-heading-alist'
> according to the constructs of their programming language. Then users
> don't need to customize these variables.
>
> > There has been a discussion today about outline-minor-mode settings for fortran
> > (both fixed and free form). Have had a go at using "!" and "!!", but "Hide Body"
> > did not hide the body.
> >
> > There could be some default headings for fortran when outline-minor-mode is enabled.
> > One could follow the current setup for emacs-lisp-mode, for fortran.
> >
> > !! for heading level 1
> > !!! for subheading level 2
> > !!!! for subsubheading level 3
>
> I agree it would be nice to set an appropriate value of `outline-regexp'
> and `outline-heading-alist' for fortran-mode in lisp/progmodes/fortran.el.
I suggest that emacs-lisp-mode does code collapse (show/hide) by default.
Then outline-minor-mode does additional headings in the form
;;; Heading 1
;;;; SubHeading
;;;;; SubSubHeading
;;; Heading 2
outline-minor-mode would then be made to collapse sections of code between
headlines.
This means that a headline hide could hide a number of variable and function
definitions that belong together.
> But the last time I used Fortran was when Fortran had the "C" character
> for comments at the first fixed column on a punched card, and now
> your example uses some new syntax "!" for comments, so sorry, can't help here.
>
> This task would be a nice assignment for the group of students.
Which major modes could be done straight away?
next prev parent reply other threads:[~2021-06-01 11:24 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <trinity-a2e798f1-1257-407e-8dfc-4ad92004a227-1622516668807@3c-app-mailcom-bs01>
[not found] ` <877djegtaq.fsf@protesilaos.com>
[not found] ` <trinity-53de0a34-f881-4ec9-b2e8-901b97d0d76f-1622519072162@3c-app-mailcom-bs01>
[not found] ` <8735u2grnc.fsf@protesilaos.com>
[not found] ` <trinity-fd06ae24-9c88-47ec-8fd1-e93789f670bf-1622551360761@3c-app-mailcom-bs01>
[not found] ` <87bl8pwvdb.fsf@protesilaos.com>
2021-05-28 20:59 ` bug#48724: Code collapsing and outline headings for elisp Christopher Dimech
2021-05-29 21:57 ` Juri Linkov
2021-05-29 23:55 ` Christopher Dimech
2021-05-30 1:38 ` Christopher Dimech
2021-05-30 22:15 ` Juri Linkov
2021-05-30 23:58 ` Christopher Dimech
2021-06-01 11:24 ` Christopher Dimech [this message]
2021-06-01 20:44 ` Juri Linkov
2021-06-02 0:07 ` Christopher Dimech
2021-06-02 20:54 ` Juri Linkov
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.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=trinity-e5a3f933-0d03-4e46-968d-54931397c9ad-1622546682659@3c-app-mailcom-bs01 \
--to=dimech@gmx.com \
--cc=48724@debbugs.gnu.org \
--cc=juri@linkov.net \
/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.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).