0001 function varargout = ltpda_constructor_helper(varargin)
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021 id = findobj('Tag', 'LTPDAconstructor_helper');
0022 if ~isempty(id)
0023 figure(id)
0024 return
0025 end
0026
0027
0028
0029 Gproperties.Gcol = [240 240 240]/255;
0030 Gproperties.Gwidth = 500;
0031 Gproperties.Gheight = 300;
0032 Gproperties.Gborder = 10;
0033 fontsize = getappdata(0, 'ltpda_repo_gui_fontsize');
0034
0035 Gproperties.Screen = get(0,'screensize');
0036 Gproperties.Gposition = [150 ...
0037 150 ...
0038 Gproperties.Gwidth...
0039 Gproperties.Gheight];
0040
0041
0042 mainfig = figure('Name', 'LTPDA Constructor Helper',...
0043 'NumberTitle', 'off',...
0044 'Visible','off',...
0045 'Position',Gproperties.Gposition,...
0046 'Color', Gproperties.Gcol,...
0047 'Toolbar', 'none',...
0048 'MenuBar', 'none',...
0049 'Resize', 'off',...
0050 'Tag', 'LTPDAconstructor_helper');
0051
0052
0053 set(mainfig, 'CloseRequestFcn', {@ltpda_constructor_helper_close, mainfig});
0054
0055
0056 setappdata(mainfig, 'Gproperties', Gproperties);
0057
0058
0059
0060
0061
0062
0063 sth = uicontrol(mainfig,'Style','text',...
0064 'String','Class',...
0065 'HorizontalAlignment', 'left', ...
0066 'BackgroundColor', Gproperties.Gcol, ...
0067 'Position',[10 Gproperties.Gheight-40 50 25]);
0068
0069
0070 pmh = uicontrol(mainfig,'Style','popupmenu',...
0071 'String', ltpda_isuserobject,...
0072 'Value', 1, ...
0073 'BackgroundColor', Gproperties.Gcol, ...
0074 'Tag', 'LTPDA_constructor_helper_class', ...
0075 'Callback', {'ltpda_constructor_helper_class', mainfig}, ...
0076 'Position',[90 Gproperties.Gheight-40 120 25]);
0077
0078
0079
0080
0081
0082 sth = uicontrol(mainfig,'Style','text',...
0083 'String','Sets',...
0084 'HorizontalAlignment', 'left', ...
0085 'BackgroundColor', Gproperties.Gcol, ...
0086 'Position',[10 Gproperties.Gheight-80 50 25]);
0087
0088
0089 lbh = uicontrol(mainfig,'Style','listbox',...
0090 'String', '',...
0091 'Value', 1, ...
0092 'BackgroundColor', 'w', ...
0093 'Tag', 'LTPDA_constructor_helper_sets', ...
0094 'Callback', {'ltpda_constructor_helper_sets', mainfig}, ...
0095 'Position',[10 Gproperties.Gheight-270 200 200]);
0096
0097
0098 eth = uicontrol(mainfig,'Style','edit',...
0099 'String','',...
0100 'BackgroundColor', 'w', ...
0101 'Max', 100, ...
0102 'HorizontalAlignment', 'left', ...
0103 'FontSize', 14, ...
0104 'Tag', 'LTPDA_constructor_helper_constructor', ...
0105 'Position',[240 Gproperties.Gheight-210 250 200]);
0106
0107
0108 sth = uicontrol(mainfig,'Style','text',...
0109 'String','Variable',...
0110 'HorizontalAlignment', 'left', ...
0111 'BackgroundColor', Gproperties.Gcol, ...
0112 'Position',[240 Gproperties.Gheight-260 50 25]);
0113
0114 eth = uicontrol(mainfig,'Style','edit',...
0115 'String','obj',...
0116 'BackgroundColor', 'w', ...
0117 'HorizontalAlignment', 'center', ...
0118 'Tag', 'LTPDA_constructor_helper_var', ...
0119 'Position',[300 Gproperties.Gheight-260 50 25]);
0120
0121
0122
0123 pbh = uicontrol(mainfig,'Style','pushbutton','String','Build',...
0124 'Position',[360 Gproperties.Gheight-260 60 25],...
0125 'Tag', 'LTPDA_constructor_helper_buildBtn');
0126 set(pbh, 'Callback', {'ltpda_constructor_helper_build'});
0127
0128
0129
0130
0131 set(mainfig,'Visible','on')
0132
0133
0134
0135
0136
0137 function ltpda_constructor_helper_close(varargin)
0138 disp('* Goodbye from the LTPDA Constructor Helper *')
0139 delete(varargin{end})
0140 end
0141 end
0142
0143
0144