# HG changeset patch # User Rik # Date 1544772234 28800 # Node ID 23b56a61c91880516c33bacf7c7a9209add11e7d # Parent 59bc720d1bf90315760577744ee50d78d9ca6b31 Force line() with a single point to display '.' (bug #38825). * __line__.m: If line has only a single point then force a marker style of '.'. diff -r 59bc720d1bf9 -r 23b56a61c918 scripts/plot/draw/private/__line__.m --- a/scripts/plot/draw/private/__line__.m Thu Dec 13 22:58:37 2018 -0800 +++ b/scripts/plot/draw/private/__line__.m Thu Dec 13 23:23:54 2018 -0800 @@ -115,7 +115,7 @@ endif ## Convert logical or complex inputs - if (islogical (tmpdata)) + if (islogical (tmpdata)) tmpdata = uint8 (tmpdata); elseif (iscomplex (tmpdata)) tmpdata = real (tmpdata); @@ -140,6 +140,11 @@ ## or linestyle. The plot will be made correctly, but the next ## call to line may not use the correct value. [linestyle, marker] = __next_line_style__ (); + if (nr == 1) + ## Marker for a single point is always '.' (bug #38825). + marker = '.'; + endif + keyboard; color = __next_line_color__ (); handles(i) = __go_line__ (hp, data_args{:},