VTK  9.1.0
vtkMathTextFreeTypeTextRenderer.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkMathTextFreeTypeTextRenderer.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=========================================================================*/
15
31#ifndef vtkMathTextFreeTypeTextRenderer_h
32#define vtkMathTextFreeTypeTextRenderer_h
33
34#include "vtkRenderingFreeTypeModule.h" // For export macro
35#include "vtkTextRenderer.h"
36
39
40class VTKRENDERINGFREETYPE_EXPORT vtkMathTextFreeTypeTextRenderer : public vtkTextRenderer
41{
42public:
44 void PrintSelf(ostream& os, vtkIndent indent) override;
45
47
49
52 bool FreeTypeIsSupported() override;
53 bool MathTextIsSupported() override;
55
56protected:
59
61
65 vtkTextProperty* tprop, const vtkStdString& str, int bbox[4], int dpi, int backend) override;
66 bool GetBoundingBoxInternal(vtkTextProperty* tprop, const vtkUnicodeString& str, int bbox[4],
67 int dpi, int backend) override;
68 bool GetMetricsInternal(vtkTextProperty* tprop, const vtkStdString& str, Metrics& metrics,
69 int dpi, int backend) override;
71 int dpi, int backend) override;
73 int textDims[2], int dpi, int backend) override;
75 int textDims[2], int dpi, int backend) override;
77 int targetWidth, int targetHeight, int dpi, int backend) override;
79 int targetWidth, int targetHeight, int dpi, int backend) override;
81 vtkTextProperty* tprop, const vtkStdString& str, vtkPath* path, int dpi, int backend) override;
83 int dpi, int backend) override;
84 void SetScaleToPowerOfTwoInternal(bool scale) override;
86
87private:
89 void operator=(const vtkMathTextFreeTypeTextRenderer&) = delete;
90
91 vtkFreeTypeTools* FreeTypeTools;
92 vtkMathTextUtilities* MathTextUtilities;
93};
94
95#endif // vtkMathTextFreeTypeTextRenderer_h
FreeType library support.
topologically and geometrically regular array of data
Definition: vtkImageData.h:157
a simple class to control print indentation
Definition: vtkIndent.h:113
Default implementation of vtkTextRenderer.
void SetScaleToPowerOfTwoInternal(bool scale) override
Reimplemented from vtkTextRenderer.
bool GetBoundingBoxInternal(vtkTextProperty *tprop, const vtkUnicodeString &str, int bbox[4], int dpi, int backend) override
Reimplemented from vtkTextRenderer.
bool RenderStringInternal(vtkTextProperty *tprop, const vtkStdString &str, vtkImageData *data, int textDims[2], int dpi, int backend) override
Reimplemented from vtkTextRenderer.
bool RenderStringInternal(vtkTextProperty *tprop, const vtkUnicodeString &str, vtkImageData *data, int textDims[2], int dpi, int backend) override
Reimplemented from vtkTextRenderer.
bool GetMetricsInternal(vtkTextProperty *tprop, const vtkStdString &str, Metrics &metrics, int dpi, int backend) override
Reimplemented from vtkTextRenderer.
bool GetBoundingBoxInternal(vtkTextProperty *tprop, const vtkStdString &str, int bbox[4], int dpi, int backend) override
Reimplemented from vtkTextRenderer.
int GetConstrainedFontSizeInternal(const vtkStdString &str, vtkTextProperty *tprop, int targetWidth, int targetHeight, int dpi, int backend) override
Reimplemented from vtkTextRenderer.
bool StringToPathInternal(vtkTextProperty *tprop, const vtkStdString &str, vtkPath *path, int dpi, int backend) override
Reimplemented from vtkTextRenderer.
bool StringToPathInternal(vtkTextProperty *tprop, const vtkUnicodeString &str, vtkPath *path, int dpi, int backend) override
Reimplemented from vtkTextRenderer.
bool FreeTypeIsSupported() override
Test for availability of various backends.
int GetConstrainedFontSizeInternal(const vtkUnicodeString &str, vtkTextProperty *tprop, int targetWidth, int targetHeight, int dpi, int backend) override
Reimplemented from vtkTextRenderer.
bool MathTextIsSupported() override
Test for availability of various backends.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkMathTextFreeTypeTextRenderer * New()
bool GetMetricsInternal(vtkTextProperty *tprop, const vtkUnicodeString &str, Metrics &metrics, int dpi, int backend) override
Reimplemented from vtkTextRenderer.
Abstract interface to equation rendering.
concrete dataset representing a path defined by Bezier curves.
Definition: vtkPath.h:33
Wrapper around std::string to keep symbols short.
Definition: vtkStdString.h:105
represent text properties.
Interface for generating images and path data from string data, using multiple backends.
String class that stores Unicode text.