Changeset 22924
- Timestamp:
- 07/13/18 14:11:02 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/m/plot/applyoptions.m
r22593 r22924 266 266 end 267 267 268 %shpdisp 269 if exist(options,'shpdisp'), 270 filename=(getfieldvalue(options,'shpdisp')); 271 style=(getfieldvalue(options,'shpstyle',{'r.-'})); 272 linewidth=(getfieldvalue(options,'linewidth',1)); 273 for i=1:length(getfieldvalue(options,'shpdisp')), 274 filenamei=filename{i}; 275 stylei=style{i}; 276 if length(linewidth)==1, 277 linewidthi=linewidth; 278 else 279 linewidthi=linewidth{i}; 280 end 281 %shpdisp(filenamei,'linestyle',stylei,'linewidth',linewidthi,'multiplier',getfieldvalue(options,'unit',1)); 282 shpdisp(filenamei,1,stylei,linewidthi,getfieldvalue(options,'unit',1)); 283 end 284 end 285 286 287 268 288 %text (default value is empty, not NaN...) 269 289 if exist(options,'text'); … … 274 294 textposition=getfieldvalue(options,'textposition'); 275 295 textrotation=getfieldvalue(options,'textrotation'); 296 text3d=getfieldvalue(options,'text3d',0); 276 297 for i=1:length(getfieldvalue(options,'text')); 277 298 textstringi=textstring{i}; … … 281 302 textpositioni=textposition{i}; 282 303 textrotationi=textrotation{i}; 283 h=text(textpositioni(1),textpositioni(2),10,textstringi,'FontSize',textsizei,'FontWeight',textweighti,'Color',textcolori,'Rotation',textrotationi); 304 if ~text3d, 305 h=text(textpositioni(1),textpositioni(2),textstringi,'FontSize',textsizei,'FontWeight',textweighti,'Color',textcolori,'Rotation',textrotationi); 306 else 307 h=text(textpositioni(1),textpositioni(2),textpositioni(3),textstringi,'FontSize',textsizei,'FontWeight',textweighti,'Color',textcolori,'Rotation',textrotationi); 308 end 284 309 if strcmpi(getfieldvalue(options,'textclip','on'),'on'), 285 310 set(h,'Clipping','on'); %prevent text from appearing outside of the box … … 312 337 if exist(options,'contourlevels'), 313 338 plot_contour(md,data,options); 339 end 340 341 %coastlines 342 if exist(options,'coastline')| exist(options,'coastlines'), 343 plot_coastlines(md.mesh,options); 314 344 end 315 345
Note:
See TracChangeset
for help on using the changeset viewer.