annotate libgui/graphics/Object.cc @ 27376:1952e110d346

Allow Qt graphics callbacks to work again (bug #56857) * Object.h, Object.cc (Object::do_connections): New virtual method. Do connections that were previously done in qt_graphics_toolkit::create_object * qt_graphics_toolkit.cc (qt_graphics_toolkit::create_object): Let Object::do_connections do the signal/slot connections. * Figure.h, Figure.cc (Figure::do_connection): Overload Object::do_connections to also make connections on peer Canvas object. * Panel.h, Panel.cc (Panel::do_connection): Overload Object::do_connections to also make connections on peer Canvas object.
author Pantxo Diribarne <pantxo.diribarne@gmail.com>
date Thu, 05 Sep 2019 10:13:39 +0200
parents 50216d7a2f6b
children c40be2cf044d
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
1 /*
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
2
26376
00f796120a6d maint: Update copyright dates in all source files.
John W. Eaton <jwe@octave.org>
parents: 25799
diff changeset
3 Copyright (C) 2011-2019 Michael Goffioul
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
4
18500
49877d3be064 update copyright notices for new QtHandles code
John W. Eaton <jwe@octave.org>
parents: 18498
diff changeset
5 This file is part of Octave.
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
6
24534
194eb4bd202b maint: Update punctuation for GPL v3 license text.
Rik <rik@octave.org>
parents: 23795
diff changeset
7 Octave is free software: you can redistribute it and/or modify it
22755
3a2b891d0b33 maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents: 22417
diff changeset
8 under the terms of the GNU General Public License as published by
24534
194eb4bd202b maint: Update punctuation for GPL v3 license text.
Rik <rik@octave.org>
parents: 23795
diff changeset
9 the Free Software Foundation, either version 3 of the License, or
22755
3a2b891d0b33 maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents: 22417
diff changeset
10 (at your option) any later version.
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
11
22755
3a2b891d0b33 maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents: 22417
diff changeset
12 Octave is distributed in the hope that it will be useful, but
3a2b891d0b33 maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents: 22417
diff changeset
13 WITHOUT ANY WARRANTY; without even the implied warranty of
3a2b891d0b33 maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents: 22417
diff changeset
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3a2b891d0b33 maint: Standardize Copyright formatting.
Rik <rik@octave.org>
parents: 22417
diff changeset
15 GNU General Public License for more details.
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
16
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
17 You should have received a copy of the GNU General Public License
18500
49877d3be064 update copyright notices for new QtHandles code
John W. Eaton <jwe@octave.org>
parents: 18498
diff changeset
18 along with Octave; see the file COPYING. If not, see
24534
194eb4bd202b maint: Update punctuation for GPL v3 license text.
Rik <rik@octave.org>
parents: 23795
diff changeset
19 <https://www.gnu.org/licenses/>.
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
20
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
21 */
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
22
21724
aba2e6293dd8 use "#if ..." consistently instead of "#ifdef" and "#ifndef"
John W. Eaton <jwe@octave.org>
parents: 21301
diff changeset
23 #if defined (HAVE_CONFIG_H)
21301
40de9f8f23a6 Use '#include "config.h"' rather than <config.h>.
Rik <rik@octave.org>
parents: 21203
diff changeset
24 # include "config.h"
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
25 #endif
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
26
19681
35bca657d74d printing for Qt plot widget (bug #42537)
John W. Eaton <jwe@octave.org>
parents: 18692
diff changeset
27 #include <QString>
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
28 #include <QVariant>
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
29
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
30 #include "Object.h"
18505
fb96b7f55242 rename file to avoid clash on case-insenstive filesystems (bug #41658)
John W. Eaton <jwe@octave.org>
parents: 18501
diff changeset
31 #include "QtHandlesUtils.h"
27317
718116e9c7d3 rename Backend to qt_graphics_toolkit
John W. Eaton <jwe@octave.org>
parents: 26376
diff changeset
32 #include "qt-graphics-toolkit.h"
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
33
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
34 #include "graphics.h"
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
35 #include "interpreter-private.h"
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
36
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
37 namespace QtHandles
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
38 {
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
39
23449
c763214a8260 maint: Use convention 'int *x' for naming pointers.
Rik <rik@octave.org>
parents: 23447
diff changeset
40 Object::Object (const graphics_object& go, QObject *obj)
25044
b6aea95a7bf9 store graphics object in Qt backend to avoid crash (bug #53487, #53500)
John W. Eaton <jwe@octave.org>
parents: 24534
diff changeset
41 : QObject (), m_go (go), m_handle (go.get_handle ()), m_qobject (nullptr)
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
42 {
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
43 gh_manager& gh_mgr = octave::__get_gh_manager__ ("Object::Object");
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
44
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
45 octave::autolock guard (gh_mgr.graphics_lock ());
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
46
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
47 if (! guard)
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
48 qCritical ("QtHandles::Object::Object: "
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
49 "creating Object (h=%g) without a valid lock!!!",
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
50 m_handle.value ());
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
51
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
52 init (obj);
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
53 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
54
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
55 void
23449
c763214a8260 maint: Use convention 'int *x' for naming pointers.
Rik <rik@octave.org>
parents: 23447
diff changeset
56 Object::init (QObject *obj, bool)
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
57 {
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
58 if (m_qobject)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
59 qCritical ("QtHandles::Object::init: "
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
60 "resetting QObject while in invalid state");
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
61
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
62 m_qobject = obj;
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
63
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
64 if (m_qobject)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
65 {
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
66 m_qobject->setProperty ("QtHandles::Object",
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
67 qVariantFromValue<void*> (this));
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
68 connect (m_qobject, SIGNAL (destroyed (QObject*)),
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
69 SLOT (objectDestroyed (QObject*)));
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
70 }
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
71 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
72
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
73 Object::~Object (void)
22417
48c00363dc74 maint: Use '{ }' for empty function bodies in C++.
Rik <rik@octave.org>
parents: 22413
diff changeset
74 { }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
75
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
76 graphics_object
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
77 Object::object (void) const
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
78 {
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
79 gh_manager& gh_mgr = octave::__get_gh_manager__ ("Object::object");
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
80
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
81 octave::autolock guard (gh_mgr.graphics_lock (), false);
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
82
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
83 if (! guard)
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
84 qCritical ("QtHandles::Object::object: "
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
85 "accessing graphics object (h=%g) without a valid lock!!!",
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
86 m_handle.value ());
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
87
25044
b6aea95a7bf9 store graphics object in Qt backend to avoid crash (bug #53487, #53500)
John W. Eaton <jwe@octave.org>
parents: 24534
diff changeset
88 return m_go;
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
89 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
90
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
91 void
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
92 Object::slotUpdate (int pId)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
93 {
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
94 gh_manager& gh_mgr = octave::__get_gh_manager__ ("Object::slotUpdate");
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
95
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
96 octave::autolock guard (gh_mgr.graphics_lock ());
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
97
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
98 switch (pId)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
99 {
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
100 // Special case for objects being deleted, as it's very likely
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
101 // that the graphics_object already has been destroyed when this
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
102 // is executed (because of the async behavior).
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
103 case base_properties::ID_BEINGDELETED:
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
104 beingDeleted ();
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
105 break;
19967
3cc0734283dc style fixes in Qt graphics code
John W. Eaton <jwe@octave.org>
parents: 19954
diff changeset
106
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
107 default:
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
108 if (object ().valid_object ())
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
109 update (pId);
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
110 break;
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
111 }
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
112 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
113
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
114 void
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
115 Object::slotFinalize (void)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
116 {
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
117 gh_manager& gh_mgr = octave::__get_gh_manager__ ("Object::slotFinalize");
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
118
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
119 octave::autolock guard (gh_mgr.graphics_lock ());
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
120
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
121 finalize ();
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
122 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
123
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
124 void
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
125 Object::slotRedraw (void)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
126 {
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
127 gh_manager& gh_mgr = octave::__get_gh_manager__ ("Object::slotRedraw");
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
128
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
129 octave::autolock guard (gh_mgr.graphics_lock ());
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
130
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
131 if (object ().valid_object ())
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
132 redraw ();
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
133 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
134
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
135 void
25799
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
136 Object::slotShow (void)
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
137 {
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
138 gh_manager& gh_mgr = octave::__get_gh_manager__ ("Object::slotShow");
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
139
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
140 octave::autolock guard (gh_mgr.graphics_lock ());
25799
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
141
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
142 if (object ().valid_object ())
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
143 show ();
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
144 }
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
145
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
146 void
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
147 Object::slotPrint (const QString& file_cmd, const QString& term)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
148 {
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
149 gh_manager& gh_mgr = octave::__get_gh_manager__ ("Object::slotPrint");
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
150
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
151 octave::autolock guard (gh_mgr.graphics_lock ());
19681
35bca657d74d printing for Qt plot widget (bug #42537)
John W. Eaton <jwe@octave.org>
parents: 18692
diff changeset
152
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
153 if (object ().valid_object ())
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
154 print (file_cmd, term);
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
155 }
19681
35bca657d74d printing for Qt plot widget (bug #42537)
John W. Eaton <jwe@octave.org>
parents: 18692
diff changeset
156
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
157 void
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
158 Object::update (int /* pId */)
22417
48c00363dc74 maint: Use '{ }' for empty function bodies in C++.
Rik <rik@octave.org>
parents: 22413
diff changeset
159 { }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
160
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
161 void
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
162 Object::finalize (void)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
163 {
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
164 if (m_qobject)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
165 {
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
166 delete m_qobject;
23795
980f39c3ab90 Use C++11 nullptr rather than 0 in code (bug #51565).
Rik <rik@octave.org>
parents: 23449
diff changeset
167 m_qobject = nullptr;
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
168 }
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
169 deleteLater ();
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
170 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
171
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
172 void
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
173 Object::redraw (void)
22417
48c00363dc74 maint: Use '{ }' for empty function bodies in C++.
Rik <rik@octave.org>
parents: 22413
diff changeset
174 { }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
175
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
176 void
25799
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
177 Object::show (void)
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
178 { }
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
179
d04b74f5d02e make shg and figure (N) activate and raise figure windows (bug #45943)
John W. Eaton <jwe@octave.org>
parents: 25054
diff changeset
180 void
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
181 Object::print (const QString& /* file_cmd */, const QString& /* term */)
22417
48c00363dc74 maint: Use '{ }' for empty function bodies in C++.
Rik <rik@octave.org>
parents: 22413
diff changeset
182 { }
19681
35bca657d74d printing for Qt plot widget (bug #42537)
John W. Eaton <jwe@octave.org>
parents: 18692
diff changeset
183
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
184 void
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
185 Object::beingDeleted (void)
22417
48c00363dc74 maint: Use '{ }' for empty function bodies in C++.
Rik <rik@octave.org>
parents: 22413
diff changeset
186 { }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
187
23449
c763214a8260 maint: Use convention 'int *x' for naming pointers.
Rik <rik@octave.org>
parents: 23447
diff changeset
188 void Object::objectDestroyed (QObject *obj)
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
189 {
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
190 if (obj && obj == m_qobject)
23795
980f39c3ab90 Use C++11 nullptr rather than 0 in code (bug #51565).
Rik <rik@octave.org>
parents: 23449
diff changeset
191 m_qobject = nullptr;
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
192 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
193
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
194 Object*
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
195 Object::parentObject (const graphics_object& go)
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
196 {
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
197 gh_manager& gh_mgr = octave::__get_gh_manager__ ("Object::parentObject");
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
198
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
199 octave::autolock guard (gh_mgr.graphics_lock ());
19954
b6061813a693 always obtain gh_manager lock before accessing graphics objects
John W. Eaton <jwe@octave.org>
parents: 19755
diff changeset
200
27317
718116e9c7d3 rename Backend to qt_graphics_toolkit
John W. Eaton <jwe@octave.org>
parents: 26376
diff changeset
201 Object *parent = qt_graphics_toolkit::toolkitObject
27335
50216d7a2f6b eliminate static wrapper functions in gh_manager class
John W. Eaton <jwe@octave.org>
parents: 27317
diff changeset
202 (gh_mgr.get_object (go.get_parent ()));
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
203
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
204 return parent;
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
205 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
206
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
207 Object*
23449
c763214a8260 maint: Use convention 'int *x' for naming pointers.
Rik <rik@octave.org>
parents: 23447
diff changeset
208 Object::fromQObject (QObject *obj)
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
209 {
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
210 QVariant v = obj->property ("QtHandles::Object");
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
211
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
212 if (v.isValid ())
23447
db1fdf4384dd maint: Use convention "static_cast<void *>" for casting of pointers.
Rik <rik@octave.org>
parents: 23220
diff changeset
213 return reinterpret_cast<Object *> (qvariant_cast<void*> (v));
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
214
23795
980f39c3ab90 Use C++11 nullptr rather than 0 in code (bug #51565).
Rik <rik@octave.org>
parents: 23449
diff changeset
215 return nullptr;
22411
c69805d1fa64 maint: Style check C++ code in libgui/
Rik <rik@octave.org>
parents: 22323
diff changeset
216 }
18498
2e7cad6f180c Initial integration of QtHandles.
John W. Eaton <jwe@octave.org>
parents:
diff changeset
217
27376
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
218 void
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
219 Object::do_connections (const QObject *receiver, const QObject *emitter)
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
220 {
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
221 if (! emitter)
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
222 emitter = this;
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
223
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
224 connect (emitter,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
225 SIGNAL (interpreter_event (const octave::fcn_callback&)),
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
226 receiver,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
227 SLOT (interpreter_event (const octave::fcn_callback&)));
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
228
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
229 connect (emitter,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
230 SIGNAL (interpreter_event (const octave::meth_callback&)),
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
231 receiver,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
232 SLOT (interpreter_event (const octave::meth_callback&)));
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
233
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
234 connect (emitter,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
235 SIGNAL (interpreter_event (const octave::meth_callback&)),
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
236 receiver,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
237 SLOT (interpreter_event (const octave::meth_callback&)));
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
238
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
239 connect (emitter,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
240 SIGNAL (gh_callback_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
241 const std::string&)),
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
242 receiver,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
243 SLOT (gh_callback_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
244 const std::string&)));
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
245
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
246 connect (emitter,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
247 SIGNAL (gh_callback_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
248 const std::string&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
249 const octave_value&)),
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
250 receiver,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
251 SLOT (gh_callback_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
252 const std::string&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
253 const octave_value&)));
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
254
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
255 connect (emitter,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
256 SIGNAL (gh_set_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
257 const std::string&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
258 const octave_value&)),
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
259 receiver,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
260 SLOT (gh_set_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
261 const std::string&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
262 const octave_value&)));
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
263
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
264 connect (emitter,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
265 SIGNAL (gh_set_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
266 const std::string&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
267 const octave_value&, bool)),
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
268 receiver,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
269 SLOT (gh_set_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
270 const std::string&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
271 const octave_value&, bool)));
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
272
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
273 connect (emitter,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
274 SIGNAL (gh_set_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
275 const std::string&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
276 const octave_value&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
277 bool, bool)),
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
278 receiver,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
279 SLOT (gh_set_event (const graphics_handle&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
280 const std::string&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
281 const octave_value&,
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
282 bool, bool)));
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
283 }
1952e110d346 Allow Qt graphics callbacks to work again (bug #56857)
Pantxo Diribarne <pantxo.diribarne@gmail.com>
parents: 27335
diff changeset
284
22413
8758addcf265 maint: Remove ';' at end of namespace declaration.
Rik <rik@octave.org>
parents: 22411
diff changeset
285 }