roo_display
API Documentation for roo_display
Loading...
Searching...
No Matches
roo_display::Line Class Reference

A straight line segment between two points. More...

#include <basic.h>

Inheritance diagram for roo_display::Line:
[legend]
Collaboration diagram for roo_display::Line:
[legend]

Public Member Functions

 Line (Point a, Point b, Color color)
 
 Line (int16_t x0, int16_t y0, int16_t x1, int16_t y1, Color color)
 
Box extents () const override
 Return the bounding box encompassing all pixels that need to be drawn.
 
- Public Member Functions inherited from roo_display::BasicShape
Color color () const
 Return the shape color.
 
- Public Member Functions inherited from roo_display::Drawable
virtual ~Drawable ()
 
virtual Box anchorExtents () const
 Return the bounds used for alignment.
 

Additional Inherited Members

- Static Public Member Functions inherited from roo_display::Drawable
static const DrawableEmpty ()
 A singleton representing a no-op drawable with no bounding box.
 
- Protected Member Functions inherited from roo_display::BasicShape
 BasicShape (Color color)
 

Detailed Description

A straight line segment between two points.

Definition at line 24 of file basic.h.

Constructor & Destructor Documentation

◆ Line() [1/2]

roo_display::Line::Line ( Point  a,
Point  b,
Color  color 
)
inline

Definition at line 26 of file basic.h.

◆ Line() [2/2]

roo_display::Line::Line ( int16_t  x0,
int16_t  y0,
int16_t  x1,
int16_t  y1,
Color  color 
)
inline

Definition at line 28 of file basic.h.

Member Function Documentation

◆ extents()

Box roo_display::Line::extents ( ) const
inlineoverridevirtual

Return the bounding box encompassing all pixels that need to be drawn.

This method is called during a transaction and must not block or perform I/O.

Implements roo_display::Drawable.

Definition at line 40 of file basic.h.


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