Re: Setting list values



In <3D9D200F 6080703 taliesin ca>, Andreas J Guelzow wrote:

> Strange,
> 
> we are using lists for some of the preferences in gnumeric without 
> problems whatsoever...

Thanks, I had a look at your source and worked out what my problem was.
I was building a list of GConfValue structs and passing that to
gconf_value_set_list, but what you're obviously supposed to do is pass a
list of the values themselves (ie plain ints, strings etc).

I think the documentation is wrong. At
<http://developer.gnome.org/doc/API/gconf/gconf-gconf-value.html#GCONF-VALUE-SET-LIST>
it says:

: The list argument should be a GSList of GConfValue. Each GConfValue in
: the list must have the same type, and this type must be specified in
: advance with gconf_value_set_list_type().

I read that as unambiguous instruction to use a list of GConfValue, not
of string or int.

-- 
TH * http://www.realh.co.uk



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]