VTK
9.4.20241231
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
Rendering
PythonContext2D
vtkPythonItem.h
Go to the documentation of this file.
1
// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2
// SPDX-License-Identifier: BSD-3-Clause
3
18
#ifndef vtkPythonItem_h
19
#define vtkPythonItem_h
20
#if !defined(__VTK_WRAP__) || defined(__VTK_WRAP_HIERARCHY__) || defined(__VTK_WRAP_PYTHON__)
21
22
#include "vtkPython.h"
// Must be first
23
24
#include "
vtkContextItem.h
"
25
#include "vtkPythonContext2DModule.h"
// For export macro
26
27
VTK_ABI_NAMESPACE_BEGIN
28
class
vtkSmartPyObject;
29
30
class
VTKPYTHONCONTEXT2D_EXPORT
vtkPythonItem
:
public
vtkContextItem
31
{
32
public
:
33
vtkTypeMacro(
vtkPythonItem
,
vtkContextItem
);
34
void
PrintSelf
(ostream& os,
vtkIndent
indent)
override
;
35
36
static
vtkPythonItem
*
New
();
37
44
void
SetPythonObject
(
PyObject
* obj);
45
46
bool
Paint
(
vtkContext2D
* painter)
override
;
47
48
protected
:
49
vtkPythonItem
();
50
~vtkPythonItem
()
override
;
51
52
private
:
53
vtkPythonItem
(
const
vtkPythonItem
&) =
delete
;
54
void
operator=(
const
vtkPythonItem
&) =
delete
;
55
56
bool
CheckResult(
const
char
* method,
const
vtkSmartPyObject& res);
57
58
PyObject
* Object;
59
};
60
61
VTK_ABI_NAMESPACE_END
62
#endif
// #ifndef vtkPythonItem_h
63
#endif
vtkContext2D
Class for drawing 2D primitives to a graphical context.
Definition
vtkContext2D.h:69
vtkContextItem
base class for items that are part of a vtkContextScene.
Definition
vtkContextItem.h:46
vtkIndent
a simple class to control print indentation
Definition
vtkIndent.h:108
vtkPythonItem
A vtkContextItem that can be implemented in Python.
Definition
vtkPythonItem.h:31
vtkPythonItem::Paint
bool Paint(vtkContext2D *painter) override
Paint event for the item, called whenever the item needs to be drawn.
vtkPythonItem::SetPythonObject
void SetPythonObject(PyObject *obj)
Specify the Python object to use to operate on the data.
vtkPythonItem::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkPythonItem::vtkPythonItem
vtkPythonItem()
vtkPythonItem::~vtkPythonItem
~vtkPythonItem() override
vtkPythonItem::New
static vtkPythonItem * New()
vtkContextItem.h
PyObject
struct _object PyObject
Definition
vtkMatplotlibMathTextUtilities.h:44
Generated on Tue Dec 31 2024 08:45:35 for VTK by
1.9.7