Changeset 682 for trunk/src/mouse_up.m
- Timestamp:
- Sep 2, 2013, 7:44:19 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/mouse_up.m
r681 r682 25 25 26 26 test_ruler=0;%default 27 AxeData=get(gca,'UserData'); 27 hcurrentaxes=get(hObject,'CurrentAxes'); 28 if isempty(hcurrentaxes) 29 return % no axes in the current figure 30 end 31 AxeData=get(hcurrentaxes,'UserData'); 28 32 if isfield(AxeData,'ParentAxes')% case of a zoom plot as current axis 29 33 hcurrentaxes=AxeData.ParentAxes; … … 33 37 else 34 38 hcurrentfig=hObject; 35 hcurrentaxes=gca; %store the current axes handle36 39 testsubplot=0; 37 40 end … … 54 57 return 55 58 end 56 xy=get( gca,'CurrentPoint');%xy(1,1),xy(1,2): current x,y positions in axes coordinates59 xy=get(hcurrentaxes,'CurrentPoint');%xy(1,1),xy(1,2): current x,y positions in axes coordinates 57 60 58 61 … … 60 63 if ~isempty(huvmat) && isfield(AxeData,'Drawing') && ~isequal(AxeData.Drawing,'off') && isfield(AxeData,'CurrentObject')... 61 64 && ~isempty(AxeData.CurrentObject) && ishandle(AxeData.CurrentObject) 62 % xy=get(currentaxes,'CurrentPoint');%xy(1,1),xy(1,2): current x,y positions in axes coordinates63 65 PlotData=get(AxeData.CurrentObject,'UserData');%get data attached to the current projection object 64 66 IndexObj=PlotData.IndexObj; … … 247 249 ChildAxeData.ParentAxes=hcurrentaxes; 248 250 ChildAxeData.ParentRect=AxeData.CurrentRectZoom;%set the rectangle drawing as a 'parent' associated to the new axe 249 %PosRect=CurrentOrigin;250 % xy=get(hcurrentaxes,'CurrentPoint');%xy(1,1),xy(1,2): current x,y positions in axes coordinates251 251 if xy(1,1)>CurrentOrigin(1) 252 252 set(AxeData.ZoomAxes,'Xlim',[CurrentOrigin(1) xy(1,1)]) … … 343 343 h_ListCoord=hh_geometry_calib.ListCoord; %handles of the coordinate list 344 344 Coord=get(h_ListCoord,'Data'); 345 % data=read_geometry_calib(Coord);346 % val=get(h_ListCoord,'Value');347 % xy=get(hcurrentaxes,'CurrentPoint');%xy(1,1),xy(1,2): current x,y positions in axes coordinates348 345 Coord(index_point,4)=xy(1,1); 349 346 Coord(index_point,5)=xy(1,2); 350 347 set(h_ListCoord,'Data',Coord) 351 % for ipoint=1:size(Coord,1)352 % for jcoord=1:5353 % Coord_cell{ipoint,jcoord}=num2str(data.Coord(ipoint,jcoord),4);%display coordiantes with 4 digits354 % end355 % end356 % Tabchar=cell2tab(Coord_cell,' | ');357 % Tabchar=[Tabchar ;{'......'}];358 % set(h_ListCoord,'String',Tabchar)359 348 set(hh,'XData',Coord(:,4)) 360 349 set(hh,'YData',Coord(:,5))
Note: See TracChangeset
for help on using the changeset viewer.