DGtal 1.3.0
Loading...
Searching...
No Matches
Public Member Functions | Data Fields
DGtal::CustomColors Struct Reference

Custom style class redefining the pen color and the fill color. You may use Board2D::Color::None for transparent color. More...

#include <DGtal/io/boards/Board2D.h>

Inheritance diagram for DGtal::CustomColors:
DGtal::DrawableWithBoard2D

Public Member Functions

 CustomColors (const Color &penColor, const Color &fillColor)
 
virtual void setStyle (Board2D &aboard) const
 
- Public Member Functions inherited from DGtal::DrawableWithBoard2D
virtual void setStyle (Board2D &) const
 
virtual ~DrawableWithBoard2D ()
 

Data Fields

Color myPenColor
 
Color myFillColor
 

Detailed Description

Custom style class redefining the pen color and the fill color. You may use Board2D::Color::None for transparent color.

Board2D board;
board << CustomColors( Board2D::Color::Red, Board2D::Color::None );
...
Aim: This class specializes a 'Board' class so as to display DGtal objects more naturally (with <<)....
Definition: Board2D.h:71
Custom style class redefining the pen color and the fill color. You may use Board2D::Color::None for ...
Definition: Board2D.h:279
See also
Board2D
Examples
arithmetic/lower-integer-convex-hull.cpp, geometry/curves/exampleAlphaThickSegment.cpp, geometry/curves/exampleAlphaThickSegmentNoisy.cpp, geometry/curves/exampleArithmeticalDSS.cpp, geometry/curves/exampleRationalConvexity.cpp, geometry/surfaces/dvcm-2d-curvature.cpp, geometry/volumes/distance/distancetransform2D.cpp, geometry/volumes/distance/toricdomainvolumetric.cpp, geometry/volumes/distance/voronoimap2D.cpp, geometry/volumes/dvcm-2d.cpp, geometry/volumes/fullConvexityCollapsiblePoints2D.cpp, geometry/volumes/fullConvexityLUT2D.cpp, graph/graphTraversal.cpp, io/boards/dgtalBoard2D-3-custom-classes.cpp, io/boards/dgtalBoard2D-4-colormaps.cpp, topology/ctopo-1.cpp, topology/ctopo-2.cpp, topology/ctopo-fillContours.cpp, topology/cubical-complex-illustrations.cpp, topology/digitalSetToCubicalComplexes2D.cpp, topology/generateSimplicityTables2D.cpp, and tutorial-examples/freemanChainFromImage.cpp.

Definition at line 278 of file Board2D.h.

Constructor & Destructor Documentation

◆ CustomColors()

DGtal::CustomColors::CustomColors ( const Color penColor,
const Color fillColor 
)
inline

Constructor.

Parameters
penColorspecifies the pen color.
fillColorspecifies the fill color.

Definition at line 289 of file Board2D.h.

291 : myPenColor( penColor ), myFillColor( fillColor )
292 {}

Member Function Documentation

◆ setStyle()

virtual void DGtal::CustomColors::setStyle ( Board2D ) const
inlinevirtual

Operation to override. Does nothing by default.

Reimplemented from DGtal::DrawableWithBoard2D.

Definition at line 294 of file Board2D.h.

295 {
296 aboard.setFillColor( myFillColor);
297 aboard.setPenColor( myPenColor );
298 }

References myFillColor, myPenColor, LibBoard::Board::setFillColor(), and LibBoard::Board::setPenColor().

Field Documentation

◆ myFillColor

Color DGtal::CustomColors::myFillColor

Definition at line 281 of file Board2D.h.

Referenced by setStyle().

◆ myPenColor

Color DGtal::CustomColors::myPenColor

Definition at line 280 of file Board2D.h.

Referenced by setStyle().


The documentation for this struct was generated from the following file: