aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMathias Dahl2006-07-25 16:20:53 +0000
committerMathias Dahl2006-07-25 16:20:53 +0000
commitb724b0ed43f6aa40a8f119f69200ef46a99b9590 (patch)
treead1e69f11394f491b009a44e0a491f5ba779d28d
parentc14a5a995d689ff818ece34bc61285bf0f24efd6 (diff)
downloademacs-b724b0ed43f6aa40a8f119f69200ef46a99b9590.tar.gz
emacs-b724b0ed43f6aa40a8f119f69200ef46a99b9590.zip
(tumme-track-original-file): Add `buffer-live-p' check.
(tumme-format-properties-string): Handle empty `buf'. (tumme-get-comment): Change variable names inside `let'. Add missing `let' variable that cause font-lock problems. (tumme-write-comments): Change variable names inside `let'. Add missing `let' variable that cause font-lock problems. (tumme-forward-image): Rename from `tumme-forward-char'. (tumme-backward-image): Rename from `tumme-backward-char'.
-rw-r--r--lisp/tumme.el26
1 files changed, 13 insertions, 13 deletions
diff --git a/lisp/tumme.el b/lisp/tumme.el
index d7b873d7cb4..9e76c6c3b59 100644
--- a/lisp/tumme.el
+++ b/lisp/tumme.el
@@ -1072,7 +1072,7 @@ move ARG lines."
1072 (if tumme-track-movement 1072 (if tumme-track-movement
1073 (tumme-track-thumbnail))) 1073 (tumme-track-thumbnail)))
1074 1074
1075(defun tumme-forward-char () 1075(defun tumme-forward-image ()
1076 "Move to next image and display properties." 1076 "Move to next image and display properties."
1077 (interactive) 1077 (interactive)
1078 ;; Before we move, make sure that there is an image two positions 1078 ;; Before we move, make sure that there is an image two positions
@@ -1088,7 +1088,7 @@ move ARG lines."
1088 (tumme-track-original-file))) 1088 (tumme-track-original-file)))
1089 (tumme-display-thumb-properties)) 1089 (tumme-display-thumb-properties))
1090 1090
1091(defun tumme-backward-char () 1091(defun tumme-backward-image ()
1092 "Move to previous image and display properties." 1092 "Move to previous image and display properties."
1093 (interactive) 1093 (interactive)
1094 (when (not (bobp)) 1094 (when (not (bobp))
@@ -1106,7 +1106,7 @@ move ARG lines."
1106 (next-line 1) 1106 (next-line 1)
1107 ;; If we end up in an empty spot, back up to the next thumbnail. 1107 ;; If we end up in an empty spot, back up to the next thumbnail.
1108 (if (not (tumme-image-at-point-p)) 1108 (if (not (tumme-image-at-point-p))
1109 (tumme-backward-char)) 1109 (tumme-backward-image))
1110 (if tumme-track-movement 1110 (if tumme-track-movement
1111 (tumme-track-original-file)) 1111 (tumme-track-original-file))
1112 (tumme-display-thumb-properties)) 1112 (tumme-display-thumb-properties))
@@ -1121,7 +1121,7 @@ move ARG lines."
1121 ;; thumbnail and did not refresh, so it is not very common. But we 1121 ;; thumbnail and did not refresh, so it is not very common. But we
1122 ;; can handle it in a good manner, so why not? 1122 ;; can handle it in a good manner, so why not?
1123 (if (not (tumme-image-at-point-p)) 1123 (if (not (tumme-image-at-point-p))
1124 (tumme-backward-char)) 1124 (tumme-backward-image))
1125 (if tumme-track-movement 1125 (if tumme-track-movement
1126 (tumme-track-original-file)) 1126 (tumme-track-original-file))
1127 (tumme-display-thumb-properties)) 1127 (tumme-display-thumb-properties))
@@ -1190,19 +1190,19 @@ dired."
1190 "Mark original image file in associated dired buffer." 1190 "Mark original image file in associated dired buffer."
1191 (interactive) 1191 (interactive)
1192 (tumme-modify-mark-on-thumb-original-file 'mark) 1192 (tumme-modify-mark-on-thumb-original-file 'mark)
1193 (tumme-forward-char)) 1193 (tumme-forward-image))
1194 1194
1195(defun tumme-unmark-thumb-original-file () 1195(defun tumme-unmark-thumb-original-file ()
1196 "Unmark original image file in associated dired buffer." 1196 "Unmark original image file in associated dired buffer."
1197 (interactive) 1197 (interactive)
1198 (tumme-modify-mark-on-thumb-original-file 'unmark) 1198 (tumme-modify-mark-on-thumb-original-file 'unmark)
1199 (tumme-forward-char)) 1199 (tumme-forward-image))
1200 1200
1201(defun tumme-flag-thumb-original-file () 1201(defun tumme-flag-thumb-original-file ()
1202 "Flag original image file for deletion in associated dired buffer." 1202 "Flag original image file for deletion in associated dired buffer."
1203 (interactive) 1203 (interactive)
1204 (tumme-modify-mark-on-thumb-original-file 'flag) 1204 (tumme-modify-mark-on-thumb-original-file 'flag)
1205 (tumme-forward-char)) 1205 (tumme-forward-image))
1206 1206
1207(defun tumme-toggle-mark-thumb-original-file () 1207(defun tumme-toggle-mark-thumb-original-file ()
1208 "Toggle mark on original image file in associated dired buffer." 1208 "Toggle mark on original image file in associated dired buffer."
@@ -1250,12 +1250,12 @@ You probably want to use this together with
1250 "Define keymap for `tumme-thumbnail-mode'." 1250 "Define keymap for `tumme-thumbnail-mode'."
1251 1251
1252 ;; Keys 1252 ;; Keys
1253 (define-key tumme-thumbnail-mode-map [right] 'tumme-forward-char) 1253 (define-key tumme-thumbnail-mode-map [right] 'tumme-forward-image)
1254 (define-key tumme-thumbnail-mode-map [left] 'tumme-backward-char) 1254 (define-key tumme-thumbnail-mode-map [left] 'tumme-backward-image)
1255 (define-key tumme-thumbnail-mode-map [up] 'tumme-previous-line) 1255 (define-key tumme-thumbnail-mode-map [up] 'tumme-previous-line)
1256 (define-key tumme-thumbnail-mode-map [down] 'tumme-next-line) 1256 (define-key tumme-thumbnail-mode-map [down] 'tumme-next-line)
1257 (define-key tumme-thumbnail-mode-map "\C-f" 'tumme-forward-char) 1257 (define-key tumme-thumbnail-mode-map "\C-f" 'tumme-forward-image)
1258 (define-key tumme-thumbnail-mode-map "\C-b" 'tumme-backward-char) 1258 (define-key tumme-thumbnail-mode-map "\C-b" 'tumme-backward-image)
1259 (define-key tumme-thumbnail-mode-map "\C-p" 'tumme-previous-line) 1259 (define-key tumme-thumbnail-mode-map "\C-p" 'tumme-previous-line)
1260 (define-key tumme-thumbnail-mode-map "\C-n" 'tumme-next-line) 1260 (define-key tumme-thumbnail-mode-map "\C-n" 'tumme-next-line)
1261 1261
@@ -2007,13 +2007,13 @@ function. The result is a couple of new files in
2007(defun tumme-display-next-thumbnail-original () 2007(defun tumme-display-next-thumbnail-original ()
2008 "In thubnail buffer, move to next thumbnail and display the image." 2008 "In thubnail buffer, move to next thumbnail and display the image."
2009 (interactive) 2009 (interactive)
2010 (tumme-forward-char) 2010 (tumme-forward-image)
2011 (tumme-display-thumbnail-original-image)) 2011 (tumme-display-thumbnail-original-image))
2012 2012
2013(defun tumme-display-previous-thumbnail-original () 2013(defun tumme-display-previous-thumbnail-original ()
2014 "Move to previous thumbnail and display image." 2014 "Move to previous thumbnail and display image."
2015 (interactive) 2015 (interactive)
2016 (tumme-backward-char) 2016 (tumme-backward-image)
2017 (tumme-display-thumbnail-original-image)) 2017 (tumme-display-thumbnail-original-image))
2018 2018
2019(defun tumme-write-comments (file-comments) 2019(defun tumme-write-comments (file-comments)