29 #ifndef vtkChartLegend_h
30 #define vtkChartLegend_h
32 #include "vtkChartsCoreModule.h"
57 vtkSetVector2Macro(Point,
float);
64 vtkGetVector2Macro(Point,
float);
92 vtkSetMacro(HorizontalAlignment,
int);
99 vtkGetMacro(HorizontalAlignment,
int);
107 vtkSetMacro(VerticalAlignment,
int);
114 vtkGetMacro(VerticalAlignment,
int);
121 vtkSetMacro(Padding,
int);
128 vtkGetMacro(Padding,
int);
135 vtkSetMacro(SymbolWidth,
int);
142 vtkGetMacro(SymbolWidth,
int);
148 virtual void SetLabelSize(
int size);
153 virtual int GetLabelSize();
161 vtkSetMacro(
Inline,
bool);
162 vtkGetMacro(
Inline,
bool);
172 vtkSetMacro(DragEnabled,
bool);
173 vtkGetMacro(DragEnabled,
bool);
229 vtkSetMacro(CacheBounds,
bool);
230 vtkGetMacro(CacheBounds,
bool);
231 vtkBooleanMacro(CacheBounds,
bool);
322 #endif // vtkChartLegend_h
base class for items that are part of a vtkContextScene.
virtual bool MouseButtonPressEvent(const vtkContextMouseEvent &mouse)
Mouse button down event Return true if the item holds the event, false if the event can be propagated...
virtual bool Paint(vtkContext2D *painter)
Paint event for the item, called whenever the item needs to be drawn.
record modification and/or execution time
bool DragEnabled
Should we move the legend box around in response to the mouse drag?
bool Inline
Should the legend be drawn inline in its chart?
int Padding
Padding between symbol and text.
Class for drawing 2D primitives to a graphical context.
Factory class for drawing 2D charts.
provides a brush that fills shapes drawn by vtkContext2D.
data structure to represent mouse events.
a simple class to control print indentation
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual bool MouseButtonReleaseEvent(const vtkContextMouseEvent &mouse)
Mouse button release event.
vtkNew< vtkBrush > Brush
The brush used to render the background of the legend.
provides a pen that draws the outlines of shapes drawn by vtkContext2D.
represent text properties.
int SymbolWidth
Width of the symbols in pixels in the legend.
int Button
Last button to be pressed.
bool CacheBounds
Should the legend attempt to avoid recalculating its position & bounds unnecessarily?
virtual bool MouseMoveEvent(const vtkContextMouseEvent &mouse)
Mouse move event.
virtual bool Hit(const vtkContextMouseEvent &mouse)
Return true if the supplied x, y coordinate is inside the item.
vtkNew< vtkTextProperty > LabelProperties
The text properties of the labels used in the legend.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
virtual void Update()
Perform any updates to the item that may be necessary before rendering.
vtkNew< vtkPen > Pen
The pen used to draw the legend box.