필터 지우기
필터 지우기

GUI - automatically delete code related to deleted GUI elements

조회 수: 6 (최근 30일)
Christian
Christian 2018년 5월 22일
댓글: Christian 2018년 5월 22일
Hello everyone,
I’m currently „building“ a GUI and there is one thing which bothers me all the time! Since the interface of my GUI is not 100% final yet, I delete push buttons, static texts, edit texts etc. several times in a week. Until today I haven’t found a workaround to delete the corresponding code in the .m-file automatically, so I was wondering if Matlab 2017 offers any kind of feature to delete the corresponding code when I delete an element of the GUI?
Thank you in advance and have a nice one! Christian

채택된 답변

Jan
Jan 2018년 5월 22일
This cannot work reliably and automatically at the same time. Remember that GUIDE cannot know, if a callback is used from anywhere else in the code. While a direct call could be identified automatically, you could hide it in feval or eval. Therefore I assume, that you have to remove the code manually.
I'm using GUIDE to design my GUIs. But as soon, as the layout is ready, I convert the figure to code. See e.g. https://www.mathworks.com/matlabcentral/fileexchange/20152-guidegetter.
  댓글 수: 1
Christian
Christian 2018년 5월 22일
That tool looks really promissing! I'll give it a try, thank you Jan!

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Migrate GUIDE Apps에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by