Recent

Author Topic: [solved] How to trigger TAxisClickTool by double-clicking  (Read 1314 times)

Muso

  • Sr. Member
  • ****
  • Posts: 356
[solved] How to trigger TAxisClickTool by double-clicking
« 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.
« Last Edit: April 18, 2021, 07:08:57 pm by Muso »

wp

  • Hero Member
  • *****
  • Posts: 11833
Re: How to trigger TAxisClickTool by double-clicking
« Reply #1 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).

Muso

  • Sr. Member
  • ****
  • Posts: 356
Re: How to trigger TAxisClickTool by double-clicking
« Reply #2 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