From ca8d250bfbe687eff7d8bc18708f6968e719ec65 Mon Sep 17 00:00:00 2001 From: Vasilij Schneidermann Date: Fri, 21 Apr 2023 17:44:21 +0200 Subject: Lift the silly file name limitation for now --- nov.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'nov.el') diff --git a/nov.el b/nov.el index 873136e..73521b3 100644 --- a/nov.el +++ b/nov.el @@ -614,6 +614,8 @@ the HTML is rendered with `nov-render-html-function'." (when (not imagep) (funcall nov-render-html-function)) + ;; NOTE: this is how doc-view avoids overwriting the file + (set-buffer-modified-p nil) (goto-char (point-min))))) (defun nov-find-document (predicate) @@ -860,10 +862,9 @@ Saving is only done if `nov-save-place-file' is set." (setq nov-documents (apply 'vector (nov-content-files work-dir content))) (setq nov-documents-index 0)) (setq buffer-undo-list t) - (setq nov-file-name (buffer-file-name)) + (setq nov-file-name (buffer-file-name)) ; kept for compatibility reasons (setq-local bookmark-make-record-function 'nov-bookmark-make-record) - (set-visited-file-name nil t) ; disable autosaves and save questions (let ((place (nov-saved-place (cdr (assq 'identifier nov-metadata))))) (if place (let ((index (cdr (assq 'index place))) -- cgit v1.2.3