World of Warcraft Forever API · SimpleScriptRegionAPI.md, for your AI
SimpleScriptRegionAPI (widget methods)
55 functions, as Blizzard documents them for Forever 1.60.1 (70959).
Making an addon with an AI? Tell it: Read https://wowaddons.gg/agents.md, then make me a World of Warcraft Forever addon that …, try it with me in the game, and publish it. It checks every call against this API before you try it in the game, then publishes it here. How it works.
Functions
CanChangeProtectedState
canChange = self:CanChangeProtectedState()
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
canChange | bool |
|---|
CanPropagateMouseClicks
canPropagate = self:CanPropagateMouseClicks()
Returns
canPropagate | bool |
|---|
CanPropagateMouseMotion
canPropagate = self:CanPropagateMouseMotion()
Returns
canPropagate | bool |
|---|
ClearScripts
self:ClearScripts()
Remove all script handlers set through Scripts in XML or SetScript in Lua
CollapsesLayout
collapsesLayout = self:CollapsesLayout()
Returns
collapsesLayout | bool |
|---|
EnableMouse
self:EnableMouse([enable])
Protected: only Blizzard's own code may call it.
Arguments
enable | bool default false |
|---|
EnableMouseMotion
self:EnableMouseMotion([enable])
Protected: only Blizzard's own code may call it.
Arguments
enable | bool default false |
|---|
EnableMouseWheel
self:EnableMouseWheel([enable])
Protected: only Blizzard's own code may call it.
Arguments
enable | bool default false |
|---|
FocusEnter
self:FocusEnter([fromMouseMotion])
Protected: only Blizzard's own code may call it.
Arguments
fromMouseMotion | bool default true |
|---|
FocusExit
self:FocusExit([fromMouseMotion])
Protected: only Blizzard's own code may call it.
Arguments
fromMouseMotion | bool default true |
|---|
GetBottom
bottom = self:GetBottom()
May return nothing.
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
bottom | uiUnit |
|---|
GetCenter
x, y = self:GetCenter()
May return nothing.
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
x | uiUnit | |
|---|---|---|
y | uiUnit |
GetHeight
height = self:GetHeight([ignoreRect])
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Arguments
ignoreRect | bool default false |
|---|
Returns
height | uiUnit |
|---|
GetLeft
left = self:GetLeft()
May return nothing.
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
left | uiUnit |
|---|
GetRect
left, bottom, width, height = self:GetRect()
May return nothing.
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
left | uiUnit | |
|---|---|---|
bottom | uiUnit | |
width | uiUnit | |
height | uiUnit |
GetRight
right = self:GetRight()
May return nothing.
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
right | uiUnit |
|---|
GetRoundLayoutToNearestPixel
enabled = self:GetRoundLayoutToNearestPixel()
Returns
enabled | bool |
|---|
GetScaledRect
left, bottom, width, height = self:GetScaledRect()
May return nothing.
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
left | uiUnit | |
|---|---|---|
bottom | uiUnit | |
width | uiUnit | |
height | uiUnit |
GetScript
script = self:GetScript(scriptTypeName, [bindingType])
Arguments
scriptTypeName | ScriptTypeName | |
|---|---|---|
bindingType | ScriptBindingType default "Extrinsic" |
Returns
script | LuaFunctionReference |
|---|
GetSize
width, height = self:GetSize([ignoreRect])
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Arguments
ignoreRect | bool default false |
|---|
Returns
width | uiUnit | |
|---|---|---|
height | uiUnit |
GetSourceLocation
location = self:GetSourceLocation()
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
location | string |
|---|
GetTop
top = self:GetTop()
May return nothing.
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
top | uiUnit |
|---|
GetWidth
width = self:GetWidth([ignoreRect])
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Arguments
ignoreRect | bool default false |
|---|
Returns
width | uiUnit |
|---|
HasScript
hasScript = self:HasScript(scriptName)
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Arguments
scriptName | cstring |
|---|
Returns
hasScript | bool |
|---|
Hide
self:Hide()
HookScript
success = self:HookScript(scriptTypeName, script, [bindingType])
Arguments
scriptTypeName | ScriptTypeName | |
|---|---|---|
script | LuaFunctionReference | |
bindingType | ScriptBindingType default "Extrinsic" |
Returns
success | bool |
|---|
Intersects
intersects = self:Intersects(region)
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Arguments
region | ScriptRegion |
|---|
Returns
intersects | bool |
|---|
IsAnchoringRestricted
isRestricted = self:IsAnchoringRestricted()
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
isRestricted | bool |
|---|
IsAnchoringSecret
isSecret = self:IsAnchoringSecret()
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
isSecret | bool |
|---|
IsCollapsed
isCollapsed = self:IsCollapsed()
Returns
isCollapsed | bool |
|---|
IsDragging
isDragging = self:IsDragging()
Returns
isDragging | bool |
|---|
IsMouseClickEnabled
enabled = self:IsMouseClickEnabled()
Returns
enabled | bool |
|---|
IsMouseEnabled
enabled = self:IsMouseEnabled()
Returns
enabled | bool |
|---|
IsMouseMotionEnabled
enabled = self:IsMouseMotionEnabled()
Returns
enabled | bool |
|---|
IsMouseMotionFocus
isMouseMotionFocus = self:IsMouseMotionFocus()
Returns
isMouseMotionFocus | bool |
|---|
IsMouseOver
isMouseOver = self:IsMouseOver([offsetTop], [offsetBottom], [offsetLeft], [offsetRight])
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Arguments
offsetTop | uiUnit default 0 | |
|---|---|---|
offsetBottom | uiUnit default 0 | |
offsetLeft | uiUnit default 0 | |
offsetRight | uiUnit default 0 |
Returns
isMouseOver | bool |
|---|
IsMouseWheelEnabled
enabled = self:IsMouseWheelEnabled()
Returns
enabled | bool |
|---|
IsProtected
isProtected, isProtectedExplicitly = self:IsProtected()
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
isProtected | bool | |
|---|---|---|
isProtectedExplicitly | bool |
IsRectValid
isValid = self:IsRectValid()
Returns
isValid | bool |
|---|
IsShown
isShown = self:IsShown()
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
isShown | bool |
|---|
IsVisible
isVisible = self:IsVisible()
Its returns can be secret values (in some instances and fights): guard them before any arithmetic.
Returns
isVisible | bool |
|---|
MouseDown
self:MouseDown([button])
Protected: only Blizzard's own code may call it.
Arguments
button | cstring default "LeftButton" |
|---|
MouseUp
self:MouseUp([button])
Protected: only Blizzard's own code may call it.
Arguments
button | cstring default "LeftButton" |
|---|
SetCollapsesLayout
self:SetCollapsesLayout(collapsesLayout)
Protected: only Blizzard's own code may call it.
Arguments
collapsesLayout | bool |
|---|
SetMouseClickEnabled
self:SetMouseClickEnabled([enabled])
Protected: only Blizzard's own code may call it.
Arguments
enabled | bool default false |
|---|
SetMouseMotionEnabled
self:SetMouseMotionEnabled([enabled])
Protected: only Blizzard's own code may call it.
Arguments
enabled | bool default false |
|---|
SetParent
self:SetParent([parent])
Protected: only Blizzard's own code may call it.
Arguments
parent | SimpleFrame may be nil |
|---|
SetPassThroughButtons
self:SetPassThroughButtons(buttons)
Protected: only Blizzard's own code may call it.
Arguments
buttons | MouseButton |
|---|
SetPropagateMouseClicks
self:SetPropagateMouseClicks(propagate)
Protected: only Blizzard's own code may call it.
Arguments
propagate | bool |
|---|
SetPropagateMouseMotion
self:SetPropagateMouseMotion(propagate)
Protected: only Blizzard's own code may call it.
Arguments
propagate | bool |
|---|
SetRoundLayoutToNearestPixel
self:SetRoundLayoutToNearestPixel(enabled)
Protected: only Blizzard's own code may call it.
Arguments
enabled | bool |
|---|
SetScript
self:SetScript(scriptTypeName, [script])
Arguments
scriptTypeName | ScriptTypeName | |
|---|---|---|
script | LuaFunctionReference may be nil |
SetShown
self:SetShown([show])
Arguments
show | bool default false |
|---|
ShouldButtonPassThrough
shouldPassThrough = self:ShouldButtonPassThrough(button)
Arguments
button | MouseButton |
|---|
Returns
shouldPassThrough | bool |
|---|
Show
self:Show()