Skip to content

AddType

StormFX edited this page Dec 13, 2022 · 1 revision

Contents

The AddType method of Masque's API adds a custom button type to Masque.

Example

-- Establish a reference to Masque.
local Masque = LibStub("Masque", true)

-- Add a custom type.
Masque:AddType("Custom", {"Icon", "Cooldown"}, "Aura")

Signature

{Masque}:AddType("Name", {List} [, "Type"])

Parameters

Parameter Type Required Description
Name string Yes A unique name for the type.
List table Yes An indexed table containing a list of regions to be skinned.
Type string No The name of the default type that the new type is based on.
Notes

  • The Name parameter must be a unique string.
  • The List parameter must be an indexed table.
  • The Type parameter should be set to a default type to ensure that Masque uses the proper settings. This is essential for buttons that inherit from native templates.
  • 9.0.2
    • Added the Type parameter.
  • 8.2.5
    • Method added.

Wiki
  • Home

Project
  • Contributors
  • History

Reference
  ⚬ Masque API
     • API_VERSION
     • AddSkin
     • AddSpellAlert
     • AddType
     • GetBackdrop
     • GetDefaultSkin
     • GetGloss
     • GetGroupByID
     • GetNormal
     • GetShadow
     • GetSlotIcon
     • GetSkin
     • GetSkins
     • GetSpellAlert
     • Group
     • Register
     • SetEmpty
     • UpdateCharge
     • UpdateSpellAlert
  ⚬ Group API
  ⚬ Regions

Skins
  • Skin List

Mirrors
  • CurseForge
  • Wago.io
  • Wow Interface

Clone this wiki locally