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

Re: Change ʽAT <date> <USER> wrote:ʼ



> > I will expand your change for more customizable citation header.
(snip)

> 1. It is strange that there is text in
> `wl-default-draft-cite-header-format-string' (On …, … wrote:) and
> `wl-default-draft-cite-date-format-string' (… at …). This is why I put
> “On” in `wl-default-draft-cite-date-format-string' and did not allow
> configuration of the overall cite header format. I thought that if
> users want to customize that, they can write a function.

I moved "On " to wl-default-draft-cite-header-format-string from
wl-default-draft-cite-date-format-string due to
wl-default-draft-cite-date-format-string's expansion.  If
wl-default-draft-cite-date-format-string is non-string and "On " is
not contained by wl-default-draft-cite-header-format-string,
additional hard-coded "On " string or customizable variable may be
needed as below.

> (defun wl-default-draft-cite ()
> ...
>      (insert
>       (format wl-default-draft-cite-header-format-string
>	       (if date
>		   (cond
>		    ((stringp wl-default-draft-cite-date-format-string)
>		     (let ((system-time-locale
>			    (or wl-default-draft-cite-time-locale
>				system-time-locale)))
>		       (format-time-string
>			wl-default-draft-cite-date-format-string
>			(elmo-time-parse-date-string date))))
>		    (wl-default-draft-cite-date-format-string
>		     (concat "On " (wl-make-date-string
>                                    (elmo-time-parse-date-string date))))
>		    (t
>		     (concat "On " date)))
>		 "Some time ago")

Possible choices would be
  1. Keep "On " in wl-default-draft-cite-date-format-string

    1-1. Add hard-coded "On " string for the case
    wl-default-draft-cite-date-format-string is non-string (as above).

    1-2. Add new variable cooresponding to "On ".  I think is is too
    complex for customization.

  2. Move "On " to wl-default-draft-cite-header-format-string.

I choiced 2.  But I think we can assume citation header is English in
the case wl-default-draft-cite-date-format-string is non-string.  So
1-1. is also possible.

> 2. Typo in the docstring of `wl-default-draft-cite-time-locale' (ciation)

I'll fix it, thank you.

> 3. I am not sure I understand the purpose of
> `wl-default-draft-cite-time-locale'. If a user wants to customize the
> date string, they can customize
> `wl-default-draft-cite-date-format-string'.

When I send a message in English, it would be better that citation
header also is in English.  But format-time-string can produce the day
of week string in locale dependent way only.  So system-time-locale
needs overriding to get English citation header with customized
wl-default-draft-cite-date-format-string on Japanese environment.

> Perhaps it would be simplest to remove customization of
> `wl-default-draft-cite-header-format-string' and set the default value
> of `wl-default-draft-cite-date-format-string' to t as you suggest.

Thank you for the comment.  I will change
wl-default-draft-cite-date-format-string's default to t.

-- 
Kazuhiro Ito