Re: [Vala] vala-list Digest, Vol 124, Issue 13
- From: Al Thomas <astavale yahoo co uk>
- To: vala-list gnome org, Fernando Silva <wild nando gmail com>
- Subject: Re: [Vala] vala-list Digest, Vol 124, Issue 13
- Date: Wed, 28 Mar 2018 17:35:28 +0000 (UTC)
> On Wednesday, 28 March 2018, 18:03:44 BST, Fernando Silva <wild nando gmail com> wrote: > I bet this
could be decided based on locale with gettext
Now, there's a challenge :)
Gettext is very good with plurals (https://www.gnu.org/software/gettext/manual/html_node/Plural-forms.html).I
didn't find anything on date presentation though.
There is the Posix nl_langinfo:
void main () { Intl.setlocale ();
print (Posix.nl_langinfo (Posix.D_FMT) + "\n");
}
but all that does is return the format based on the forward slash separator. This can then be used instrftime
or GLib.DateTime.format(). For my locale (en_GB) I get %d/%m/%y
Al
[
Date Prev][
Date Next] [
Thread Prev][Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]