Re: Adjustment problem
- From: Murray Cumming <murrayc murrayc com>
- To: Paul Davis <pjdavis engineering uiowa edu>
- Cc: "Amadeus W.M." <amadeus84 verizon net>, gtkmm-list gnome org
- Subject: Re: Adjustment problem
- Date: Wed, 01 Nov 2006 18:15:11 +0100
On Wed, 2006-11-01 at 11:09 -0600, Paul Davis wrote:
>
> At what point in the call to gtk_adjustment_new() does
> adjustment->value get set?
During g_object_new(), because a value has been specified for the
"value" property:
GtkObject*
gtk_adjustment_new (gdouble value,
gdouble lower,
gdouble upper,
gdouble step_increment,
gdouble page_increment,
gdouble page_size)
{
return g_object_new (GTK_TYPE_ADJUSTMENT,
"lower", lower,
"upper", upper,
"step-increment", step_increment,
"page-increment", page_increment,
"page-size", page_size,
"value", value,
NULL);
}
> The point of contention is not that it
> works after instantiation, but that instantiation is incorrectly using
> the gobject api to store values when instead, they should just be
> placed in the structure.
Why do you believe that it should access the struct directly instead of
doing it via the property API? The end result should be the same, though
the set_property() vfunc implementation may decide to
a) validate property values somehow.
b) otherwise respond to the change, for instance by updating the UI.
--
Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]