XLQP Gen1
ElementsControls

AddBind

Adds a keybind control that lets the user choose or trigger a keyboard shortcut.

AddBind

What it does

Adds a keybind control that lets the user choose or trigger a keyboard shortcut.

When to use it

Use it when a feature needs a configurable key, including optional hold-to-activate behavior.

ElementFunction:AddBind(BindConfig)

local Result = Section:AddBind({
    Name = "Example",
    Default = false,
    Callback = function(value)
        print(value)
    end,
})

Behavior and return value

Call this method on the compatible section, tab, panel, or element container shown by the signature. Store the returned value when you need to update, read, or destroy the element later.

Fields marked optional may be omitted. XLQP then uses the method’s built-in default or leaves that feature disabled.