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

Style class for a filled, rectangular region. More...

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

Public Member Functions

 RectangleStyle (RectangleStyle &&)=default
 Default move constructor.
 
 RectangleStyle (const RectangleStyle &)=default
 Default copy constructor.
 
RectangleStyleoperator= (RectangleStyle &&)=default
 Default move assignment.
 
RectangleStyleoperator= (const RectangleStyle &)=default
 Default copy assignment.
 
 RectangleStyle (FillStyle f)
 Initialize using a FillStyle.
 
double borderT () const
 Returns the border width if the top border is to be drawn, 0 otherwise.
 
double borderR () const
 Returns the border width if the right border is to be drawn, 0 otherwise.
 
double borderB () const
 Returns the border width if the bottom border is to be drawn, 0 otherwise.
 
double borderL () const
 Returns the border width if the left border is to be drawn, 0 otherwise.
 
double borderLR () const
 Returns the total drawn horizontal border width, i.e. borderR() + borderL()
 
double borderTB () const
 Returns the total drawn vertical border width, i.e. borderT() + borderB()
 
- Public Member Functions inherited from creativity::data::graph::FillStyle
 FillStyle (RGBA fill)
 Constructs a FillStyle using just a fill colour: the borders will be omitted (i.e. More...
 
 FillStyle (RGBA fill, LineStyle border)
 Constructs a FillStyle using a fill colour and line style for the borders. More...
 
 FillStyle (LineStyle border)
 Constructs a FillStyle using just a LineStyle; the fill will be omitted (i.e. transparent).
 
 FillStyle (FillStyle &&)=default
 Move constructor.
 
 FillStyle (const FillStyle &)=default
 Copy constructor.
 
FillStyleoperator= (FillStyle &&)=default
 Default move assignment.
 
FillStyleoperator= (const FillStyle &)=default
 Default copy assignment.
 

Public Attributes

bool border_top = true
 
bool border_right = true
 
bool border_bottom = true
 
bool border_left = true
 
- Public Attributes inherited from creativity::data::graph::FillStyle
RGBA fill_colour
 The fill colour for the region.
 
LineStyle border
 The border colour for the region.
 

Detailed Description

Style class for a filled, rectangular region.

In addition to the fill colour and border of a FillStyle, this also allows any of the 4 borders to be disabled.

Member Data Documentation

§ border_bottom

bool creativity::data::graph::RectangleStyle::border_bottom = true

True if the named border should be drawn, false if not. Only applies when drawing rectangles.

§ border_left

bool creativity::data::graph::RectangleStyle::border_left = true

True if the named border should be drawn, false if not. Only applies when drawing rectangles.

§ border_right

bool creativity::data::graph::RectangleStyle::border_right = true

True if the named border should be drawn, false if not. Only applies when drawing rectangles.

§ border_top

bool creativity::data::graph::RectangleStyle::border_top = true

True if the named border should be drawn, false if not. Only applies when drawing rectangles.

Inheritance diagram for creativity::data::graph::RectangleStyle:
[legend]
Collaboration diagram for creativity::data::graph::RectangleStyle:
[legend]

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