ButtonDownFcn on geoscatter disables panning

2 ビュー (過去 30 日間)
Malte Nagel
Malte Nagel 2022 年 4 月 5 日
回答済み: Malte Nagel 2022 年 4 月 6 日
I have built an application in App Designer that plots points on a geoaxis object using geoscatter. However, if I set the ButtonDownFcn of the returned Scatter object, panning iand zooming are disabled in the geoaxes. I didn't modify the properties of the geoaxes object. If I remove the line setting the ButtonDownFcn property, panning works again.
s = geoscatter(gx, lat, lon, 50, 'green', 'Marker', 'x');
s.ButtonDownFcn = @app.PointClickedCallback;
Could someone explain to me why this happens and how to prevent this?

採用された回答

Malte Nagel
Malte Nagel 2022 年 4 月 6 日
I am still not sure what caused the issue, but adding this line before setting the callback function worked:
enableDefaultInteractivity(gx);

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeDevelop Apps Using App Designer についてさらに検索

製品


リリース

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by