comparison lisp/tumme.el @ 68682:23eaa0d773ea

Added more autoload cookies.
author Mathias Dahl <mathias.dahl@gmail.com>
date Tue, 07 Feb 2006 21:24:22 +0000
parents 3a94c391ebe4
children 9c1ca2e3695c
comparison
equal deleted inserted replaced
68681:7b228a060cbc 68682:23eaa0d773ea
1206 (setq tags (buffer-substring (point) end))) 1206 (setq tags (buffer-substring (point) end)))
1207 (setq tags (buffer-substring (point) end)))))) 1207 (setq tags (buffer-substring (point) end))))))
1208 (kill-buffer buf) 1208 (kill-buffer buf)
1209 (split-string tags ";")))) 1209 (split-string tags ";"))))
1210 1210
1211 ;;;###autoload
1211 (defun tumme-tag-files (arg) 1212 (defun tumme-tag-files (arg)
1212 "Tag marked file(s) in dired. With prefix ARG, tag file at point." 1213 "Tag marked file(s) in dired. With prefix ARG, tag file at point."
1213 (interactive "P") 1214 (interactive "P")
1214 (let ((tag (read-string "Tag to add: ")) 1215 (let ((tag (read-string "Tag to add: "))
1215 curr-file files) 1216 curr-file files)
1224 (let ((tag (read-string "Tag to add: "))) 1225 (let ((tag (read-string "Tag to add: ")))
1225 (tumme-write-tag (tumme-original-file-name) tag)) 1226 (tumme-write-tag (tumme-original-file-name) tag))
1226 (tumme-update-property 1227 (tumme-update-property
1227 'tags (tumme-list-tags (tumme-original-file-name)))) 1228 'tags (tumme-list-tags (tumme-original-file-name))))
1228 1229
1230 ;;;###autoload
1229 (defun tumme-tag-remove (arg) 1231 (defun tumme-tag-remove (arg)
1230 "Remove tag for selected file(s). 1232 "Remove tag for selected file(s).
1231 With prefix argument ARG, remove tag from file at point." 1233 With prefix argument ARG, remove tag from file at point."
1232 (interactive "P") 1234 (interactive "P")
1233 (let ((tag (read-string "Tag to remove: ")) 1235 (let ((tag (read-string "Tag to remove: "))
1487 (if (not (equal (selected-frame) (setq frame (window-frame window)))) 1489 (if (not (equal (selected-frame) (setq frame (window-frame window))))
1488 (select-frame-set-input-focus frame)) 1490 (select-frame-set-input-focus frame))
1489 (select-window window)) 1491 (select-window window))
1490 (message "Associated dired buffer not visible")))) 1492 (message "Associated dired buffer not visible"))))
1491 1493
1494 ;;;###autoload
1492 (defun tumme-jump-thumbnail-buffer () 1495 (defun tumme-jump-thumbnail-buffer ()
1493 "Jump to thumbnail buffer." 1496 "Jump to thumbnail buffer."
1494 (interactive) 1497 (interactive)
1495 (let ((window (tumme-thumbnail-window)) 1498 (let ((window (tumme-thumbnail-window))
1496 frame) 1499 frame)
1885 (let ((inhibit-read-only t)) 1888 (let ((inhibit-read-only t))
1886 (delete-char 1) 1889 (delete-char 1)
1887 (if (looking-at " ") 1890 (if (looking-at " ")
1888 (delete-char 1)))) 1891 (delete-char 1))))
1889 1892
1893 ;;;###autoload
1890 (defun tumme-display-thumbs-append () 1894 (defun tumme-display-thumbs-append ()
1891 "Append thumbnails to `tumme-thumbnail-buffer'." 1895 "Append thumbnails to `tumme-thumbnail-buffer'."
1892 (interactive) 1896 (interactive)
1893 (tumme-display-thumbs nil t)) 1897 (tumme-display-thumbs nil t))
1894 1898
1899 ;;;###autoload
1895 (defun tumme-display-thumb () 1900 (defun tumme-display-thumb ()
1896 "Shorthard for `tumme-display-thumbs' with prefix argument." 1901 "Shorthard for `tumme-display-thumbs' with prefix argument."
1897 (interactive) 1902 (interactive)
1898 (tumme-display-thumbs t)) 1903 (tumme-display-thumbs t))
1899 1904
1960 (message "No original file name found") 1965 (message "No original file name found")
1961 (shell-command (format "%s \"%s\"" 1966 (shell-command (format "%s \"%s\""
1962 tumme-external-viewer 1967 tumme-external-viewer
1963 file)))))) 1968 file))))))
1964 1969
1970 ;;;###autoload
1965 (defun tumme-dired-display-external () 1971 (defun tumme-dired-display-external ()
1966 "Display file at point using an external viewer." 1972 "Display file at point using an external viewer."
1967 (interactive) 1973 (interactive)
1968 (let ((file (dired-get-filename))) 1974 (let ((file (dired-get-filename)))
1969 (shell-command (format "%s \"%s\"" 1975 (shell-command (format "%s \"%s\""
2068 (if (not file) 2074 (if (not file)
2069 (message "No original file name found") 2075 (message "No original file name found")
2070 (tumme-display-image file arg) 2076 (tumme-display-image file arg)
2071 (display-buffer tumme-display-image-buffer)))))) 2077 (display-buffer tumme-display-image-buffer))))))
2072 2078
2079 ;;;###autoload
2073 (defun tumme-display-dired-image (&optional arg) 2080 (defun tumme-display-dired-image (&optional arg)
2074 "Display current image file. 2081 "Display current image file.
2075 See documentation for `tumme-display-image' for more information. 2082 See documentation for `tumme-display-image' for more information.
2076 With prefix argument ARG, display image in its original size." 2083 With prefix argument ARG, display image in its original size."
2077 (interactive "P") 2084 (interactive "P")
2318 (put-text-property 2325 (put-text-property
2319 (point) (1+ (point)) 2326 (point) (1+ (point))
2320 prop 2327 prop
2321 value))) 2328 value)))
2322 2329
2330 ;;;###autoload
2323 (defun tumme-dired-comment-files () 2331 (defun tumme-dired-comment-files ()
2324 "Add comment to current or marked files in dired." 2332 "Add comment to current or marked files in dired."
2325 (interactive) 2333 (interactive)
2326 (let ((files (dired-get-marked-files)) 2334 (let ((files (dired-get-marked-files))
2327 (comment (tumme-read-comment))) 2335 (comment (tumme-read-comment)))
2368 (setq comment (buffer-substring 2376 (setq comment (buffer-substring
2369 comment-beg comment-end)))))) 2377 comment-beg comment-end))))))
2370 (kill-buffer buf) 2378 (kill-buffer buf)
2371 comment))) 2379 comment)))
2372 2380
2381 ;;;###autoload
2373 (defun tumme-mark-tagged-files () 2382 (defun tumme-mark-tagged-files ()
2374 "Use regexp to mark files with matching tag." 2383 "Use regexp to mark files with matching tag."
2375 (interactive) 2384 (interactive)
2376 (let ((tag (read-string "Mark tagged files (regexp): ")) 2385 (let ((tag (read-string "Mark tagged files (regexp): "))
2377 (hits 0) 2386 (hits 0)