Why is appdesigner toolbar not visible when visible is defined as 'on'?

Hello,
I am having trouble with Appdesigner toolbar.
First, is there a way to get it always be visible and not just when you hover over it with your mouse?
Second, despite when I define:
app.UIAxes.Toolbar.Visible = 'on'
the toolbar is not visible. I'm able to interact with it but it just disappears. Is there a fix?

8 Comments

The visibility is on by default which means that it becomes visible when you hover over it. I'm not sure what the fix is for uifigures.
Thanks for the response. Occasionally I'm able to hover and see the toolbar, but there are certain times that I hover and nothing pops up despite the visibility still being set to on. In the latter scenerio I'm able to click and still interact with zoom etc...I just can't see what I'm clocking on.
I'm just seeing if this is a general bug or is there something I can change in the code to make sure I can always see the toolbar when I hover.
I have never experienced that and it's certainly not a documented option for the axis toolbar. If the axes contain very many object that can slow down rendering and may affect the listeners that are responsible for revealing the toolbar but it should eventually appear when hovering in the right place.
You can contact tech support: Contact Us - MATLAB & Simulink
Hello, I have experienced the same issue (toolbar not showing upon hovering over an UIAxes component, but being able to zoom, drag the plot etc.).
A workaround that worked for me was to 'reset' the Toolbar Handle Visibility after creating a plot in the UIAxes like:
app.UIAxes.Toolbar.HandleVisibility = 'off'
app.UIAxes.Toolbar.HandleVisibility = 'on'
Thank you! I'm trying to accept your answer, but can't see how.
Have you tried to turn the HandleVisibility on and off after adding data to your UIAxes component, as I suggested in my previous answer?
If you still encounter the issue could you try to elaborate on your problem?
Thanks, I did and it works. My previous comment was referring to the 'Accept this Answer' option in the forum. Since you answered in the comments I'm unable to accept your answer.
Ah I see, glad it worked. I'll post my answer again below so it can be found more easily.

Sign in to comment.

 Accepted Answer

A workaround that worked for me was to 'reset' the Toolbar Handle Visibility after creating a plot in the UIAxes component like:
app.UIAxes.Toolbar.HandleVisibility = 'off'
app.UIAxes.Toolbar.HandleVisibility = 'on'

1 Comment

This didn't work for me, unfortunately (R2020a). Maybe because the axes contain an image instead of a plot...?

Sign in to comment.

More Answers (0)

Categories

Asked:

on 14 May 2021

Edited:

on 21 Nov 2021

Community Treasure Hunt

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

Start Hunting!