unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Michelangelo Rodriguez <michelangelo.rodriguez@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: [elpa] externals/greader 2ac46a52d4: greader-reading-mode: disabling `view-mode' when we are active.
Date: Thu, 21 Sep 2023 09:29:18 -0400	[thread overview]
Message-ID: <jwvil83k6n7.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <20230921124427.69EDDC05819@vcs2.savannah.gnu.org> (ELPA Syncer's message of "Thu, 21 Sep 2023 08:44:24 -0400 (EDT)")

>     This solution, I hope temporary, is necessary because some
>     keys in `greader-reading-mode' and `view-mode' collide, and
>     `view-mode' is loaded before greader.

Hmm... if `view-mode` is loaded first, its in `minor-mode-map-alist`
should come afterwards and so should have lower precedence, no?

>     I don't like this solution, it seems somehow inelegant,
>     but for now it's the only one that comes to mind.

There's indeed a lack of control about relative ordering in (minor)
modes in `minor-mode-map-alist` which occasionally bites us.

You might be able to solve it with:

- (require 'view) to make sure the other entry is there so you can
  change its place if needed.
- Manually rearrange the entries right after `define-minor-mode` at the
  top-level of your file (i.e. when your file is loaded rather than when
  your minor mode is activated).

Another option is to use `minor-mode-overriding-map-alist` (where you'd
put a slightly different modified for `view-mode`), but that
tends to be more invasive.


        Stefan




       reply	other threads:[~2023-09-21 13:29 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <169530026436.5470.1609959274510970863@vcs2.savannah.gnu.org>
     [not found] ` <20230921124427.69EDDC05819@vcs2.savannah.gnu.org>
2023-09-21 13:29   ` Stefan Monnier [this message]
2023-09-21 14:13     ` [elpa] externals/greader 2ac46a52d4: greader-reading-mode: disabling `view-mode' when we are active Stefan Monnier

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=jwvil83k6n7.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=emacs-devel@gnu.org \
    --cc=michelangelo.rodriguez@gmail.com \
    /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).