Path: news.mathworks.com!newsfeed-00.mathworks.com!newscon02.news.prodigy.net!prodigy.net!news.glorb.com!postnews.google.com!d34g2000cwd.googlegroups.com!not-for-mail
From: "Dan K" <dkominsky@primephotonics.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: R2006b dialog throws error with DockControls
Date: 6 Sep 2006 10:49:41 -0700
Organization: http://groups.google.com
Lines: 51
Message-ID: <1157564980.964600.192170@d34g2000cwd.googlegroups.com>
References: <1157554142.827948.87950@d34g2000cwd.googlegroups.com>
NNTP-Posting-Host: 206.158.106.243
Mime-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
X-Trace: posting.google.com 1157564986 10241 127.0.0.1 (6 Sep 2006 17:49:46 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Wed, 6 Sep 2006 17:49:46 +0000 (UTC)
In-Reply-To: <1157554142.827948.87950@d34g2000cwd.googlegroups.com>
User-Agent: G2/0.2
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.6) Gecko/20060728 Firefox/1.5.0.6,gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.0 SRV1
Complaints-To: groups-abuse@google.com
Injection-Info: d34g2000cwd.googlegroups.com; posting-host=206.158.106.243;
Xref: news.mathworks.com comp.soft-sys.matlab:368383




Dan K wrote:
> Don't know if anybody else has noticed this yet, but I just installed
> R2006b, and discovered that because of the way it is parsing property
> value pairs, it has a real problem with the DockControls property.
>
> Try this:
> set(0,'DefaultWindowStyle','docked')
>
>
> test=figure('DockCointrols','off','WindowStyle','normal')
>
> >> test=figure('DockControls','off','WindowStyle','normal')
> ??? Error using ==> figure
> Error using ==> figure
> Cannot set DockControls to 'off' while WindowStyle is 'docked'
>
>
>
> You can use modal too in the test line.  Now, the following works fine
> for me:
> test=figure('WindowStyle','normal',DockCointrols','off')
>
> Since I use the defaultwindowstyle, this has broken a whole lot of my
> m-files.  I'd really like a speedy fix on this one.  Anybody else?
>
> Dan K

Wanted to let folks know I found a workaround for this one:
*first make a copy of dialog.m and dialog.p which are in
$matlabroot\toolbox\matlab\uitools*

edit dialog.m

In dialog.m
on line 85: find the place where the figure is created and put the line
which says:
'WindowStyle'      ,winstyle  , ...

Before the line which says:
'DockControls'     ,dockctrls , ...

save the m file.  Make this directory your working directory (i.e. cd
'$matlabroot\toolbox\matlab\uitools'

In the command window type:  pcode dialog

The dialogs should work again.

HTH