vtkRulerSourceRepresentation.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Kitware Inc.
2 // SPDX-License-Identifier: BSD-3-Clause
10 #ifndef vtkRulerSourceRepresentation_h
11 #define vtkRulerSourceRepresentation_h
12 
13 #include "vtkNew.h" //needed for instances of vtkPolyData
15 #include "vtkRemotingViewsModule.h" //needed for exports
16 
18 class vtkPolyData;
19 class vtkProperty2D;
20 class vtkTextProperty;
21 
23 {
24 public:
27  void PrintSelf(ostream& os, vtkIndent indent) override;
28 
30 
33  void SetDistanceRepresentation(vtkDistanceRepresentation2D*);
34  vtkGetObjectMacro(DistanceRepresentation, vtkDistanceRepresentation2D);
36 
40  void SetTextProperty(vtkTextProperty* prop);
41 
45  void SetAxisLineWidth(float width);
46 
50  void SetAxisColor(double red, double green, double blue);
51 
55  void SetVisibility(bool) override;
56 
62  void SetLabelFormat(char* labelFormat);
63 
65 
72  void SetRulerMode(int choice);
73  int GetRulerMode();
75 
77 
82  void SetRulerDistance(double distance);
83  double GetRulerDistance();
85 
87 
92  void SetScale(double distance);
93  double GetScale();
95 
101  void SetNumberOfRulerTicks(int numberOfRulerTicks);
102 
110  vtkInformation* outInfo) override;
111 
112 protected:
114  ~vtkRulerSourceRepresentation() override;
115 
117 
121  int FillInputPortInformation(int port, vtkInformation* info) override;
122 
128  bool AddToView(vtkView* view) override;
129 
135  bool RemoveFromView(vtkView* view) override;
136 
139 
140 private:
142  void operator=(const vtkRulerSourceRepresentation&) = delete;
143 };
144 
145 #endif
#define VTKREMOTINGVIEWS_EXPORT
vtkPVDataRepresentation adds some ParaView specific API to data representations.
bool AddToView(vtkView *view) override
Making these methods public.
virtual void SetVisibility(bool val)
Get/Set the visibility for this representation.
virtual int ProcessViewRequest(vtkInformationRequestKey *request_type, vtkInformation *inInfo, vtkInformation *outInfo)
vtkAlgorithm::ProcessRequest() equivalent for rendering passes.
virtual int FillInputPortInformation(int port, vtkInformation *info)
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
Overridden to invoke vtkCommand::UpdateDataEvent.
vtkDistanceRepresentation2D * DistanceRepresentation
bool RemoveFromView(vtkView *view) override
Making these methods public.
static vtkDataRepresentation * New()
vtkRulerSourceRepresentation is a representation to show a ruler.
void PrintSelf(ostream &os, vtkIndent indent) override