perform their function correctly. Specifically, make sure that the font size changes accordingly.
网上的对GUI控件的介绍!
And that s it. Those are the basics of using the different buttons within the Matlab
GUI.
Download Source Files Source files can be downloaded
here
.
This is the end of the tutorial.
网上的对GUI控件的介绍!
Jim: Here is a relatively simple example of how this can be done. Download the files here. The example is an adder GUI that will add two numbers together when you press the enter key or when you press the “add” pushbutton.
Good luck. Stay tuned for the tutorial on this topic.
Quan
网上的对GUI控件的介绍!
Hello! and thank you very much, the info in this page was very usefull and I think it s fair to let you know it.
anyway, I implemented my code just like you said here, and it works very good, except for the case when I don t change the initial position of the buttons… in that
case it never enter to the selectionchangefnc, and therefore, it never performs what I need.
am I missing something?
thank you very much in advanced.
Benja
Hi froggy,
I don t have that version installed, but i would imagine there is some sort of option
to change the title on the button group panel. Unfortunately, I do not know how to do it since I use version 2007a.
Quan
网上的对GUI控件的介绍!
I d like to suggest that Matlab makes GUI more easier for using by doing the following
1. After click button group, asking for No. of button in the group, then generate the group with buttons automatically.
2. Generate selectionChangeFcn automatically when saving.
Hallo Mr Quan
Greetings . I like your clear succint style. As to the Button group
where exactly in the massive Simulink documentation does one find the instruction to be entered in the opening function.(Section 5 of part3). The problem here is suppression of individual callbacks for the radio buttons to ensure exclusivity i.e one
button is active at a time. The Eventdata thing is supposed to be in a future version of Simulink. Could you please elaborate on function_handles and scope of variables
in the context! Will look forward to your reply
All the best
udaya
网上的对GUI控件的介绍!
Try these links for a brief introduction of handles:
/matlab/matlab-gui-tutorial-a-brief-introduction-to-handles
Try this one for an intro on how to share data between callbacks
/matlab/matlab-gui-tutorial-sharing-data-among-callbacks-and-sub-functions
Thank u very much,
I have a doubt in setting the Value property of Check Box in MATLAB GUI, can u pls help me in solving the same.
My question is:
How to change the state of a check box by programmatically by setting the check box Value property ???
I tried with following two methods and both are not working:
function GUI_OpeningFcn(hObject, eventdata, handles, varargin)
global hObject_checkbox
1 . set(hObject_checkbox, Value , Max ); or
2 . set(hObject_checkbox, Value , 1);
Actually I want to set the Check Box property from different GUI (Main/ Parent GUI) before calling the Sub GUI, How do i do it????
PLs reply as early as possible, it is very urgent requirement to me.
Thanks and Regards,
Ashwini
Bonjour M .Quan
Thanks for the references to your tutorials. My questions were not quite at that user level but more on the use of function handles , event detections (past and current like swich closures), reference cells. The line to be inserted in the opening function (your
button_tutorial part 3 section 5) does replace individual callbacks for the radio buttons by one main with subfunctions chosen by , current tags. I feel a detailed
网上的对GUI控件的介绍!
tutorial on these topics will be of interest to many. Keep up the good work! udaya
Hi, I used a calculate pushbutton to calculate some values. When i run the gui and press the calculate button, the whole gui looks blocked. None of the buttons worked after that. Do I have to change something in the property inspector to correct it?
hi, l used push button for showing my succive data, i don t how to make the button , can l have fu rther information about it.
thanks,
Hey, I am doing the same thing as you, but it doesn t work.
Look at my code:
function varargout = test_button_group(varargin)
% TEST_BUTTON_GROUP M-file for test_button_group.fig
% TEST_BUTTON_GROUP, by itself, creates a new TEST_BUTTON_GROUP or raises
网上的对GUI控件的介绍!
the existing
% singleton*.
%
% H = TEST_BUTTON_GROUP returns the handle to a new TEST_BUTTON_GROUP or the handle to
% the existing singleton*.
%
% TEST_BUTTON_GROUP( CALLBACK ,hObject,eventData,handles,…) calls the local
% function named CALLBACK in TEST_BUTTON_GROUP.M with the given input arguments.