Changeset 1303
- Timestamp:
- 07/13/09 11:55:36 (15 years ago)
- Location:
- issm/trunk/src/m/classes/public/plot
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/src/m/classes/public/plot/applyoptions.m
r1262 r1303 22 22 23 23 %title 24 if ~isnan(options_structure.title),24 if iscell(options_structure.title), 25 25 title(options_structure.title,'FontSize',fontsize,'FontWeight',fontweight); 26 else 27 if ~isnan(options_structure.title), 28 title(options_structure.title,'FontSize',fontsize,'FontWeight',fontweight); 29 end 26 30 end 27 31 … … 103 107 if ~isnan(options_structure.colorbar), 104 108 if options_structure.colorbar, 105 c=colorbar; 109 c=colorbar;set(c,'FontSize',fontsize); 106 110 if ~isnan(options_structure.wrapping) 107 111 lim=get(c,'Ylim'); … … 112 116 set(c,'Position',options_structure.colorbarpos); 113 117 end 118 if ~isnan(options_structure.log), 119 logvalue=options_structure.log; 120 121 scalestring=get(c,'YTickLabel'); 122 scalevalues=get(c,'YTick'); 123 scaleminmax=caxis; 124 numvalues=length(scalevalues); 125 126 scalestring=[]; 127 for i=1:numvalues, 128 fraction=(scalevalues(i)-scaleminmax(1))/(scaleminmax(2)-scaleminmax(1)); 129 scalevalues(i)=round_ice(logvalue^scalevalues(i),2); 130 scalestring=[scalestring; sprintf('%8.4g',scalevalues(i))]; 131 end 132 set(c,'YTickLabel',scalestring); 133 set(c,'FontSize',fontsize); 134 end 114 135 elseif ~options_structure.colorbar, 115 136 colorbar('off'); 116 137 end 117 138 else 118 c=colorbar; 139 c=colorbar;set(c,'FontSize',fontsize); 119 140 if ~isnan(options_structure.wrapping) 120 141 lim=get(c,'Ylim'); -
issm/trunk/src/m/classes/public/plot/parse_options.m
r1124 r1303 213 213 titlevalues=findarg(optionstring,'title'); 214 214 if ~isempty(titlevalues), 215 if ischar(titlevalues.value) ,215 if ischar(titlevalues.value) | iscell(titlevalues.value), 216 216 options_struct.title=titlevalues.value; 217 217 else
Note:
See TracChangeset
for help on using the changeset viewer.