aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCarsten Dominik2006-04-13 07:05:56 +0000
committerCarsten Dominik2006-04-13 07:05:56 +0000
commita4b39e39ca4246b1667b0648907d767d54cd70e1 (patch)
tree247a187dc602755ccaee69ab524a2cf986eebec7
parent6e9715ae06a1e9444e5148af381793430938dc2d (diff)
downloademacs-a4b39e39ca4246b1667b0648907d767d54cd70e1.tar.gz
emacs-a4b39e39ca4246b1667b0648907d767d54cd70e1.zip
(org-ctrl-c-ctrl-c): Improved documentation string.
(org-agenda-mouse-1-follows-link) (org-mouse-1-follows-link): New options. (org-format-agenda-item): Fixed bug if TAGS is nil. (org-agenda-get-scheduled): Quote `priority' symbol in plist.
-rw-r--r--lisp/textmodes/org.el94
1 files changed, 67 insertions, 27 deletions
diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el
index 2ef9c60ce7c..75077b900dd 100644
--- a/lisp/textmodes/org.el
+++ b/lisp/textmodes/org.el
@@ -5,7 +5,7 @@
5;; Author: Carsten Dominik <dominik at science dot uva dot nl> 5;; Author: Carsten Dominik <dominik at science dot uva dot nl>
6;; Keywords: outlines, hypermedia, calendar, wp 6;; Keywords: outlines, hypermedia, calendar, wp
7;; Homepage: http://www.astro.uva.nl/~dominik/Tools/org/ 7;; Homepage: http://www.astro.uva.nl/~dominik/Tools/org/
8;; Version: 4.21 8;; Version: 4.22
9;; 9;;
10;; This file is part of GNU Emacs. 10;; This file is part of GNU Emacs.
11;; 11;;
@@ -81,8 +81,10 @@
81;; 81;;
82;; Changes since version 4.00: 82;; Changes since version 4.00:
83;; --------------------------- 83;; ---------------------------
84;; Version 4.21 84;; Version 4.22
85;; - Bug fixes. 85;; - Bug fixes.
86;; - In agenda buffer, mouse-1 no longer follows link.
87;; See `org-agenda-mouse-1-follows-link' and `org-mouse-1-follows-link'.
86;; 88;;
87;; Version 4.20 89;; Version 4.20
88;; - Links use now the [[link][description]] format by default. 90;; - Links use now the [[link][description]] format by default.
@@ -174,7 +176,7 @@
174 176
175;;; Customization variables 177;;; Customization variables
176 178
177(defvar org-version "4.21" 179(defvar org-version "4.22"
178 "The version number of the file org.el.") 180 "The version number of the file org.el.")
179(defun org-version () 181(defun org-version ()
180 (interactive) 182 (interactive)
@@ -870,6 +872,13 @@ Needs to be set before org.el is loaded."
870 :group 'org-link-follow 872 :group 'org-link-follow
871 :type 'boolean) 873 :type 'boolean)
872 874
875(defcustom org-mouse-1-follows-link t
876 "Non-nil means, mouse-1 on a link will follow the link.
877A longer mouse click will still set point. Does not wortk on XEmacs.
878Needs to be set before org.el is loaded."
879 :group 'org-link-follow
880 :type 'boolean)
881
873(defcustom org-mark-ring-length 4 882(defcustom org-mark-ring-length 4
874 "Number of different positions to be recorded in the ring 883 "Number of different positions to be recorded in the ring
875Changing this requires a restart of Emacs to work correctly." 884Changing this requires a restart of Emacs to work correctly."
@@ -1301,21 +1310,28 @@ forth between agenda and calendar."
1301 :tag "Org Agenda Window Setup" 1310 :tag "Org Agenda Window Setup"
1302 :group 'org-agenda) 1311 :group 'org-agenda)
1303 1312
1313(defcustom org-agenda-mouse-1-follows-link nil
1314 "Non-nil means, mouse-1 on a link will follow the link in the agenda.
1315A longer mouse click will still set point. Does not wortk on XEmacs.
1316Needs to be set before org.el is loaded."
1317 :group 'org-agenda-setup
1318 :type 'boolean)
1319
1304(defcustom org-select-timeline-window t 1320(defcustom org-select-timeline-window t
1305 "Non-nil means, after creating a timeline, move cursor into Timeline window. 1321 "Non-nil means, after creating a timeline, move cursor into Timeline window.
1306When nil, cursor will remain in the current window." 1322When nil, cursor will remain in the current window."
1307 :group 'org-agenda-window-setup 1323 :group 'org-agenda-setup
1308 :type 'boolean) 1324 :type 'boolean)
1309 1325
1310(defcustom org-select-agenda-window t 1326(defcustom org-select-agenda-window t
1311 "Non-nil means, after creating an agenda, move cursor into Agenda window. 1327 "Non-nil means, after creating an agenda, move cursor into Agenda window.
1312When nil, cursor will remain in the current window." 1328When nil, cursor will remain in the current window."
1313 :group 'org-agenda-window-setup 1329 :group 'org-agenda-setup
1314 :type 'boolean) 1330 :type 'boolean)
1315 1331
1316(defcustom org-fit-agenda-window t 1332(defcustom org-fit-agenda-window t
1317 "Non-nil means, change window size of agenda to fit content." 1333 "Non-nil means, change window size of agenda to fit content."
1318 :group 'org-agenda-window-setup 1334 :group 'org-agenda-setup
1319 :type 'boolean) 1335 :type 'boolean)
1320 1336
1321(defgroup org-agenda-display nil 1337(defgroup org-agenda-display nil
@@ -2406,7 +2422,8 @@ that will be added to PLIST. Returns the string that was modified."
2406 (if (featurep 'xemacs) [button2] [mouse-2]) 'org-open-at-mouse) 2422 (if (featurep 'xemacs) [button2] [mouse-2]) 'org-open-at-mouse)
2407(define-key org-mouse-map 2423(define-key org-mouse-map
2408 (if (featurep 'xemacs) [button3] [mouse-3]) 'org-find-file-at-mouse) 2424 (if (featurep 'xemacs) [button3] [mouse-3]) 'org-find-file-at-mouse)
2409(define-key org-mouse-map [follow-link] 'mouse-face) 2425(when org-mouse-1-follows-link
2426 (define-key org-mouse-map [follow-link] 'mouse-face))
2410(when org-tab-follows-link 2427(when org-tab-follows-link
2411 (define-key org-mouse-map [(tab)] 'org-open-at-point) 2428 (define-key org-mouse-map [(tab)] 'org-open-at-point)
2412 (define-key org-mouse-map "\C-i" 'org-open-at-point)) 2429 (define-key org-mouse-map "\C-i" 'org-open-at-point))
@@ -4249,7 +4266,7 @@ used to insert the time stamp into the buffer to include the time."
4249 ;; the range start. 4266 ;; the range start.
4250 (if (save-excursion 4267 (if (save-excursion
4251 (re-search-backward 4268 (re-search-backward
4252 (concat org-ts-regexp "--\\=") 4269 (concat org-ts-regexp "--\\=") ; FIXME: exactly two minuses?
4253 (- (point) 20) t)) 4270 (- (point) 20) t))
4254 (apply 4271 (apply
4255 'encode-time 4272 'encode-time
@@ -4769,7 +4786,8 @@ The following commands are available:
4769 (if (featurep 'xemacs) [(button2)] [(mouse-2)]) 'org-agenda-goto-mouse) 4786 (if (featurep 'xemacs) [(button2)] [(mouse-2)]) 'org-agenda-goto-mouse)
4770(define-key org-agenda-keymap 4787(define-key org-agenda-keymap
4771 (if (featurep 'xemacs) [(button3)] [(mouse-3)]) 'org-agenda-show-mouse) 4788 (if (featurep 'xemacs) [(button3)] [(mouse-3)]) 'org-agenda-show-mouse)
4772(define-key org-agenda-keymap [follow-link] 'mouse-face) 4789(when org-agenda-mouse-1-follows-link
4790 (define-key org-agenda-keymap [follow-link] 'mouse-face))
4773(easy-menu-define org-agenda-menu org-agenda-mode-map "Agenda menu" 4791(easy-menu-define org-agenda-menu org-agenda-mode-map "Agenda menu"
4774 '("Agenda" 4792 '("Agenda"
4775 ("Agenda Files") 4793 ("Agenda Files")
@@ -5522,7 +5540,7 @@ With prefix ARG, go back that many times `org-agenda-ndays'."
5522 (org-disable-agenda-to-diary t)) 5540 (org-disable-agenda-to-diary t))
5523 (save-excursion 5541 (save-excursion
5524 (save-window-excursion 5542 (save-window-excursion
5525 (list-diary-entries date 1))) 5543 (list-diary-entries date 1))) ;; Keep this name for now, compatibility
5526 (if (not (get-buffer fancy-diary-buffer)) 5544 (if (not (get-buffer fancy-diary-buffer))
5527 (setq entries nil) 5545 (setq entries nil)
5528 (with-current-buffer fancy-diary-buffer 5546 (with-current-buffer fancy-diary-buffer
@@ -5954,6 +5972,7 @@ the documentation of `org-diary'."
5954 (if scheduledp "Scheduled: " "")) 5972 (if scheduledp "Scheduled: " ""))
5955 (match-string 1) category tags timestr))) 5973 (match-string 1) category tags timestr)))
5956 (setq txt org-agenda-no-heading-message)) 5974 (setq txt org-agenda-no-heading-message))
5975 (debug)
5957 (setq priority (org-get-priority txt)) 5976 (setq priority (org-get-priority txt))
5958 (org-add-props txt props 5977 (org-add-props txt props
5959 'org-marker marker 'org-hd-marker hdmarker) 5978 'org-marker marker 'org-hd-marker hdmarker)
@@ -5966,7 +5985,7 @@ the documentation of `org-diary'."
5966 (org-add-props txt nil 5985 (org-add-props txt nil
5967 'face 'org-scheduled-today 5986 'face 'org-scheduled-today
5968 'undone-face 'org-scheduled-today 'done-face 'org-done 5987 'undone-face 'org-scheduled-today 'done-face 'org-done
5969 'category category priority (+ 99 priority)) 5988 'category category 'priority (+ 99 priority))
5970 (org-add-props txt nil 'priority priority 'category category))) 5989 (org-add-props txt nil 'priority priority 'category category)))
5971 (push txt ee)) 5990 (push txt ee))
5972 (outline-next-heading)))) 5991 (outline-next-heading))))
@@ -6227,7 +6246,8 @@ only the correctly processes TXT should be returned - this is used by
6227 (file-name-sans-extension 6246 (file-name-sans-extension
6228 (file-name-nondirectory buffer-file-name)) 6247 (file-name-nondirectory buffer-file-name))
6229 ""))) 6248 "")))
6230 (tag (or (nth (1- (or (length tags) 0)) tags) "")) 6249 (tag (if tags (nth (1- (length tags)) tags) ""))
6250 ;;(tag (or (nth (1- (or (length tags) 0)) tags) "")) FIXME: rm
6231 time ;; needed for the eval of the prefix format 6251 time ;; needed for the eval of the prefix format
6232 (ts (if dotime (concat (if (stringp dotime) dotime "") txt))) 6252 (ts (if dotime (concat (if (stringp dotime) dotime "") txt)))
6233 (time-of-day (and dotime (org-get-time-of-day ts))) 6253 (time-of-day (and dotime (org-get-time-of-day ts)))
@@ -10153,7 +10173,8 @@ $1-> %s\n" orig formula form))
10153 (org-table-align))))) 10173 (org-table-align)))))
10154 10174
10155(defun org-table-recalculate (&optional all noalign) 10175(defun org-table-recalculate (&optional all noalign)
10156 "Recalculate the current table line by applying all stored formulas." 10176 "Recalculate the current table line by applying all stored formulas.
10177With prefix arg ALL, do this for all lines in the table."
10157 (interactive "P") 10178 (interactive "P")
10158 (or (memq this-command org-recalc-commands) 10179 (or (memq this-command org-recalc-commands)
10159 (setq org-recalc-commands (cons this-command org-recalc-commands))) 10180 (setq org-recalc-commands (cons this-command org-recalc-commands)))
@@ -12742,19 +12763,37 @@ See the individual commands for more information."
12742 (org-paste-subtree arg))) 12763 (org-paste-subtree arg)))
12743 12764
12744(defun org-ctrl-c-ctrl-c (&optional arg) 12765(defun org-ctrl-c-ctrl-c (&optional arg)
12745 "Call realign table, or recognize a table.el table, or update keywords. 12766 "Set tags in headline, or update according to changed information at point.
12746When the cursor is inside a table created by the table.el package, 12767
12747activate that table. Otherwise, if the cursor is at a normal table 12768This command does many different things, depending on context:
12748created with org.el, re-align that table. This command works even if 12769
12749the automatic table editor has been turned off. 12770- If the cursor is in a headline, prompt for tags and insert them
12750 12771 into the current line, aligned to `org-tags-column'. When called
12751If the cursor is in a headline, prompt for tags and insert them into 12772 with prefix arg, realign all tags in the current buffer.
12752the current line, aligned to `org-tags-column'. When in a headline and 12773
12753called with prefix arg, realign all tags in the current buffer. 12774- If the cursor is in one of the special #+KEYWORD lines, this
12754 12775 triggers scanning the buffer for these lines and updating the
12755If the cursor is in one of the special #+KEYWORD lines, this triggers 12776 information.
12756scanning the buffer for these lines and updating the information. 12777
12757If the cursor is on a #+TBLFM line, re-apply the formulae to the table." 12778- If the cursor is inside a table, realign the table. This command
12779 works even if the automatic table editor has been turned off.
12780
12781- If the cursor is on a #+TBLFM line, re-apply the formulas to
12782 the entire table.
12783
12784- If the cursor is inside a table created by the table.el package,
12785 activate that table. Otherwise, if the cursor is at a normal table
12786 created with org.el, re-align that table.
12787
12788- If the current buffer is a remember buffer, close note and file it.
12789 with a prefix argument, file it without further interaction to the default
12790 location.
12791
12792- If the cursor is on a <<<target>>>, update radio targets and corresponding
12793 links in this buffer.
12794
12795- If the cursor is on a numbered item in a plain list, renumber the
12796 ordered list."
12758 (interactive "P") 12797 (interactive "P")
12759 (let ((org-enable-table-editor t)) 12798 (let ((org-enable-table-editor t))
12760 (cond 12799 (cond
@@ -13505,7 +13544,7 @@ The XOXO buffer is named *xoxo-<source buffer name>*"
13505 13544
13506 ;; Finish the buffer off and clean it up. 13545 ;; Finish the buffer off and clean it up.
13507 (switch-to-buffer-other-window out) 13546 (switch-to-buffer-other-window out)
13508 (indent-region (point-min) (point-max) nil) 13547 (indent-region (point-min) (point-max))
13509 (save-buffer) 13548 (save-buffer)
13510 (goto-char (point-min)) 13549 (goto-char (point-min))
13511 ))) 13550 )))
@@ -13513,3 +13552,4 @@ The XOXO buffer is named *xoxo-<source buffer name>*"
13513;; arch-tag: e77da1a7-acc7-4336-b19e-efa25af3f9fd 13552;; arch-tag: e77da1a7-acc7-4336-b19e-efa25af3f9fd
13514;;; org.el ends here 13553;;; org.el ends here
13515 13554
13555 \ No newline at end of file