diff options
Diffstat (limited to 'lisp/ldg-register.el')
-rw-r--r-- | lisp/ldg-register.el | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/lisp/ldg-register.el b/lisp/ldg-register.el index 02e50de9..7b5c0d0a 100644 --- a/lisp/ldg-register.el +++ b/lisp/ldg-register.el @@ -25,29 +25,29 @@ (dolist (post posts) (let ((index 1)) (dolist (xact (nthcdr 5 post)) - (let ((beg (point)) - (where - (with-current-buffer data-buffer - (cons - (nth 0 post) - (if ledger-clear-whole-entries - (save-excursion - (goto-line (nth 1 post)) - (point-marker)) - (save-excursion - (goto-line (nth 0 xact)) - (point-marker))))))) - (insert (format ledger-register-line-format - (format-time-string ledger-register-date-format - (nth 2 post)) - (nth 4 post) (nth 1 xact) (nth 2 xact))) - (if (nth 3 xact) - (set-text-properties beg (1- (point)) - (list 'face 'ledger-register-pending-face - 'where where)) - (set-text-properties beg (1- (point)) - (list 'where where)))) - (setq index (1+ index))))) + (let ((beg (point)) + (where + (with-current-buffer data-buffer + (cons + (nth 0 post) + (if ledger-clear-whole-entries + (save-excursion + (goto-line (nth 1 post)) + (point-marker)) + (save-excursion + (goto-line (nth 0 xact)) + (point-marker))))))) + (insert (format ledger-register-line-format + (format-time-string ledger-register-date-format + (nth 2 post)) + (nth 4 post) (nth 1 xact) (nth 2 xact))) + (if (nth 3 xact) + (set-text-properties beg (1- (point)) + (list 'face 'ledger-register-pending-face + 'where where)) + (set-text-properties beg (1- (point)) + (list 'where where)))) + (setq index (1+ index))))) (goto-char (point-min)) ) @@ -55,10 +55,10 @@ (let ((buf (or data-buffer (current-buffer)))) (with-current-buffer (get-buffer-create "*ledger-register*") (let ((pos (point)) - (inhibit-read-only t)) - (erase-buffer) - (ledger-register-render buf (apply #'ledger-exec-read buf args)) - (goto-char pos)) + (inhibit-read-only t)) + (erase-buffer) + (ledger-register-render buf (apply #'ledger-exec-read buf args)) + (goto-char pos)) (set-buffer-modified-p nil) (toggle-read-only t) (display-buffer (current-buffer) t)))) |