Function: eww-open-file

eww-open-file is an autoloaded, interactive and byte-compiled function defined in eww.el.gz.

Signature

(eww-open-file FILE &optional NEW-BUFFER)

Documentation

Render FILE using EWW.

If NEW-BUFFER is non-nil (interactively, the prefix arg), use a new buffer instead of reusing the default EWW buffer.

View in manual

Probably introduced at or before Emacs version 30.1.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/net/eww.el.gz
;;;###autoload (defalias 'browse-web 'eww)

;;;###autoload
(defun eww-open-file (file &optional new-buffer)
  "Render FILE using EWW.
If NEW-BUFFER is non-nil (interactively, the prefix arg), use a
new buffer instead of reusing the default EWW buffer."
  (interactive "fFile: \nP")
  (let ((url-allow-non-local-files t))
    (eww (concat "file://"
                 (and (memq system-type '(windows-nt ms-dos))
		      "/")
                 (expand-file-name file))
         new-buffer)))