xtd - Reference Guide
0.1.0
Modern c++17/20 framework to create console, GUI and unit test applications on Windows, macOS, Linux, iOS and android.
|
#include <link.h>
Represents a link within a xtd::forms::link_label control.
Inherits xtd::object.
Public Member Functions | |
link ()=default | |
Initializes a new instance of the xtd::forms::link class. | |
link (size_t start, size_t length) | |
Initializes a new instance of the xtd::forms::link_label::link class with the specified starting location and number of characters after the starting location within the xtd::forms::link_label. | |
link (size_t start, size_t length, std::any link_data) | |
Initializes a new instance of the xtd::forms::link_label::link class with the specified starting location, number of characters after the starting location within the xtd::forms::link_label, and the data associated with the link. | |
const xtd::ustring & | description () const |
Gets a text description of the link. | |
link & | description (const xtd::ustring &value) |
Sets a text description of the link. | |
bool | enabled () const |
Gets a value indicating whether the link is enabled. | |
link & | enabled (bool value) |
Sets a value indicating whether the link is enabled. | |
size_t | length () const |
Gets the number of characters in the link text. | |
link & | length (size_t value) |
Sets the number of characters in the link text. | |
std::any | link_data () const |
Gets the data associated with the link. | |
link & | link_data (std::any value) |
Sets the data associated with the link. | |
const xtd::ustring & | name () const |
Gets the name of the xtd::forms::link_label::link. | |
link & | name (const xtd::ustring &value) |
Sets the name of the xtd::forms::link_label::link. | |
size_t | start () const |
Gets the starting location of the link within the text of the xtd::forms::link_label::link. | |
link & | start (size_t value) |
Sets the starting location of the link within the text of the xtd::forms::link_label::link. | |
std::any | tag () const |
Gets the object that contains data about the xtd::forms::link_label::link. | |
link & | tag (std::any value) |
Sets the object that contains data about the xtd::forms::link_label::link. | |
bool | visited () const |
Gets a value indicating whether the user has visited the link. | |
link & | visited (bool value) |
Sets a value indicating whether the user has visited the link. | |
Public Member Functions inherited from xtd::object | |
object ()=default | |
Create a new instance of the ultimate base class object. | |
virtual bool | equals (const object &obj) const noexcept |
Determines whether the specified object is equal to the current object. | |
virtual size_t | get_hash_code () const noexcept |
Serves as a hash function for a particular type. | |
template<typename object_t > | |
std::unique_ptr< object_t > | memberwise_clone () const |
Gets the type of the current instance. | |
virtual xtd::ustring | to_string () const noexcept |
Returns a std::string that represents the current object. | |
Additional Inherited Members | |
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. | |
static bool | reference_equals (const object &object_a, const object &object_b) noexcept |
Determines whether the specified object instances are the same instance. | |
|
default |
Initializes a new instance of the xtd::forms::link class.
xtd::forms::link::link | ( | size_t | start, |
size_t | length | ||
) |
Initializes a new instance of the xtd::forms::link_label::link class with the specified starting location and number of characters after the starting location within the xtd::forms::link_label.
start | The zero-based starting location of the link area within the text of the xtd::forms::link_label. |
length | The number of characters, after the starting character, to include in the link area. |
xtd::forms::link::link | ( | size_t | start, |
size_t | length, | ||
std::any | link_data | ||
) |
Initializes a new instance of the xtd::forms::link_label::link class with the specified starting location, number of characters after the starting location within the xtd::forms::link_label, and the data associated with the link.
start | The zero-based starting location of the link area within the text of the xtd::forms::link_label. |
length | The number of characters, after the starting character, to include in the link area. |
link_data | The data associated with the link. |
const xtd::ustring & xtd::forms::link::description | ( | ) | const |
Gets a text description of the link.
link & xtd::forms::link::description | ( | const xtd::ustring & | value | ) |
Sets a text description of the link.
value | A xtd::ustring representing a text description of the link. |
bool xtd::forms::link::enabled | ( | ) | const |
Gets a value indicating whether the link is enabled.
link & xtd::forms::link::enabled | ( | bool | value | ) |
Sets a value indicating whether the link is enabled.
value | true if the link is enabled; otherwise, false. |
size_t xtd::forms::link::length | ( | ) | const |
Gets the number of characters in the link text.
link & xtd::forms::link::length | ( | size_t | value | ) |
Sets the number of characters in the link text.
value | The number of characters, including spaces, in the link text. |
std::any xtd::forms::link::link_data | ( | ) | const |
Gets the data associated with the link.
link & xtd::forms::link::link_data | ( | std::any | value | ) |
Sets the data associated with the link.
value | A std::any object representing the data associated with the link. |
const xtd::ustring & xtd::forms::link::name | ( | ) | const |
Gets the name of the xtd::forms::link_label::link.
link & xtd::forms::link::name | ( | const xtd::ustring & | value | ) |
Sets the name of the xtd::forms::link_label::link.
value | A xtd::ustring representing the name of the xtd::forms::link_label::link. The default value is the empty string (""). |
size_t xtd::forms::link::start | ( | ) | const |
Gets the starting location of the link within the text of the xtd::forms::link_label::link.
link & xtd::forms::link::start | ( | size_t | value | ) |
Sets the starting location of the link within the text of the xtd::forms::link_label::link.
value | The location within the text of the the xtd::forms::link_label control where the link starts. |
std::any xtd::forms::link::tag | ( | ) | const |
Gets the object that contains data about the xtd::forms::link_label::link.
link & xtd::forms::link::tag | ( | std::any | value | ) |
Sets the object that contains data about the xtd::forms::link_label::link.
value | An std::any object that contains data about the control. The default has no value. |
bool xtd::forms::link::visited | ( | ) | const |
Gets a value indicating whether the user has visited the link.
link & xtd::forms::link::visited | ( | bool | value | ) |
Sets a value indicating whether the user has visited the link.
value | true if the link has been visited; otherwise, false. |