GNU bug report logs - #51809
29.0.50; [PATCH] Support for outline default state in Diff buffers

Previous Next

Package: emacs;

Reported by: Matthias Meulien <orontee <at> gmail.com>

Date: Sat, 13 Nov 2021 13:10:02 UTC

Severity: normal

Tags: fixed, patch

Fixed in version 29.0.50

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


Message #83 received at 51809 <at> debbugs.gnu.org (full text, mbox):

From: Juri Linkov <juri <at> linkov.net>
To: Matthias Meulien <orontee <at> gmail.com>
Cc: 51809 <at> debbugs.gnu.org
Subject: Re: bug#51809: 29.0.50; [PATCH] Support for outline default state
 in Diff buffers
Date: Tue, 28 Dec 2021 20:32:22 +0200
> @@ -353,7 +353,9 @@ outline-mode
> +  (add-hook 'change-major-mode-hook #'outline-show-all nil t)
> +  (add-hook 'hack-local-variables-hook
> +	    #'outline-apply-default-state))
>
> @@ -436,7 +438,9 @@ outline-minor-mode
> +        (add-hook 'hack-local-variables-hook
> +	          #'outline-apply-default-state))

Are you sure about modifying the global value of hack-local-variables-hook
instead of the buffer-local hook with `nil t' at the end?

> Here is a file used to test this feature:
>
> # -*- mode: outline; -*-
> [...]
> # Local Variables:
> # outline-default-state: 2
> # outline-default-state-subtree-visibility: ((match-regexp . "TOHIDE") subtree-has-long-lines subtree-is-long)
> # outline-long-line-threshold: 200
> # outline-line-count-threshold: 100
> # End:

When this feature will be used a lot, even variable names will affect
usability - with longer names usability deteriorates, and 40 characters of
'outline-default-state-subtree-visibility' takes half of the standard window width.
Would it be possible to find a shorter name?

Since it defines the rules, how about 'outline-default-rules'?
It has the same length as 'outline-default-state', so these names
will align nicely:

# Local Variables:
# outline-default-state: 1
# outline-default-rules: ((match-regexp . "ChangeLog"))
# mode: outline-minor
# End:

Also outline-long-line-threshold and outline-line-count-threshold could share
the same prefix, maybe:

# outline-default-long-line: 200
# outline-default-line-count: 100




This bug report was last modified 3 years and 91 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.