Restore toolbar buttons to app after migration from GUIDE

3 views (last 30 days)
After using the Guide-to-AppDesigner migration tool, my app no longer has the standard figure toolbar buttons in the app figure window. Moreover, since the figure has now become a uifigure, it seems impossible to give it a toolbar (correct me if I'm wrong).
The app does contain a uiaxes, and I'd be satisfied if I could have a standard toolbar local to this uiaxes. However, the uiaxes.Toolbar property is empty, perhaps as a side-effect of the migration tool. When I attempt to install the toolbar manually with this line,
handles.ImageAxes.Toolbar=axtoolbar(handles.ImageAxes,'default');
in the OpeningFcn created by the migration tool, the toolbar does indeed appear (see below), but is completely non-functional. None of the buttons do anything. This may be because axtoolbar creates the buttons but does not (correct me if I'm wrong) populate the buttons with their standard callbacks. Is there a simple way to install a fully functional default toolbar in a uiaxes or uifigure?
  1 Comment
Matt J
Matt J on 23 Nov 2021
Edited: Matt J on 23 Nov 2021
A possibly related problem is that when I open the attached mlapp in appdesigner's Design VIew and activite the "Toolbar Visible" checkbox for the UIAxes, it does not stay checked. If I save and reopen the app, the "Toolbar Visible" checkbox is unchecked again. Are there rules about toolbars in app components that I just don't understand ???

Sign in to comment.

Answers (1)

Matt J
Matt J on 4 Dec 2021
Mathworks Tech Support claims this has been fixed in R2020b.

Categories

Find more on Develop Apps Using App Designer in Help Center and File Exchange

Products


Release

R2020a

Community Treasure Hunt

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

Start Hunting!