Re: Slider Widget

From: Dmitry Karasik <dmitry_at_karasik.eu.org>
Date: Mon, 29 Dec 2008 09:59:53 +0100
To: tjg_at_gimmel.org

        Hi Tim!

On 29 ΔΕΛ 08 at 01:33, "Tim" (Tim Gimmel) wrote:

 Tim> Dmitry, thanks for all you help so far! Now I trying to work with a
 Tim> slider. I cannot find where the value of the slider is returned.

It is in the ::value property.

 Tim> The onChange just returns a hash. There are so many things missing
 Tim> (in docs) the task is becoming to great ):

Patches are welcome :)

 Tim> The slider docs only show
 Tim> 3 events and methods with no direction on how to call the methods.
 Tim> For example, pos2info X,Y looks like a good candidate, but where do
 Tim> the X,Y values come from? Is it values from the mouse movement? That

As doc states, "converts widget coordinates X and Y". Mouse movement
is a possible, but not only source for these coordinates. More strictly,
these coordinates are widget coordinates in pixels, counted rightwards
and upwards from the left lower pixel, which is has coordinates (0,0).

 Tim> (Also onMove is not called when the slider moves.)

onMove, as doc states, "triggered when widget changes its position relative
to its parent, either by Prima::Widget methods or by the user". It has
nothing to do with mouse.

 Tim> I would love to find an app that has a lot of these items implemented
 Tim> and Visual Builder was used. I think that would help a lot.

Look at examples, run them all even. They don't cover it all, but
I'm sure you'll find something useful there. F.ex. IIRC examples/fontdlg.pl
deals with both types of sliders.

-- 
Sincerely,
	Dmitry Karasik
Received on Mon 29 Dec 2008 - 09:59:56 CET

This archive was generated by hypermail 2.2.0 : Sat 19 Mar 2011 - 18:35:06 CET