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 =========================================================================*/
67 #ifndef vtkSVGExporter_h
68 #define vtkSVGExporter_h
69 
70 #include "vtkExporter.h"
71 #include "vtkIOExportModule.h" // For export macro
72 
73 class vtkContextActor;
74 class vtkRenderer;
76 class vtkXMLDataElement;
77 
78 class VTKIOEXPORT_EXPORT vtkSVGExporter : public vtkExporter
79 {
80 public:
81  static vtkSVGExporter* New();
82  vtkTypeMacro(vtkSVGExporter, vtkExporter);
83  void PrintSelf(ostream& os, vtkIndent indent) override;
84 
86  vtkSetStringMacro(Title);
87  vtkGetStringMacro(Title);
91  vtkSetStringMacro(Description);
92  vtkGetStringMacro(Description);
115  vtkSetMacro(TextAsPath, bool);
116  vtkGetMacro(TextAsPath, bool);
117  vtkBooleanMacro(TextAsPath, bool);
125  vtkSetMacro(DrawBackground, bool);
126  vtkGetMacro(DrawBackground, bool);
127  vtkBooleanMacro(DrawBackground, bool);
145  vtkSetMacro(SubdivisionThreshold, float);
146  vtkGetMacro(SubdivisionThreshold, float);
149 protected:
151  ~vtkSVGExporter() override;
152 
153  void WriteData() override;
154 
155  void WriteSVG();
160 
161  char* Title;
162  char* Description;
163  char* FileName;
164 
169 
173 
174 private:
175  vtkSVGExporter(const vtkSVGExporter&) = delete;
176  void operator=(const vtkSVGExporter&) = delete;
177 };
178 
179 #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:119
abstract specification for renderers
Definition: vtkRenderer.h:182
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.