reckfellENGINE

LinkButton

Text link button with optional OS-level URI opening.

On this page
class LinkButtonReckfellSharpInherits BaseButton

LinkButton uses BaseButton behavior and draws underlined text. Defaults are Underline = Always, TextOverrunBehavior = NoTrimming and empty Uri. For ordinary Tab navigation, explicitly set FocusMode = All: the constructor uses Accessibility.

Text is the visible label and Uri is a separate target. Assigning Uri neither opens it nor changes Text. Activation passes nonempty Uri to the OS through shell_open, including programmatic Press. This is neither an embedded browser nor a website router. Pressed handlers run after the built-in action and do not cancel it. For custom navigation or a dialog, leave Uri empty and handle Pressed yourself.

Long text normally contributes to minimum width. To trim it, set TextOverrunBehavior and constrain width through parent layout. EllipsisChar selects one Unicode character instead of the default ellipsis; longer strings warn and truncate to the first character. Trimming does not modify Text or Uri. LinkButton uses single-line display rather than Button wrapping.

Language selects text-processing language and TextDirection selects direction; neither translates the source string by itself. StructuredTextBidiOverride chooses structured-text processing, such as URI or email, so mixed LTR/RTL fragments follow their structure. It processes the label rather than validating or opening Uri.

StructuredTextBidiOverrideOptions shares its Array on get/set. Editing the returned array changes stored options without triggering reshaping. For predictable updates, first create an independent Array, edit it and assign it back. Nested mutable values can remain shared with a shallow copy.

Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.

Constructors1

LinkButtonConstructor
# LinkButton
C#
public LinkButton();

Creates a text link: empty Uri, Underline = Always, FocusMode = Accessibility, PointingHand cursor. Set FocusMode = All for ordinary Tab navigation.

Properties9

EllipsisCharProperty
# EllipsisChar
C#
public string EllipsisChar { get; set; }

Trimming character, default …. Use one Unicode character: longer strings warn and retain the first. Does not change selected TextOverrunBehavior.

LanguageProperty
# Language
C#
public string Language { get; set; }

Shaping language; empty uses Control locale. Does not switch application locale or replace source Text with a translation.

StructuredTextBidiOverrideProperty
# StructuredTextBidiOverride
C#
public TextServer.StructuredTextParser StructuredTextBidiOverride { get; set; }

Label-structure BiDi parser, default Default. URI/Email/File and other modes process mixed-direction text rather than opening targets or translating the label.

StructuredTextBidiOverrideOptionsProperty
# StructuredTextBidiOverrideOptions
C#
public Reckfell.Collections.Array StructuredTextBidiOverrideOptions { get; set; }

Shared Array of structured BiDi parser options. Get/set share the array; alias edits do not trigger reshaping. Edit an independent copy and assign it back to refresh.

TextProperty
# Text
C#
public string Text { get; set; }

Source label, empty by default. Getter returns text before translation/trimming. Does not automatically set Uri.

TextDirectionProperty
# TextDirection
C#
public Control.TextDirection TextDirection { get; set; }

Text direction, default Auto. Inherited uses Control LayoutDirection. Does not validate Uri direction or correctness.

TextOverrunBehaviorProperty
# TextOverrunBehavior
C#
public TextServer.OverrunBehavior TextOverrunBehavior { get; set; }

Single-line label trimming when width is insufficient, default NoTrimming. Enabling removes natural text minimum width; parent layout constrains the area. Text/Uri stay unchanged.

UnderlineProperty
# Underline
C#
public LinkButton.UnderlineMode Underline { get; set; }

Always, OnHover or Never, default Always. OnHover also underlines pressed states. Controls drawing rather than clickability.

UriProperty
# Uri
C#
public string Uri { get; set; }

OS-opening target, empty by default. Setter only stores it; activation with nonempty Uri invokes shell_open, including Press. Leave empty for custom actions; Pressed does not cancel built-in opening.

Methods18

GetEllipsisCharstring
# GetEllipsisChar
C#
public string GetEllipsisChar();

Trimming character, default …. Use one Unicode character: longer strings warn and retain the first. Does not change selected TextOverrunBehavior.

Returns string

Stored trimming-character string.

GetLanguagestring
# GetLanguage
C#
public string GetLanguage();

Shaping language; empty uses Control locale. Does not switch application locale or replace source Text with a translation.

Returns string

Stored language code, or empty for Control locale.

GetStructuredTextBidiOverrideTextServer.StructuredTextParser
# GetStructuredTextBidiOverride
C#
public TextServer.StructuredTextParser GetStructuredTextBidiOverride();

