XML UI ← XML elements < CheckButton

Inheritance[edit | edit source]

Inherited by: none, Inherits: <Button>, Runtime object: CheckButton
Defined in: Frames, Ui

Elements[edit | edit source]

Attributes[edit | edit source]

  • checked

Details[edit | edit source]

For checkbuttons, setting the label of the checkbutton works differently from normal buttons. Using MyCheckButton:SetText("monkey"); will not give you a visible result. Instead, you need to address the text property of the checkbuttons invisible FontString frame. The FontString frame is named "<checkButtonName>Text", so to address it, use the following Lua code: getglobal(MyCheckButton:GetName() .. "Text"):SetText("Monkey");

Example[edit | edit source]

Included in Backdrop

<CheckButton name="$parentCheckButton" inherits="OptionsCheckButtonTemplate" checked="true">
  <Anchors>
    <Anchor point="LEFT">
    <Offset>
      <AbsDimension x="20" y="0" />
    </Offset>
    </Anchor>
  </Anchors>
</CheckButton>

Wow checkbutton.jpg

Community content is available under CC-BY-SA unless otherwise noted.