Skip to content

AceConfigDialog-3.0

AceConfigDialog-3.0 generates AceGUI-3.0 based windows based on option tables.

API Reference

AddToBlizOptions

method#
lua
AceConfigDialog:AddToBlizOptions(appName, name?, parent?, ...)

Add an option table into the Blizzard Interface Options panel.

You can optionally supply a descriptive name to use and a parent frame to use, as well as a path in the options table. If no name is specified, the appName will be used instead.

If you specify a proper parent (by name), the interface options will generate a tree layout. Note that only one level of children is supported, so the parent always has to be a head-level node.

This function returns a reference to the container frame registered with the Interface Options, as well as the registered ID. You can use the ID to open the options with the API function Settings.OpenToCategory.

Parameters

ParameterTypeDefaultDescription
appNamestringThe application name as given to :RegisterOptionsTable.
name (optional)stringA descriptive name to display in the options tree (defaults to appName).
parent (optional)stringThe parent to use in the interface options tree.
...anyThe path in the options table to feed into the interface options panel.

Returns

TypeDescription
frameThe reference to the frame registered into the Interface Options.
anyThe category ID to pass to Settings.OpenToCategory.

Example

lua
local frame, categoryID = LibStub("AceConfigDialog-3.0"):AddToBlizOptions("MyAddon")

Close

method#
lua
AceConfigDialog:Close(appName)

Close a specific options window.

Parameters

ParameterTypeDefaultDescription
appNamestringThe application name as given to :RegisterOptionsTable.

CloseAll

method#
lua
AceConfigDialog:CloseAll()

Close all open options windows.

Open

method#
lua
AceConfigDialog:Open(appName, container?, ...)

Open an option window at the specified path (if any).

This function can optionally feed the group into a pre-created container instead of creating a new container frame.

Parameters

ParameterTypeDefaultDescription
appNamestringThe application name as given to :RegisterOptionsTable.
container (optional)tableAn optional container frame to feed the options into.
...anyThe path to open after creating the options window (see :SelectGroup for details).

SelectGroup

method#
lua
AceConfigDialog:SelectGroup(appName, ...)

Selects the specified path in the options window.

The path specified has to match the keys of the groups in the table.

Parameters

ParameterTypeDefaultDescription
appNamestringThe application name as given to :RegisterOptionsTable.
...anyThe path to the key that should be selected.

Example

lua
LibStub("AceConfigDialog-3.0"):SelectGroup("MyAddon", "display", "colors")

SetDefaultSize

method#
lua
AceConfigDialog:SetDefaultSize(appName, width, height)

Sets the default size of the options window for a specific application.

Parameters

ParameterTypeDefaultDescription
appNamestringThe application name as given to :RegisterOptionsTable.
widthnumberThe default width.
heightnumberThe default height.

GetStatusTable

method#
lua
AceConfigDialog:GetStatusTable(appName, path?)

Get the table AceConfigDialog uses to persist the open window's UI state (such as the selected group or tab) for appName at the given path. Read it to inspect the dialog, or seed it to control the initial state.

Parameters

ParameterTypeDefaultDescription
appNamestringThe application name as given to :RegisterOptionsTable.
path (optional)tableThe path of group keys identifying a node in the options tree; omit for the root.

Returns

TypeDescription
tableThe status table for that node, created on first access.

Ace3, a World of Warcraft addon framework.