Index: /trunk/src/find_imadoc.m
===================================================================
--- /trunk/src/find_imadoc.m	(revision 700)
+++ /trunk/src/find_imadoc.m	(revision 701)
@@ -17,5 +17,5 @@
         XmlFileName=fullfile(RootPath,[SubDir(1:dotchar(end-idot+1)-1) '.xml']);
         if exist(XmlFileName,'file')
-            SubDirBase=fullfile(RootPath,SubDir(1:dotchar(end-idot+1)));
+            SubDirBase=fullfile(RootPath,SubDir(1:dotchar(end-idot+1)-1));
             break
         end
Index: /trunk/src/get_field.m
===================================================================
--- /trunk/src/get_field.m	(revision 700)
+++ /trunk/src/get_field.m	(revision 701)
@@ -97,5 +97,5 @@
         check_singleton(idim)=isequal(Field.DimValue(dim_index),1);%check_singleton=1 for singleton
     end
-    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 value
+    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
     if ~Field.Check0D(ilist)
     Field.Display.VarDimName{ilist}=Field.VarDimName{ilist}(~check_singleton);% eliminate singletons in the list of variable dimensions
@@ -495,5 +495,9 @@
 y_index=get(handles.ordinate,'Value');
 y_menu=get(handles.ordinate,'String');
+if isempty(y_menu)
+    return
+else
 YName=y_menu{y_index};
+end
 
 %% set list of possible coordinates
Index: /trunk/src/mouse_motion.m
===================================================================
--- /trunk/src/mouse_motion.m	(revision 700)
+++ /trunk/src/mouse_motion.m	(revision 701)
@@ -50,4 +50,5 @@
 test_zoom_draw=0;
 test_object=0; %test for object editing or creation 
+test_create_object=0;
 test_edit_object=0;% edit test for mouse shape: an arrow
 test_ruler=0;%test for active ruler 
@@ -56,4 +57,5 @@
 if ~isempty(huvmat)
     hhuvmat=guidata(huvmat);%handles of the elements in uvma
+    test_create_object=strcmp(get(hhuvmat.MenuObject,'checked'),'on');
     test_edit_object=get(hhuvmat.CheckEditObject,'Value');
     test_ruler=isequal(get(hhuvmat.MenuRuler,'checked'),'on');
@@ -109,13 +111,15 @@
     test_zoom_draw=test_draw && isequal(AxeData.Drawing,'zoom')&& isfield(AxeData,'CurrentOrigin') && isequal(get(gcf,'SelectionType'),'normal');
     test_object=test_draw && isfield(AxeData,'CurrentObject') && ~isempty(AxeData.CurrentObject) && ishandle(AxeData.CurrentObject);
-    if ~test_edit_object  && ~test_ruler 
+    if CheckZoom
+           pointershape='zoom';
+    elseif CheckZoomFig
+            pointershape='zoomfig';
+    elseif ~test_edit_object  && ~test_ruler 
         if CheckZoom
            pointershape='zoom';
-        elseif CheckZoomFig
-            pointershape='zoomfig';
-        elseif test_draw
-            pointershape='crosshair';%set pointer with cross shape (default when mouse is over an axis)
+        elseif test_draw|| test_create_object
+            pointershape='crosshair';%set pointer with cross shape 
         else
-        pointershape='fullcross';%set pointer with cross shape (default when mouse is over an axis)
+        pointershape='fullcross';%set pointer with large cross (default when mouse is over an axis)
         end
     end
Index: /trunk/src/mouse_up.m
===================================================================
--- /trunk/src/mouse_up.m	(revision 700)
+++ /trunk/src/mouse_up.m	(revision 701)
@@ -96,11 +96,6 @@
                 if size(ObjectData.Coord,1)==1 % this is the mouse up for the first point, continue until next click
                     check_multiple=1;
-                else
-                    %ObjectData.Coord=[ObjectData.Coord ;CurrentOrigin];% append the second point of the line (the last pointed position during mouse down)
                 end
             case {'rectangle','ellipse','volume'}
-                %                  if size(ObjectData.Coord,1)==1 % this is the mouse up for the first point, continue until next click
-                %                     check_multiple=1;
-                %                  else
                 ObjectData.Coord=(CurrentOrigin+xy(1,1:2))/2;% keep only the first point coordinate
                 ObjectData.RangeX=abs(ObjectData.Coord(1,1)-xy(1,1));%rectangle width
