(equal (elpher-page-address elpher-current-page)
(elpher-page-address page)))
(push elpher-current-page elpher-history))
- (setq elpher-current-page page)
+ (setq-local elpher-current-page page)
(let* ((address (elpher-page-address page))
(type (elpher-address-type address))
(type-record (cdr (assoc type elpher-type-map))))
"Evaluate ARGS with a clean *elpher* buffer as current."
`(with-current-buffer elpher-buffer-name
(unless (eq major-mode 'elpher-mode)
+ ;; avoid resetting buffer-local variables
(elpher-mode))
(let ((inhibit-read-only t))
(setq-local network-security-level
(defun elpher-back-to-start ()
"Go all the way back to the start page."
(interactive)
- (setq elpher-current-page nil)
- (setq elpher-history nil)
+ (setq-local elpher-current-page nil)
+ (setq-local elpher-history nil)
(let ((start-page (elpher-make-page "Elpher Start Page"
(elpher-make-special-address 'start))))
(elpher-visit-page start-page)))
(get-buffer-create name)))))
(pop-to-buffer-same-window buf)
(unless (buffer-modified-p)
- (let ((elpher-buffer-name (buffer-name)); for elpher-with-clean-buffer
- (start-page (elpher-make-page "Elpher Start Page"
- (elpher-make-special-address 'start))))
+ (elpher-mode)
+ (let ((start-page (elpher-make-page "Elpher Start Page"
+ (elpher-make-special-address 'start))))
(elpher-visit-page start-page))
- "Started Elpher."))) ; Otherwise (elpher) evaluates to start page string.
+ "Started Elpher."))); Otherwise (elpher) evaluates to start page string.
;;; elpher.el ends here