Commit 1697048f authored by LAMBERT Jean-charles's avatar LAMBERT Jean-charles

add properties for 2dplot circles

parent 003c2088
......@@ -753,8 +753,15 @@ class C2dplot:
img=ax.imshow(zd , origin='lower',cmap=cmap, norm = matplotlib.colors.LogNorm(),extent=[view_xmin, view_xmax, view_ymin, view_ymax])
if self.__circle!="" :
for radius in self.__circle.split(","):
cc=plt.Circle((0.,0.),float(radius),color='r',fill=False)
for prop in self.__circle.split(","):
radius=prop.split("%")
lstyle="solid"
color="red"
if len(radius) > 1:
color=radius[1].split("#")
if len(color) > 1:
lstyle=color[1]
cc=plt.Circle((0.,0.),float(radius[0]),color=str(color[0]),linestyle=lstyle,fill=False)
ax.add_artist(cc)
#cax=fig.add_axes(np.linspace(np.log(zd.min()),np.log(zd.max()),4))
......@@ -807,7 +814,8 @@ def commandLine():
parser.add_argument('--noxz',help='no XZ projection',dest="noxz", action="store_true", default=False)
parser.add_argument('--nopart',help='not display particles number',dest="nopart", action="store_true", default=False)
parser.add_argument('--contour',help='toggle iso contour display',dest="contour", action="store_true", default=False)
parser.add_argument('--circle',help='Draw circles with given radius[,radius1,radius2] centered in 0,0,0. ',dest="circle", default="", type=str)
parser.add_argument('--circle',help='Draw circles with given radius{%%color#linestyle}[,radius1,radius2] centered in 0,0,0.'
'Eg. 1.5%%red#dashed,2.6%%yellow#dotted, use real name for color, like red,yellow etc.., possible linestyle={solid,dashed,dashdot,dotted} ',dest="circle", default="", type=str)
parser.add_argument('--nc',help='#levels contour',default=20,type=int)
parser.add_argument('--cpt', help="index of the image (out.cpt.jpg)",default=0,type=int)
parser.add_argument('--verbose',help='verbose mode',dest="verbose", action="store_true", default=False)
......
......@@ -82,7 +82,7 @@ class build_py(_build_py, object):
#
MAJOR = '0'
MINOR = '0'
MICRO = '5'
MICRO = '6'
VERSION = '%s.%s.%s' % (MAJOR, MINOR, MICRO)
#
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment