Gnus development mailing list
 help / color / mirror / Atom feed
* gnus-article-view-part no longer seems to work (since commit 041b3904?)
@ 2021-02-06 12:13 Eric S Fraga
  2021-02-07 11:56 ` Lars Ingebrigtsen
  0 siblings, 1 reply; 5+ messages in thread
From: Eric S Fraga @ 2021-02-06 12:13 UTC (permalink / raw)
  To: ding; +Cc: emacs-devel

Dear gnus developers,

I updated my Emacs from git yesterday and reading multi-part emails no
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).

I note that Stefan made some changes this past week, commit 041b3904.

I'm not entirely sure what gnus-article-view-part is now doing as it
seems to move point randomly in my summary buffer.

thank you,
eric

-- 
Eric S Fraga via Emacs 28.0.50 & org 9.4.4 on Debian bullseye/sid



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: gnus-article-view-part no longer seems to work (since commit 041b3904?)
  2021-02-06 12:13 gnus-article-view-part no longer seems to work (since commit 041b3904?) Eric S Fraga
@ 2021-02-07 11:56 ` Lars Ingebrigtsen
  2021-02-07 16:05   ` Stefan Monnier
  0 siblings, 1 reply; 5+ messages in thread
From: Lars Ingebrigtsen @ 2021-02-07 11:56 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: ding, emacs-devel, Stefan Monnier

Eric S Fraga <e.fraga@ucl.ac.uk> writes:

> 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?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: gnus-article-view-part no longer seems to work (since commit 041b3904?)
  2021-02-07 11:56 ` Lars Ingebrigtsen
@ 2021-02-07 16:05   ` Stefan Monnier
  2021-02-08  6:12     ` Lars Ingebrigtsen
  0 siblings, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2021-02-07 16:05 UTC (permalink / raw)
  To: Lars Ingebrigtsen; +Cc: Eric S Fraga, ding, emacs-devel

>> 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



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: gnus-article-view-part no longer seems to work (since commit 041b3904?)
  2021-02-07 16:05   ` Stefan Monnier
@ 2021-02-08  6:12     ` Lars Ingebrigtsen
  2021-02-08 11:58       ` Eric S Fraga
  0 siblings, 1 reply; 5+ messages in thread
From: Lars Ingebrigtsen @ 2021-02-08  6:12 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: Eric S Fraga, ding, emacs-devel

Stefan Monnier <monnier@iro.umontreal.ca> writes:

> 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))

Yup; now done.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: gnus-article-view-part no longer seems to work (since commit 041b3904?)
  2021-02-08  6:12     ` Lars Ingebrigtsen
@ 2021-02-08 11:58       ` Eric S Fraga
  0 siblings, 0 replies; 5+ messages in thread
From: Eric S Fraga @ 2021-02-08 11:58 UTC (permalink / raw)
  To: ding; +Cc: emacs-devel

Thank you.  Working fine now.

-- 
Eric S Fraga via Emacs 28.0.50 & org 9.4.4 on Debian bullseye/sid



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-02-09 21:03 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-06 12:13 gnus-article-view-part no longer seems to work (since commit 041b3904?) Eric S Fraga
2021-02-07 11:56 ` Lars Ingebrigtsen
2021-02-07 16:05   ` Stefan Monnier
2021-02-08  6:12     ` Lars Ingebrigtsen
2021-02-08 11:58       ` Eric S Fraga

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).