VTK  9.1.0
vtkQtLabelRenderStrategy.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkQtLabelRenderStrategy.h
5
6 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7 All rights reserved.
8 See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9
10 This software is distributed WITHOUT ANY WARRANTY; without even
11 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12 PURPOSE. See the above copyright notice for more information.
13
14=========================================================================*/
25#ifndef vtkQtLabelRenderStrategy_h
26#define vtkQtLabelRenderStrategy_h
27
29#include "vtkRenderingQtModule.h" // For export macro
30
33class vtkPlaneSource;
36class vtkTexture;
39
40class VTKRENDERINGQT_EXPORT vtkQtLabelRenderStrategy : public vtkLabelRenderStrategy
41{
42public:
43 void PrintSelf(ostream& os, vtkIndent indent) override;
46
50 void ComputeLabelBounds(vtkTextProperty* tprop, vtkStdString label, double bds[4]) override
51 {
52 this->Superclass::ComputeLabelBounds(tprop, label, bds);
53 }
54 void ComputeLabelBounds(vtkTextProperty* tprop, vtkUnicodeString label, double bds[4]) override;
55
57
61 void RenderLabel(int x[2], vtkTextProperty* tprop, vtkStdString label) override
62 {
63 this->Superclass::RenderLabel(x, tprop, label);
64 }
65 void RenderLabel(int x[2], vtkTextProperty* tprop, vtkStdString label, int maxWidth) override
66 {
67 this->Superclass::RenderLabel(x, tprop, label, maxWidth);
68 }
69 void RenderLabel(int x[2], vtkTextProperty* tprop, vtkUnicodeString label) override;
70 void RenderLabel(int x[2], vtkTextProperty* tprop, vtkUnicodeString label, int maxWidth) override;
72
76 void StartFrame() override;
77
81 void EndFrame() override;
82
88 void ReleaseGraphicsResources(vtkWindow* window) override;
89
90protected:
93
94 class Internals;
96
103 bool AntialiasText; // Should the text be antialiased, inherited from render window.
104
105private:
107 void operator=(const vtkQtLabelRenderStrategy&) = delete;
108};
109
110#endif
a simple class to control print indentation
Definition: vtkIndent.h:113
Superclass for label rendering implementations.
This filter takes an input dataset, an array to process (which must be a string array),...
draw text labels at dataset points
create an array of quadrilaterals located in a plane
draw vtkPolyData onto the image plane
Create image data from a QImage.
void EndFrame() override
End a rendering frame.
void RenderLabel(int x[2], vtkTextProperty *tprop, vtkStdString label) override
Render a label at a location in world coordinates.
void ReleaseGraphicsResources(vtkWindow *window) override
Release any graphics resources that are being consumed by this strategy.
vtkTextureMapToPlane * TextureMapToPlane
void RenderLabel(int x[2], vtkTextProperty *tprop, vtkStdString label, int maxWidth) override
Render a label at a location in world coordinates.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void RenderLabel(int x[2], vtkTextProperty *tprop, vtkUnicodeString label, int maxWidth) override
Render a label at a location in world coordinates.
~vtkQtLabelRenderStrategy() override
void ComputeLabelBounds(vtkTextProperty *tprop, vtkUnicodeString label, double bds[4]) override
void RenderLabel(int x[2], vtkTextProperty *tprop, vtkUnicodeString label) override
Render a label at a location in world coordinates.
vtkQImageToImageSource * QImageToImage
void StartFrame() override
Start a rendering frame.
void ComputeLabelBounds(vtkTextProperty *tprop, vtkStdString label, double bds[4]) override
Compute the bounds of a label.
static vtkQtLabelRenderStrategy * New()
Wrapper around std::string to keep symbols short.
Definition: vtkStdString.h:105
represent text properties.
generate texture coordinates by mapping points to plane
handles properties associated with a texture map
Definition: vtkTexture.h:175
actor that draws 2D data with texture support
String class that stores Unicode text.
window superclass for vtkRenderWindow
Definition: vtkWindow.h:36