- Timestamp:
- Dec 13, 2013, 10:51:21 PM (11 years ago)
- Location:
- trunk/src
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/find_imadoc.m
r674 r701 17 17 XmlFileName=fullfile(RootPath,[SubDir(1:dotchar(end-idot+1)-1) '.xml']); 18 18 if exist(XmlFileName,'file') 19 SubDirBase=fullfile(RootPath,SubDir(1:dotchar(end-idot+1) ));19 SubDirBase=fullfile(RootPath,SubDir(1:dotchar(end-idot+1)-1)); 20 20 break 21 21 end -
trunk/src/get_field.m
r693 r701 97 97 check_singleton(idim)=isequal(Field.DimValue(dim_index),1);%check_singleton=1 for singleton 98 98 end 99 Field.Check0D(ilist)=(isequal(check_singleton,ones(1,NbDim)))||(~isequal(Field.VarType(ilist),4)&&~isequal(Field.VarType(ilist),5) );% =1 if the variable reduces to a single value99 Field.Check0D(ilist)=(isequal(check_singleton,ones(1,NbDim)))||(~isequal(Field.VarType(ilist),4)&&~isequal(Field.VarType(ilist),5)&&~isequal(Field.VarType(ilist),6));% =1 if the variable reduces to a single value 100 100 if ~Field.Check0D(ilist) 101 101 Field.Display.VarDimName{ilist}=Field.VarDimName{ilist}(~check_singleton);% eliminate singletons in the list of variable dimensions … … 495 495 y_index=get(handles.ordinate,'Value'); 496 496 y_menu=get(handles.ordinate,'String'); 497 if isempty(y_menu) 498 return 499 else 497 500 YName=y_menu{y_index}; 501 end 498 502 499 503 %% set list of possible coordinates -
trunk/src/mouse_motion.m
r699 r701 50 50 test_zoom_draw=0; 51 51 test_object=0; %test for object editing or creation 52 test_create_object=0; 52 53 test_edit_object=0;% edit test for mouse shape: an arrow 53 54 test_ruler=0;%test for active ruler … … 56 57 if ~isempty(huvmat) 57 58 hhuvmat=guidata(huvmat);%handles of the elements in uvma 59 test_create_object=strcmp(get(hhuvmat.MenuObject,'checked'),'on'); 58 60 test_edit_object=get(hhuvmat.CheckEditObject,'Value'); 59 61 test_ruler=isequal(get(hhuvmat.MenuRuler,'checked'),'on'); … … 109 111 test_zoom_draw=test_draw && isequal(AxeData.Drawing,'zoom')&& isfield(AxeData,'CurrentOrigin') && isequal(get(gcf,'SelectionType'),'normal'); 110 112 test_object=test_draw && isfield(AxeData,'CurrentObject') && ~isempty(AxeData.CurrentObject) && ishandle(AxeData.CurrentObject); 111 if ~test_edit_object && ~test_ruler 113 if CheckZoom 114 pointershape='zoom'; 115 elseif CheckZoomFig 116 pointershape='zoomfig'; 117 elseif ~test_edit_object && ~test_ruler 112 118 if CheckZoom 113 119 pointershape='zoom'; 114 elseif CheckZoomFig 115 pointershape='zoomfig'; 116 elseif test_draw 117 pointershape='crosshair';%set pointer with cross shape (default when mouse is over an axis) 120 elseif test_draw|| test_create_object 121 pointershape='crosshair';%set pointer with cross shape 118 122 else 119 pointershape='fullcross';%set pointer with cross shape(default when mouse is over an axis)123 pointershape='fullcross';%set pointer with large cross (default when mouse is over an axis) 120 124 end 121 125 end -
trunk/src/mouse_up.m
r699 r701 96 96 if size(ObjectData.Coord,1)==1 % this is the mouse up for the first point, continue until next click 97 97 check_multiple=1; 98 else99 %ObjectData.Coord=[ObjectData.Coord ;CurrentOrigin];% append the second point of the line (the last pointed position during mouse down)100 98 end 101 99 case {'rectangle','ellipse','volume'} 102 % if size(ObjectData.Coord,1)==1 % this is the mouse up for the first point, continue until next click103 % check_multiple=1;104 % else105 100 ObjectData.Coord=(CurrentOrigin+xy(1,1:2))/2;% keep only the first point coordinate 106 101 ObjectData.RangeX=abs(ObjectData.Coord(1,1)-xy(1,1));%rectangle width … … 109 104 check_multiple=1;% pass to next mous up if width of height=0 110 105 end 111 % ObjectData.Coord(1,1)=(xy(1,1)+XYData(1))/2;%origin rectangle, x coordinate112 % ObjectData.Coord(1,2)=(xy(1,2)+XYData(2))/2;113 % ObjectData.RangeX=abs(xy(1,1)-XYData(1))/2;%rectangle width114 % ObjectData.RangeY=abs(xy(1,2)-XYData(2))/2;%rectangle height115 % end116 106 case 'plane' %case of 'plane' 117 107 DX=(xy(1,1)-ObjectData.Coord(1,1)); … … 130 120 131 121 %show object coordinates in the GUI set_object 132 % h_set_object=findobj(allchild(0),'Tag','set_object');133 % hh_set_object=guidata(h_set_object);134 % set(hh_set_object.Coord,'Data',ObjectData.Coord);135 122 if strcmp(ObjectData.Type,'rectangle')||strcmp(ObjectData.Type,'ellipse') 136 123 set(hh_set_object.num_RangeX_2,'String',num2str(ObjectData.RangeX,4)); … … 179 166 end 180 167 set(hhuvmat.CheckViewField,'Value',1);% 181 set(hhuvmat.CheckEditObject,'Value',1);% 168 set(hhuvmat.CheckEditObject,'Value',1);% 169 set(hhuvmat.MenuObject,'checked','off'); %desactivate object creation mode 182 170 set(hhuvmat.CheckEditObject,'Enable','on');% 183 171 set(get(h_set_object,'children'),'Enable','on') -
trunk/src/uvmat.m
r699 r701 1953 1953 Field_a=transform(Field_a,UvData.XmlData{index});%the first field has been stored without transform 1954 1954 end 1955 if nargin(transform)>=2 1955 1956 Field_b=transform(Field_b,UvData.XmlData{index}); 1957 else 1958 Field_b=transform(Field_b); 1959 end 1956 1960 end 1957 1961 end … … 4242 4246 if get(handles.CheckEditObject,'Value') 4243 4247 %suppress the other options 4248 set(handles.MenuObject,'checked','off') 4244 4249 set(handles.CheckZoom,'Value',0) 4245 4250 CheckZoom_Callback(hObject, eventdata, handles) … … 4390 4395 if ishandle(hdisplay(iview)) && ~isequal(hdisplay(iview),0) 4391 4396 ObjectData=get(hdisplay(iview),'UserData'); 4392 if isfield(ObjectData,'SubObject') && ishandle(ObjectData.SubObject)4393 delete(ObjectData.SubObject );% delete the graphic 'sub-objects (e.g. projection bounds)4397 if isfield(ObjectData,'SubObject') && ~isempty(ObjectData.SubObject) 4398 delete(ObjectData.SubObject(ishandle(ObjectData.SubObject)));% delete the graphic 'sub-objects (e.g. projection bounds) 4394 4399 end 4395 check_suppress= isfield(ObjectData,'DeformPoint') && ishandle(ObjectData.DeformPoint); 4396 delete(ObjectData.DeformPoint(check_suppress));% delete the graphic deformation points 4397 delete(hdisplay(iview))% delete the main graphic representation of the object 4400 if isfield(ObjectData,'DeformPoint')&& ~isempty(ObjectData.DeformPoint) 4401 delete(ObjectData.DeformPoint(ishandle(ObjectData.DeformPoint)));% delete the graphic deformation points 4402 delete(hdisplay(iview))% delete the main graphic representation of the object 4403 end 4398 4404 end 4399 4405 ishandle(hdisplay(iview)) … … 4713 4719 set(handles.CheckZoomFig,'Value',0) %desactivate zoom sub fig 4714 4720 set(handles.CheckZoom,'Value',0) %desactivate the zoom action 4721 set(handles.MenuObject,'checked','on')% indicate object creation for mouse pointer display 4715 4722 if ishandle(handles.UVMAT_title) 4716 4723 delete(handles.UVMAT_title) %delete the initial display of uvmat if no field has been entered yet
Note: See TracChangeset
for help on using the changeset viewer.