From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chen Zhang Subject: Bug: property "CLOCK_MODELINE_TOTAL" is not inherted Date: Mon, 1 Jan 2018 20:00:10 +0800 Message-ID: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="001a114798cc66a06c0561b5b96f" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:59007) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eVylJ-0000Rr-1q for emacs-orgmode@gnu.org; Mon, 01 Jan 2018 07:00:14 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eVylI-0001zb-AL for emacs-orgmode@gnu.org; Mon, 01 Jan 2018 07:00:13 -0500 Received: from mail-qk0-x22b.google.com ([2607:f8b0:400d:c09::22b]:42089) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eVylI-0001zT-5a for emacs-orgmode@gnu.org; Mon, 01 Jan 2018 07:00:12 -0500 Received: by mail-qk0-x22b.google.com with SMTP id d202so34348770qkc.9 for ; Mon, 01 Jan 2018 04:00:11 -0800 (PST) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode@gnu.org --001a114798cc66a06c0561b5b96f Content-Type: text/plain; charset="UTF-8" Hi all, When using clock I prefer to set "CLOCK_MODELINE_TOTAL" to "current". Since it's used frequently I want to set it as an upper level property (or a global configuration). So I try to use property inheritance, but I failed. After struggling 2 days I find the reason. The related function "org-clock-get-sum-start" calls (org-entry-get nil "CLOCK_MODELINE_TOTAL") to get the property value. But the INHERIT argument of org-entry-get is not set. So this property doesn't use inheritance at all. By checking the source I also found the variable "org-clock-mode-line-total" can be used for global settings. So my problem is partially solved. During my investigation, I think the key problems are: 1. The Org manual only mentions CLOCK_MODELINE_TOTAL to change mode line clock time. And it's easy to guide people like me to use property inheritance to do global settings. But it doesn't work. 2. The org-clock-mode-line-total can be used as global settings. But it doesn't mentioned in Org manual at all. So I suggest to change code to something like (org-entry-get nil "CLOCK_MODELINE_TOTAL" t) to use inheritance. If inheritance has to be disabled for some reason (e.g performance). It's better to tell users in the Org manual. GNU Emacs 25.3.1 (x86_64-apple-darwin17.0.0, NS appkit-1561.00 Version 10.13 (Build 17A405)) of 2017-11-07 Org mode version 9.1.4 Regards, David Chen --001a114798cc66a06c0561b5b96f Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi all,

When using clock I p= refer to set "CLOCK_MODELINE_TOTAL" to "current". Since= it's used frequently I want to set it as an upper level property (or a= global configuration). So I try to use property inheritance, but I failed.=

After struggling 2 days I find the reason. The re= lated function "org-clock-get-sum-start" calls (org-entry-get nil= "CLOCK_MODELINE_TOTAL") to get the property value. But the INHER= IT argument of org-entry-get is not set. So this property doesn't use i= nheritance at all.

By checking the source I also f= ound the variable "org-clock-mode-line-total" can be used for glo= bal settings. So my problem is partially solved.

D= uring my investigation, I think the key problems are:
1. The Org = manual only mentions CLOCK_MODELINE_TOTAL to change mode line clock time. A= nd it's easy to guide people like me to use property inheritance to do = global settings. But it doesn't work.
2. The org-clock-mode-l= ine-total can be used as global settings. But it doesn't mentioned in O= rg manual at all.

So I suggest to change code to s= omething like (org-entry-get nil "CLOCK_MODELINE_TOTAL" t) to use= inheritance. If inheritance has to be disabled for some reason (e.g perfor= mance). It's better to tell users in the Org manual.


GNU Emacs 25.3.1 (x86_64-apple-darwin17.0.0, NS appkit-156= 1.00 Version 10.13 (Build 17A405)) of 2017-11-07
Org mode version 9= .1.4

Regards,

David C= hen
--001a114798cc66a06c0561b5b96f--