Back to API Reference
Class

LinkModifier

Marks text ranges as clickable hyperlinks and dispatches their click/hover events.

Remarks

Visual styling and state feedback are configured with ordinary modifiers and parameter changes in a CompositeModifier, as in the built-in Link preset. The primary parameter is the URL. Subscribe to LinkClicked to handle activation (a confirmed click / tap — raised from the interaction machine's Activated event), or let the modifier open the URL via OpenURL when AutoOpenUrl is set.

Example

csharp
public string Url{ get; set }

URL used when the source does not supply a primary value.

public bool AutoOpenUrl{ get; set }

Whether activation automatically opens the resolved URL.

protected override void OnApply()
protected override void HandleInteraction()
protected override void HandleDefaultAction()
public Action<string> LinkClicked

Occurs when a link has been clicked, providing the URL.

public Action<string> LinkEntered

Occurs when the pointer has entered a link, providing the URL.

public Action LinkExited

Occurs when the pointer has exited a link.

See Also