Variable: browse-url-handlers
browse-url-handlers is a customizable variable defined in
browse-url.el.gz.
Value
nil
Documentation
An alist with elements of the form (REGEXP-OR-PREDICATE . HANDLER).
Each REGEXP-OR-PREDICATE is matched against the URL to be opened in turn and the first match's HANDLER is invoked with the URL.
A HANDLER must be a function with the same arguments as
browse-url.
If no REGEXP-OR-PREDICATE matches, the same procedure is
performed with the value of browse-url-default-handlers. If
there is also no match, the URL is opened using the value of
browse-url-browser-function.
This variable was added, or its default value changed, in Emacs 28.1.
Probably introduced at or before Emacs version 28.1.
Source Code
;; Defined in /usr/src/emacs/lisp/net/browse-url.el.gz
(defcustom browse-url-handlers nil
"An alist with elements of the form (REGEXP-OR-PREDICATE . HANDLER).
Each REGEXP-OR-PREDICATE is matched against the URL to be opened
in turn and the first match's HANDLER is invoked with the URL.
A HANDLER must be a function with the same arguments as
`browse-url'.
If no REGEXP-OR-PREDICATE matches, the same procedure is
performed with the value of `browse-url-default-handlers'. If
there is also no match, the URL is opened using the value of
`browse-url-browser-function'."
:type '(alist :key-type (choice
(regexp :tag "Regexp")
(function :tag "Predicate"))
:value-type (function :tag "Handler"))
:version "28.1")