-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathresetfigspecr.m
More file actions
28 lines (25 loc) · 1009 Bytes
/
Copy pathresetfigspecr.m
File metadata and controls
28 lines (25 loc) · 1009 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
function resetfigspecr(varargin)
% Reset all the plots in specr
hFigSpecr = findall(0,'Tag','specr_Fig');
hPopupmenuX = findall(hFigSpecr,'Tag','specr_PopupmenuX');
hPopupmenuY = findall(hFigSpecr,'Tag','specr_PopupmenuY');
hPopupmenuPlotStyle = findall(hFigSpecr,'Tag','specr_PopupmenuPlotStyle');
hAxes = findall(hFigSpecr,'Tag','specr_Axes');
settings = getappdata(hFigSpecr,'settings');
resettoolbar(hFigSpecr);
cla(hAxes);
set(hPopupmenuX,'String','X Axis','Value',1);
set(hPopupmenuY,'String','Y Axis','Value',1);
file = settings.file;
[filepath,filename,fileext] = fileparts(file);
set(hAxes,'Title',text('String',['File: ',titlestr([filename,fileext])]));
set(hAxes,'XLabel',text('String',''));
set(hAxes,'YLabel',text('String',''));
set(hFigSpecr,'Name',['Spec Reader - ',filename,fileext]);
hTimerMonitor = timerfindall('Tag','timerMonitor');
if ~isempty(hTimerMonitor)
if isvalid(hTimerMonitor)
stop(hTimerMonitor);
end
delete(hTimerMonitor);
end