[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: patch for "area" when parent is not an axes object
From: |
David Bateman |
Subject: |
Re: patch for "area" when parent is not an axes object |
Date: |
Wed, 14 Nov 2007 10:38:59 +0100 |
User-agent: |
Thunderbird 1.5.0.7 (X11/20060921) |
Michael Goffioul wrote:
> Index: scripts/plot/patch.m
> ===================================================================
> RCS file: /cvs/octave/scripts/plot/patch.m,v
> retrieving revision 1.7
> diff -c -p -r1.7 patch.m
> *** scripts/plot/patch.m 9 Nov 2007 16:59:43 -0000 1.7
> --- scripts/plot/patch.m 14 Nov 2007 09:30:23 -0000
> *************** function h = patch (varargin)
> *** 38,49 ****
>
> if (isscalar (varargin{1}) && ishandle (varargin{1}))
> h = varargin {1};
> ! if (! strcmp (get (h, "type"), "axes"))
> ! error ("patch: expecting first argument to be an axes object");
> endif
> oldh = gca ();
> unwind_protect
> ! axes (h);
> [tmp, fail] = __patch__ (h, varargin{2:end});
> unwind_protect_cleanup
> axes (oldh);
> --- 38,49 ----
>
> if (isscalar (varargin{1}) && ishandle (varargin{1}))
> h = varargin {1};
> ! if (! strcmp (get (h, "type"), "axes") && ! strcmp (get (h,
> "type"), "hggroup"))
> ! error ("patch: expecting first argument to be an axes or
> hggroup object");
> endif
> oldh = gca ();
> unwind_protect
> ! axes (ancestor (h, "axes"));
> [tmp, fail] = __patch__ (h, varargin{2:end});
> unwind_protect_cleanup
> axes (oldh);
>
>
Hey, we've started adding hggroups :-) .... Seriously, this won't hurt,
and we want to add them eventually, so I see no issue with a reference
to an hggroup in patch.m
D.
--
David Bateman address@hidden
Motorola Labs - Paris +33 1 69 35 48 04 (Ph)
Parc Les Algorithmes, Commune de St Aubin +33 6 72 01 06 33 (Mob)
91193 Gif-Sur-Yvette FRANCE +33 1 69 35 77 01 (Fax)
The information contained in this communication has been classified as:
[x] General Business Information
[ ] Motorola Internal Use Only
[ ] Motorola Confidential Proprietary