Libraries.Interface.Controls.TextStyles.TextUnderline Documentation

Inherits from: Libraries.Interface.Controls.TextStyles.TextHighlight, Libraries.Language.Object

Actions Documentation

Compare(Libraries.Language.Object object)

This action returns the priority value on this highlight. If multiple highlights overlap in the TextBox, highlights with a higher priority will be rendered on top of highlights with a lower priority.

Parameters

Return

integer:

Equals(Libraries.Language.Object object)

This action determines if two objects are equal based on their hash code values.

Parameters

Return

boolean: True if the hash codes are equal and false if they are not equal.

Example

use Libraries.Language.Object
use Libraries.Language.Types.Text
Object o
Text t
boolean result = o:Equals(t)

GetColor()

70% opaque white.

Return

Libraries.Game.Graphics.ColorGroup:

GetDrawable(number width, number height)

This action returns a Drawable representing the visual content of a text highlight of a given width and height.

Parameters

  • number width
  • number height

Return

Libraries.Game.Graphics.Drawable:

GetHashCode()

This action gets the hash code for an object.

Return

integer: The integer hash code of the object.

Example

Object o
integer hash = o:GetHashCode()

GetRenderPriority()

This action returns the priority value on this highlight. If multiple highlights overlap in the TextBox, highlights with a higher priority will be rendered on top of highlights with a lower priority.

Return

number:

IsError()

This action returns a value indicating whether or not this highlight represents an error in the text, most commonly a spelling error. This is used by the accessibility platform to inform screen readers if they interact with a spelling error. By default, this value returns false.

Return

boolean:

IsLineHighlight()

This action returns whether or not this highlight is applied to an entire line of text.

Return

boolean:

IsVisibleWhileSelected()

This action returns whether or not this highlight will be visible on selected text. If this value is false and text is selected, the selection highlight will be rendered on top of this highlight. Note that if the selection highlight uses transparency, this highlight will be partially visible underneath the selection highlight.

Return

boolean:

SetColor(Libraries.Game.Graphics.Color color)

30% opaque white.

Parameters

SetErrorFlag(boolean error)

The SetErrorFlag action is used to designate this highlight as representing an error in the text, most commonly a spelling error. This is used by the accessibility platform to inform screen readers if they interact with a spelling error.

Parameters

  • boolean error

SetLineHighlight(boolean isLineHighlight)

This action sets whether or not this highlight should be applied to an entire line of text. The highlight will be applied to whatever line contains the start index of the TextStyle that is using this highlight.

Parameters

  • boolean isLineHighlight: True to make this highlight appear on an entire line, false to make it appear only for the TextStyle's specific text.

SetRenderPriority(number priority)

This action sets a priority value on this highlight. If multiple highlights overlap in the TextBox, highlights with a higher priority will be rendered on top of highlights with a lower priority.

Parameters

  • number priority

SetVisibleWhileSelected(boolean visible)

This action sets whether or not this highlight will be rendered on top of the selection highlight for selected text. If the provided value is false, then the highlight will appear normally on unselected text, but will be hidden on selected text. If the text's selection color uses transparency, this highlight will be partially visible underneath the selection highlight.

Parameters

  • boolean visible