GUI Problem with uipanel+axes+hist3() using GUIDE

1 次查看(过去 30 天)
Hello everbody,
I am having trouble with functions like hist3() using axes within uipanels. To give a simple example:
I create a new GUI with GUIDE (errorGUI.fig,errorGUI.m) and add a new uipanel called "uipanel1". In this panel I add an axes called "axes1".
Now I write the following code in the OpeningFcn of the m-File:
% Just a simple example: random matrix and hist3() function
A=rand(20,2);
hist3(handles.axes1, A);
If I save and run the changes I get the following errors:
--------------------------------------------------------------------------------------
Error using hg.uipanel/set The name 'renderer' is not an accessible property for an instance of class 'uipanel'.
Error in hist3 (line 297) set(get(cax,'parent'),'renderer','zbuffer');
Error in error_GUI>error_GUI_OpeningFcn (line 66) hist3(handles.axes1, A);
Error in gui_mainfcn (line 221) feval(gui_State.gui_OpeningFcn, gui_hFigure, [], guidata(gui_hFigure), varargin{:});
Error in error_GUI (line 42) gui_mainfcn(gui_State, varargin{:});
--------------------------------------------------------------------------------------
If I delete the uipanel and simple use axes1 inside the figure, everything works fine. But I really need panels containing several different axes inside.
Can anyone tell me what I have to do to make it work? Thank you very much in advance!

回答(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