Defines an object used to draw lines and curves. This class cannot be inherited.
Constructors | |
| template<typename brush_t > | |
| pen (const brush_t &brush) | |
| Initializes a new instance of the xtd::drawing::pen class with the specified xtd::drawing::brush. More... | |
| template<typename brush_t > | |
| pen (const brush_t &brush, float width) | |
| Initializes a new instance of the xtd::drawing::pen class with the specified xtd::drawing::brush. More... | |
| pen (const xtd::drawing::color &color) | |
| Initializes a new instance of the xtd::drawing::pen class with the specified xtd::drawing::color. More... | |
| pen (const xtd::drawing::color &color, float width) | |
| Initializes a new instance of the xtd::drawing::pen class with the specified xtd::drawing::color. More... | |
Properties | |
| xtd::drawing::drawing_2d::pen_alignment | alignment () const noexcept |
| Gets the alignment for this xtd::drawing::pen. More... | |
| xtd::drawing::pen & | alignment (xtd::drawing::drawing_2d::pen_alignment value) |
| Sets the alignment for this xtd::drawing::pen. More... | |
| const std::unique_ptr< xtd::drawing::brush > & | brush () const noexcept |
| Gets the xtd::drawing::brush that determines attributes of this xtd::drawing::pen. More... | |
| template<typename brush_t > | |
| xtd::drawing::pen & | brush (const brush_t &value) |
| Sets the xtd::drawing::brush that determines attributes of this xtd::drawing::pen. More... | |
| const xtd::drawing::color & | color () const noexcept |
| Gets the color of this xtd::drawing::pen. More... | |
| xtd::drawing::pen & | color (const xtd::drawing::color &value) |
| Sets the color of this xtd::drawing::pen. More... | |
| std::vector< float > | dash_pattern () const noexcept |
| Gets an array of custom dashes and spaces. More... | |
| xtd::drawing::pen & | dash_pattern (const std::vector< float > &value) |
| Sets an array of custom dashes and spaces. More... | |
| xtd::drawing::dash_style | dash_style () const noexcept |
| Gets the style used for dashed lines drawn with this xtd::drawing::pen. More... | |
| xtd::drawing::pen & | dash_style (drawing::dash_style value) |
| Sets the style used for dashed lines drawn with this xtd::drawing::pen. More... | |
| xtd::drawing::drawing_2d::line_cap | end_cap () const noexcept |
| Gets the cap style used at the end of lines drawn with this xtd::drawing::pen. More... | |
| xtd::drawing::pen & | end_cap (xtd::drawing::drawing_2d::line_cap value) |
| Sets the cap style used at the end of lines drawn with this xtd::drawing::pen. More... | |
| intptr | handle () const noexcept |
| Gets the handle of the pen. More... | |
| xtd::drawing::drawing_2d::line_join | line_join () const noexcept |
| Gets the join style for the ends of two consecutive lines drawn with this xtd::drawing::pen. More... | |
| xtd::drawing::pen & | line_join (xtd::drawing::drawing_2d::line_join value) |
| Sets the join style for the ends of two consecutive lines drawn with this xtd::drawing::pen. More... | |
| float | miter_limit () const noexcept |
| Gets the limit of the thickness of the join on a mitered corner. More... | |
| xtd::drawing::pen & | miter_limit (float value) |
| Sets the limit of the thickness of the join on a mitered corner. More... | |
| xtd::drawing::drawing_2d::line_cap | start_cap () const noexcept |
| Gets the cap style used at the beginning of lines drawn with this xtd::drawing::pen. More... | |
| xtd::drawing::pen & | start_cap (xtd::drawing::drawing_2d::line_cap value) |
| Sets the cap style used at the beginning of lines drawn with this xtd::drawing::pen. More... | |
| xtd::drawing::drawing_2d::pen_type | type () const noexcept |
| Gets the style of lines drawn with this xtd::drawing::pen. More... | |
| float | width () const noexcept |
| Gets the width of this xtd::drawing::pen, in units of the xtd::drawing::graphics object used for drawing. More... | |
| xtd::drawing::pen & | width (float value) |
| Sets the width of this xtd::drawing::pen, in units of the xtd::drawing::graphics object used for drawing. More... | |
Methods | |
| bool | equals (const xtd::drawing::pen &value) const noexcept override |
| xtd::ustring | to_string () const noexcept override |
| Returns a sxd::ustring that represents the current object. More... | |
Additional Inherited Members | |
Public Member Functions inherited from xtd::object | |
| object ()=default | |
| Create a new instance of the ultimate base class object. More... | |
| bool | equals (const object &obj) const noexcept |
| Determines whether the specified object is equal to the current object. More... | |
| virtual size_t | get_hash_code () const noexcept |
| Serves as a hash function for a particular type. More... | |
| virtual type_object | get_type () const noexcept |
| Gets the type of the current instance. More... | |
| template<typename object_t > | |
| std::unique_ptr< object_t > | memberwise_clone () const noexcept |
| Creates a shallow copy of the current object. More... | |
Public Member Functions inherited from xtd::iequatable< pen > | |
| virtual bool | equals (const pen &) const noexcept=0 |
| Indicates whether the current object is equal to another object of the same type. More... | |
Static Public Member Functions inherited from xtd::object | |
| static bool | equals (const object &object_a, const object &object_b) noexcept |
| Determines whether the specified object instances are considered equal. More... | |
| static bool | reference_equals (const object &object_a, const object &object_b) noexcept |
| Determines whether the specified object instances are the same instance. More... | |
|
inlineexplicit |
Initializes a new instance of the xtd::drawing::pen class with the specified xtd::drawing::brush.
| brush | A xtd::drawing::brush that determines the fill properties of this xtd::drawing::pen. |
|
inline |
Initializes a new instance of the xtd::drawing::pen class with the specified xtd::drawing::brush.
| brush | A xtd::drawing::brush that determines the fill properties of this xtd::drawing::pen. |
| width | A single number that represent the pen width. |
|
explicit |
Initializes a new instance of the xtd::drawing::pen class with the specified xtd::drawing::color.
| color | A xtd::drawing::color structure that indicates the color of this xtd::drawing::pen. |
| xtd::drawing::pen::pen | ( | const xtd::drawing::color & | color, |
| float | width | ||
| ) |
Initializes a new instance of the xtd::drawing::pen class with the specified xtd::drawing::color.
| color | A xtd::drawing::color structure that indicates the color of this xtd::drawing::pen. |
| width | A single number that represent the pen width. |
|
noexcept |
Gets the alignment for this xtd::drawing::pen.
| xtd::drawing::pen& xtd::drawing::pen::alignment | ( | xtd::drawing::drawing_2d::pen_alignment | value | ) |
Sets the alignment for this xtd::drawing::pen.
| value | A xtd::drawing::drawing_2d/::pen_alignment that represents the alignment for this xtd::drawing::pen. |
|
noexcept |
Gets the xtd::drawing::brush that determines attributes of this xtd::drawing::pen.
|
inline |
Sets the xtd::drawing::brush that determines attributes of this xtd::drawing::pen.
| value | A xtd::drawing::brush that determines attributes of this xtd::drawing::pen. |
|
noexcept |
Gets the color of this xtd::drawing::pen.
| xtd::drawing::pen& xtd::drawing::pen::color | ( | const xtd::drawing::color & | value | ) |
Sets the color of this xtd::drawing::pen.
| value | A xtd::drawing::color structure that represents the color of this xtd::drawing::pen. |
|
noexcept |
Gets an array of custom dashes and spaces.
| xtd::drawing::pen& xtd::drawing::pen::dash_pattern | ( | const std::vector< float > & | value | ) |
Sets an array of custom dashes and spaces.
| value | An array of real numbers that specifies the lengths of alternating dashes and spaces in dashed lines. |
|
noexcept |
Gets the style used for dashed lines drawn with this xtd::drawing::pen.
| xtd::drawing::pen& xtd::drawing::pen::dash_style | ( | drawing::dash_style | value | ) |
Sets the style used for dashed lines drawn with this xtd::drawing::pen.
| value | A xtd::drawing::dash_style that represents the style used for dashed lines drawn with this xtd::drawing::pen. |
|
noexcept |
Gets the cap style used at the end of lines drawn with this xtd::drawing::pen.
| xtd::drawing::pen& xtd::drawing::pen::end_cap | ( | xtd::drawing::drawing_2d::line_cap | value | ) |
Sets the cap style used at the end of lines drawn with this xtd::drawing::pen.
| value | One of the xtd::drawing::drawing_2d/::line_cap values that represents the cap style used at the end of lines drawn with this xtd::drawing::pen. |
|
noexcept |
Gets the handle of the pen.
|
noexcept |
Gets the join style for the ends of two consecutive lines drawn with this xtd::drawing::pen.
| xtd::drawing::pen& xtd::drawing::pen::line_join | ( | xtd::drawing::drawing_2d::line_join | value | ) |
Sets the join style for the ends of two consecutive lines drawn with this xtd::drawing::pen.
| value | A xtd::drawing::drawing_2d/::line_join that represents the join style for the ends of two consecutive lines drawn with this xtd::drawing::pen. |
|
noexcept |
Gets the limit of the thickness of the join on a mitered corner.
| xtd::drawing::pen& xtd::drawing::pen::miter_limit | ( | float | value | ) |
Sets the limit of the thickness of the join on a mitered corner.
| value | The limit of the thickness of the join on a mitered corner. |
|
noexcept |
Gets the cap style used at the beginning of lines drawn with this xtd::drawing::pen.
| xtd::drawing::pen& xtd::drawing::pen::start_cap | ( | xtd::drawing::drawing_2d::line_cap | value | ) |
Sets the cap style used at the beginning of lines drawn with this xtd::drawing::pen.
| value | One of the xtd::drawing::drawing_2d/::line_cap values that represents the cap style used at the beginning of lines drawn with this xtd::drawing::pen. |
|
overridevirtualnoexcept |
Returns a sxd::ustring that represents the current object.
Reimplemented from xtd::object.
|
noexcept |
Gets the style of lines drawn with this xtd::drawing::pen.
|
noexcept |
Gets the width of this xtd::drawing::pen, in units of the xtd::drawing::graphics object used for drawing.
| xtd::drawing::pen& xtd::drawing::pen::width | ( | float | value | ) |
Sets the width of this xtd::drawing::pen, in units of the xtd::drawing::graphics object used for drawing.
| value | The width of this xtd::drawing::pen. |