# HG changeset patch # User Daniel J Sebald # Date 1463208480 18000 # Node ID e6fcaea7d43380a2f696d385e37fb80e0e8122d1 # Parent 21fdab18f85726684b1dcfbf529fc60508412839 Properly handle 'flat' face color for gnuplot graphics toolkit (bug #47911). * __gnuplot_draw_axes__.m: Get color from obj.cdata in case of 'flat' facecolor in addition to 'none' or [1 1 1]. Remove gnuplot style qualifier 'linecolor rgb variable' in the case of 'flat' facecolor. diff -r 21fdab18f857 -r e6fcaea7d433 scripts/plot/util/private/__gnuplot_draw_axes__.m --- a/scripts/plot/util/private/__gnuplot_draw_axes__.m Fri May 13 18:59:29 2016 -0500 +++ b/scripts/plot/util/private/__gnuplot_draw_axes__.m Sat May 14 01:48:00 2016 -0500 @@ -1174,14 +1174,13 @@ zz(:,kk) = xdat(:,k); zz(:,kk+1) = ydat(:,k); zz(:,kk+2) = zdat(:,k); - zz(:,kk+3) = cdat(:,k); - if (facecolor_none_or_white) + if (flat_interp_face || facecolor_none_or_white) zz(:,kk+3) = cdat(:,k); else ## Convert color to 24-bit RGB zz(:,kk+3) = hex2dec (sprintf ("%02x%02x%02x", round (255*obj.facecolor))); - endif + endif k += 1; endfor data{data_idx} = zz.'; @@ -1229,7 +1228,12 @@ endif else hidden_removal = true; - withclause{data_idx} = sprintf ("with pm3d linecolor rgb variable"); + if (flat_interp_face) + color_source = ""; + else + color_source = " linecolor rgb variable"; + endif + withclause{data_idx} = sprintf ("with pm3d%s", color_source); if (doing_interp_color) ## "depthorder" interferes with interpolation of colors.