Changeset 705 for trunk/src/set_object.m


Ignore:
Timestamp:
Feb 12, 2014, 12:02:04 AM (11 years ago)
Author:
sommeria
Message:

several bugs repaired

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/set_object.m

    r684 r705  
    3636function varargout = set_object(varargin)
    3737
    38 % Last Modified by GUIDE v2.5 02-Sep-2013 11:39:56
     38% Last Modified by GUIDE v2.5 11-Feb-2014 20:08:17
    3939
    4040% Begin initialization code - DO NOT REFRESH
     
    8282set(0,'Unit','pixels')
    8383ScreenSize=get(0,'ScreenSize');% get the size of the screen, to put the fig on the upper right
    84 Width=300;% fig width in pixels
    85 Height=600;
     84PosGUI=get(handles.set_object,'Position');% fig width in pixels
     85Width=PosGUI(3);%width of the gui set_object in pixels
     86Height=PosGUI(4);
    8687Left=ScreenSize(3)- Width-40; %right edge close to the right, with margin=40
    8788Bottom=ScreenSize(4)-Height-40; %put fig at top right
     
    650651        def=[Object.Style '.xml'];
    651652    end
    652     displ_txt={'save object as an .xml file in';dir_save};%default display
     653    displ_txt={['save object in' dir_save]; 'with file name (.xml):'};%default display
    653654    menu=get(handles.ProjMode,'String');
    654655    value=get(handles.ProjMode,'Value');
    655656    ProjMode=menu{value};
    656657    if strcmp(ProjMode,'mask_inside')||strcmp(ProjMode,'mask_outside')
    657         displ_txt={'save mask contour as an .xml file:'; 'to create a mask image, use save_mask on the GUI uvmat (lower right)'};
     658        displ_txt={displ_txt; '(to create a mask image, use save_mask on the GUI uvmat upper menu)'};
    658659    end
    659660    answer=msgbox_uvmat('INPUT_TXT',displ_txt,def);
    660     if iscell(answer)
    661         FullName=fullfile(dir_save,answer{1});
     661    if ischar(answer)
     662        FullName=fullfile(dir_save,answer);
    662663        t=struct2xml(Object);
    663664        t=set(t,1,'name','ProjObject');
     
    784785    set(handles.Coord,'Data',Coord);
    785786end
    786 
    787 
    788 
Note: See TracChangeset for help on using the changeset viewer.