From tlikonen@iki.fi Wed Dec 17 01:57:32 2008 Received: (at submit) by emacsbugs.donarmstrong.com; 17 Dec 2008 09:57:32 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=0.0 required=4.0 tests=none autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mBH9vSG0022522 for ; Wed, 17 Dec 2008 01:57:30 -0800 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LCt9k-00010J-9P for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 04:57:28 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LCt9i-0000zW-6V for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 04:57:27 -0500 Received: from [199.232.76.173] (port=48707 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LCt9h-0000zR-NK for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 04:57:25 -0500 Received: from mta-out.inet.fi ([195.156.147.13]:40035 helo=kirsi1.inet.fi) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LCt9g-0000tw-Ao for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 04:57:25 -0500 Received: from mithlond.arda.local (80.220.180.181) by kirsi1.inet.fi (8.5.014) id 48FC5AC9029CAB84 for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 11:57:15 +0200 Received: from dtw by mithlond.arda.local with local (Exim 4.69) (envelope-from ) id 1LCt9W-0000yY-Je for bug-gnu-emacs@gnu.org; Wed, 17 Dec 2008 11:57:14 +0200 To: bug-gnu-emacs@gnu.org Subject: Please add easy key bindings for outline-(minor-)mode From: Teemu Likonen Date: Wed, 17 Dec 2008 11:57:14 +0200 Message-ID: <87hc53i0p1.fsf@iki.fi> User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) --=-=-= This is a "wishlist" bug with an example code to solve the issue. The default key bindings for outline-mode and outline-minor-mode are difficult to remember and slow to use. I think the main reason is that there are way too many different key-bindings to operate with outlining. I suggest that you make keys like M- and M- to act modally so that they open and close one outline level at the time depending on which levels and bodies are currently visible. In addition to that, and to make outline navigating easy, M- and M- could move the cursor to previous and next visible outline header. I'll attach a code that I use. It works as I explained above. The code is partly written by me but it's based on a code on Emacs wiki page: http://www.emacswiki.org/emacs/OutlineMinorMode In the Emacs wiki the original code is titled "Explorer like Key-Bindings" and my modified version is "Variation of Explorer-like bindings". The latter is attached to this message). The code is licensed with the usual Emacs wiki license (see the bottom of the web page): This work is licensed to you under version 2 of the GNU General Public License. Alternatively, you may choose to receive this work under any other license that grants the right to use, copy, modify, and/or distribute the work, as long as that license imposes the restriction that derivative works have to grant the same rights and impose the same restriction. For example, you may choose to receive this work under the GNU Free Documentation License, the CreativeCommons ShareAlike License, the XEmacs manual license, or similar licenses. --=-=-= Content-Type: application/emacs-lisp Content-Disposition: attachment; filename=outline-mode-easy-bindings.el Content-Transfer-Encoding: quoted-printable Content-Description: Outline-mode easy key-bindings ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; outline-mode-easy-bindings.el ;; ;; Store this file as outline-mode-easy-bindings.el somewhere in your ;; load-path and add the following lines to your init file: ;; ;; (add-hook 'outline-mode-hook ;; '(lambda () ;; (require 'outline-mode-easy-bindings))) ;; ;; (add-hook 'outline-minor-mode-hook ;; '(lambda () ;; (require 'outline-mode-easy-bindings))) (defun outline-body-p () (save-excursion (outline-back-to-heading) (outline-end-of-heading) (and (not (eobp)) (progn (forward-char 1) (not (outline-on-heading-p)))))) (defun outline-body-visible-p () (save-excursion (outline-back-to-heading) (outline-end-of-heading) (not (outline-invisible-p)))) (defun outline-subheadings-p () (save-excursion (outline-back-to-heading) (let ((level (funcall outline-level))) (outline-next-heading) (and (not (eobp)) (< level (funcall outline-level)))))) (defun outline-subheadings-visible-p () (interactive) (save-excursion (outline-next-heading) (not (outline-invisible-p)))) (defun outline-do-close () (interactive) (when (outline-on-heading-p) (cond ((and (outline-body-p) (outline-body-visible-p)) (hide-entry) (hide-leaves)) (t (hide-subtree))))) (defun outline-do-open () (interactive) (when (outline-on-heading-p) (cond ((and (outline-subheadings-p) (not (outline-subheadings-visible-p))) (show-children 1)) ((and (not (outline-subheadings-p)) (not (outline-body-visible-p))) (show-subtree)) ((and (outline-body-p) (not (outline-body-visible-p))) (show-entry)) (t (show-subtree))))) (define-key outline-mode-map (kbd "M-") 'outline-do-close) (define-key outline-mode-map (kbd "M-") 'outline-do-open) (define-key outline-mode-map (kbd "M-") 'outline-previous-visible-headi= ng) (define-key outline-mode-map (kbd "M-") 'outline-next-visible-heading) (define-key outline-minor-mode-map (kbd "M-") 'outline-do-close) (define-key outline-minor-mode-map (kbd "M-") 'outline-do-open) (define-key outline-minor-mode-map (kbd "M-") 'outline-previous-visible= -heading) (define-key outline-minor-mode-map (kbd "M-") 'outline-next-visible-h= eading) (provide 'outline-mode-easy-bindings) --=-=-=-- From monnier@IRO.UMontreal.CA Wed Dec 17 08:20:53 2008 Received: (at 1598) by emacsbugs.donarmstrong.com; 17 Dec 2008 16:20:54 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-4.9 required=4.0 tests=FOURLA,HAS_BUG_NUMBER, VALID_BTS_CONTROL autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: from chene.dit.umontreal.ca (chene.dit.umontreal.ca [132.204.246.20]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mBHGKjgR027010; Wed, 17 Dec 2008 08:20:46 -0800 Received: from alfajor.home (vpn-132-204-232-37.acd.umontreal.ca [132.204.232.37]) by chene.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id mBHGKh5t015362; Wed, 17 Dec 2008 11:20:43 -0500 Received: by alfajor.home (Postfix, from userid 20848) id D045E1C4F6; Wed, 17 Dec 2008 11:20:42 -0500 (EST) From: Stefan Monnier To: Teemu Likonen Cc: 1598@debbugs.gnu.org Subject: Re: bug#1598: Please add easy key bindings for outline-(minor-)mode Message-ID: References: <87hc53i0p1.fsf@iki.fi> Date: Wed, 17 Dec 2008 11:20:42 -0500 In-Reply-To: <87hc53i0p1.fsf@iki.fi> (Teemu Likonen's message of "Wed, 17 Dec 2008 11:57:14 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV3170=0 X-CrossAssassin-Score: 2 severity 1598 wishlist thanks > The default key bindings for outline-mode and outline-minor-mode are > difficult to remember and slow to use. I think the main reason is that > there are way too many different key-bindings to operate with outlining. Have you tried org-mode? It's a superset of outline-mode with a magic TAB key to show/hide subparts. Personally I use outline-minor-mode with reveal-mode, so that the hiding/showing is done automatically as I move around the buffer. Since the ESP communication is broken right now, it doesn't always do quite what I want, but I like it. YMMV. So, I agree with you that outline-(minor-)mode's key bindings aren't great. This said, using M-next and such for a minor mode is problematic (can interact with the underlying major mode), so such bindings should at least depend on a user setting. Stefan From tlikonen@iki.fi Wed Dec 17 08:49:17 2008 Received: (at 1598) by emacsbugs.donarmstrong.com; 17 Dec 2008 16:49:17 +0000 X-Spam-Checker-Version: SpamAssassin 3.2.3-bugs.debian.org_2005_01_02 (2007-08-08) on rzlab.ucr.edu X-Spam-Level: X-Spam-Bayes: score:0.5 Bayes not run. spammytokens:Tokens not available. hammytokens:Tokens not available. X-Spam-Status: No, score=-3.0 required=4.0 tests=HAS_BUG_NUMBER autolearn=ham version=3.2.3-bugs.debian.org_2005_01_02 Received: from jenni1.inet.fi (mta-out.inet.fi [195.156.147.13]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mBHGnE0v000864 for <1598@emacsbugs.donarmstrong.com>; Wed, 17 Dec 2008 08:49:15 -0800 Received: from mithlond.arda.local (80.220.180.181) by jenni1.inet.fi (8.5.014) id 48FC59C702A2E89A; Wed, 17 Dec 2008 18:49:11 +0200 Received: from dtw by mithlond.arda.local with local (Exim 4.69) (envelope-from ) id 1LCza7-0001bh-AK; Wed, 17 Dec 2008 18:49:07 +0200 To: Stefan Monnier Cc: 1598@debbugs.gnu.org Subject: Re: bug#1598: Please add easy key bindings for outline-(minor-)mode In-Reply-To: (Stefan Monnier's message of "Wed\, 17 Dec 2008 11\:20\:42 -0500") References: <87hc53i0p1.fsf@iki.fi> From: Teemu Likonen Date: Wed, 17 Dec 2008 18:49:07 +0200 Message-ID: <87fxkmn3wc.fsf@iki.fi> User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Stefan Monnier (2008-12-17 11:20 -0500) wrote: > Have you tried org-mode? It's a superset of outline-mode with a magic > TAB key to show/hide subparts. Oh yes, org-mode is great. I use it when I need outlining with a pure human-language text. But I also need outline-minor-mode with other major modes, usually with AucTex's LaTeX-mode and without quick and easy outline navigation the whole outline is too inconvenient to be really usable. Only a couple of months ago I switched from Vim to Emacs, and since Vim has really easy and convenient outlining features (called folding) it was quite a shock to see Emacs's implementation. Fortunately I managed to fix it and I'm really happy with my solution, but I'd also like to see Emacs improve so this is why I sent this wishlist report. > So, I agree with you that outline-(minor-)mode's key bindings aren't > great. This said, using M-next and such for a minor mode is > problematic (can interact with the underlying major mode), so such > bindings should at least depend on a user setting. I guess you are right that M- may be too intrusive for a minor mode. Perhaps an user option for turning them on (off by default) and two menu entries like "Hide more" and "Show more". Also, outline-mode and outline-minor-mode functions' documentation could advertise these interactive outline-do-close and outline-do-open functions (or whatever they would be called). From debbugs-submit-bounces@debbugs.gnu.org Mon Jul 19 11:04:21 2021 Received: (at 1598) by debbugs.gnu.org; 19 Jul 2021 15:04:21 +0000 Received: from localhost ([127.0.0.1]:59782 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5Uof-0008SW-Ic for submit@debbugs.gnu.org; Mon, 19 Jul 2021 11:04:21 -0400 Received: from quimby.gnus.org ([95.216.78.240]:45984) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5Uoc-0008SC-UW for 1598@debbugs.gnu.org; Mon, 19 Jul 2021 11:04:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=9RtXMSegBObcp5j4j+iLnjoebB0BNzACyxkDoD28xf8=; b=iug0ajSE6h6E96ew0cWyqABQtU Riq8YsEsHK4j7oSk9By9RdH5dkIbhDq+OwyyAjJ8RasdTdgiuE1dVJH16bP/MBAVIvxlw7Akb+m4L mMn+Gy7niHnl7GISSYbSRHcNhbvA4rYxjk1TsRXbh/7SQ2AAB3tnvlTd8LOecCEgH+Uw=; Received: from cm-84.212.220.105.getinternet.no ([84.212.220.105] helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m5UoU-00081r-9f; Mon, 19 Jul 2021 17:04:12 +0200 From: Lars Ingebrigtsen To: Teemu Likonen Subject: Re: bug#1598: Please add easy key bindings for outline-(minor-)mode References: <87hc53i0p1.fsf@iki.fi> X-Now-Playing: Colored Music's _Individual Beauty_: "Heartbeat (Previously Unreleased Version)" Date: Mon, 19 Jul 2021 17:04:09 +0200 In-Reply-To: <87hc53i0p1.fsf@iki.fi> (Teemu Likonen's message of "Wed, 17 Dec 2008 11:57:14 +0200") Message-ID: <87sg0amjkm.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Teemu Likonen writes: > The default key bindings for outline-mode and outline-minor-mode are > difficult to remember and slow to use. I think the main reason is that > there are way too many different key-bindings to opera [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 1598 Cc: 1598@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Teemu Likonen writes: > The default key bindings for outline-mode and outline-minor-mode are > difficult to remember and slow to use. I think the main reason is that > there are way too many different key-bindings to operate with outlining. > > I suggest that you make keys like M- and M- to act modally > so that they open and close one outline level at the time depending on > which levels and bodies are currently visible. In addition to that, and > to make outline navigating easy, M- and M- could move the > cursor to previous and next visible outline header. (I'm going through old bug reports that unfortunately wasn't resolved at the time.) I agree that the outline commands are pretty awkward... but outline minor mode is used in a large number of major modes, and has to be consistent throughout all those modes. So M- can't really be used for this, I think. So I'm closing this bug report. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Mon Jul 19 11:04:25 2021 Received: (at control) by debbugs.gnu.org; 19 Jul 2021 15:04:25 +0000 Received: from localhost ([127.0.0.1]:59785 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5Uoi-0008Sl-SC for submit@debbugs.gnu.org; Mon, 19 Jul 2021 11:04:24 -0400 Received: from quimby.gnus.org ([95.216.78.240]:45998) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5Uoh-0008SL-3x for control@debbugs.gnu.org; Mon, 19 Jul 2021 11:04:23 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=yIReg6XrhOOenVDAJby082Fne2xe4kW6ve7wpUA+qyc=; b=Tg/h0xGWAC11P3pZ84Qc/i60xf BC7AoeTpBN5qVcZigCzPb78EDyVxuhO/dq5WC0EgdzlKoOCSNAHFVGghiihhOMVAdowkjOvGYJDpq 8imgM6Oh8ziFecp2kJmp4gLgXVqkNnpNg17wduho696BK9skx1tgF8OOgUwfUAnUZ0Ss=; Received: from cm-84.212.220.105.getinternet.no ([84.212.220.105] helo=elva) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m5UoZ-00081z-HI for control@debbugs.gnu.org; Mon, 19 Jul 2021 17:04:17 +0200 Date: Mon, 19 Jul 2021 17:04:15 +0200 Message-Id: <87r1fumjkg.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #1598 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: close 1598 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) close 1598 quit From debbugs-submit-bounces@debbugs.gnu.org Mon Jul 19 11:33:36 2021 Received: (at 1598) by debbugs.gnu.org; 19 Jul 2021 15:33:36 +0000 Received: from localhost ([127.0.0.1]:59898 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5VGx-0005Fo-R1 for submit@debbugs.gnu.org; Mon, 19 Jul 2021 11:33:36 -0400 Received: from mout.gmx.net ([212.227.15.19]:50933) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5VGv-0005FY-Ot for 1598@debbugs.gnu.org; Mon, 19 Jul 2021 11:33:34 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1626708806; bh=xJ2Patg2fjQ0j52ddNP+kDeDVlDYKGcTLMaAiblLlKg=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=N/ecJmMMa/yy/2T3OTYsr04iANbIeGo1YgImzaiLzNmawzpU3J1QZcE4zP96mk0Pq rLaxrr5+PwV83jO1pw7dzhmVCl1eVZLD9eWYhvSXGpm9h/j1JOZAcgr1DY4/6M4BOq gppXSYG/6CUrh7aeCIJmwx8190/sOEeaFEL7g2P0= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [92.251.40.31] ([92.251.40.31]) by web-mail.gmx.net (3c-app-mailcom-bs14.server.lan [172.19.170.182]) (via HTTP); Mon, 19 Jul 2021 17:33:26 +0200 MIME-Version: 1.0 Message-ID: From: Christopher Dimech To: Lars Ingebrigtsen Subject: bug#1598: Please add easy key bindings for outline-(minor-)mode Content-Type: text/plain; charset=UTF-8 Date: Mon, 19 Jul 2021 17:33:26 +0200 Importance: normal Sensitivity: Normal In-Reply-To: <87sg0amjkm.fsf@gnus.org> References: <87hc53i0p1.fsf@iki.fi> <87sg0amjkm.fsf@gnus.org> X-UI-Message-Type: mail X-Priority: 3 X-Provags-ID: V03:K1:9y0+piCVYHfYNCfOXmL08pjDj6pvS9DY6r49tpOJuSVoGIYKa4d6hHqldBikzSq8oG/WJ egahYTJu1X0QXw7yg4+VTjgSve1jJOwtXJh6QVf3IZHL6/2dy7WBG0RWhEPR9VeAk5+9fc+U7ope jwGkNzwTOXoU3Vr/ddJ1mIw0iprfJwPLyPJ/62rcLbwLlGogpExDNHk9aVlkNum1e0ZWEs+DuqDM YqdGDgx4Td6JHUM86prnudiVrd4iD46FSCwu8nPlOMq88rKMKRKwUrI1Lv/cKmClXIZo81LPY8lb cM= X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:H30LfDxDX34=:JLOJrCEBsoGk2aC0bO1ss0 pgtRQCYgQN4eoJioUWD6YjfePaBCrLD4xr7tsEVpmuhk8fGF+PYJ9CO8VK4kpLPTwvaKnkQ7I 5kVKLlrgLVgEbKJphtTKM2NZWFei9KVQyEWWqCFkr45L2lUP/ZflniQU45iiIiBq/K0xxe4XY FmQWOSGKILgd5MczUpIBzOGf4NIjVqLLSb2auQoYNB75CImixMnzqZZrZedzC9uckN0oEjlq/ RFgNXAM7OeKZS1eFA7dnzDJd9W2sD3rChCFYfeVjTSOruZ4RNmC3n5S4uyWPXr+mZYPYKV7Y7 yMH7WvnJjTZh0aWtQOG8w99MsfXMo+SFm8T6WkRnnCPJ9flLjYsdilGDwGj23FUVmqfIyhC+c YCm3EfK9j6/9d65rIqwMcGwqxGDDHlmOOV0kXsWdCpenTtIv0WREoEL1ZQ5ZfUczdNq7DkcV1 xPqV31g6wLvumO4YLbWmIOB7EJRKRFONhs4QO6U6JL85dgL5k+0LncpAsFVGpFcZ8Ty7j6G2v xgh50QQSc1LE4WEn0U57FSo0b4W2wk6aeOMfD3jlvseF1bkefTCJ4HgIPZgsXQBQjOfLM81sg 9x6W0Pga9FQvd4xLfE+ddwNd8clJMwe2LxT+qyY/oId1qzglNurWcgYP7fJ/Yg+XXkxkKBUvf cBPIFOd84v5/7YysmrL/szAgB3ApQUFjaYp23wu73HmZNc/ZOa3NvhaTCFyv/qkxeQc6xMa41 W5Ml+l0LLID52Y3Hkf4q8bu40jdVc8tto2rqRu24SoJTCMEx3d8inbCcrTGkNUtp3+1a8WZ+E kzJ3AuIeoRsvzi1uoqqXHizjJHm3Q== Content-Transfer-Encoding: quoted-printable X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 1598 Cc: Teemu Likonen , 1598@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Lars, I have been scrutinising outline-minor-mode for some time now. One thing I found that can help in hiding and exposing parts in the follow= ing function (defun gilgamesh-entry-sweep () "todo" (interactive) (when (not (eq last-command this-command)) (put this-command 'state 0)) (cond ;; ..................................................... ;; show subheadings ((equal 0 (get this-command 'state)) (outline-show-branches) (message "Expose Sub-Headings, Next: Expose Body") (put this-command 'state 2)) ;; ..................................................... ;; show body of heading ((equal 1 (get this-command 'state)) (outline-show-entry) (message "Expose Body, Next: Expose Sub-Headings") (put this-command 'state 1)) ;; ..................................................... ;; show subheadings with bodies ((equal 2 (get this-command 'state)) (outline-show-subtree) (message "Expose Sub-Bodies, Next: hide-subtree") (put this-command 'state 3)) ;; ..................................................... ;; hide subheadings ((equal 3 (get this-command 'state)) (outline-hide-subtree) (message "hide-subtree, Next: show-entry") (put this-command 'state 0)) )) You could try to improve on this (on how best the hiding showing works out= ). Users can then add a keybinding they wish. > Sent: Tuesday, July 20, 2021 at 3:04 AM > From: "Lars Ingebrigtsen" > To: "Teemu Likonen" > Cc: 1598@debbugs.gnu.org > Subject: bug#1598: Please add easy key bindings for outline-(minor-)mode > > Teemu Likonen writes: > > > The default key bindings for outline-mode and outline-minor-mode are > > difficult to remember and slow to use. I think the main reason is that > > there are way too many different key-bindings to operate with outlinin= g. > > > > I suggest that you make keys like M- and M- to act modall= y > > so that they open and close one outline level at the time depending on > > which levels and bodies are currently visible. In addition to that, an= d > > to make outline navigating easy, M- and M- could move the > > cursor to previous and next visible outline header. > > (I'm going through old bug reports that unfortunately wasn't resolved at > the time.) > > I agree that the outline commands are pretty awkward... but outline > minor mode is used in a large number of major modes, and has to be > consistent throughout all those modes. So M- can't really be > used for this, I think. > > So I'm closing this bug report. > > -- > (domestic pets only, the antidote for overdose, milk.) > bloggy blog: http://lars.ingebrigtsen.no > > > > From debbugs-submit-bounces@debbugs.gnu.org Mon Jul 19 11:44:12 2021 Received: (at 1598) by debbugs.gnu.org; 19 Jul 2021 15:44:12 +0000 Received: from localhost ([127.0.0.1]:59964 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5VRD-0005a4-Sk for submit@debbugs.gnu.org; Mon, 19 Jul 2021 11:44:12 -0400 Received: from relay6-d.mail.gandi.net ([217.70.183.198]:53373) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5VRC-0005Zf-Q2 for 1598@debbugs.gnu.org; Mon, 19 Jul 2021 11:44:11 -0400 Received: (Authenticated sender: juri@linkov.net) by relay6-d.mail.gandi.net (Postfix) with ESMTPSA id 65B3AC0006; Mon, 19 Jul 2021 15:44:02 +0000 (UTC) From: Juri Linkov To: Lars Ingebrigtsen Subject: Re: bug#1598: Please add easy key bindings for outline-(minor-)mode Organization: LINKOV.NET References: <87hc53i0p1.fsf@iki.fi> <87sg0amjkm.fsf@gnus.org> Date: Mon, 19 Jul 2021 18:34:11 +0300 In-Reply-To: <87sg0amjkm.fsf@gnus.org> (Lars Ingebrigtsen's message of "Mon, 19 Jul 2021 17:04:09 +0200") Message-ID: <874kcql3m4.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 1598 Cc: Teemu Likonen , 1598@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> The default key bindings for outline-mode and outline-minor-mode are >> difficult to remember and slow to use. I think the main reason is that >> there are way too many different key-bindings to operate with outlining. >> >> I suggest that you make keys like M- and M- to act modally >> so that they open and close one outline level at the time depending on >> which levels and bodies are currently visible. In addition to that, and >> to make outline navigating easy, M- and M- could move the >> cursor to previous and next visible outline header. > > I agree that the outline commands are pretty awkward... but outline > minor mode is used in a large number of major modes, and has to be > consistent throughout all those modes. So M- can't really be > used for this, I think. For personal customization of keys in outline-minor-mode now there is outline-mode-cycle-map. Currently I'm experimenting with using M-, but still these keys conflict with some modes, so M- can't be bound by default. Anyway, here is an example of customization: #+begin_src emacs-lisp (setq-default outline-minor-mode-cycle t outline-minor-mode-highlight t) (let ((map outline-mode-cycle-map) (cmds '(("M-" outline-next-visible-heading) ("M-" outline-previous-visible-heading) ;; ("M-" outline-hide-subtree) ;; ("M-" outline-show-subtree) ))) (dolist (command cmds) (define-key map (kbd (nth 0 command)) `(menu-item "" ,(nth 1 command) ;; Only takes effect if point is on a heading. :filter ,(lambda (cmd) (when (and (outline-on-heading-p) ;; Exclude emacs-lisp-mode: ;; outline-minor-mode-highlight ;; BETTER: ;; (buffer-file-name (current-buffer)) buffer-read-only ) cmd)))))) #+end_src From debbugs-submit-bounces@debbugs.gnu.org Mon Jul 19 11:55:36 2021 Received: (at 1598) by debbugs.gnu.org; 19 Jul 2021 15:55:36 +0000 Received: from localhost ([127.0.0.1]:60015 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5VcG-00086X-JO for submit@debbugs.gnu.org; Mon, 19 Jul 2021 11:55:36 -0400 Received: from mail-wr1-f52.google.com ([209.85.221.52]:41891) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1m5VcE-00086K-OU for 1598@debbugs.gnu.org; Mon, 19 Jul 2021 11:55:35 -0400 Received: by mail-wr1-f52.google.com with SMTP id k4so22629414wrc.8 for <1598@debbugs.gnu.org>; Mon, 19 Jul 2021 08:55:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=tl9byWNDLndF51nT9elpDrZeQ0M32Ydj8W6seQAVhRA=; b=n+xe/a0hBiof01MEOKnuxjNinq2dhLrgtjVFz76AouMhjBXzaV4EHb1bWZ2z+7qwxG mykR+p2KUj8+TcZhpAf0/AVE4tjv6TjrAhSMV98Ft/wN6WuSCgm2iP1GLrv1/jbjA22h wn7DaGl5GVlNNH7y4+e7/6As8UG0Dz/cukcUFXwDcb2pxyQnrO3h//sbFizcgKsCcciq 9kEwPwi1UsDUl4UcAaha9iHKYoW5cm3A9Ywz48/iY8xkn2A1bnMvDKu8MCqvEfNYDD2q r0zXDzwtFZ978fQj2mG7AxXHulS8b1aEogbCENW8WgR5VC922uO29NY0Ge+zMn53B/ez 6YMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=tl9byWNDLndF51nT9elpDrZeQ0M32Ydj8W6seQAVhRA=; b=YkgCmsavA1SoSvg2MTk+6Oc7fEAiwg836w66e685PV89bX5IEfOHkQLqnW490RyrzD ST2uSODCunFmqGxkDsHBnCbrwSdd0sRycITkVbyordAYMxgwkQWtDS+HLqtF56R7CfDr NgdZe7cuYbHduPhjE85HwKuydCd1IOLzxjC3lgFcoAokgnuPKB6vaIUODIEV6bCD2K22 AR/B11WaJiix6kIsTJy82wj5Yqy5IJdNbOzVSpdxy/tV5NWAsN1bxUtruK6r6fAM4lKK cKZKatH0TwT9FAl42F5avEfAolVyTP0L+ho4eqqeJRG9uf5uo/DkrAzIniH7UrAnDzBq 1kbA== X-Gm-Message-State: AOAM530G2zkUFr8Qs9qQS1VF0pGTcPqIVAwyZwc2yK/SxZYCnRpv8twX 75s7NF7J9nW30cN9dmaTc/a0NZppndk= X-Google-Smtp-Source: ABdhPJwDCsyKTmgX6+GbmKfEGwtMr+Zo+bY0o5fRm2mtXzqnz/mzgHChjZrgVTW0gpLI71vgX9AUTw== X-Received: by 2002:a5d:4ccb:: with SMTP id c11mr30112719wrt.331.1626710128506; Mon, 19 Jul 2021 08:55:28 -0700 (PDT) Received: from amdahl30 ([2a01:e0a:20e:d340:2ef0:5dff:fed2:7b49]) by smtp.gmail.com with ESMTPSA id a10sm20317325wrm.12.2021.07.19.08.55.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 19 Jul 2021 08:55:28 -0700 (PDT) From: =?utf-8?Q?K=C3=A9vin_Le_Gouguec?= To: Lars Ingebrigtsen Subject: Re: bug#1598: Please add easy key bindings for outline-(minor-)mode References: <87hc53i0p1.fsf@iki.fi> <87sg0amjkm.fsf@gnus.org> Date: Mon, 19 Jul 2021 17:55:27 +0200 In-Reply-To: <87sg0amjkm.fsf@gnus.org> (Lars Ingebrigtsen's message of "Mon, 19 Jul 2021 17:04:09 +0200") Message-ID: <87im165mds.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 1598 Cc: Teemu Likonen , 1598@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Lars Ingebrigtsen writes: > Teemu Likonen writes: > >> The default key bindings for outline-mode and outline-minor-mode are >> difficult to remember and slow to use. I think the main reason is that >> there are way too many different key-bindings to operate with outlining. >> >> I suggest that you make keys like M- and M- to act modally >> so that they open and close one outline level at the time depending on >> which levels and bodies are currently visible. In addition to that, and >> to make outline navigating easy, M- and M- could move the >> cursor to previous and next visible outline header. > > (I'm going through old bug reports that unfortunately wasn't resolved at > the time.) > > I agree that the outline commands are pretty awkward... but outline > minor mode is used in a large number of major modes, and has to be > consistent throughout all those modes. So M- can't really be > used for this, I think. Also, FWIW, Emacs 28 now makes it possible to use TAB and S-TAB in outline-minor-mode by setting outline-minor-mode-cycle. That doesn't address navigation, but at least it brings outline-minor-mode on par with Org in terms of ergonomy for cycling levels. From unknown Thu Aug 14 21:51:59 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Tue, 17 Aug 2021 11:24:10 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator