On Saturday 23 April 2016 01:08:48 Krzysztof wrote:
> 2016-04-23 0:39 GMT+02:00 Krzysztof <[email protected]>:
> > It should also correspond with "accept" param in "onsetvalue"
> > event. Let say that my "accept" is for every 0.25 (4 steps), click on
> > slider should move button / change value to the closest mouse position
> > "checkpoint"
>
> Answering for my own question. "avalue" in "onsetvalue" is passed as
> var, so I can correct it to the closest "checkpoint" and accept or
> not.

All OnSetValue properties of editwidgets work this way. If "accept" is 
true "avalue" will be stored in "Value" property and OnDataEntered" called.

Use for example in OnSetValue:
"
procedure tmainfo.setslider(const sender: TObject; var avalue: realty;
               var accept: Boolean);
begin
 avalue:= round(avalue*10)/10.0;
end;
"
> So question left is how to jump to the mouse click. What option
> is it?
>
Use Ctrl+LeftClick or activate TSlider.ScrollBar.Options sbo_clicktovalue (git 
master 2d26a8281b79bb6f3005036dc28e8232b810998b).

Martin

------------------------------------------------------------------------------
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
_______________________________________________
mseide-msegui-talk mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mseide-msegui-talk

Reply via email to