figure versus uifigure the best way to manage complex gui

26 ビュー (過去 30 日間)
Alain Barraud
Alain Barraud 2022 年 7 月 6 日
コメント済み: Alain Barraud 2022 年 7 月 6 日
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 件のコメント
Bruno Luong
Bruno Luong 2022 年 7 月 6 日
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.

サインインしてコメントする。

採用された回答

Walter Roberson
Walter Roberson 2022 年 7 月 6 日
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 件のコメント
Yair Altman
Yair Altman 2022 年 7 月 6 日
編集済み: Yair Altman 2022 年 7 月 6 日
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).

サインインしてコメントする。

その他の回答 (1 件)

Alain Barraud
Alain Barraud 2022 年 7 月 6 日
yes me too about uitable, althought using java similar result can be obtained. Uitree is also very useful with uifigure. I have not be able to have similar aesthetic results with figure (widget toolbox). Why not uifigure I hope better speed in the future.
  4 件のコメント
Yair Altman
Yair Altman 2022 年 7 月 6 日
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.
Alain Barraud
Alain Barraud 2022 年 7 月 6 日
Yes you are right. Adding to your code
mtree.Tree.setBackground(java.awt.Color(0,.8,1))
do the job. The nodes remain white OK. (I don't remember how to access to the Nodes properties)

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeDevelop uifigure-Based Apps についてさらに検索

製品


リリース

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by