#include <stdio.h>
#include <stdlib.h>

- (void) setDoubleValue:(double) value
{
    char string[64];

    sprintf(string, "%g", value);
    gtk_entry_set_text(gtk, string);
}

- (void) setIntValue:(int) value
{
    char string[64];

    sprintf(string, "%d", value);
    gtk_entry_set_text(gtk, string);
}

- (void) setStringValue:(NSString *) value
{
    gtk_entry_set_text(gtk, NSString_to_String(value));
}

- (double) doubleValue
{
    return atof(gtk_entry_get_text(gtk));
}

- (int) intValue
{
    return atoi(gtk_entry_get_text(gtk));
}

- (NSString *) stringValue
{
    return String_to_NSString(gtk_entry_get_text(gtk));
}