@@ -109,9 +104,4 @@
                     check_multiple=1;% pass to next mous up if width of height=0
                 end
-                %                 ObjectData.Coord(1,1)=(xy(1,1)+XYData(1))/2;%origin rectangle, x coordinate
-                %                 ObjectData.Coord(1,2)=(xy(1,2)+XYData(2))/2;
-                %                 ObjectData.RangeX=abs(xy(1,1)-XYData(1))/2;%rectangle width
-                %                 ObjectData.RangeY=abs(xy(1,2)-XYData(2))/2;%rectangle height
-                %                  end
             case 'plane' %case of 'plane'
                 DX=(xy(1,1)-ObjectData.Coord(1,1));
@@ -130,7 +120,4 @@
     
     %show object coordinates in the GUI set_object
-    %     h_set_object=findobj(allchild(0),'Tag','set_object');
-    %     hh_set_object=guidata(h_set_object);
-    %     set(hh_set_object.Coord,'Data',ObjectData.Coord);
     if strcmp(ObjectData.Type,'rectangle')||strcmp(ObjectData.Type,'ellipse')
         set(hh_set_object.num_RangeX_2,'String',num2str(ObjectData.RangeX,4));
@@ -179,5 +166,6 @@
             end
             set(hhuvmat.CheckViewField,'Value',1);%
-            set(hhuvmat.CheckEditObject,'Value',1);%           
+            set(hhuvmat.CheckEditObject,'Value',1);%   
+            set(hhuvmat.MenuObject,'checked','off'); %desactivate object creation mode
             set(hhuvmat.CheckEditObject,'Enable','on');%
             set(get(h_set_object,'children'),'Enable','on')
Index: /trunk/src/uvmat.m
===================================================================
--- /trunk/src/uvmat.m	(revision 700)
+++ /trunk/src/uvmat.m	(revision 701)
@@ -1953,5 +1953,9 @@
         Field_a=transform(Field_a,UvData.XmlData{index});%the first field has been stored without transform
         end
+        if nargin(transform)>=2
         Field_b=transform(Field_b,UvData.XmlData{index});
+        else
+          Field_b=transform(Field_b);
+        end
     end
 end
@@ -4242,4 +4246,5 @@
 if get(handles.CheckEditObject,'Value') 
     %suppress the other options 
+    set(handles.MenuObject,'checked','off')
     set(handles.CheckZoom,'Value',0)
     CheckZoom_Callback(hObject, eventdata, handles)
@@ -4390,10 +4395,11 @@
             if ishandle(hdisplay(iview)) && ~isequal(hdisplay(iview),0)
                 ObjectData=get(hdisplay(iview),'UserData');
-                if isfield(ObjectData,'SubObject') && ishandle(ObjectData.SubObject)
-                    delete(ObjectData.SubObject);% delete the graphic 'sub-objects (e.g. projection bounds)
+                if isfield(ObjectData,'SubObject') && ~isempty(ObjectData.SubObject)
+                    delete(ObjectData.SubObject(ishandle(ObjectData.SubObject)));% delete the graphic 'sub-objects (e.g. projection bounds)
                 end
-                check_suppress= isfield(ObjectData,'DeformPoint') && ishandle(ObjectData.DeformPoint);
-                delete(ObjectData.DeformPoint(check_suppress));% delete the graphic deformation points 
-                delete(hdisplay(iview))% delete the main graphic representation of the object
+                if isfield(ObjectData,'DeformPoint')&& ~isempty(ObjectData.DeformPoint)
+                    delete(ObjectData.DeformPoint(ishandle(ObjectData.DeformPoint)));% delete the graphic deformation points
+                    delete(hdisplay(iview))% delete the main graphic representation of the object
+                end
             end
             ishandle(hdisplay(iview))
@@ -4713,4 +4719,5 @@
 set(handles.CheckZoomFig,'Value',0) %desactivate zoom sub fig
 set(handles.CheckZoom,'Value',0)    %desactivate the zoom action
+set(handles.MenuObject,'checked','on')% indicate object creation for mouse pointer display
 if ishandle(handles.UVMAT_title)
     delete(handles.UVMAT_title)     %delete the initial display of uvmat if no field has been entered yet
