VTK  9.6.20260228
vtkWebAssemblyHardwareWindow.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
20
21#ifndef vtkWebAssemblyHardwareWindow_h
22#define vtkWebAssemblyHardwareWindow_h
23
24#if !defined(__EMSCRIPTEN__)
25#error "vtkWebAssemblyHardwareWindow cannot be built without emscripten!"
26#endif
27
28#include "vtkHardwareWindow.h"
29
30#include "vtkRenderingUIModule.h" // For export macro
31#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
32
33VTK_ABI_NAMESPACE_BEGIN
35
37{
38public:
41 void PrintSelf(ostream& os, vtkIndent indent) override;
44
48 void SetFullScreen(vtkTypeBool) override;
49
51
54 void SetSize(int, int) override;
55 void SetSize(int a[2]) override { this->SetSize(a[0], a[1]); }
57
58 // /**
59 // * Get the current size of the screen in pixels.
60 // */
61 // int* GetScreenSize() VTK_SIZEHINT(2) override;
62
66 int* GetPosition() VTK_SIZEHINT(2) override;
67
69
73 void* GetGenericWindowId() override;
74 void* GetGenericDrawable() override;
76
78
82 void HideCursor() override;
83 void ShowCursor() override;
85
89 vtkGetStringMacro(CanvasSelector);
90 vtkSetStringMacro(CanvasSelector);
91
96 void SetShowWindow(bool) override {}
97
98 void Create() override;
99 void Destroy() override;
100
101protected:
104
105 void* WindowId = nullptr;
106 char* CanvasSelector = nullptr;
107
108private:
110 void operator=(const vtkWebAssemblyHardwareWindow&) = delete;
111};
112
113#define vtkWebAssemblyHardwareWindow_OVERRIDE_ATTRIBUTES \
114 vtkWebAssemblyHardwareWindow::CreateOverrideAttributes()
115VTK_ABI_NAMESPACE_END
116#endif
a simple class to control print indentation
Definition vtkIndent.h:108
Attribute for vtkObjectFactory overrides.
int * GetPosition() override
Get the current size of the screen in pixels.
void SetShowWindow(bool) override
Make the setter for ShowWindow no-op.
void SetSize(int a[2]) override
Set the size of the window in pixels.
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...
void SetSize(int, int) override
Set the size of the window in pixels.
static vtkWebAssemblyHardwareWindow * New()
static vtkOverrideAttribute * CreateOverrideAttributes()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkWebAssemblyHardwareWindow() override
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 * GetGenericDrawable() override
These are window system independent methods that are used to help interface vtkWindow to native windo...
void SetFullScreen(vtkTypeBool) override
Change the window to fill the entire screen.
void * GetGenericWindowId() override
These are window system independent methods that are used to help interface vtkWindow to native windo...
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_SIZEHINT(...)
#define VTK_MARSHALAUTO
#define VTK_NEWINSTANCE