Changeset 19428
- Timestamp:
- 07/07/15 13:12:36 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/m/plot/applyoptions.py
r19424 r19428 2 2 from cmaptools import truncate_colormap 3 3 from plot_contour import plot_contour 4 from expdisp import expdisp5 4 6 5 try: 7 6 from matplotlib.ticker import MaxNLocator 8 7 from mpl_toolkits.axes_grid1 import make_axes_locatable 8 from mpl_toolkits.mplot3d import Axes3D 9 9 import matplotlib as mpl 10 10 import pylab as p … … 24 24 25 25 See also: PLOTMODEL, PARSE_OPTIONS 26 26 27 ''' 27 28 … … 133 134 134 135 #view 136 if int(md.mesh.dimension) == 3 and options.exist('layer'): 137 #options.getfieldvalue('view') ? 138 ax=fig.gca(projection='3d') 139 plt.show() 135 140 136 141 #axis {{{ … … 143 148 144 149 #box 150 if options.exist('box'): 151 eval(options.getfieldvalue('box')) 145 152 146 153 #xlim, ylim, zlim {{{ … … 173 180 174 181 #shading 182 if options.exist('shading'): 175 183 176 184 #grid {{{ … … 235 243 cb.set_label(options.getfieldvalue('colorbartitle'),fontsize=fontsize) 236 244 cb.ax.tick_params(labelsize=fontsize) 237 cb.solids.set_rasterized(True)238 245 cb.update_ticks() 239 cb.set_alpha(1)240 cb.draw_all()241 246 plt.sca(ax) # return to original axes control 242 247 #}}} 243 248 244 #expdisp {{{245 if options.exist('expdisp'):246 filename=options.getfieldvalue('expdisp')247 style=options.getfieldvalue('expstyle','k')248 linewidth=options.getfieldvalue('explinewidth',1)249 for i in xrange(len(filename)):250 filenamei=filename[i]251 stylei=style[i]252 if type(linewidth)==list:253 linewidthi=linewidth[i]254 else:255 linewidthi=linewidth256 expdisp(filenamei,ax,linestyle=stylei,linewidth=linewidthi,unitmultiplier=options.getfieldvalue('unit',1))257 #}}}258 259 249 #area 250 251 #expdisp 260 252 261 253 #text {{{
Note:
See TracChangeset
for help on using the changeset viewer.