Medical Imaging Interaction Toolkit  2022.04.99-685cdc74
Medical Imaging Interaction Toolkit
mitkScaleLegendAnnotation.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef SCALELEGENDAnnotation_H
14 #define SCALELEGENDAnnotation_H
15 
16 #include "MitkAnnotationExports.h"
18 #include <mitkVtkAnnotation.h>
19 #include <vtkSmartPointer.h>
20 
21 class vtkLegendScaleActor;
22 
23 namespace mitk
24 {
27  {
28  public:
30  {
31  public:
33  vtkSmartPointer<vtkLegendScaleActor> m_legendScaleActor;
34 
36  itk::TimeStamp m_LastUpdateTime;
37 
39  LocalStorage();
41  ~LocalStorage();
42  };
43 
45  itkFactorylessNewMacro(Self);
46  itkCloneMacro(Self);
47 
48  void SetRightAxisVisibility(bool visibility);
49  bool GetRightAxisVisibility() const;
50 
51  void SetLeftAxisVisibility(bool visibility);
52  bool GetLeftAxisVisibility() const;
53 
54  void SetTopAxisVisibility(bool visibility);
55  bool GetTopAxisVisibility() const;
56 
57  void SetBottomAxisVisibility(bool visibility);
58  bool GetBottomAxisVisibility() const;
59 
60  void SetLegendVisibility(bool visibility);
61  bool GetLegendVisibility() const;
62 
63  void SetRightBorderOffset(int offset);
64  int GetRightBorderOffset() const;
65 
66  void SetLeftBorderOffset(int offset);
67  int GetLeftBorderOffset() const;
68 
69  void SetTopBorderOffset(int offset);
70  int GetTopBorderOffset() const;
71 
72  void SetBottomBorderOffset(int offset);
73  int GetBottomBorderOffset() const;
74 
75  void SetFontFactor(double fontFactor);
76  double GetFontFactor() const;
77 
78  void SetCornerOffsetFactor(double offsetFactor);
79  double GetCornerOffsetFactor() const;
80 
81  protected:
84 
85  vtkProp *GetVtkProp(BaseRenderer *renderer) const override;
86  void UpdateVtkAnnotation(BaseRenderer *renderer) override;
87 
89  explicit ScaleLegendAnnotation();
90 
92  ~ScaleLegendAnnotation() override;
93 
94  private:
97 
99  ScaleLegendAnnotation &operator=(const ScaleLegendAnnotation &);
100  };
101 
102 } // namespace mitk
103 #endif // SCALELEGENDAnnotation_H
#define MITKANNOTATION_EXPORT
Organizes the rendering process.
vtkSmartPointer< vtkLegendScaleActor > m_legendScaleActor
Actor of a 2D render window.
DataCollection - Class to facilitate loading/accessing structured data.
Base class for mapper specific rendering ressources.
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:36
The VtkAnnotation class is the base for all Annotation which are using the VTK framework to render th...
itk::TimeStamp m_LastUpdateTime
Timestamp of last update of stored data.
Base class for all Annotation This class is to be implemented in order to create Annotation which are...
Displays configurable scales on the renderwindow. The scale is determined by the image spacing...
mitk::LocalStorageHandler< LocalStorage > m_LSH
The LocalStorageHandler holds all LocalStorages for the render windows.