From 1cc7abd4d7561731a9be7c179e53595e037312d9 Mon Sep 17 00:00:00 2001 From: Daniel Borchmann Date: Mon, 22 Jan 2024 19:49:20 +0100 Subject: [PATCH] Clarify that remaining time is computed over clocked time of subtree --- site-lisp/db-org.el | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/site-lisp/db-org.el b/site-lisp/db-org.el index 727ed69..d646d3b 100644 --- a/site-lisp/db-org.el +++ b/site-lisp/db-org.el @@ -210,6 +210,8 @@ _y_: ?y? year _q_: quit _L__l__c_: ?l? The remaining effort is computed as the planned effort minus the already clocked time. If this result is negative, return zero. +The clocked time is computed over the complete subtree of the Org +item at point, and not only from the item itself. Return the remaining effort as duration string by default. When optional AS-NUMBER is non-nil, return the effort as number. @@ -478,10 +480,11 @@ user for the next task to clock into." (message org-clock-current-task)) (defun db/org-clocked-time-for-current-item () - "Return all clocked time for Org item at point. + "Return overall clocked time for the subtree of the Org item at point. -Also includes the currently running clock when the current item -is clocked in." +The clocked time of the item itself is also included, as is the +time of the currently running clock, in case item at point is +clocked in." (unless (derived-mode-p 'org-mode) (user-error "Not in Org mode buffer, aborting"))