Table of Contents

Class DialogRenderer

Namespace
OmegaGUI
Assembly
OmegaGUI.dll

Displays a Dialog using Dialog.

public sealed class DialogRenderer : IDisposable
Inheritance
DialogRenderer
Implements
Inherited Members
Extension Methods

Constructors

DialogRenderer(GuiManager, Dialog, Point, Lua?)

Creates a new dialog renderer for a Dialog

public DialogRenderer(GuiManager manager, Dialog dialog, Point location = default, Lua? lua = null)

Parameters

manager GuiManager

The GuiManager used to interface with the Engine

dialog Dialog

The dialog to be displayed

location Point

The location of the dialog on the screen

lua Lua

The scripting engine to execute event handlers.

DialogRenderer(GuiManager, string, Point, Lua?)

Creates a new dialog renderer from an XML file

public DialogRenderer(GuiManager manager, string filename, Point location = default, Lua? lua = null)

Parameters

manager GuiManager

The GuiManager used to interface with the Engine

filename string

The filename of the XML file to load

location Point

The location of the dialog on the screen

lua Lua

The scripting engine to execute event handlers.

Properties

DialogModel

The dialog to be displayed

public Dialog DialogModel { get; }

Property Value

Dialog

DialogRender

The rendering system used to display DialogModel

public Dialog DialogRender { get; }

Property Value

Dialog

Disposed

Has this dialog been disposed?

[Browsable(false)]
public bool Disposed { get; }

Property Value

bool

Name

Text value to make it easier to identify a particular dialog

public string? Name { get; set; }

Property Value

string

Methods

Close()

Closes the dialog

public void Close()

Dispose()

Removes the Engine hooks and queues the LuaInterface.Lua interpreter for disposal

public void Dispose()

~DialogRenderer()

protected ~DialogRenderer()

GetControl(string)

Gets the first Control in this DialogRenderer with the specified name

public Control GetControl(string name)

Parameters

name string

Returns

Control

Exceptions

ArgumentNullException

name is null.

KeyNotFoundException

An element with the specified key does not exist in the dictionary.

ImportLua(string)

Imports an external Lua script into the GUI's Lua instance

public void ImportLua(string filename)

Parameters

filename string

The Lua file to import

MsgBox(string)

public void MsgBox(string text)

Parameters

text string

MsgBox(string, MsgBoxType, Action<MsgBoxResult>)

public void MsgBox(string text, MsgBoxType type, Action<MsgBoxResult> callback)

Parameters

text string
type MsgBoxType
callback Action<MsgBoxResult>

MsgBox(string, Action<MsgBoxResult>)

public void MsgBox(string text, Action<MsgBoxResult> callback)

Parameters

text string
callback Action<MsgBoxResult>

SetLocation(int, int)

Changes the dialog's on-screen position.

public void SetLocation(int x, int y)

Parameters

x int
y int

Show()

Show the dialog

public void Show()

ShowModal()

Show the dialog with exclusive mouse handling

public void ShowModal()

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.

Update()

Update the dialog output

public void Update()