[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] [PATCH] Separate clocksum format for durations >= 1 day

From: Achim Gratz
Subject: Re: [O] [PATCH] Separate clocksum format for durations >= 1 day
Date: Mon, 05 Nov 2012 18:40:20 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux)

Nicolas Goaziou writes:
> Then let's wait for Achim (Cc'ed) to illustrate what he has in mind,
> because his proposal is too vague yet to permit discussion about it.

What I had in mind was to remove org-time-clocksum-format and replace
the associated format calls with a formatting function that has
customizable behaviour (how customizable is t.b.d.).

(format org-time-clocksum-format h m) => (org--format-time n fmt)

Even if nothing else changes, that removes a lot of unnecessary code
duplication, like the seven or so different ways to split the hours from
the minutes that may or may not agree on their results.  This is not far
from your own suggestion to provide different functions depending on
which output is desired, I just happen to think that these functions
would all be so similar that they should be rolled into a single
function that can produce different outputs.  I think there'd only be a
handful of possible values for fmt based on the current usage and that
suggests just another cond form would be needed in implementing this
function rather than a full-blown format string interpreter.  The fmt
argument might even be optional (use the custom value if nil) or
dynamically bound instead of being a function argument.

+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

Waldorf MIDI Implementation & additional documentation:

reply via email to

[Prev in Thread] Current Thread [Next in Thread]