|
| LinearGradient (cairo_pattern_t*cobject, bool has_reference=false) |
| Create a C++ wrapper for the C instance. More...
|
|
void | get_linear_points (double& x0, double& y0, double& x1, double& y1) const |
|
| ~LinearGradient () override |
|
| Gradient (cairo_pattern_t*cobject, bool has_reference=false) |
| Create a C++ wrapper for the C instance. More...
|
|
| ~Gradient () override |
|
void | add_color_stop_rgb (double offset, double red, double green, double blue) |
| Adds an opaque color stop to a gradient pattern. More...
|
|
void | add_color_stop_rgba (double offset, double red, double green, double blue, double alpha) |
| Adds a translucent color stop to a gradient pattern. More...
|
|
std::vector< ColorStop > | get_color_stops () const |
| Gets the color stops and offsets for this Gradient. More...
|
|
| Pattern (cairo_pattern_t*cobject, bool has_reference=false) |
| Create a C++ wrapper for the C instance. More...
|
|
| Pattern (const Pattern&)=delete |
|
Pattern& | operator= (const Pattern&)=delete |
|
virtual | ~Pattern () |
|
void | set_matrix (const Matrix& matrix) |
| Sets the pattern's transformation matrix to . More...
|
|
void | get_matrix (Matrix& matrix) const |
| Returns the pattern's transformation matrix. More...
|
|
Matrix | get_matrix () const |
| Returns the pattern's transformation matrix. More...
|
|
void | set_matrix (const cairo_matrix_t& matrix) |
|
void | get_matrix (cairo_matrix_t& matrix) const |
|
PatternType | get_type () const |
| Returns the type of the pattern. More...
|
|
void | set_extend (Extend extend) |
| Sets the mode to be used for drawing outside the area of a pattern. More...
|
|
Extend | get_extend () const |
| Gets the current extend mode See Cairo::Extend for details on the semantics of each extend strategy. More...
|
|
cobject* | cobj () |
|
const cobject* | cobj () const |
|
void | reference () const |
|
void | unreference () const |
|
static RefPtr<LinearGradient> Cairo::LinearGradient::create |
( |
double |
x0, |
|
|
double |
y0, |
|
|
double |
x1, |
|
|
double |
y1 |
|
) |
| |
|
static |
Create a new linear gradient Cairo::Pattern along the line defined by (x0, y0) and (x1, y1).
Before using the gradient pattern, a number of color stops should be defined using Cairo::Gradient::add_color_stop_rgb() or Cairo::Gradient::add_color_stop_rgba().
Note: The coordinates here are in pattern space. For a new pattern, pattern space is identical to user space, but the relationship between the spaces can be changed with Cairo::Pattern::set_matrix().
- Parameters
-
x0 | x coordinate of the start point |
y0 | y coordinate of the start point |
x1 | x coordinate of the end point |
y1 | y coordinate of the end point |