function varargout = GUmenu(varargin)
% Due slider per provare l'inferenza fuzzy std
% Chiama GUStdInf
% GUMENU M-file for GUmenu.fig
%      GUMENU, by itself, creates a new GUMENU or raises the existing
%      singleton*.
%
%      H = GUMENU returns the handle to a new GUMENU or the handle to
%      the existing singleton*.
%
%      GUMENU('Property','Value',...) creates a new GUMENU using the
%      given property value pairs. Unrecognized properties are passed via
%      varargin to GUmenu_OpeningFcn.  This calling syntax produces a
%      warning when there is an existing singleton*.
%
%      GUMENU('CALLBACK') and GUMENU('CALLBACK',hObject,...) call the
%      local function named CALLBACK in GUMENU.M with the given input
%      arguments.
%
%      *See GUI Options on GUIDE's Tools menu.  Choose "GUI allows only one
%      instance to run (singleton)".
%
% See also: GUIDE, GUIDATA, GUIHANDLES

% Edit the above text to modify the response to help GUmenu

% Last Modified by GUIDE v2.5 22-Mar-2003 17:05:31
% GU Mar03

% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name',       mfilename, ...
                   'gui_Singleton',  gui_Singleton, ...
                   'gui_OpeningFcn', @GUmenu_OpeningFcn, ...
                   'gui_OutputFcn',  @GUmenu_OutputFcn, ...
                   'gui_LayoutFcn',  [], ...
                   'gui_Callback',   []);
if nargin & isstr(varargin{1})
    gui_State.gui_Callback = str2func(varargin{1});
end

if nargout
    [varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});
else
    gui_mainfcn(gui_State, varargin{:});
end
% End initialization code - DO NOT EDIT


% --- Executes just before GUmenu is made visible.
function GUmenu_OpeningFcn(hObject, eventdata, handles, varargin)
% This function has no output args, see OutputFcn.
% hObject    handle to figure
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)
% varargin   unrecognized PropertyName/PropertyValue pairs from the
%            command line (see VARARGIN)

% Choose default command line output for GUmenu
handles.output = hObject;

% Update handles structure
guidata(hObject, handles);

% UIWAIT makes GUmenu wait for user response (see UIRESUME)
% uiwait(handles.figure1);


% --- Outputs from this function are returned to the command line.
function varargout = GUmenu_OutputFcn(hObject, eventdata, handles)
% varargout  cell array for returning output args (see VARARGOUT);
% hObject    handle to figure
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Get default command line output from handles structure
varargout{1} = handles.output;


% --- Executes during object creation, after setting all properties.
function sliderU1_CreateFcn(hObject, eventdata, handles)
% hObject    handle to sliderU1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: slider controls usually have a light gray background, change
%       'usewhitebg' to 0 to use default.  See ISPC and COMPUTER.
usewhitebg = 0;
if usewhitebg
    set(hObject,'BackgroundColor',[.9 .9 .9]);
else
    set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));
end
U2val=45;
set(hObject,'max',100,'min',0,'Value',U2val)

% --- Executes on slider movement.
function sliderU1_Callback(hObject, eventdata, handles)
% hObject    handle to sliderU1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'Value') returns position of slider
%        get(hObject,'Min') and get(hObject,'Max') to determine range of slider
U1val=get(handles.sliderU1,'Value');
U2val=get(handles.sliderU2,'Value');
GUStdInf

% --- Executes during object creation, after setting all properties.
function sliderU2_CreateFcn(hObject, eventdata, handles)
% hObject    handle to sliderU2 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: slider controls usually have a light gray background, change
%       'usewhitebg' to 0 to use default.  See ISPC and COMPUTER.
usewhitebg = 1;
if usewhitebg
    set(hObject,'BackgroundColor',[.9 .9 .9]);
else
    set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));
end
U1val=35;
set(hObject,'max',100,'min',0,'Value',U1val)

% --- Executes on slider movement.
function sliderU2_Callback(hObject, eventdata, handles)
% hObject    handle to sliderU2 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: get(hObject,'Value') returns position of slider
%        get(hObject,'Min') and get(hObject,'Max') to determine range of slider
U2val=get(handles.sliderU2,'Value');
U1val=get(handles.sliderU1,'Value');
GUStdInf

