datatip buttondownfcn callback not executing

Hi,
In matlab 2020a, I'm trying to use the ButtonDownFcn with a datatip object. However, the callback never executes. I've tried playing with 'HitTest' and 'PickableParts' and still nothing happens.
When using 'ValueChangedFcn' the callback does execute.
What am I missing?
Code looks somewhat like this:
f = figure();
p = plot(x,y);
dt = datatip(p,1,1,'ButtonDownFunction',@myCallback);
set(dt,'PickableParts','visible');
set(dt,'HitTest','on');

回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeInteractive Control and Callbacks についてさらに検索

質問済み:

2020 年 6 月 16 日

コメント済み:

2021 年 2 月 7 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by