Mercurial > hg > octave-lyh
annotate scripts/plot/gco.m @ 16580:adc150db1809
style fixes for uigetfile changes
* dialog.cc, dialog.h, main-window.cc, octave-qt-link.cc,
octave-qt-link.h, octave-link.cc, octave-link.h, uigetfile.m:
Style fixes.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Sun, 28 Apr 2013 13:41:37 -0400 |
parents | fa8f3955e70a |
children | 772f51539af8 |
rev | line source |
---|---|
14837
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
1 ## Copyright (C) 2012 Michael Goffioul |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
2 ## |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
3 ## This file is part of Octave. |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
4 ## |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
5 ## Octave is free software; you can redistribute it and/or modify it |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
6 ## under the terms of the GNU General Public License as published by |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
7 ## the Free Software Foundation; either version 3 of the License, or (at |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
8 ## your option) any later version. |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
9 ## |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
10 ## Octave is distributed in the hope that it will be useful, but |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
11 ## WITHOUT ANY WARRANTY; without even the implied warranty of |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
13 ## General Public License for more details. |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
14 ## |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
15 ## You should have received a copy of the GNU General Public License |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
16 ## along with Octave; see the file COPYING. If not, see |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
17 ## <http://www.gnu.org/licenses/>. |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
18 |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
19 ## -*- texinfo -*- |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
20 ## @deftypefn {Function File} {@var{h} =} gco () |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
21 ## @deftypefnx {Function File} {@var{h} =} gco (@var{fig}) |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
22 ## Return a handle to the current object of the current figure, or a handle |
15007
8f0e3c5bfa5f
doc: Periodic grammarcheck of documentation
Rik <rik@octave.org>
parents:
14837
diff
changeset
|
23 ## to the current object of the figure with handle @var{fig}. The current |
8f0e3c5bfa5f
doc: Periodic grammarcheck of documentation
Rik <rik@octave.org>
parents:
14837
diff
changeset
|
24 ## object of a figure is the object that was last clicked on. It is stored |
14837
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
25 ## in the CurrentObject property of the target figure. |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
26 ## |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
27 ## If the last mouse click didn't occur on any child object of the figure, |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
28 ## the current object is the figure itself. |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
29 ## |
15010
f7bcfb3b96e7
doc: Fix typo in docstring for gco.m
Rik <rik@octave.org>
parents:
15007
diff
changeset
|
30 ## If no mouse click occured in the target figure, this function returns an |
14837
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
31 ## empty matrix. |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
32 ## |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
33 ## Note that the value returned by this function is not necessarily the same |
15007
8f0e3c5bfa5f
doc: Periodic grammarcheck of documentation
Rik <rik@octave.org>
parents:
14837
diff
changeset
|
34 ## as the one returned by gcbo during callback execution. An executing |
14837
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
35 ## callback can be interrupted by another callback and the current object |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
36 ## can be modified. |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
37 ## |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
38 ##@seealso{gcbo, gcf} |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
39 ##@end deftypefn |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
40 |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
41 function h = gco () |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
42 |
15246
fa8f3955e70a
gco.m: Don't create figure if it doesn't already exist (Bug #37211)
Rik <rik@octave.org>
parents:
15010
diff
changeset
|
43 h = get (get (0, "currentfigure"), "currentobject"); |
14837
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
44 |
c55493bb7363
Add gco implementation.
Michael Goffioul <michael.goffioul@gmail.com>
parents:
diff
changeset
|
45 endfunction |