GParamSpec



Hello,

I'm wondering if there's a work in progress (or already done) on wrapping
GParamSpec into glibmm ? I've not found any.

If not, I would like to write one as I need it. So, some help on how to do so
will be appreciated. Do you have some tools to autogenerate part of the code ?
(as gob2 ?). Or should I wrote it by hand ?

Second, I would like to extend GParamSpec features. I would like to add
functionnalities to say if the value associated may be null or not.
If I've wrote somethink like
// C++
Glib::Value<int>   a; // A should be initialize to null

Perhaps just adding a function saying if the value has been initialize (by init)
must be enought ? And another to uninitialize it should also be added in order
to set the value to null once it has been initialized.

This features must be available for all GParamSpec structure (that is
GParamSpecInt, GParamSpecUInt, etc).

I would also like to add default value. I've seen that you can specify one at
construction time of a GParamSpecInt like:
// C
GParamSpec* spec = g_param_spec_int(
        "one-name" ,
        "one-nick" ,
        "one-blurb",
        1234,
        -1234,
        -1, // DEFAULT VALUE
        flags );

But, How may I get the default value set ? I've not find any function nor field
into the GParamSpecInt structure where this value is stored ?


Thanks for your help.
Best regards



+--------------------+
+ Laurent Marzullo
+



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