Files
matlab-learning/kongjian5.m
2025-10-24 11:42:36 +08:00

4 lines
227 B
Matlab

h1=uicontrol(gcf,'Style','listbox','String','red|blue|green|yellow|white',...
'Position',[100,100,100,80],'Callback',...
['cbcol=[''r'',''b'',''g'',''y'',''w''];',...
'set(gcf,''color'',cbcol(get(h1,''Value'')))']);