Changeset 78 for trunk/src/mouse_up.m
- Timestamp:
- Apr 2, 2010, 9:01:21 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/mouse_up.m
r71 r78 262 262 263 263 % editing calibration point 264 if strcmp(MouseAction,'calib') 265 hh=findobj(currentaxes,'Tag','calib_points')%look for handle of calibration points 266 if ~isempty(hh) 264 if ~zoomstate strcmp(MouseAction,'calib') 265 h_geometry_calib=findobj(allchild(0),'Name','geometry_calib'); %find the geomterty_calib GUI 266 hh_geometry_calib=guidata(h_geometry_calib); 267 edit_test=get(hh_geometry_calib.edit_append,'Value'); 268 hh=findobj(currentaxes,'Tag','calib_points');%look for handle of calibration points 269 if ~isempty(hh) && edit_test 270 index_point=get(hh,'UserData'); 267 271 set(hh,'UserData',[])%remove edit mode 268 h_geometry_calib=findobj(allchild(0),'Name','geometry_calib'); %find the geomterty_calib GUI269 hh_geometry_calib=guidata(h_geometry_calib);270 272 h_ListCoord=hh_geometry_calib.ListCoord; %handles of the coordinate list 271 273 Coord=get(h_ListCoord,'String'); 272 val=get(h_ListCoord,'Value');273 coord_str=Coord{ val}; %current line (string)274 % val=get(h_ListCoord,'Value'); 275 coord_str=Coord{index_point}; %current line (string) 274 276 k=findstr('|',coord_str);%find separator indices on the string 275 277 xy=get(currentaxes,'CurrentPoint');%xy(1,1),xy(1,2): current x,y positions in axes coordinates … … 279 281 coord_str=[ ' | ' ' | ' ' | ' num2str(xy(1,1),4) ' | ' num2str(xy(1,2),4)]; 280 282 end 281 Coord{ val}=coord_str;283 Coord{index_point}=coord_str; 282 284 set(h_ListCoord,'String',Coord) 285 data=read_geometry_calib(Coord);%transform char cell to numbers 286 set(hh,'XData',data.Coord(:,4)) 287 set(hh,'YData',data.Coord(:,5)) 283 288 end 284 289 end
Note: See TracChangeset
for help on using the changeset viewer.