casa::PlotCanvasLayout Class Reference

Base class for any layout. More...

#include <PlotCanvasLayout.h>

Inheritance diagram for casa::PlotCanvasLayout:
casa::PlotLayoutGrid casa::PlotLayoutSingle

List of all members.

Public Member Functions

 PlotCanvasLayout ()
 Constructor.
virtual ~PlotCanvasLayout ()
 Destructor.
virtual Plotterplotter () const
 Returns the plotter this layout is used in, or NULL for none.
virtual void attach (Plotter *p)
 Attaches this layout to the given plotter.
virtual bool coordIsValid (const PlotLayoutCoordinate &coord) const =0
 ABSTRACT METHODS //.
virtual int coordToIndex (const PlotLayoutCoordinate &coord) const =0
 turn the coordinate into an index.
virtual void setCanvasAt (const PlotLayoutCoordinate &coord, PlotCanvasPtr canvas)=0
 Sets the canvas at the given coordinate to the given canvas.
virtual PlotCanvasPtr canvasAt (const PlotLayoutCoordinate &coord) const =0
 Returns the canvas at the given coordinate.
virtual PlotCanvasPtr canvas () const =0
 For single layouts, returns the canvas; otherwise returns the "first".
virtual vector< PlotCanvasPtrallCanvases () const =0
 Returns all canvases in this layout.
virtual bool isValid () const =0
 Indicates whether the layout is valid.
virtual unsigned int spacing () const =0
 Gets/sets the spacing between the canvases in the layout.
virtual void setSpacing (unsigned int spacing)=0

Protected Attributes

Plotterm_plotter

Detailed Description

Base class for any layout.

Definition at line 52 of file PlotCanvasLayout.h.


Constructor & Destructor Documentation

casa::PlotCanvasLayout::PlotCanvasLayout (  )  [inline]

Constructor.

Definition at line 55 of file PlotCanvasLayout.h.

virtual casa::PlotCanvasLayout::~PlotCanvasLayout (  )  [inline, virtual]

Destructor.

Definition at line 58 of file PlotCanvasLayout.h.


Member Function Documentation

virtual vector<PlotCanvasPtr> casa::PlotCanvasLayout::allCanvases (  )  const [pure virtual]

Returns all canvases in this layout.

Implemented in casa::PlotLayoutSingle, and casa::PlotLayoutGrid.

virtual void casa::PlotCanvasLayout::attach ( Plotter p  )  [inline, virtual]

Attaches this layout to the given plotter.

The plotter's layoutOptionsChanged method can then be called when the layout changes.

Definition at line 66 of file PlotCanvasLayout.h.

References m_plotter.

virtual PlotCanvasPtr casa::PlotCanvasLayout::canvas (  )  const [pure virtual]

For single layouts, returns the canvas; otherwise returns the "first".

Implemented in casa::PlotLayoutSingle, and casa::PlotLayoutGrid.

virtual PlotCanvasPtr casa::PlotCanvasLayout::canvasAt ( const PlotLayoutCoordinate coord  )  const [pure virtual]

Returns the canvas at the given coordinate.

Implemented in casa::PlotLayoutSingle, and casa::PlotLayoutGrid.

virtual bool casa::PlotCanvasLayout::coordIsValid ( const PlotLayoutCoordinate coord  )  const [pure virtual]

ABSTRACT METHODS //.

Returns true if the given coordinate is valid for this layout.

Implemented in casa::PlotLayoutSingle, and casa::PlotLayoutGrid.

virtual int casa::PlotCanvasLayout::coordToIndex ( const PlotLayoutCoordinate coord  )  const [pure virtual]

turn the coordinate into an index.

the index should >= 0 and < the total number of canvases in the layout.

Implemented in casa::PlotLayoutSingle, and casa::PlotLayoutGrid.

virtual bool casa::PlotCanvasLayout::isValid (  )  const [pure virtual]

Indicates whether the layout is valid.

Implemented in casa::PlotLayoutSingle, and casa::PlotLayoutGrid.

virtual Plotter* casa::PlotCanvasLayout::plotter (  )  const [inline, virtual]

Returns the plotter this layout is used in, or NULL for none.

Definition at line 62 of file PlotCanvasLayout.h.

References m_plotter.

virtual void casa::PlotCanvasLayout::setCanvasAt ( const PlotLayoutCoordinate coord,
PlotCanvasPtr  canvas 
) [pure virtual]

Sets the canvas at the given coordinate to the given canvas.

Implemented in casa::PlotLayoutSingle, and casa::PlotLayoutGrid.

virtual void casa::PlotCanvasLayout::setSpacing ( unsigned int  spacing  )  [pure virtual]
virtual unsigned int casa::PlotCanvasLayout::spacing (  )  const [pure virtual]

Gets/sets the spacing between the canvases in the layout.

May not be valid for all layout types. The implementation for Plotter should use this attribute appropriately.

Implemented in casa::PlotLayoutSingle, and casa::PlotLayoutGrid.


Member Data Documentation

Definition at line 103 of file PlotCanvasLayout.h.

Referenced by attach(), and plotter().


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on 31 Aug 2016 for casa by  doxygen 1.6.1