Launch a desktop layout programmatically

조회 수: 8 (최근 30일)
Matt J
Matt J 2025년 5월 12일
댓글: TED MOSBY 2025년 5월 17일
In the Environment seciton of the desktop's Home Tab, there is an area for saving and loading one's preferred desktop layouts:
What I'd like to know is, once you've created and saved a desktop layout, is there a way to launch it programmatically?

채택된 답변

TED MOSBY
TED MOSBY 2025년 5월 13일
Hi Matt,
As I understand from your question, you want to launch a saved desktop layout programmatically. For that you can run the commands shown below in MATLAB command window:
desktop = com.mathworks.mde.desk.MLDesktop.getInstance;
desktop.restoreLayout('fav');
Here "fav" is the name of the layout you had saved. Please note the commands are case senstitive.
Hope this helps!
  댓글 수: 4
TED MOSBY
TED MOSBY 2025년 5월 13일
편집: TED MOSBY 2025년 5월 13일

It doesn't show such warning in my editor though but let me see some other workaround

TED MOSBY
TED MOSBY 2025년 5월 17일
Couldnt find any other workaround, but you can use this for the time being!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Environment and Settings에 대해 자세히 알아보기

태그

제품


릴리스

R2024b

Community Treasure Hunt

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

Start Hunting!

Translated by