Hi Erik,For (1), I would use the call 'g_object_set'. Currently, in the standard configfile this is defined as:
FUNCTION_NAME = g_object_set, NONE, NONE, 4, WIDGET, STRING, INT, NULLIn your case, you need to redefine it as follows: gtk_server_redefine(g_object_set, NONE, NONE, 4, WIDGET, STRING, FLOAT, NULL)
From here, you should be able to set the x-alignment as follows: g_object_set(CellRendererID, "xalign", 1.0, NULL)
For (2), this seems a question which is more related to GTK, than it is related to GTK-server. Nevertheless it would be interesting to see if there is a possibility in GTK at all to limit the amount of decimals. Probably this can be done with a GLIB call.
But you can always format the float number in the client program, and then let it print by GTK.
Best regards Peter Quoting Erik Winkels <euqirea@xxxxxxxxx>:
Don't worry about activity since I've got some more questions lined up :-) (I have to Google some more but I'm wondering how to set properties and how to change the formatting of a GtkTreeView cell .)Also, excuse me for the retarded quoting but I'm subscribed to the list in digest mode (by choice).Erik I want to change the align the numbers in a cell to the right and so far I've found out I can do that by setting a cell renderer's "x-align" attribute to 1.0 if I remember correctly. However, adding the function g_object_set_property to the config file wasn't enough. I want to limit the printed decimals to two instead of the six or seven that are printed at the moment.