Label-structure BiDi parser, default Default. URI/Email/File and other modes process mixed-direction text rather than opening targets or translating the label.

Returns TextServer.StructuredTextParser

Selected TextServer.StructuredTextParser.

GetStructuredTextBidiOverrideOptionsReckfell.Collections.Array
# GetStructuredTextBidiOverrideOptions
C#
public Reckfell.Collections.Array GetStructuredTextBidiOverrideOptions();

Shared Array of structured BiDi parser options. Get/set share the array; alias edits do not trigger reshaping. Edit an independent copy and assign it back to refresh.

Returns Reckfell.Collections.Array

Shared options Array; editing changes the stored array.

GetTextstring
# GetText
C#
public string GetText();

Source label, empty by default. Getter returns text before translation/trimming. Does not automatically set Uri.

Returns string

Source label before translation and trimming.

GetTextDirectionControl.TextDirection
# GetTextDirection
C#
public Control.TextDirection GetTextDirection();

Text direction, default Auto. Inherited uses Control LayoutDirection. Does not validate Uri direction or correctness.

Returns Control.TextDirection

Stored Control.TextDirection.

GetTextOverrunBehaviorTextServer.OverrunBehavior
# GetTextOverrunBehavior
C#
public TextServer.OverrunBehavior GetTextOverrunBehavior();

Single-line label trimming when width is insufficient, default NoTrimming. Enabling removes natural text minimum width; parent layout constrains the area. Text/Uri stay unchanged.

Returns TextServer.OverrunBehavior

Selected TextServer.OverrunBehavior.

GetUnderlineModeLinkButton.UnderlineMode
# GetUnderlineMode
C#
public LinkButton.UnderlineMode GetUnderlineMode();

Always, OnHover or Never, default Always. OnHover also underlines pressed states. Controls drawing rather than clickability.

Returns LinkButton.UnderlineMode

Selected LinkButton.UnderlineMode.

GetUristring
# GetUri
C#
public string GetUri();

OS-opening target, empty by default. Setter only stores it; activation with nonempty Uri invokes shell_open, including Press. Leave empty for custom actions; Pressed does not cancel built-in opening.

Returns string

Stored opening target, or empty string.

SetEllipsisCharvoid
# SetEllipsisChar
C#
public void SetEllipsisChar(string @char);

Trimming character, default …. Use one Unicode character: longer strings warn and retain the first. Does not change selected TextOverrunBehavior.

Parameters
NameTypeDefault
charstring—
char

Trimming character, default …. Use one Unicode character: longer strings warn and retain the first. Does not change selected TextOverrunBehavior.

SetLanguagevoid
# SetLanguage
C#
public void SetLanguage(string language);

Shaping language; empty uses Control locale. Does not switch application locale or replace source Text with a translation.

Parameters
NameTypeDefault
languagestring—
language

Shaping language; empty uses Control locale. Does not switch application locale or replace source Text with a translation.

SetStructuredTextBidiOverridevoid
# SetStructuredTextBidiOverride
C#
public void SetStructuredTextBidiOverride(TextServer.StructuredTextParser parser);

Label-structure BiDi parser, default Default. URI/Email/File and other modes process mixed-direction text rather than opening targets or translating the label.

Parameters
NameTypeDefault
parserTextServer.StructuredTextParser—
parser

Label-structure BiDi parser, default Default. URI/Email/File and other modes process mixed-direction text rather than opening targets or translating the label.

SetStructuredTextBidiOverrideOptionsvoid
# SetStructuredTextBidiOverrideOptions
C#
public void SetStructuredTextBidiOverrideOptions(Reckfell.Collections.Array args);

Shared Array of structured BiDi parser options. Get/set share the array; alias edits do not trigger reshaping. Edit an independent copy and assign it back to refresh.

Parameters
NameTypeDefault
argsReckfell.Collections.Array—
args

Shared Array of structured BiDi parser options. Get/set share the array; alias edits do not trigger reshaping. Edit an independent copy and assign it back to refresh.

SetTextvoid
# SetText
C#
public void SetText(string text);

Source label, empty by default. Getter returns text before translation/trimming. Does not automatically set Uri.

Parameters
NameTypeDefault
textstring—
text

Source label, empty by default. Getter returns text before translation/trimming. Does not automatically set Uri.

SetTextDirectionvoid
# SetTextDirection
C#
public void SetTextDirection(Control.TextDirection direction);

