The LinePattern class is a concept class for line-pattern-related enum classes. More...
#include <hps.h>
Public Types | |
enum | SizeUnits : uint32_t { SizeUnits::ObjectSpace, SizeUnits::SubscreenRelative, SizeUnits::WindowRelative, SizeUnits::WorldSpace, SizeUnits::Points, SizeUnits::Pixels, SizeUnits::ScaleFactor } |
Enumerates the units used when specifying length, weight and offsets for line patterns. More... | |
enum | InsetBehavior : uint32_t { InsetBehavior::Overlap, InsetBehavior::Trim, InsetBehavior::Inline } |
Enumerates how glyphs interact with other line pattern elements within a line pattern. More... | |
enum | Join : uint32_t { Join::Mitre, Join::Round, Join::Bevel } |
Enumerates the types of join to use for a line pattern. More... | |
enum | Cap : uint32_t { Cap::Butt, Cap::Square, Cap::Round, Cap::Mitre } |
Enumerates the predefined cap types that can be used at the ends of line segments within a line pattern. More... | |
enum | Justification : uint32_t { Justification::Center, Justification::Stretch } |
Enumerates the justfication modes for a line pattern. More... | |
enum | Modifier : uint32_t { Modifier::GlyphName, Modifier::Enumerated } |
Enumerates the types of joins, start caps, and end caps that can be set when a line pattern attribute is set. More... | |
enum | Default : uint32_t { Default::Solid, Default::DashDot, Default::Dashed, Default::Dotted, Default::Dash2Dot, Default::Dash3Dot, Default::LongDash, Default::LongDashShortDash, Default::LongDash2ShortDash, Default::FineDot } |
Private Member Functions | |
LinePattern () | |
The LinePattern class is a concept class for line-pattern-related enum classes.
|
strong |
Enumerates the predefined cap types that can be used at the ends of line segments within a line pattern.
Enumerator | |
---|---|
Butt | Line segments will end with a flat cap perpendicular to the line segment vector. This cap will occur immediately at the end of the line segment and will not extend its length. |
Square | Line segments will end with half of a filled square cap whose side is perpendicular to the line segment vector. This cap will extend the length of a line segment, but otherwise will appear the same as the ButtCap. |
Round | Line segments will end with half of a filled circle cap whose diameter is perpendicular to the line segment vector. This cap will extend the length of a line segment. |
Mitre | Line segments will end with a filled triangle cap whose base is perpendicular to the line segment vector. This cap will extend the length of a line segment. |
|
strong |
Enumerates the predefined line patterns in Visualize. These can be accessed via the LinePatternKit::GetDefault function and their appearance can be seen here. Hardware acceleration for line patterns is available when the following conditions are met:
The following line patterns can be hardware accelerated: Dashed, Dotted, DashDot, Dash2Dot, Dash3Dot, LongDash, FineDot. The pattern does not continue along adjacent edges. The pattern is restarted for each edge.
|
strong |
Enumerates how glyphs interact with other line pattern elements within a line pattern.
Enumerator | |
---|---|
Overlap | Glyphs will overlap with surrounding line pattern elements. Line pattern elements adjacent to glyphs will not be trimmed. |
Trim | Glyphs will overlap with surrounding line pattern elements. Line pattern elements adjacent to glyphs will be trimmed. |
Inline | Glyphs will not overlap with surrounding line pattern elements, and adjacent line pattern elements will not be trimmed. |
|
strong |
Enumerates the types of join to use for a line pattern.
Joins will always be mitred at the half angle for the smaller angle defined by two line segments. This enumeration defines what the join will look like for the larger angle defined by two line segments.
Enumerator | |
---|---|
Mitre | The join for the larger angle will be mitred, i.e., the segments will meet at a point at the half angle of the larger angle. |
Round | The join for the larger angle will be rounded, i.e., there will be a circle that subtends the larger angle. |
Bevel | The join for the larger angle will be beveled, i.e., there will be a line that subtends the larger angle. |
|
strong |
Enumerates the justfication modes for a line pattern.
These are used to attempt to make the line pattern appear evenly spaced between end points of a line.
|
strong |
|
strong |
Enumerates the units used when specifying length, weight and offsets for line patterns.
Enumerator | |
---|---|
ObjectSpace | Object space units ignoring any scaling components in modelling matrices. |
SubscreenRelative | Fraction of the height of the outermost window. |
WindowRelative | Fraction of the height of the local window. |
WorldSpace | Object space units including any scaling components in modelling matrices and cameras. |
Points | Points units typically used for text size. 1 point corresponds to 1/72 inch. |
Pixels | Number of pixels. |
ScaleFactor | Fraction of the default line width. A value of 1 corresponds to 0.1 percent of the screen size. |
|
inlineprivate |