Gnus development mailing list
 help / color / mirror / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: Eric S Fraga <e.fraga@ucl.ac.uk>,  ding@gnus.org,  emacs-devel@gnu.org
Subject: Re: gnus-article-view-part no longer seems to work (since commit 041b3904?)
Date: Sun, 07 Feb 2021 11:05:38 -0500	[thread overview]
Message-ID: <jwvtuqn27ds.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <87czxc8528.fsf@gnus.org> (Lars Ingebrigtsen's message of "Sun, 07 Feb 2021 12:56:15 +0100")

>> longer behaves as it used to.  In particular, invoking
>> gnus-article-view-part (typically by hitting "b" but I've tried the
>> other bindings just in case) in the summary buffer does not change the
>> view of the article as it used to (for articles that had, say, text and
>> HTML parts).
>
> This comes from this patch:
>
> commit e1e9e4eefa41bacb6b412e57a569440a0847e4fa
> Author:     Stefan Monnier <monnier@iro.umontreal.ca>
> AuthorDate: Fri Jan 29 23:58:58 2021 -0500
>
>     * lisp/gnus/gnus-art.el: Add `event` args and operate at its position.
>
> In particular, it's this bit:
>
> (defun gnus-article-press-button (&optional event)
>   "Check text at point for a callback function.
> If the text at point has a `gnus-callback' property,
> call it with the value of the `gnus-data' text property."
>   (interactive (list last-nonmenu-event))
>   (save-excursion
>     (mouse-set-point event)
>
> `mouse-set-point' here changes the buffer to the summary buffer.  I'm
> not quite sure what the rationale here is...  and there's no mouse
> involved...
>
> Stefan?

Hmm... indeed in the OP's case the function is not called interactively,
but via some other function (`gnus-article-view-part`) which
changes buffer.  We could change the caller to provide some dummy
`event` but it's easier to just replace the 

    (mouse-set-point event)

with

    (if event (mouse-set-point event))


-- Stefan



  reply	other threads:[~2021-02-09 21:03 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-06 12:13 Eric S Fraga
2021-02-07 11:56 ` Lars Ingebrigtsen
2021-02-07 16:05   ` Stefan Monnier [this message]
2021-02-08  6:12     ` Lars Ingebrigtsen
2021-02-08 11:58       ` Eric S Fraga

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=jwvtuqn27ds.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=ding@gnus.org \
    --cc=e.fraga@ucl.ac.uk \
    --cc=emacs-devel@gnu.org \
    --cc=larsi@gnus.org \
    /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.
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 NNTP newsgroup(s).