Str.asciiFormatd

Converts a gdouble to a string, using the '.' as decimal point. To format the number you pass in a printf()-style format string. Allowed conversion specifiers are 'e', 'E', 'f', 'F', 'g' and 'G'.

The returned buffer is guaranteed to be nul-terminated.

If you just want to want to serialize the value into a string, use g_ascii_dtostr().

struct Str
static
string
asciiFormatd
(
string buffer
,
int bufLen
,
string format
,
double d
)

Parameters

buffer string

A buffer to place the resulting string in

bufLen int

The length of the buffer.

format string

The printf()-style format to use for the code to use for converting.

d double

The gdouble to convert

Return Value

Type: string

The pointer to the buffer with the converted string.