Modify axtoolbar in App designer

Hello,
I'm using app designer and I'm trying to modify the tools in the axtoolbar without succes. More specific I'm trying to add the data cursor tool to the tools that are created automatically.
The command
tb1 = axtoolbar(app.Axes,{'export','datacursor','pan','zoomin','zoomout','restoreview'});
didn't work.
Maybe the datacursor is not yet implemented in appdesigner.
If I try to modify the tools and set less of them it works.
tb1 = axtoolbar(app.Axes,{'restoreview'});
Any solution?
Thank you

댓글 수: 6

Matthew Schmidt
Matthew Schmidt 2019년 5월 19일
I have seen a similar problem. it appears that 'datacursor', 'brush" and 'rotate' are not implemented yet. Would be nice if documentation were more clear on which of these buttons are implemented for app designer and which are not. I've wasted a bunch of time in app designer trying to get stuff like this to work. In my vew, help is not very good yet on showing clearly what is and is not available in app designer.
Mirko Maurici
Mirko Maurici 2019년 6월 17일
I agree, the help is not clear when the app designer is involved.
Bas Peters
Bas Peters 2019년 7월 17일
Thank you for this, I just spend a lot of time on the same problem. Let's hope it will be implemented soon.
Batnasan Byambasuren
Batnasan Byambasuren 2020년 4월 7일
I am having a same problem. It does not work in 2020a.
I need to get axes curtain point data when mouse clicked. Any suggestions?
Ajeya Gupta
Ajeya Gupta 2020년 10월 12일
Hi guys,
Did anyone get arrive at solution to this? I am looking to modify the appearance of Axes toolbar on Matlab's Appdesigner. I am currently using Matlab 2020a version.
Thanks
Ajeya
Thomas Nevalainen
Thomas Nevalainen 2021년 10월 14일
Hello friends,
Checking up on the status a year after Ajeya's comment, any progress on the issue yet? Can we get the devs involved to get word if the issue is being worked on?
Specifically, I'm trying to implement both 'brush' and 'datacursor' in a UIfigure using R2020b without any success with 'datacursor'.
Cheers!
Thomas

댓글을 달려면 로그인하십시오.

답변 (1개)

Aniket
Aniket 2024년 11월 21일

0 개 추천

As of R2023a, 'datacursor' mode can be used for apps created in App Designer and using the "uifgure" function.
As a workaround for versions prior to R2023a, you can make your own custom data tip button as follows:
axtoolbarbtn(tb,"state","Icon","datacursor","Tooltip","Data Tips",...
"ValueChangedFcn",@(e,d)datacursormode(ancestor(d.Source,'figure'),d.Value))
Please refer to the following R2023a release notes of “App Building”:
I hope this helps you achieve the functionality you want to implement.

카테고리

도움말 센터File Exchange에서 Simulink Functions에 대해 자세히 알아보기

제품

릴리스

R2019a

질문:

2019년 5월 16일

답변:

2024년 11월 21일

Community Treasure Hunt

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

Start Hunting!

Translated by