pdf-macs.el (1678B)
1 ;;; pdf-macs.el --- Macros for pdf-tools. -*- lexical-binding:t -*- 2 3 ;; Copyright (C) 2013 Andreas Politz 4 5 ;; Author: Andreas Politz <politza@fh-trier.de> 6 ;; Keywords: files, doc-view, pdf 7 8 ;; This program is free software; you can redistribute it and/or modify 9 ;; it under the terms of the GNU General Public License as published by 10 ;; the Free Software Foundation, either version 3 of the License, or 11 ;; (at your option) any later version. 12 13 ;; This program is distributed in the hope that it will be useful, 14 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of 15 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 ;; GNU General Public License for more details. 17 18 ;; You should have received a copy of the GNU General Public License 19 ;; along with this program. If not, see <http://www.gnu.org/licenses/>. 20 21 ;;; Commentary: 22 ;; 23 ;;; Code: 24 ;; 25 26 (defmacro pdf-view-current-page (&optional window) 27 ;;TODO: write documentation! 28 `(image-mode-window-get 'page ,window)) 29 30 (defmacro pdf-view-current-overlay (&optional window) 31 ;;TODO: write documentation! 32 `(image-mode-window-get 'overlay ,window)) 33 34 (defmacro pdf-view-current-image (&optional window) 35 ;;TODO: write documentation! 36 `(image-mode-window-get 'image ,window)) 37 38 (defmacro pdf-view-current-slice (&optional window) 39 ;;TODO: write documentation! 40 `(image-mode-window-get 'slice ,window)) 41 42 (defmacro pdf-view-current-window-size (&optional window) 43 ;;TODO: write documentation! 44 `(image-mode-window-get 'window-size ,window)) 45 46 (defmacro pdf-view-window-needs-redisplay (&optional window) 47 `(image-mode-window-get 'needs-redisplay ,window)) 48 49 (provide 'pdf-macs) 50 51 ;;; pdf-macs.el ends here