Review Request: Partial date formats for KLocale

Allen Winter winter at kde.org
Sat May 2 12:49:33 BST 2009


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://reviewboard.kde.org/r/648/#review1025
-----------------------------------------------------------


I'm happy you are working on this.  I need a safe way to print the date in the locale without the year for the Kontact summary page.  No complaints.

- Allen


On 2009-05-01 09:25:45, Chusslove Illich wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://reviewboard.kde.org/r/648/
> -----------------------------------------------------------
> 
> (Updated 2009-05-01 09:25:45)
> 
> 
> Review request for kdelibs.
> 
> 
> Summary
> -------
> 
> KLocale provides default short and long full date formatting (e.g. "04/08/2007" and "Sunday 08 April 2007"), which are properly localized. However, at many places it is clunky to use full dates, and some shortening is preferred (e.g. just day and month, just month and year, etc.) In such situations, programmers resort to one of: hardcoding KLocale format strings, piecing up date strings from QDate reported day/month names, exposing any mix of these to translators, or not even that. This leads to headache whenever such a "partial" date is reported as improperly localizable by translators.
> 
> Therefore it would be good to extend possible KLocale date formats to partial dates too. Current patch is only proposal for the interface: adding enums for sane combinations (e.g. day+month and month+year, but not day+year), and for each a long, short, and numeric form (e.g. "December 2008", "Dec 2008", "12/2008") as applicable. (Translators would get to set one localized format pattern for each partial format, in kdelibs4.po.)
> 
> 
> Diffs
> -----
> 
>   trunk/KDE/kdelibs/kdecore/localization/klocale.h 961864 
> 
> Diff: http://reviewboard.kde.org/r/648/diff
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Chusslove
> 
>





More information about the kde-core-devel mailing list