Format NCdisplayGui.m

This commit is contained in:
2024-07-25 13:27:15 -04:00
parent 37533136ae
commit d569bc4be7

View File

@@ -1,21 +1,16 @@
%% CALLED WHEN ACCESSING 'CurveFit Display' %% %% CALLED WHEN ACCESSING 'CurveFit Display' %%
function [scLst, row, col] = NCdisplayGui(eDir) %(ExpPath) function [scLst, row, col] = NCdisplayGui(eDir) %(ExpPath)
%global ExpPath
%global expDir
xPos=0.05; xPos=0.05;
btnWid=0.10; btnWid=0.10;
btnHt=0.05; btnHt=0.05;
spacing=0.02; % Spacing between the button and the next command's label spacing=0.02; % Spacing between the button and the next command's label
%hSpot= figure; % Figure
%figure
%====================================
% The ADD Groups button % The ADD Groups button
btnNumber=1; btnNumber=1;
yPos=0.85-(btnNumber-1)*(btnHt+spacing); yPos=0.85-(btnNumber-1)*(btnHt+spacing);
btnPos=[xPos yPos-spacing btnWid btnHt]; btnPos=[xPos yPos-spacing btnWid btnHt];
%
row=1; row=1;
hedit=uicontrol(... hedit=uicontrol(...
'Style', 'edit',... 'Style', 'edit',...
@@ -31,15 +26,11 @@ user_entry = str2double(get(source,'string'));
return return
end end
row=user_entry; row=user_entry;
end end
%-------------------222222-----------
%
btnNumber=2; btnNumber=2;
yPos=0.85-(btnNumber-1)*(btnHt+spacing); yPos=0.85-(btnNumber-1)*(btnHt+spacing);
btnPos=[xPos yPos-spacing btnWid btnHt]; btnPos=[xPos yPos-spacing btnWid btnHt];
col=1; col=1;
hedit=uicontrol(... hedit=uicontrol(...
'Style', 'edit',... 'Style', 'edit',...
@@ -55,19 +46,16 @@ user_entry = str2double(get(source,'string'));
return return
end end
col=user_entry; col=user_entry;
end end
%}
%************************************************************* % Read in numeric folder names
%Ncode 12_0120 for reading in numeric folder names
nlist=dir(fullfile(eDir,'*')); %(ExpPath,'*')); nlist=dir(fullfile(eDir,'*')); %(ExpPath,'*'));
nnn=0; nnn=0;
for n=1:size(nlist,1) for n=1:size(nlist,1)
if (~isempty(str2num(nlist(n).name))) if (~isempty(str2num(nlist(n).name)))
nnn=nnn+1; nnn=nnn+1;
PnumLst(nnn)=(str2num(nlist(n).name)); PnumLst(nnn)=(str2num(nlist(n).name));
slst(nnn,1)={nlist(n).name};
slst(nnn,1)={(nlist(n).name)}; slst(nnn,1)={(nlist(n).name)};
end end
end end
@@ -86,14 +74,10 @@ hListbox = uicontrol(...
userIndx=(get(source,'value')); userIndx=(get(source,'value'));
userStr=(get(source,'string')); userStr=(get(source,'string'));
%scLstIndx=str2num(char(strrep(userStr(userIndx), 'Scan', ''))) %scLstIndx=str2num(char(strrep(userStr(userIndx), 'Scan', '')))
user_entry=userStr(userIndx); user_entry=userStr(userIndx);
scLst=user_entry; scLst=user_entry;
end end
%*****************************************************************
%-------------------10 10 10 10-----------
btnNumber=10; btnNumber=10;
yPos=0.85-(btnNumber-1)*(btnHt+spacing); yPos=0.85-(btnNumber-1)*(btnHt+spacing);
btnPos=[xPos yPos-spacing btnWid btnHt]; btnPos=[xPos yPos-spacing btnWid btnHt];
@@ -105,29 +89,19 @@ hedit8 = uicontrol(...
'Position', btnPos,... 'Position', btnPos,...
'callback','uiresume(gcbf)'); 'callback','uiresume(gcbf)');
% Labels
%------------------------------
%***************************************************************
% {
%********LABELS******************************
% The Labels
xLPos=0.175; xLPos=0.175;
yPos=0; yPos=0;
btnWid=0.20; btnWid=0.20;
% Removed Not needed for Ncode ImRobot
lblNumber=1; lblNumber=1;
yPos=0.85-(lblNumber-1)*(btnHt+spacing); yPos=0.85-(lblNumber-1)*(btnHt+spacing);
btnPos=[xLPos yPos-spacing btnWid btnHt]; btnPos=[xLPos yPos-spacing btnWid btnHt];
htxt=uicontrol(... htxt=uicontrol(...
'Style', 'text',... 'Style', 'text',...
'String','Row',... 'String','Row',...
'Units','normalized',... 'Units','normalized',...
'Position', btnPos); 'Position', btnPos);
%-------------------222222-----------
lblNumber=2; lblNumber=2;
yPos=0.85-(lblNumber-1)*(btnHt+spacing); yPos=0.85-(lblNumber-1)*(btnHt+spacing);
btnPos=[xLPos yPos-spacing btnWid btnHt]; btnPos=[xLPos yPos-spacing btnWid btnHt];
@@ -137,10 +111,11 @@ htxt = uicontrol(...
'String','Column',... 'String','Column',...
'Units','normalized',... 'Units','normalized',...
'Position', btnPos); 'Position', btnPos);
% Not needed for Ncode ImRobot
% Not needed for Ncode ImRobot
uiwait(gcf); uiwait(gcf);
end %function end $$$$$ end %function end $$$$$[/INST]
%} %}
%{ %{
%-------------------333333----------- %-------------------333333-----------