the @kbd{A C} command (@code{gnus-summary-show-complete-article}) will
do so.
+@item w
+@itemx A w
+@kindex w @r{(Summary)}
+@kindex A w @r{(Summary)}
+@cindex web
+@cindex url
+@findex gnus-summary-browse-url
+Scan the article buffer for links, and offer them to the user for
+browsing with @code{browse-url}. By default, only scan the article
+body; with a prefix arg, also scan the article headers.
+
@end table
"s" gnus-summary-isearch-article
"\t" gnus-summary-widget-forward
[backtab] gnus-summary-widget-backward
+ "w" gnus-summary-browse-url
"t" gnus-summary-toggle-header
"g" gnus-summary-show-article
"l" gnus-summary-goto-last-article
"s" gnus-summary-isearch-article
"\t" gnus-summary-widget-forward
[backtab] gnus-summary-widget-backward
+ "w" gnus-summary-browse-url
"P" gnus-summary-print-article
"S" gnus-sticky-article
"M" gnus-mailing-list-insinuate
(goto-char (point-max)))
(widget-backward arg)))
+(defun gnus-summary-browse-url (arg)
+ "Scan the current article body for links, and offer to browse them.
+With prefix ARG, also collect links from message headers.
+
+Links are opened using `browse-url'. If only one link is found,
+browse that directly, otherwise use completion to select a link."
+ (interactive "P")
+ (let (pt urls target)
+ (gnus-summary-select-article)
+ (gnus-configure-windows 'article)
+ (gnus-with-article-buffer
+ (if arg
+ (goto-char (point-min))
+ (article-goto-body)
+ ;; Back up a char, in case body starts with a widget.
+ (backward-char))
+ (setq pt (point))
+ (while (progn (widget-forward 1)
+ ;; `widget-forward' wraps around to top of
+ ;; buffer.
+ (> (point) pt))
+ (setq pt (point))
+ (when-let ((u (or (get-text-property (point) 'shr-url)
+ (get-text-property (point) 'gnus-string))))
+ (when (string-match-p "\\`[[:alpha:]]+://" u)
+ (push u urls))))
+ (setq target
+ (cond ((= (length urls) 1)
+ (car urls))
+ ((> (length urls) 1)
+ (completing-read
+ "URL to browse: "
+ (setq urls (nreverse (delete-dups urls)))
+ nil t))))
+ (if target
+ (browse-url target)
+ (message "No URLs found.")))))
+
(defun gnus-summary-isearch-article (&optional regexp-p)
"Do incremental search forward on the current article.
If REGEXP-P (the prefix) is non-nil, do regexp isearch."