diff src/graphics.cc @ 11168:36442102c340

Fix treatment of facevertexcdata if facecolor is 'none' with the fltk backend
author David Bateman <dbateman@free.fr>
date Fri, 29 Oct 2010 21:46:58 +0200
parents 51ac3a08e53c
children c0a95a5c6d25
line wrap: on
line diff
--- a/src/graphics.cc	Thu Oct 28 14:12:46 2010 +0200
+++ b/src/graphics.cc	Fri Oct 29 21:46:58 2010 +0200
@@ -4966,8 +4966,11 @@
 octave_value
 patch::properties::get_color_data (void) const
 {
-  return convert_cdata (*this, get_facevertexcdata (),
-                        cdatamapping_is ("scaled"), 2);
+  octave_value fvc = get_facevertexcdata();
+  if (fvc.is_undefined () || fvc.is_empty ())
+    return Matrix ();
+  else
+    return convert_cdata (*this, fvc,cdatamapping_is ("scaled"), 2);
 }
 
 // ---------------------------------------------------------------------