31 #ifndef __vtkRenderedGraphRepresentation_h
32 #define __vtkRenderedGraphRepresentation_h
78 virtual void SetVertexLabelArrayName(
const char*
name);
79 virtual const char* GetVertexLabelArrayName();
80 virtual void SetVertexLabelPriorityArrayName(
const char*
name);
81 virtual const char* GetVertexLabelPriorityArrayName();
82 virtual void SetVertexLabelVisibility(
bool b);
83 virtual bool GetVertexLabelVisibility();
84 vtkBooleanMacro(VertexLabelVisibility,
bool);
87 vtkSetStringMacro(VertexHoverArrayName);
88 vtkGetStringMacro(VertexHoverArrayName);
92 vtkSetMacro(HideVertexLabelsOnInteraction,
bool)
93 vtkGetMacro(HideVertexLabelsOnInteraction,
bool)
94 vtkBooleanMacro(HideVertexLabelsOnInteraction,
bool)
100 virtual
void SetEdgeLabelArrayName(const
char*
name);
101 virtual const
char* GetEdgeLabelArrayName();
102 virtual
void SetEdgeLabelPriorityArrayName(const
char* name);
103 virtual const
char* GetEdgeLabelPriorityArrayName();
104 virtual
void SetEdgeLabelVisibility(
bool b);
105 virtual
bool GetEdgeLabelVisibility();
106 vtkBooleanMacro(EdgeLabelVisibility,
bool);
109 vtkSetStringMacro(EdgeHoverArrayName);
110 vtkGetStringMacro(EdgeHoverArrayName);
114 vtkSetMacro(HideEdgeLabelsOnInteraction,
bool)
115 vtkGetMacro(HideEdgeLabelsOnInteraction,
bool)
116 vtkBooleanMacro(HideEdgeLabelsOnInteraction,
bool)
122 virtual
void SetVertexIconArrayName(const
char* name);
123 virtual const
char* GetVertexIconArrayName();
124 virtual
void SetVertexIconPriorityArrayName(const
char* name);
125 virtual const
char* GetVertexIconPriorityArrayName();
126 virtual
void SetVertexIconVisibility(
bool b);
127 virtual
bool GetVertexIconVisibility();
128 vtkBooleanMacro(VertexIconVisibility,
bool);
129 virtual
void AddVertexIconType(const
char* name,
int type);
130 virtual
void ClearVertexIconTypes();
131 virtual
void SetUseVertexIconTypeMap(
bool b);
132 virtual
bool GetUseVertexIconTypeMap();
133 vtkBooleanMacro(UseVertexIconTypeMap,
bool);
134 virtual
void SetVertexIconAlignment(
int align);
135 virtual
int GetVertexIconAlignment();
136 virtual
void SetVertexSelectedIcon(
int icon);
137 virtual
int GetVertexSelectedIcon();
138 virtual
void SetVertexDefaultIcon(
int icon);
139 virtual
int GetVertexDefaultIcon();
147 virtual
void SetVertexIconSelectionMode(
int mode);
148 virtual
int GetVertexIconSelectionMode();
149 virtual
void SetVertexIconSelectionModeToSelectedIcon()
150 { this->SetVertexIconSelectionMode(0); }
152 { this->SetVertexIconSelectionMode(1); }
154 { this->SetVertexIconSelectionMode(2); }
156 { this->SetVertexIconSelectionMode(3); }
162 virtual void SetEdgeIconArrayName(
const char*
name);
163 virtual const char* GetEdgeIconArrayName();
164 virtual void SetEdgeIconPriorityArrayName(
const char*
name);
165 virtual const char* GetEdgeIconPriorityArrayName();
166 virtual void SetEdgeIconVisibility(
bool b);
167 virtual bool GetEdgeIconVisibility();
168 vtkBooleanMacro(EdgeIconVisibility,
bool);
169 virtual void AddEdgeIconType(
const char*
name,
int type);
170 virtual void ClearEdgeIconTypes();
171 virtual void SetUseEdgeIconTypeMap(
bool b);
172 virtual bool GetUseEdgeIconTypeMap();
173 vtkBooleanMacro(UseEdgeIconTypeMap,
bool);
174 virtual void SetEdgeIconAlignment(
int align);
175 virtual int GetEdgeIconAlignment();
180 virtual void SetColorVerticesByArray(
bool b);
181 virtual bool GetColorVerticesByArray();
182 vtkBooleanMacro(ColorVerticesByArray,
bool);
183 virtual void SetVertexColorArrayName(
const char*
name);
184 virtual const char* GetVertexColorArrayName();
189 virtual void SetColorEdgesByArray(
bool b);
190 virtual bool GetColorEdgesByArray();
191 vtkBooleanMacro(ColorEdgesByArray,
bool);
192 virtual void SetEdgeColorArrayName(
const char*
name);
193 virtual const char* GetEdgeColorArrayName();
198 virtual void SetEnableVerticesByArray(
bool b);
199 virtual bool GetEnableVerticesByArray();
200 vtkBooleanMacro(EnableVerticesByArray,
bool);
201 virtual void SetEnabledVerticesArrayName(
const char*
name);
202 virtual const char* GetEnabledVerticesArrayName();
207 virtual void SetEnableEdgesByArray(
bool b);
208 virtual bool GetEnableEdgesByArray();
209 vtkBooleanMacro(EnableEdgesByArray,
bool);
210 virtual void SetEnabledEdgesArrayName(
const char*
name);
211 virtual const char* GetEnabledEdgesArrayName();
213 virtual void SetEdgeVisibility(
bool b);
214 virtual bool GetEdgeVisibility();
215 vtkBooleanMacro(EdgeVisibility,
bool);
217 void SetEdgeSelection(
bool b);
218 bool GetEdgeSelection();
231 virtual void SetLayoutStrategy(
const char*
name);
232 vtkGetStringMacro(LayoutStrategyName);
238 { this->SetLayoutStrategy(
"Random"); }
240 { this->SetLayoutStrategy(
"Force Directed"); }
242 { this->SetLayoutStrategy(
"Simple 2D"); }
244 { this->SetLayoutStrategy(
"Clustering 2D"); }
246 { this->SetLayoutStrategy(
"Community 2D"); }
248 { this->SetLayoutStrategy(
"Fast 2D"); }
250 { this->SetLayoutStrategy(
"Pass Through"); }
252 { this->SetLayoutStrategy(
"Circular"); }
254 { this->SetLayoutStrategy(
"Tree"); }
256 { this->SetLayoutStrategy(
"Cosmic Tree"); }
258 { this->SetLayoutStrategy(
"Cone"); }
260 { this->SetLayoutStrategy(
"Span Tree"); }
266 virtual void SetLayoutStrategyToAssignCoordinates(
267 const char* xarr,
const char* yarr = 0,
const char* zarr = 0);
280 virtual void SetLayoutStrategyToTree(
283 double leafSpacing = 0.9,
284 double logSpacing = 1.0);
297 virtual void SetLayoutStrategyToCosmicTree(
298 const char* nodeSizeArrayName,
299 bool sizeLeafNodesOnly =
true,
312 { this->SetEdgeLayoutStrategy(
"Arc Parallel"); }
314 { this->SetEdgeLayoutStrategy(
"Pass Through"); }
319 virtual void SetEdgeLayoutStrategyToGeo(
double explodeFactor = 0.2);
323 virtual void SetEdgeLayoutStrategy(
const char*
name);
324 vtkGetStringMacro(EdgeLayoutStrategyName);
335 virtual void SetGlyphType(
int type);
336 virtual int GetGlyphType();
341 virtual void SetScaling(
bool b);
342 virtual bool GetScaling();
343 vtkBooleanMacro(Scaling,
bool);
348 virtual void SetScalingArrayName(
const char*
name);
349 virtual const char* GetScalingArrayName();
354 virtual void SetVertexScalarBarVisibility(
bool b);
355 virtual bool GetVertexScalarBarVisibility();
356 virtual void SetEdgeScalarBarVisibility(
bool b);
357 virtual bool GetEdgeScalarBarVisibility();
361 virtual bool IsLayoutComplete();
364 virtual void UpdateLayout();
367 void ComputeSelectedGraphBounds(
double bounds[6] );
430 vtkSetStringMacro(VertexColorArrayNameInternal);
431 vtkGetStringMacro(VertexColorArrayNameInternal);
434 vtkSetStringMacro(EdgeColorArrayNameInternal);
435 vtkGetStringMacro(EdgeColorArrayNameInternal);
438 vtkSetStringMacro(ScalingArrayNameInternal);
439 vtkGetStringMacro(ScalingArrayNameInternal);
442 vtkSetStringMacro(LayoutStrategyName);
444 vtkSetStringMacro(EdgeLayoutStrategyName);