Re: Posix(?) on numeric entry
- From: Olexiy Avramchenko <olexiy ctech cn ua>
- To: antongiulio <antongiulio email it>
- Cc: gtk-list gnome org
- Subject: Re: Posix(?) on numeric entry
- Date: Tue, 15 Feb 2005 11:57:48 +0200
antongiulio wrote:
[...]
buffer = g_strdup_printf("%g", value);
[...]
this value appears like: 2,59787 where ',' replaces a '.'
I suppose it's related to *_NL locale replaces posix locale.
How can I replace ',' with dot notation?
Hi,
Consider g_ascii_dtostr() function:
http://developer.gnome.org/doc/API/2.0/glib/glib-String-Utility-Functions.html#g-ascii-dtostr
Note that it doesn't allocate a memory for you, you need to provide a
buffer.
Olexiy
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]