Scroom  0.14
RectangleVerticalTestScaffold Class Reference
Inheritance diagram for RectangleVerticalTestScaffold:
Inheritance graph
Collaboration diagram for RectangleVerticalTestScaffold:
Collaboration graph

Public Member Functions

 RectangleVerticalTestScaffold (int verticalStart, int verticalSize)
 
 RectangleVerticalTestScaffold ()=default
 
 RectangleVerticalTestScaffold (const Rectangle< int > &r)
 
int getSize () const
 
int getStart () const
 
int getEnd () const
 
bool contains (int y) const
 
bool contains (const RectangleVerticalTestScaffold &other) const
 
RectangleVerticalTestScaffold intersection (const RectangleVerticalTestScaffold &other) const
 
Rectangle moveTo (int y)
 
- Public Member Functions inherited from Scroom::Utils::Rectangle< int >
 Rectangle ()=default
 
 Rectangle (value_type x_, value_type y_, value_type width_, value_type height_)
 
 Rectangle (const Segment< value_type > &horizontally_, const Segment< value_type > &vertically_)
 
 Rectangle (const cairo_rectangle_int_t &rect)
 
 Rectangle (typename std::enable_if<!T_is_int, Rectangle< int > const & >::type rect)
 
cairo_rectangle_int_t toGdkRectangle () const
 
Rectangle moveTo (xy_type const &other) const
 
Rectangle moveTo (value_type const &x, value_type const &y) const
 
bool contains (xy_type const &other) const
 
bool contains (const Rectangle &other) const
 
bool intersects (const Rectangle &other) const
 
void reduceSizeToMultipleOf (value_type size)
 
Rectangle intersection (const Rectangle &other) const
 
Rectangle< typename std::common_type< int, U >::type > intersection (const Rectangle< U > &other) const
 
value_type getTop () const
 
value_type getLeft () const
 
value_type getBottom () const
 
value_type getRight () const
 
void setTop (value_type v)
 
void setLeft (value_type v)
 
void setBottom (value_type v)
 
void setRight (value_type v)
 
value_type getWidth () const
 
value_type getHeight () const
 
value_type x () const
 
value_type y () const
 
value_type width () const
 
value_type height () const
 
xy_type getTopLeft () const
 
xy_type getTopRight () const
 
xy_type getBottomLeft () const
 
xy_type getBottomRight () const
 
bool isEmpty () const
 
Rectangle< value_typeleftOf (value_type v) const
 
Rectangle< value_typeleftOf (Rectangle< value_type > const &r) const
 
Rectangle< value_typerightOf (value_type v) const
 
Rectangle< value_typerightOf (Rectangle< value_type > const &r) const
 
Rectangle< value_typeabove (value_type v) const
 
Rectangle< value_typeabove (Rectangle< value_type > const &r) const
 
Rectangle< value_typebelow (value_type v) const
 
Rectangle< value_typebelow (Rectangle< value_type > const &r) const
 
bool operator== (const Rectangle &other) const
 
bool operator!= (const Rectangle &other) const
 
Rectangle< value_type > & operator+= (xy_type const &other)
 
Rectangle< value_type > & operator-= (xy_type const &other)
 
Rectangle< value_type > & operator*= (value_type other)
 
Rectangle< value_type > & operator*= (xy_type const &other)
 
Rectangle< value_type > & operator/= (value_type other)
 
Rectangle< value_type > & operator/= (xy_type const &other)
 
const Segment< value_type > & getHorizontally () const
 
const Segment< value_type > & getVertically () const
 
void setSize (xy_type const &s)
 
xy_type getSize () const
 
Rectangle< U > to () const
 

Static Private Attributes

static const int horizontalStart = -1
 
static const int horizontalContainedStart = 0
 
static const int horizontalContainedWidth = 1
 
static const int horizontalSize = 5
 

Additional Inherited Members

- Public Types inherited from Scroom::Utils::Rectangle< int >
using value_type = int
 
using xy_type = Point< int >
 

Constructor & Destructor Documentation

◆ RectangleVerticalTestScaffold() [1/3]

RectangleVerticalTestScaffold::RectangleVerticalTestScaffold ( int  verticalStart,
int  verticalSize 
)
inline
75  : Rectangle(horizontalStart, verticalStart, horizontalSize, verticalSize)
76  {
77  }

◆ RectangleVerticalTestScaffold() [2/3]

RectangleVerticalTestScaffold::RectangleVerticalTestScaffold ( )
default

◆ RectangleVerticalTestScaffold() [3/3]

RectangleVerticalTestScaffold::RectangleVerticalTestScaffold ( const Rectangle< int > &  r)
inline
82  : Rectangle(r)
83  {
84  }

Member Function Documentation

◆ contains() [1/2]

bool RectangleVerticalTestScaffold::contains ( const RectangleVerticalTestScaffold other) const
inline
91 { return Rectangle<int>::contains(other); }

◆ contains() [2/2]

bool RectangleVerticalTestScaffold::contains ( int  y) const
inline
89 { return Rectangle::contains(make_point(horizontalContainedStart, y)); }
Here is the call graph for this function:

◆ getEnd()

int RectangleVerticalTestScaffold::getEnd ( ) const
inline
88 { return getTop() + getHeight(); }
Here is the call graph for this function:

◆ getSize()

int RectangleVerticalTestScaffold::getSize ( ) const
inline
86 { return getHeight(); }
Here is the call graph for this function:

◆ getStart()

int RectangleVerticalTestScaffold::getStart ( ) const
inline
87 { return getTop(); }
Here is the call graph for this function:

◆ intersection()

RectangleVerticalTestScaffold RectangleVerticalTestScaffold::intersection ( const RectangleVerticalTestScaffold other) const
inline
94  {
95  return Rectangle<int>::intersection(other);
96  }

◆ moveTo()

Rectangle RectangleVerticalTestScaffold::moveTo ( int  y)
inline
98 { return Rectangle::moveTo(make_point(horizontalContainedStart, y)); }
Here is the call graph for this function:

Member Data Documentation

◆ horizontalContainedStart

const int RectangleVerticalTestScaffold::horizontalContainedStart = 0
staticprivate

Referenced by contains(), and moveTo().

◆ horizontalContainedWidth

const int RectangleVerticalTestScaffold::horizontalContainedWidth = 1
staticprivate

◆ horizontalSize

const int RectangleVerticalTestScaffold::horizontalSize = 5
staticprivate

◆ horizontalStart

const int RectangleVerticalTestScaffold::horizontalStart = -1
staticprivate

The documentation for this class was generated from the following file:
Scroom::Utils::Rectangle< int >::getHeight
value_type getHeight() const
Definition: rectangle.hh:123
RectangleVerticalTestScaffold::horizontalSize
static const int horizontalSize
Definition: rectangletests.cc:71
Scroom::Utils::make_point
Point< T > make_point(T x, T y)
Definition: point.hh:116
Scroom::Utils::Rectangle< int >::Rectangle
Rectangle()=default
RectangleVerticalTestScaffold::horizontalContainedStart
static const int horizontalContainedStart
Definition: rectangletests.cc:69
Scroom::Utils::Rectangle< int >::y
value_type y() const
Definition: rectangle.hh:127
Scroom::Utils::Rectangle
Definition: rectangle.hh:22
Scroom::Utils::Rectangle< int >::getTop
value_type getTop() const
Definition: rectangle.hh:108
RectangleVerticalTestScaffold::horizontalStart
static const int horizontalStart
Definition: rectangletests.cc:68