Lazarus

Programming => Graphics and Multimedia => TAChart => Topic started by: Muso on April 18, 2021, 03:49:49 pm

Title: [solved] How to trigger TAxisClickTool by double-clicking
Post by: Muso on April 18, 2021, 03:49:49 pm
I use TAxisClickTool with Laz 2.1. When I set its shift state to "ssLeft" or "ssRight", everything is fine - the user clicks on the axis and the OnClick event is triggered.

When I now change the shift state to "ssDouble", it doesn't work. Since the tool has no "OnDoubleClick" event I don't know how to achieve that when double-clicking on the axis title, the "OnClick" event is triggered.
Title: Re: How to trigger TAxisClickTool by double-clicking
Post by: wp on April 18, 2021, 05:12:21 pm
In the Shift property, check ssDouble in addition to ssLeft, and it should work (just tested it myself).
Title: Re: How to trigger TAxisClickTool by double-clicking
Post by: Muso on April 18, 2021, 07:08:41 pm
In the Shift property, check ssDouble in addition to ssLeft, and it should work (just tested it myself).

Many thanks. This works, but the ChartEditor demo will then crash under certain circumstances, see this thread: https://forum.lazarus.freepascal.org/index.php/topic,54215.0.html
TinyPortal © 2005-2018