Table of Contents

Class ControlTile

Namespace
RichHudFramework.UI.Client
Assembly
RichHudClient.dll

Represents a vertical layout column within a ControlCategory in the RichHudTerminal.

Tiles are organized horizontally within a category. Each tile should generally contain no more than 3 controls to maintain proper UI scaling and layout bounds.

public class ControlTile : IEnumerable<ITerminalControl>, IEnumerable
Inheritance
ControlTile
Implements
IEnumerable<ITerminalControl>

Examples

new ControlTile()
{
    new TerminalColorPicker()
    {
        Name = "TerminalColorPicker",
        ControlChangedHandler = (obj, args) =>
        {
            var picker = obj as TerminalColorPicker;
            ExceptionHandler.SendChatMessage($"Color = ({picker.Value.R}, {picker.Value.G}, {picker.Value.B})");
        },
        ToolTip = "Sets a simple 24-bit RGB color, 0-255/8-bits per channel."
    }
}

Constructors

ControlTile()

public ControlTile()

Properties

ControlContainer

Interface accessor for use in collection initializers.

public IControlTile ControlContainer { get; }

Property Value

IControlTile

Controls

Read-only collection of the TerminalControlBase elements attached to this tile.

public IReadOnlyList<TerminalControlBase> Controls { get; }

Property Value

IReadOnlyList<TerminalControlBase>

Enabled

Determines whether or not the tile and its contents will be rendered in the list.

public bool Enabled { get; set; }

Property Value

bool

ID

Unique identifier used by the Framework API.

public object ID { get; }

Property Value

object

Methods

Add(TerminalControlBase)

Adds a TerminalControlBase to this tile.

Note: Controls are stacked vertically within the tile.

public void Add(TerminalControlBase control)

Parameters

control TerminalControlBase

GetApiData()

Retrieves the internal data tuple required by the Framework API.

public MyTuple<Func<object, int, object>, MyTuple<object, Func<int>>, object> GetApiData()

Returns

MyTuple<Func<object, int, object>, MyTuple<object, Func<int>>, object>

Explicit Interface Implementations

IEnumerable<ITerminalControl>.GetEnumerator()

Returns an enumerator that iterates through the collection.

IEnumerator<ITerminalControl> IEnumerable<ITerminalControl>.GetEnumerator()

Returns

IEnumerator<ITerminalControl>

An enumerator that can be used to iterate through the collection.

IEnumerable.GetEnumerator()

Returns an enumerator that iterates through a collection.

IEnumerator IEnumerable.GetEnumerator()

Returns

IEnumerator

An IEnumerator object that can be used to iterate through the collection.