figure versus uifigure the best way to manage complex gui
27 views (last 30 days)
Show older comments
Alain Barraud
on 6 Jul 2022
Commented: Alain Barraud
on 6 Jul 2022
I am currently writing complex gui for scientific computation app which must be compatible both with figure and uifigure. My experience is that using uifigue the gui is always very time consuming to build and drag and drop is not reactive. Moreovers save gui as a *.fig may take 15 ~ 20 mn and when openfig is executed to come back at the state where user exit the app, does not work except for basic interface tests.
Using figure all is right. My question is the following what is the goal of mathworks in the future. I use matlab since 1984 it was an extraordinary tool. Nice gui is today a necessary step when developping large engineering app. It is always a difficult task, java customization helps very much. Waterloo toolbox is a good exemple. Why to abandon this approach? The beautiful functions inluded within gui layout toolbox should be directly included within matlab. Web oriented figure is a specifig goal, if figure could support the new uifigure facilities it would be perfect!
Is there some subtilities to know to have better experience with uifigure.
Using matlab is very easy, learning java was not trivial and now with uifigure it would be necessary to learn javascript....?
Best regards
1 Comment
Bruno Luong
on 6 Jul 2022
Let me guess : you would never get an answer from TMW folks on their roadmap.
To me the only reason I would use uifigure is if you are interested in embeded the components that are not supported in stadard figure. They look more modern. Personaly I use the uitable with great features.
Otherwise I would stick with figure.
Accepted Answer
Walter Roberson
on 6 Jul 2022
I do not know why uifigure is so much slower than traditional figures. I know people have been grumbling about that for years, and I know the current situation is better than it used to be.
With regards to "Why?":
One of the reasons is that Mathworks is trying to remove dependency on Java. There are a couple of reasons for this:
- industry has been finding Java too slow and not flexible enough for modern use
- Oracle put in a per-desktop end-user license charge to use Java. As a result, a lot of companies are getting out of Java as soon as they can, so that end users do not have to pay Oracle to use products such as MATLAB. Mathworks uses the last no-charge version of Java Development Kit
1 Comment
Yair Altman
on 6 Jul 2022
Edited: Yair Altman
on 6 Jul 2022
In addition to the wish to avoid Java, basing the UI on web technologies (HTML, CSS, JavaScript) will enable users to use MathWorks products on any platform that supports a Chrome browser, and this has significant potential benefits. For example, in the future we could use Matlab on smartphones, tablets, and other platforms that do not currently support Matlab (we can use Matlab Online already, with some limitations - over time I expect these limitations will decrease). MathWorks is still not quite there with the conversion (it's an enormous development effort), but the path forward is quite clear. And indeed, performance is indeed a problem (getting better with each new release, though).
More Answers (1)
Alain Barraud
on 6 Jul 2022
4 Comments
Yair Altman
on 6 Jul 2022
I'm pretty certain that you can change the Java uitree's background color, separately from each node's color. Just update the Background property of the main tree control.
See Also
Categories
Find more on Develop uifigure-Based Apps in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!