Re: Spin button sugar



Hi,

Sorry to be slow here, I was hoping for input from others since I
filed the report, but failing that I guess input from me will do...

Mike Kestner <mkestner ameritech net> writes: 
> Rename the existing constructor to:
> 
> gtk_spin_button_new_with_adjustment(GtkAdjustment *, gfloat climb_rate,
> guint digits);
> 
> Add a new convenience constructor:
> 
> gtk_spin_button_new(gfloat value, gfloat min, gfloat max, gfloat
> step_incr);

In general we don't rename old functions, the standard thing would be
to use a different name for the new
function. e.g. gtk_spin_button_new_with_range() or something. The
price of legacy code.
 
> If we also add a spin_value_changed signal and some get/set_value
> methods, we can allow users to live in ignorant bliss of the underlying
> adjustment object. All of the attributes can be made private, as the
> adjustment is the only interesting attribute and it already has get/set
> accessors.

Sounds good to me. I kind of wish the signal could just be "changed",
but the weird derivation from GtkEntry prevents that.

Havoc




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