uicontrol('style','slider') in new App Design (uifigure)
Ältere Kommentare anzeigen
Dear Community,
I want to migrate an old-style GUI containing many uicontrols to the new app design based on uifigure.
How can I replace scrollbar-like 'uicontrol('style', 'slider')' with an object that has similar properties and may consist of a uislider and two single step buttons? Has anyone already developed a class object that uses all the properties of uislider, such as the overall position of the object and the single step button feature at both ends of the uislider?
Are alternatives available?
Antworten (1)
Taylor
am 13 Nov. 2025
0 Stimmen
Have you tried the GUIDE to App Designer Migration Tool? There is also a slider/spinner component in the Widgets Toolbox Add-On that is pretty close to what you're describing.
4 Kommentare
Andre Zeug
am 14 Nov. 2025
Taylor
am 14 Nov. 2025
No, the Migration Tool will only work if you originally created the app with GUIDE.
That documentation link you sent will work after you install the add-on in MATLAB and open that GettingStarted.mlx file in the Editor.
There are definitely some limitations around component sizes, but I would recommend looking at grid layouts and apps with auto reflow. Both of those are useful for managing the layout of the app.
Andre Zeug
am 15 Nov. 2025
Bearbeitet: Andre Zeug
am 16 Nov. 2025
Taylor
am 19 Nov. 2025
You should look into creating your own custom component. You can combine one uislider and two uispinner components in your own custom component that does exactly what you want.
When you compile your "matVis" application, if you include the files for any components used in the Widgets Toolbox, your end user will not need to install the Widgets Toolbox.
Kategorien
Mehr zu Develop Apps Programmatically finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

