From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nicolas Goaziou Subject: Re: [PATCH] Separate clocksum format for durations >= 1 day Date: Fri, 09 Nov 2012 09:04:02 +0100 Message-ID: <87mwyrjj7x.fsf@gmail.com> References: <87wqxxkkhj.fsf@gmail.com> <20121108112857.GA4911@c3po> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([208.118.235.92]:37924) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TWjdX-0003CU-T4 for emacs-orgmode@gnu.org; Fri, 09 Nov 2012 03:08:29 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TWjdS-0001y8-FT for emacs-orgmode@gnu.org; Fri, 09 Nov 2012 03:08:23 -0500 Received: from mail-wi0-f169.google.com ([209.85.212.169]:35139) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TWjdS-0001xy-8c for emacs-orgmode@gnu.org; Fri, 09 Nov 2012 03:08:18 -0500 Received: by mail-wi0-f169.google.com with SMTP id hq4so367007wib.0 for ; Fri, 09 Nov 2012 00:08:17 -0800 (PST) In-Reply-To: <20121108112857.GA4911@c3po> (Toby Cubitt's message of "Thu, 8 Nov 2012 12:28:57 +0100") 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-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org Toby Cubitt writes: > Minor point: I would order the format strings minutes, hours, days. In > case we ever want to extend to months or years, that way we can simply > extend the list and it will be completely backwards compatible. Using a plist can circumvent the problem, too. I'm ok either way. > One other thing that needs some thought (which I already mentioned > previously). The minutes format string needs to change, depending on > whether the data format is fractional or regular. Not necessarily. The format string can use %s. We can also remind it in the docstring of both variables and provide examples. > So if a user wants to switch to fractional, it's not enough to set the > first variable; they have to *also* change the minute format string. > If they don't the durations will be garbled. Sometimes, yes. > A customization setter function could be used to change the value of the > second variable when the first one is modified through customize. But > that quickly gets complex, e.g. we have to be careful about clobbering > any customizations the user has already made to the format strings. That sounds too complicated. > The simpler solution would be to always have two format strings for the > minutes in the list: a fractional format, and a regular format. This > shouldn't be too confusing as long as it's documented in the variable > docstring and there are good descriptive :tags for each list element in > the customization type. I think this is not necessary. We can just document the fact that the user must check both variables before applying some change. Anyway, I let you judge this. > Looks good to me, and lets me do what I wanted in my original patch. > > Now I just need to find time to code it up... Good to hear we eventually settled on a solution ! Regards, -- Nicolas Goaziou