Boost logo

Boost :

From: Jeff Garland (jeff_at_[hidden])
Date: 2005-04-23 12:49:02


On Sat, 23 Apr 2005 20:40:05 +0300, Peter Dimov wrote

> >> You are right. However there are legitimate cases where I might want
> >> both. That is, override the locale-specific month names using a
> >> facet _and_ choose a strftime-style date format independently. So I
> >> think that you need both a facet (for storing locale-dependent
> >> information for %a, %A, %b, %B, %c, %p, %r, %x, %X, and the other
> >> locale-dependent specifiers) and a manipulator for the format string.
> >
> > Yep, I can see the convenience of having the manipulator. For now
> > though users will have to reset formats thru the facets...
>
> That's OK as long as you can reset the default format without
> erasing all locale-dependent information, such as month names.

Yep -- each element is individually replaceable. So you can change your date
format, month strings, day of the week strings, period formatting, etc a piece
at a time. To reset the format you just call 'format' with the new string.

Jeff


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk