Plots and progress bars in GUIs
3 ビュー (過去 30 日間)
古いコメントを表示
Hello all,
I a have GUI that with multiple checkboxes, each one showing collected field data for different variables of a Doppler speed log. A certain function of the GUI asks the user for an interval of the signals to run some analyses (noise, calibration,...). When the callback of this function is invoked, it also calls a routine to zoom all plots in the selected intervals.
The refresh plot function is as follows:
function [] = update_cb(hObject,pan_name)
% Get handles
handles=guidata(hObject);
%Get Panel
P_f=getfield(handles,pan_name);
% Get all checkboxes
P_h= findall(P_f,'Style','checkbox');
Lcb=length(P_h);
pbh_prog= 0;
pbh_inc=1/Lcb;
% iterate over checkboxes and run callbacks
for i=1:Lcb
% Get callback Tag
tag=get(P_h(i),'tag');
fname = get(P_h(i),'Callback');
% Run callback function
feval(fname, hObject,handles);
% % Update progress bar
pbh_prog=pbh_prog+pbh_inc;
multiWaitbar( 'Updating Plots', pbh_prog );
end
Thing is , the execution takes some seconds during which the GUI seems frozen to the user. I want to add a progress bar , but that makes that the signals are plot one by one in the new interval, while the app changes each signal representation from old interval (normally the total length of the variables) to the new selected interval.Also, the progress bar loses focus (is minimized) after the refresh of the first signal.All in all, is an ugly effect for the user.
My question: How is it possible to run the progress bar without losing focus, and have all the plots refreshed when the progress bar reaches 100 %?
Thanks in advance,
Jose
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Data Exploration についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!