Hyperlink
struct · ferroui-controls · v0.5.0
struct Hyperlink
An interactive span. Its host supplies hit testing/focus and forwards pointer and keyboard gestures; invocation and URI launch use the framework services.
Members
TYPEto_refnavigate_uri_propertytarget_name_propertyis_enabled_propertyis_tab_stop_propertytab_index_propertyis_visited_propertyunderline_style_propertyconstructnewwith_textnavigate_uriset_navigate_uritarget_nameset_target_nameis_enabledset_is_enabledis_tab_stopset_is_tab_stoptab_indexset_tab_indexis_visitedset_is_visitedunderline_styleset_underline_styleshould_draw_underlinecontent_textis_pointer_overis_pressedis_focusedset_is_pointer_overset_is_focusedclicknavigation_requestednavigatepointer_pressedpointer_releasedcancel_pointerkey_downkey_upis_link_navigation_key
TYPE
const TYPE: &'static $crate::TypeInfo
The runtime type of this class.
to_ref
fn to_ref(self: &Self) -> $crate::Ref<Hyperlink>
Returns a strong reference to this object.
navigate_uri_property
fn navigate_uri_property() -> &'static StyledProperty<Option<String>>
target_name_property
fn target_name_property() -> &'static StyledProperty<Option<String>>
is_enabled_property
fn is_enabled_property() -> &'static StyledProperty<bool>
is_tab_stop_property
fn is_tab_stop_property() -> &'static StyledProperty<bool>
tab_index_property
fn tab_index_property() -> &'static StyledProperty<i32>
is_visited_property
fn is_visited_property() -> &'static StyledProperty<bool>
underline_style_property
fn underline_style_property() -> &'static StyledProperty<UnderlineStyle>
construct
fn construct() -> Self
new
fn new() -> Ref<Self>
with_text
fn with_text(text: &str, navigate_uri: Option<&str>) -> Ref<Self>
navigate_uri
fn navigate_uri(self: &Self) -> Option<String>
set_navigate_uri
fn set_navigate_uri(self: &Self, value: Option<String>)
target_name
fn target_name(self: &Self) -> Option<String>
set_target_name
fn set_target_name(self: &Self, value: Option<String>)
is_enabled
fn is_enabled(self: &Self) -> bool
set_is_enabled
fn set_is_enabled(self: &Self, value: bool)
is_tab_stop
fn is_tab_stop(self: &Self) -> bool
set_is_tab_stop
fn set_is_tab_stop(self: &Self, value: bool)
tab_index
fn tab_index(self: &Self) -> i32
set_tab_index
fn set_tab_index(self: &Self, value: i32)
is_visited
fn is_visited(self: &Self) -> bool
set_is_visited
fn set_is_visited(self: &Self, value: bool)
underline_style
fn underline_style(self: &Self) -> UnderlineStyle
set_underline_style
fn set_underline_style(self: &Self, value: UnderlineStyle)
should_draw_underline
fn should_draw_underline(self: &Self) -> bool
content_text
fn content_text(self: &Self) -> String
is_pointer_over
fn is_pointer_over(self: &Self) -> bool
is_pressed
fn is_pressed(self: &Self) -> bool
is_focused
fn is_focused(self: &Self) -> bool
set_is_pointer_over
fn set_is_pointer_over(self: &Self, value: bool)
set_is_focused
fn set_is_focused(self: &Self, value: bool)
click
fn click(self: &Self, handler: impl Fn(&HyperlinkClickEventArgs) -> () + 'static) -> Subscription
Dropping the returned guard removes the handler; Subscription::detach keeps it for the
life of the hyperlink.
navigation_requested
fn navigation_requested(self: &Self, handler: impl Fn(&HyperlinkClickEventArgs) -> () + 'static) -> Subscription
Dropping the returned guard removes the handler; Subscription::detach keeps it for the
life of the hyperlink.
navigate
fn navigate(self: &Self) -> bool
Raises Click, then NavigationRequested. A handled event cancels default URI launch. A relative URI remains available to an application navigation handler.
pointer_pressed
fn pointer_pressed(self: &Self) -> bool
pointer_released
fn pointer_released(self: &Self, is_over: bool) -> bool
cancel_pointer
fn cancel_pointer(self: &Self)
key_down
fn key_down(self: &Self, key: Key) -> bool
key_up
fn key_up(self: &Self, key: Key) -> bool
is_link_navigation_key
fn is_link_navigation_key(key: Key) -> bool
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeInlineImplExtTextElementImplExtBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>ReceiverAnyFerroObjectImplExtStyledElementImplExtClassDefaultsErasedDestructorIntoEitherDerefUpcast<T>Upcast<Hyperlink>StaticTypeObjectTypeSubclassable<T>DefaultConstructibleStyledElementImplTextElementImplInlineImplFerroObjectImpl
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.