I have created a GUI in MATLAB 7.0 (R14) that features a number of uicontrol objects stacked on top of each other. When I set the uicontrol properties after creating the uicontrols, the uicontrol objects are not displayed in the correct stacking order. The following example code produces an editable text box on top of a frame; however the frame is displayed above the text box:
h = [];h(1) = figure;h(2) = uicontrol;h(3) = uicontrol;h(4) = uicontrol;set(h(2),...'style','frame',...'pos',[5 5 100 200])set(h(3),...'style','edit',...'string','edit',...'pos',[10 10 80 30])set(h(4),...'style','text',...'string','text',...'pos',[10 60 80 30])
Best Answer