diff options
author | Bastien Guerry <bzg@altern.org> | 2012-03-28 00:49:55 +0200 |
---|---|---|
committer | Bastien Guerry <bzg@altern.org> | 2012-03-28 00:49:55 +0200 |
commit | 7686a81c140ac3266664d3ec3a66df616f523a56 (patch) | |
tree | 4174120592f5cfdebb3df175a2a8fb1c0e2b8128 | |
parent | 122f5fd5b5afb8721e34d637a6f796c5ccff5e52 (diff) | |
download | org-mode-7686a81c140ac3266664d3ec3a66df616f523a56.tar.gz |
New option to format the total time cells.
* org-clock.el (org-clock-in-prepare-hook): New option to
format the total time cells.
(org-clocktable-write-default): Use the new option.
-rw-r--r-- | lisp/org-clock.el | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/lisp/org-clock.el b/lisp/org-clock.el index 5fca941..7c2c2ab 100644 --- a/lisp/org-clock.el +++ b/lisp/org-clock.el @@ -323,6 +323,12 @@ play with them." :version "24.1" :type 'boolean) +(defcustom org-clock-total-time-cell-format "*%s*" + "Format string for the total time cells." + :group 'org-clock + :version "24.1" + :type 'boolean) + (defvar org-clock-in-prepare-hook nil "Hook run when preparing the clock. This hook is run before anything happens to the task that @@ -2231,11 +2237,11 @@ from the dynamic block definition." ; file column, maybe (if level-p "|" "") ; level column, maybe (if timestamp "|" "") ; timestamp column, maybe - (if properties (make-string (length properties) ?|) "") ;properties columns, maybe - (concat "*" (nth 7 lwords) "*| ") ; instead of a headline - "*" - (org-minutes-to-hh:mm-string (or total-time 0)) ; the time - "*|\n") ; close line + (if properties (make-string (length properties) ?|) "") ; properties columns, maybe + (concat (format org-clock-total-time-cell-format (nth 7 lwords)) "| ") ; instead of a headline + (format org-clock-total-time-cell-format + (org-minutes-to-hh:mm-string (or total-time 0))) ; the time + "|\n") ; close line ;; Now iterate over the tables and insert the data ;; but only if any time has been collected |