I created a function that contains the following commands:
function f = stacktestf = figure; h = [];h(2) = uicontrol('pos', [120 20 60 20]);h(3) = uicontrol('pos', [120 20 60 20]);h(4) = uicontrol('pos', [120 20 60 20]);set(h(2),...'style','frame',... 'back', 'white', ... 'pos',[5 5 100 200]);set(h(3),... 'style','edit',... 'back', 'red', ...'string','edit',...'pos',[10 10 80 30]);set(h(4),... 'style','text',... 'back', 'green', ...'string','text',...'pos',[10 60 80 30]);
When I execute the function, the edit uicontrol is not visible, until I manually resize the figure. If I execute the commands line by line with the debugger, then the edit uicontrol is visible.
Best Answer