creativity  v1.3.0
Agent-based model of creativity and piracy
Public Member Functions | Public Attributes | List of all members
creativity::data::graph::LineStyle Class Reference

Style class for a drawn line. More...

#include <creativity/data/graph/style.hpp>

Public Member Functions

 LineStyle (RGBA rgba, double thickness=1.0, double length=std::numeric_limits< double >::quiet_NaN())
 Constructs a line style directly from an Gdk::RGBA object. More...
 
void applyTo (Cairo::RefPtr< Cairo::Context > ctx) const
 Applies the line style to the given Cairo::Context.
 

Public Attributes

RGBA colour
 The colour of the line.
 
double thickness
 The thickness of the line.
 
double length
 Length of the line, if applicable. More...
 

Detailed Description

Style class for a drawn line.

Constructor & Destructor Documentation

§ LineStyle()

creativity::data::graph::LineStyle::LineStyle ( RGBA  rgba,
double  thickness = 1.0,
double  length = std::numeric_limits<double>::quiet_NaN() 
)
inline

Constructs a line style directly from an Gdk::RGBA object.

Member Data Documentation

§ length

double creativity::data::graph::LineStyle::length

Length of the line, if applicable.

This is used for things like tick marks where thickness is the line width and this is the line length. In other cases, this value is unused.

Collaboration diagram for creativity::data::graph::LineStyle:
[legend]

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