Path: news.mathworks.com!newsfeed-00.mathworks.com!nlpi057.nbdc.sbc.com!prodigy.net!border1.nntp.dca.giganews.com!nntp.giganews.com!postnews.google.com!v15g2000yqn.googlegroups.com!not-for-mail
From: ImageAnalyst <imageanalyst@mailinator.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Matlab GUI newbye
Date: Mon, 1 Dec 2008 07:17:51 -0800 (PST)
Organization: http://groups.google.com
Lines: 45
Message-ID: <d9977286-b494-4197-b4c2-ac521c595bfa@v15g2000yqn.googlegroups.com>
References: <ggv8nh$smj$1@fred.mathworks.com> <c2fd2c68-5120-49ca-8cd0-06ca543eb7be@20g2000yqt.googlegroups.com> 
	<gh0np6$dgl$1@fred.mathworks.com> <gh0qbp$ssc$1@fred.mathworks.com>
NNTP-Posting-Host: 192.44.136.113
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-Trace: posting.google.com 1228144671 4574 127.0.0.1 (1 Dec 2008 15:17:51 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Mon, 1 Dec 2008 15:17:51 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: v15g2000yqn.googlegroups.com; posting-host=192.44.136.113; 
	posting-account=0rLUzAkAAABojYSRC64DkTbtiSCX77HH
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET 
	CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 
	3.5.21022),gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 bdci2px (NetCache NetApp/6.0.7)
Bytes: 3956
Xref: news.mathworks.com comp.soft-sys.matlab:504118


On Dec 1, 8:55=A0am, "Husam Aldahiyat" <numand...@gmail.com> wrote:
> GUIDE on default creates an m-file for your GUI with callback functions f=
or each of the uicontrols that you put (edit, text, slider, etc.). So after=
 you make the GUI and save it, scroll down to one of the functions and put =
your code there (you can check control's callback but doiuble clicking on i=
t).

---------------------------------------------------------------------------=
--------------
Well, not exactly.  These functions are only created in your source
code AFTER you right click on the control then select "View Callbacks"
and pick the callback function that you want.  Only AFTER this, does
the callback function actually show up in the source code.  (Try it
and you'll see.)

Your best option may be to create the callbacks by right clicking as
described above, then paste your template code (from some other m-
file) into the appropriate function.  I just go with the automatically-
created callback function names, but you can change these if you want
by modifying the string in the callback property of the control.  This
will give it the name you want instead of the automatically-generated
name.  So this could be an option for you if you really like the
function names in your template instead.  Just make sure that the
three input arguments match the automatically-generated input
arguments.

I know it's not as nice as Visual Studio and I hear they are working
on a massive upgrade for the lame GUIDE.  For example, when you double
click the control, it brings up the properties window instead of the
callback source code (Visual Studio brings up the callback source
code).  Plus there's no way to dock the properties window.  Why they
chose not to allow docking of that window when they do allow docking
of most other windows, I don't know.  I'd prefer a docked properties
window and to go to the control's callback source code when you double
click on the control (i.e. just like it is in Visual Studio).  And
control-a selects all controls on the figure EXCEPT those controls
within group boxes.  And there's the whole issue with units -
normalized, pixels, etc.  How if you're in normalized and then want to
adjust something - well, it's a major pain to get things aligned.  I
could go on but they know it's crappy and hopefully the next version
will be a lot better.  But for now, it's all we have and it's still
better than creating all the figures and controls on it manually in
your code.
Regards,
ImageAnalyst