Creating and Displaying Graphical User Interface
Creating and Displaying Graphical User Interface
A graphical user interface is a pictorial interface to a program. A good GUI can make
programs easier to use by providing them with consistence appearance, and intuitive controls
the GUI should behave in an understandable and predictable manner, so that the user knows
what to expect when performs an action. A graphical user interface provides the user with a
familiar environment in which to work. It contains push button ,toggle buttons,list, menus,
text boxes, and so forth, all of which are already familiar to the user,so that user can the
instead of the mechanics involved in doing things.the three principal elements required to
create aMATLAB Graphical User Interface are:
MATLAB graphical user interface are created using a tool called Guide,GUI
Development Environment.The toolallows the programmer tolay out the GUI,selecting
and aligning the GUI component tobe in it.once the componets are in place, the
programmer can edit their properties:name, color,size,font,text to display, and so forth
when guidesaves the GUI it creates aworking program , including skelton function that
the programmer can modify to placedmpliment the behaviour of the GUI
1. what elements are required for the GUI and what the function of each element will be.Make a
rough layout of the components .
2. Using MATLAB toolcalled GUIDE to lay out the component in figure.the size of the figure
and the alignment and specing of components on the figure can be adjusted using the tools
built into guide.
3. Use a MATLAB tool called the Property Inspector to give each component name and to set
the characteristics of each , such as its colour or the text it displays.
4. Save the figure to a file.When the figure is saved two files will be created on disk with the
same name but different extents.The fig file containsthe GUI layout and the componets of the
GUI;the M-file contains the code to load the figure along with skelton callback function for
each GUI element.
5. Write code to implement the behaviour associated with each callback function.