From: "per isakson" <poi1@kth2.se>
Path: news.mathworks.com!newsfeed-00.mathworks.com!webcrossing
Newsgroups: comp.soft-sys.matlab
Subject: Re: GUIs:  GUIDE vs Code Only
Message-ID: <ef3f3e7.10@webcrossing.raydaftYaTP>
Date: Fri, 25 Aug 2006 17:09:17 -0400
References: <ef3f3e7.-1@webcrossing.raydaftYaTP>
Lines: 58
NNTP-Posting-Host: 130.237.60.110
MIME-Version: 1.0
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
Xref: news.mathworks.com comp.soft-sys.matlab:366619


Jeremy Smith wrote:
>
>
> What are the pros and cons of creating GUIs (graphical user
> interfaces) with GUIDE and programmatically (code only)?
>
> For either method, what are the pros and cons of using the
> switchyard
> approach to functions vs function handles? When I speak of
> switchyard I mean calling one function with a switch and a number
> of
> cases to execute the proper function.
>
> A bit about me and why I asked these questions:
> I've been programming GUIs for a year now and I see people mostly
> discussing GUIDE methods. After using GUIDE for a bit I grew to
> hate
> it. The GUI based programs in Matlab I've used (and reverse
> engineered) and been able to find code for all seem to be done
> using
> the programmatic method. This is why I would like to know why you
> use the methods you use.
>
> Thanks in advance for your replies.
  
I made my first GUI in Matlab 10+ years ago. I played a little with
GUIDE when it appeared and have not tried it since.

GUI without GUIDE

Pros (without order)

Possibility to control the GUI layout programatically. (See Layout
Manager at xtargets.com for an advanced example.) That makes it
possible to adapt the GUI nicely to (take advantage of) various
screen sizes. Furthermore, it saves time to stick to scheme and resit
all tweaking.

Reuse of GUI-related code. I define groups of controls, which I
reuse. E.g. a listbox together with pushbuttons for search and sort
and a context menu for copy and copy options. I do not modify such
groups for various GUIs, which help both me and other user to
remember how they behave. Theese groups become kind of high level
controls.

Cons (without order)

There are little documentation and help. You have to invent the wheel
yourself.

Take more time to make a simple guis.

There is an upfront investment. Low productivity to start with.

And last, the combination of nested functions and function handles is
superior to the switch-yard pattern.

/ per