- Open the App in which your custom icon is present.
- By using ‘findall’ save all graphic objects handles.
- Save ‘CData’ of require icon into a new variable by indexing to the require graphic object’s CData.
- Save this new variable as ‘.mat’ file.
- Import this ‘.mat’ in ‘iconeditor’ of GUIDE to use you customized icon.
How to save an icon made in GUIDE toolbar editor?
조회 수: 2 (최근 30일)
이전 댓글 표시
I have an icon, made by myself, in one of my (GUIDE) programs. I would like to have the same icon in another program. I could not find out how to copy, save the icon I already have. Only import is possible, save is not possible.
Also I could not copy CData through "Inspector".
Is there any way?
댓글 수: 0
답변 (1개)
Payas Bahade
2019년 11월 28일
Hi Csaba,
Custom icon made in icon editor of GUIDE can be saved by following steps mentioned below:
Sample Code:
myApp; % Opening App which as customized icon which needs to be saved for resuse
h=findall(myApp); % Saving all graphic object handles of App ‘myApp’ into ‘h’
iCData=h(4).CData; % Indexing to required graphic object and saving it's CData into variable 'iCData'
save('myIcon.mat','iCData')% Saving variable 'iCData' as 'myIcon.mat'
Hope this helps!
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Migrate GUIDE Apps에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!