To: alan.schmitt at inria.fr Cc: lablgtk at kaba.or.jp Subject: Re: setting the "upper" value of an adjustment In-Reply-To: <20011210092113.B894 at alan-schm1p> References: <20011209180210.A11954 at alan-schm1p> <20011210151319H.garrigue@kurims.kyoto-u.ac.jp> <20011210092113.B894@alan-schm1p> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-Id: <20011210173741D.garrigue at kurims.kyoto-u.ac.jp> Date: Mon, 10 Dec 2001 17:37:41 +0900 From: Jacques Garrigue Lines: 21 From: Alan Schmitt > > Yet, this doesn't seem that clear: the documentation says that this is > > OK for the owner of an adjustment to change the bounds, then calling > > the "changed" signal. Does it mean that I should add a set_bounds > > functions, eventhough there is no such thing in GTK+ ? > > Actually I don't think so anymore ... I create a new adjustment each > time I need one, and use the scale#set_adjustment to attach it to the > scale (luckily enough there is such a function). I don't know if > set_value is just a convenience function in gtk, or if it exists to > discourage direct modification of the record ... Well, I added it anyway. This will be in the next release, after 3.04. To be correct you have to both call "changed" after modifying, and reset the value with set_value. Of course set_bounds will do all that for you (we don't want to get into an incoherent state, do we?) By the way, set_value is not completely dumb, it forces the value to be in the interval [lower,upper]. Jacques