VTK  9.6.20260202
vtkXlibHardwareWindow.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
11
12#ifndef vtkXlibHardwareWindow_h
13#define vtkXlibHardwareWindow_h
14
15#include "vtkHardwareWindow.h"
16#include "vtkRenderingUIModule.h" // For export macro
17
18#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
19#include "vtkX11Functions.h" // Needed for X types used in the public interface
20
21VTK_ABI_NAMESPACE_BEGIN
22// Forward declarations
23class vtkImageData;
24
25class VTKRENDERINGUI_EXPORT VTK_MARSHALAUTO vtkXlibHardwareWindow : public vtkHardwareWindow
26{
27public:
30 void PrintSelf(ostream& os, vtkIndent indent) override;
31
33
40 Display* GetDisplayId();
42 void SetDisplayId(Display* display);
44
49 void SetParentId(Window);
50
55 Window GetWindowId();
56
58
62 void SetWindowId(Window);
63 void SetWindowId(void*) override;
65
66 void Create() override;
67 void Destroy() override;
68
70
74 void SetDisplayId(void*) override;
75 void SetParentId(void*) override;
76 void* GetGenericDisplayId() override;
77 void* GetGenericWindowId() override;
78 void* GetGenericParentId() override;
80
82
85 void SetSize(int, int) override;
88
90
93 void SetPosition(int, int) override;
96
98
102 void HideCursor() override;
103 void ShowCursor() override;
105
109 void SetCurrentCursor(int) override;
110
114 void SetWindowName(const char*) override;
115
120 void SetIcon(vtkImageData* img) override;
121
125 void SetWindowInfo(const char* info) override;
126
131 void SetCoverable(vtkTypeBool coverable) override;
132
136 bool EnsureDisplay() override;
137
138protected:
141
142 // Helper members
143 vtkXVisualInfo* GetDesiredVisualInfo();
145
146 Display* DisplayId;
147 Window ParentId;
148 Window WindowId;
149 Colormap ColorMap;
153
154 // we must keep track of the cursors we are using
156 Cursor XCArrow;
157 Cursor XCSizeAll;
158 Cursor XCSizeNS;
159 Cursor XCSizeWE;
160 Cursor XCSizeNE;
161 Cursor XCSizeNW;
162 Cursor XCSizeSE;
163 Cursor XCSizeSW;
164 Cursor XCHand;
165 Cursor XCCustom;
166
167private:
169 void operator=(const vtkXlibHardwareWindow&) = delete;
170};
171
172VTK_ABI_NAMESPACE_END
173#endif // vtkXlibHardwareWindow_h
topologically and geometrically regular array of data
a simple class to control print indentation
Definition vtkIndent.h:108
void ShowCursor() override
Hide or Show the mouse cursor, it is nice to be able to hide the default cursor if you want VTK to di...
vtkXVisualInfo * GetDesiredVisualInfo()
void SetParentId(Window)
Sets the parent of the window that WILL BE created.
void Create() override
void * GetGenericWindowId() override
These are window system independent methods that are used to help interface vtkWindow to native windo...
Window GetWindowId()
Get this RenderWindow's X window id.
void SetCoverable(vtkTypeBool coverable) override
Set whether this xwindow should be coverable by other windows, as opposed to always on top.
void * GetGenericParentId() override
These are window system independent methods that are used to help interface vtkWindow to native windo...
void SetSize(int, int) override
Set the size of the window in pixels.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void Destroy() override
void SetWindowName(const char *) override
Set name of window.
void SetWindowInfo(const char *info) override
Set this RenderWindow's X window id to a pre-existing window.
void * GetGenericDisplayId() override
These are window system independent methods that are used to help interface vtkWindow to native windo...
static vtkXlibHardwareWindow * New()
void SetCurrentCursor(int) override
Change the shape of the cursor.
void SetDisplayId(Display *display)
Get/set the X11 display.
bool EnsureDisplay() override
Ensure the X display is opened.
void SetPosition(int, int) override
Set the position of the window.
void HideCursor() override
Hide or Show the mouse cursor, it is nice to be able to hide the default cursor if you want VTK to di...
void SetIcon(vtkImageData *img) override
For window manager that supports it, set the icon displayed in the taskbar and the title bar.
void SetWindowId(Window)
Set this RenderWindow's X window id to a pre-existing window.
Display * GetDisplayId()
Get/set the X11 display.
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_MARSHAL_EXCLUDE_REASON_NOT_SUPPORTED
#define VTK_MARSHALAUTO
#define VTK_MARSHALEXCLUDE(reason)