summaryrefslogtreecommitdiffhomepage
path: root/lib
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2022-10-06 20:17:12 +0100
committerjao <jao@gnu.org>2022-10-06 20:17:12 +0100
commitcea86c1d147eeb1630477b76f37a635c94eedd04 (patch)
tree33662c21a0f08c66c1c3d414d6325e7a15d81ea5 /lib
parent24c0d3565d8e7aedc636fbdcf3df93b0c727afcc (diff)
downloadelibs-cea86c1d147eeb1630477b76f37a635c94eedd04.tar.gz
elibs-cea86c1d147eeb1630477b76f37a635c94eedd04.tar.bz2
better matching of existing zathura windows
Diffstat (limited to 'lib')
-rw-r--r--lib/doc/jao-pdf.el3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/doc/jao-pdf.el b/lib/doc/jao-pdf.el
index 5ab3f24..78d5196 100644
--- a/lib/doc/jao-pdf.el
+++ b/lib/doc/jao-pdf.el
@@ -72,6 +72,9 @@
(let ((page (if page (format "-P %s" page) "")))
(format "zathura %s %s %s" file page (or suffix ""))))
+(defun jao-pdf-zathura-title-rx (file)
+ (concat (file-name-nondirectory file) " \\[.+\\]"))
+
;; e.g. "~/org/doc/write-yourself-a-scheme-in-48-hours.pdf [96 (96/138)]"
(defun jao-pdf-zathura-file-info (title)
(when (string-match "\\(.+\\) \\[\\(.+\\) (\\([0-9]+\\)/\\([0-9]+\\))\\]"