VTK  9.2.6
vtkSVGExporter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkSVGExporter.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 =========================================================================*/
48 #ifndef vtkSVGExporter_h
49 #define vtkSVGExporter_h
50 
51 #include "vtkExporter.h"
52 #include "vtkIOExportModule.h" // For export macro
53 
54 class vtkContextActor;
55 class vtkRenderer;
57 class vtkXMLDataElement;
58 
59 class VTKIOEXPORT_EXPORT vtkSVGExporter : public vtkExporter
60 {
61 public:
62  static vtkSVGExporter* New();
63  vtkTypeMacro(vtkSVGExporter, vtkExporter);
64  void PrintSelf(ostream& os, vtkIndent indent) override;
65 
67  vtkSetStringMacro(Title);
68  vtkGetStringMacro(Title);
72  vtkSetStringMacro(Description);
73  vtkGetStringMacro(Description);
96  vtkSetMacro(TextAsPath, bool);
97  vtkGetMacro(TextAsPath, bool);
98  vtkBooleanMacro(TextAsPath, bool);
106  vtkSetMacro(DrawBackground, bool);
107  vtkGetMacro(DrawBackground, bool);
108  vtkBooleanMacro(DrawBackground, bool);
126  vtkSetMacro(SubdivisionThreshold, float);
127  vtkGetMacro(SubdivisionThreshold, float);
130 protected:
132  ~vtkSVGExporter() override;
133 
134  void WriteData() override;
135 
136  void WriteSVG();
141 
142  char* Title;
143  char* Description;
144  char* FileName;
145 
150 
154 
155 private:
156  vtkSVGExporter(const vtkSVGExporter&) = delete;
157  void operator=(const vtkSVGExporter&) = delete;
158 };
159 
160 #endif // vtkSVGExporter_h
provides a vtkProp derived object.
abstract class to write a scene to a file
Definition: vtkExporter.h:48
a simple class to control print indentation
Definition: vtkIndent.h:49
abstract specification for renderers
Definition: vtkRenderer.h:82
vtkContextDevice2D implementation for use with vtkSVGExporter.
Exports vtkContext2D scenes to SVG.
vtkGetFilePathMacro(FileName)
The name of the exported file.
static vtkSVGExporter * New()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkXMLDataElement * RootNode
vtkXMLDataElement * DefinitionNode
float SubdivisionThreshold
void PrepareDocument()
vtkSVGContextDevice2D * Device
void RenderContextActors()
void RenderBackground(vtkRenderer *ren)
vtkSetFilePathMacro(FileName)
The name of the exported file.
void WriteData() override
vtkXMLDataElement * PageNode
void RenderContextActor(vtkContextActor *actor, vtkRenderer *renderer)
~vtkSVGExporter() override
Represents an XML element and those nested inside.