Text direction, default Auto. Inherited uses Control LayoutDirection. Does not validate Uri direction or correctness.

Parameters
NameTypeDefault
directionControl.TextDirection—
direction

Text direction, default Auto. Inherited uses Control LayoutDirection. Does not validate Uri direction or correctness.

SetTextOverrunBehaviorvoid
# SetTextOverrunBehavior
C#
public void SetTextOverrunBehavior(TextServer.OverrunBehavior overrunBehavior);

Single-line label trimming when width is insufficient, default NoTrimming. Enabling removes natural text minimum width; parent layout constrains the area. Text/Uri stay unchanged.

Parameters
NameTypeDefault
overrunBehaviorTextServer.OverrunBehavior—
overrunBehavior

Single-line label trimming when width is insufficient, default NoTrimming. Enabling removes natural text minimum width; parent layout constrains the area. Text/Uri stay unchanged.

SetUnderlineModevoid
# SetUnderlineMode
C#
public void SetUnderlineMode(LinkButton.UnderlineMode underlineMode);

Always, OnHover or Never, default Always. OnHover also underlines pressed states. Controls drawing rather than clickability.

Parameters
NameTypeDefault
underlineModeLinkButton.UnderlineMode—
underlineMode

Always, OnHover or Never, default Always. OnHover also underlines pressed states. Controls drawing rather than clickability.

SetUrivoid
# SetUri
C#
public void SetUri(string uri);

OS-opening target, empty by default. Setter only stores it; activation with nonempty Uri invokes shell_open, including Press. Leave empty for custom actions; Pressed does not cancel built-in opening.

Parameters
NameTypeDefault
uristring—
uri

OS-opening target, empty by default. Setter only stores it; activation with nonempty Uri invokes shell_open, including Press. Leave empty for custom actions; Pressed does not cancel built-in opening.

LinkButton.UnderlineMode

ValueDescription
Always = 0

The LinkButton will always show an underline at the bottom of its text.

Never = 2

The LinkButton will never show an underline at the bottom of its text.

OnHover = 1

The LinkButton will show an underline at the bottom of its text when the mouse cursor is over it.

Theme properties

These are Theme resource keys, not C# properties. Use the matching Control GetTheme…() and AddTheme…Override() methods for each value type.

Key and typeDescription
font_color
Color

Default text Color of the LinkButton.

Default: Color(0.875, 0.875, 0.875, 1)
font_disabled_color
Color

Text Color used when the LinkButton is disabled.

Default: Color(0, 0, 0, 1)
font_focus_color
Color

Text Color used when the LinkButton is focused. Only replaces the normal text color of the button. Disabled, hovered, and pressed states take precedence over this color.

Default: Color(0.95, 0.95, 0.95, 1)
font_hover_color
Color

Text Color used when the LinkButton is being hovered.

Default: Color(0.95, 0.95, 0.95, 1)
font_hover_pressed_color
Color

Text Color used when the LinkButton is being hovered and pressed.

Default: Color(0, 0, 0, 1)
font_outline_color
Color

The tint of text outline of the LinkButton.

Default: Color(0, 0, 0, 1)
font_pressed_color
Color

Text Color used when the LinkButton is being pressed.

Default: Color(1, 1, 1, 1)
outline_size
int

The size of the text outline. Note: If using a font with FontFile.MultichannelSignedDistanceField enabled, its FontFile.MsdfPixelRange must be set to at least twice the value of LinkButton.outline_size for outline rendering to look correct. Otherwise, the outline may appear to be cut off earlier than intended.

Default: 0
underline_spacing
int

The vertical space between the baseline of text and the underline.

Default: 2
font
Font

Font of the LinkButton's text.

font_size
int

Font size of the LinkButton's text.

focus
StyleBox

StyleBox used when the LinkButton is focused. The LinkButton.focus StyleBox is displayed over the base StyleBox, so a partially transparent StyleBox should be used to ensure the base StyleBox remains visible. A StyleBox that represents an outline or an underline works well for this purpose. To disable the focus visual effect, assign a StyleBoxEmpty resource. Note that disabling the focus visual effect will harm keyboard/controller navigation usability, so this is not recommended for accessibility reasons.

Reckfell Engine documentationBack to top ↑
QUICK LINKSGetting startedEntity hierarchyC# & .NET 10Scenes and prefabs
Reckfell guides and full API K
reckfellENGINE
RECKFELL ACCOUNT

Sign in

Sign in to your Reckfell account.

One account for the entire Reckfell platform.