MATLAB: Does setting the propoerties for a CONTOURF object generate errors in MATLAB 7.4 (R2007a) when it worked fine in earlier releases

edgecolorMATLAB

I have generated plots in MATLAB 6.5.2 (R13SP2) using the CONTOURF command. After generating the plots I have changed the Facecolor Property using
set(handle,'Facecolor','none').
The command works fine in MATLAB 6.5.2 (R13SP2) but gives the following error in more recent versions such as MATLAB 7.4 (R2007a).
There is no 'Facecolor' property in the 'contourgroup' class

Best Answer

Starting with MATLAB 7.4 (R2007a), the CONTOURF plot creates an HGGROUP object for which there is no FaceColor Property. The children of the HGGROUP object are Patch objects, which do have FaceColor properties. Thus, in order to set the Facecolor property, obtain the handle to the contour object using code such as the example below:
children = get(handle_contour,'Children');
set(children,'FaceColor', 'none');