annotate m-toolbox/m/gui/gltpda/progressBar.m @ 41:6def6533cb16 database-connection-manager

Report authentication errors to user
author Daniele Nicolodi <nicolodi@science.unitn.it>
date Mon, 05 Dec 2011 18:04:34 +0100
parents f0afece42f48
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
1 function progressBar(varargin)
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
2 % Progress bar for the LTPDA GUI.
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
3 %
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
4 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
5 %
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
6 % This function is called whenever the user starts an analysis by clicking
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
7 % on the 'Start' button in the LTPDA GUI.
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
8 % It calculates how many blocks in the current Simulink model are
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
9 % M-S-function blocks calling 'ltpdasim.m', ie. how many LTPDA analysis
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
10 % blocks are present.
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
11 % This excludes all 'service' blocks which do not perform any real
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
12 % calculation, such as the input 'Object from list' block or the output
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
13 % 'Send to output' block: the execution of these blocks is almost immediate
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
14 % and there would be non sense in considering them for the sake of the
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
15 % 'progress bar'.
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
16 %
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
17 % Actually, the progress bar do NOT provide an estimate of the remaining
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
18 % time, since this would be impossible to achieve (the time required by
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
19 % every function/block is different and depending on its relative input,
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
20 % so there's no way to estimate it). It only shows how many blocks there
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
21 % are, how many have already been executed and how many to go.
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
22 % Its primary purpose thus is provide the user with a perception of how the
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
23 % analysis is going, and in case which block requires too much time to be
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
24 % executed.
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
25 %
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
26 % $Id: progressBar.m,v 1.8 2008/11/06 10:04:36 nicola Exp $
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
27 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
28
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
29 close(findobj('Name','LTPDA Progress Bar'));
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
30
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
31 funcBlocks = utils.prog.find_in_models(bdroot,'LookUnderMasks','all','FunctionName','ltpdasim');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
32
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
33 screenSize = get(0,'ScreenSize');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
34 backColor = [0.98 , 0.98 , 0.98];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
35
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
36 loopStatus = getappdata(0,'loopStatus');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
37 if isempty(loopStatus)
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
38 position = [(screenSize(3)-400)/2,(screenSize(4)-200)/2,400,180];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
39 progressWind = figure('Position',position,'Name','LTPDA Progress Bar','Tag','LTPDAProgressBar','Resize','off','NumberTitle','off','Toolbar','none','Menubar','none');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
40
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
41 barBackSize = [position(3)-20,14];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
42 barBackDimension = [(position(3)-barBackSize(1))/2 , (position(4)-barBackSize(2))/2-25 , barBackSize];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
43 progressBack = axes('Parent',progressWind,'Units','pixels','Position',barBackDimension);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
44 image(imread('progressbarg.jpg'),'Parent',progressBack);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
45 axis off;
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
46 barSize = [1,14];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
47 barDimension = [(position(3)-barBackSize(1))/2 , (position(4)-barBackSize(2))/2-25 , barSize];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
48 set(progressBack,'HandleVisibility','callback');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
49 progressBar = axes('Parent',progressWind,'Units','pixels','Position',barDimension);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
50 image(imread('progressbar.jpg'),'Parent',progressBar);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
51 set(progressBar,'Tag','progressaxes')
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
52 set(progressBar,'UserData',barBackDimension)
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
53 axis off;
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
54 set(progressBar,'HandleVisibility','callback');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
55 set(gcf,'NextPlot','new');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
56
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
57 % Total number of blocks
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
58 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','center','Position',[0 position(4)-40 position(3) 20],'String',['Total number of blocks to compute: ',num2str(numel(funcBlocks))],'FontName','Arial','FontSize',9,'FontWeight','normal','Visible','on','Tag','blockstotal','UserData',numel(funcBlocks),'Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
59 % Currently executed block
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
60 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','center','Position',[0 position(4)-85 position(3) 35],'String','','FontName','Arial','FontSize',9,'FontWeight','bold','Visible','on','Tag','currentexec','Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
61 % Blocks done
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
62 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','left','Position',[10 (position(4)-barBackSize(2))/2-5 60 14],'String','Done: 0','FontName','Arial','FontSize',8,'FontWeight','normal','Visible','on','Tag','done','UserData',0,'Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
63 % Blocks to go
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
64 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','right','Position',[position(3)-60-10 (position(4)-barBackSize(2))/2-5 60 14],'String',['To go: ',num2str(numel(funcBlocks))],'FontName','Arial','FontSize',8,'FontWeight','normal','Visible','on','Tag','togo','UserData',numel(funcBlocks),'Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
65 % Press X to stop
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
66 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','center','Position',[0 20 position(3) 20],'String','Press X to stop the analysis','FontName','Arial','FontSize',9,'FontWeight','normal','Visible','on','Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
67
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
68 else % loop execution
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
69 position = [(screenSize(3)-400)/2,(screenSize(4)-320)/2,400,300];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
70 progressWind = figure('Position',position,'Name','LTPDA Progress Bar','Tag','LTPDAProgressBar','Resize','off','NumberTitle','off','Toolbar','none','Menubar','none');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
71
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
72 barBackSize = [position(3)-20,14];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
73 barBackDimension = [(position(3)-barBackSize(1))/2 , (position(4)-barBackSize(2))/2+35 , barBackSize];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
74 progressBack = axes('Parent',progressWind,'Units','pixels','Position',barBackDimension);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
75 image(imread('progressbarg.jpg'),'Parent',progressBack);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
76 axis off;
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
77 barSize = [1,14];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
78 set(progressBack,'HandleVisibility','callback');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
79 barDimension = [(position(3)-barBackSize(1))/2 , (position(4)-barBackSize(2))/2+35 , barSize];
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
80 progressBar = axes('Parent',progressWind,'Units','pixels','Position',barDimension);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
81 image(imread('progressbar.jpg'),'Parent',progressBar);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
82 set(progressBar,'Tag','progressaxes')
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
83 set(progressBar,'UserData',barBackDimension)
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
84 axis off;
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
85 set(progressBar,'HandleVisibility','callback');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
86
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
87 barBackDimension(2) = (position(4)-barBackSize(2))/2-60;
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
88 barDimension(2) = (position(4)-barBackSize(2))/2-60;
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
89 progressBack2 = axes('Parent',progressWind,'Units','pixels','Position',barBackDimension);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
90 image(imread('progressbarg.jpg'),'Parent',progressBack2);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
91 axis off;
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
92 set(progressBack2,'HandleVisibility','callback');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
93 progressBarLoop = axes('Parent',progressWind,'Units','pixels','Position',barDimension);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
94 image(imread('progressbarb.jpg'),'Parent',progressBarLoop);
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
95 set(progressBarLoop,'Tag','progressaxes2')
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
96 set(progressBarLoop,'UserData',barBackDimension)
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
97 axis off;
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
98 set(progressBarLoop,'HandleVisibility','callback');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
99
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
100 set(gcf,'NextPlot','new');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
101
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
102 % Total number of blocks
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
103 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','center','Position',[0 position(4)-40 position(3) 20],'String',['Total number of blocks to compute: ',num2str(numel(funcBlocks))],'FontName','Arial','FontSize',9,'FontWeight','normal','Visible','on','Tag','blockstotal','UserData',numel(funcBlocks),'Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
104 % Currently executed block
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
105 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','center','Position',[0 position(4)-70 position(3) 20],'String','','FontName','Arial','FontSize',9,'FontWeight','bold','Visible','on','Tag','currentexec','Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
106 % Blocks done
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
107 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','left','Position',[10 (position(4)-barBackSize(2))/2+50 90 14],'String','Blocks done: 0','FontName','Arial','FontSize',8,'FontWeight','normal','Visible','on','Tag','done','UserData',0,'Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
108 % Blocks to go
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
109 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','right','Position',[position(3)-60-10 (position(4)-barBackSize(2))/2+50 60 14],'String',['To go: ',num2str(numel(funcBlocks))],'FontName','Arial','FontSize',8,'FontWeight','normal','Visible','on','Tag','togo','UserData',numel(funcBlocks),'Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
110 % Total number of loops
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
111 loopStatus = getappdata(0,'loopStatus');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
112 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','center','Position',[0 (position(4)-barBackSize(2))/2-15 position(3) 20],'String',['Total number of loops to compute: ',num2str(loopStatus(1))],'FontName','Arial','FontSize',9,'FontWeight','normal','Visible','on','Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
113 % Loops done
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
114 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','left','Position',[10 (position(4)-barBackSize(2))/2-45 90 14],'String',['Loops done: ',num2str(loopStatus(2))],'FontName','Arial','FontSize',8,'FontWeight','normal','Visible','on','Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
115 % Loops to go
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
116 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','right','Position',[position(3)-60-10 (position(4)-barBackSize(2))/2-45 60 14],'String',['To go: ',num2str(loopStatus(1)-loopStatus(2))],'FontName','Arial','FontSize',8,'FontWeight','normal','Visible','on','Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
117 % Press X to stop
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
118 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','center','Position',[0 10 position(3) 20],'String','Press X to stop the analysis','FontName','Arial','FontSize',9,'FontWeight','normal','Visible','on','Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
119 % Estimated time to completion:
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
120 if nargin>0 && ~isempty(varargin{1})
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
121 executionTime = varargin{1};
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
122 time2go = datestr(mean(executionTime)*(loopStatus(1)-loopStatus(2)+1),'MM:SS');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
123 else
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
124 time2go = '--:--';
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
125 end
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
126 uicontrol('Parent',progressWind,'BackgroundColor',backColor,'HorizontalAlignment','center','Position',[0 40 position(3) 20],'String',['Estimated time to completion: ',time2go],'FontName','Arial','FontSize',9,'FontWeight','normal','Visible','on','Style','text');
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
127
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
128 end
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
129
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
130
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
131
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
132
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
133
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
134
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
135
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
136
f0afece42f48 Import.
Daniele Nicolodi <nicolodi@science.unitn.it>
parents:
diff changeset
137 end