Scenic v0.10.2 Scenic.Primitive.Triangle View Source
Draw a triangle on the screen.
Data
{point_a, point_b, point_c}
The data for a line is a tuple containing three points.
point_a
- position to start drawing frompoint_b
- position to draw topoint_c
- position to draw to
Styles
This primitive recognizes the following styles
hidden
- show or hide the primitivefill
- fill in the area of the primitivestroke
- stroke the outline of the primitive. In this case, only the curvy part.join
- control how segments are joined.miter_limit
- control how segments are joined.
Usage
You should add/modify primitives via the helper functions in
Scenic.Primitives
Link to this section Summary
Functions
Returns the centroid of the triangle. This is used as the default pin when applying rotate or scale transforms
Returns a list of styles recognized by this primitive
Link to this section Functions
Link to this function
centroid(data) View Source
Returns the centroid of the triangle. This is used as the default pin when applying rotate or scale transforms.
Link to this function
valid_styles()
View Source
valid_styles()
View Source
valid_styles() :: [:fill | :hidden | :stroke, ...]
valid_styles() :: [:fill | :hidden | :stroke, ...]
Returns a list of styles recognized by this primitive.