Table of Contents

Class LabelBoxBase

Namespace
RichHudFramework.UI
Assembly
RichHudClient.dll

Abstract base class for UI elements that combine a text label with a textured background.

public abstract class LabelBoxBase : HudElementBase, IReadOnlyHudElement, IReadOnlyHudNode, IReadOnlyHudParent
Inheritance
LabelBoxBase
Implements
Derived
Inherited Members

Constructors

LabelBoxBase(HudParentBase)

public LabelBoxBase(HudParentBase parent)

Parameters

parent HudParentBase

Fields

Background

The textured, tintable background element drawn behind the text.

public readonly TexturedBox Background

Field Value

TexturedBox

Properties

AutoResize

If true, the element's size is driven by the size of the text content. If false, the element's size is set manually, and text may be clipped if the bounds are too small.

public abstract bool AutoResize { get; set; }

Property Value

bool

Color

Gets or sets the color of the background texture.

public virtual Color Color { get; set; }

Property Value

Color

FitToTextElement

If true, the background size will match the size of the text element exactly.

If false, the background size is clamped so it cannot be smaller than the text element, but can be larger.

Note: This property is ignored if AutoResize is disabled.

public bool FitToTextElement { get; set; }

Property Value

bool

TextPadding

Gets or sets the padding applied to the text element, offsetting it from the edges of the background.

public abstract Vector2 TextPadding { get; set; }

Property Value

Vector2

TextSize

Gets or sets the total dimensions of the text element.

public abstract Vector2 TextSize { get; set; }

Property Value

Vector2