ScriptRegionResizing:GetPoint

From Warcraft Wiki
Jump to navigation Jump to search

Returns an anchor point for the region.

point, relativeTo, relativePoint, offsetX, offsetY = ScriptRegionResizing:GetPoint([anchorIndex])

Arguments

anchorIndex
number? = 1 - Index between 1 and GetNumPoints.

Returns

Returns nil if the region has no points.

Frame points
point
string : FramePointTOPLEFT, TOPRIGHT, BOTTOMLEFT, BOTTOMRIGHT, TOP, BOTTOM, LEFT, RIGHT, CENTER - Point on this region at which it is anchored to another.
TOPLEFT, TOPRIGHT, BOTTOMLEFT, BOTTOMRIGHT
TOP, BOTTOM, LEFT, RIGHT, CENTER
relativeTo
Object - Reference to the other region to which this region is anchored.
relativePoint
string : FramePointTOPLEFT, TOPRIGHT, BOTTOMLEFT, BOTTOMRIGHT, TOP, BOTTOM, LEFT, RIGHT, CENTER - Point on the other region to which this region is anchored.
offsetX
number - Offset right (negative for left).
offsetY
number - Offset up (negative for down).

Example

/run print(PlayerFrame:GetPoint()) -- "BOTTOMRIGHT", <Frame:UIParent>, "BOTTOM", -300, 250.00001525879

Patch changes

Bc icon.gif Patch 2.2.0 (2007-09-25): The screen coordinates are no longer relative to the TOPLEFT instead they are relative to closest screen position which can be TOPLEFT, TOP, TOPRIGHT, LEFT, CENTER, RIGHT, BOTTOMLEFT, BOTTOM and BOTTOMRIGHT be sure to use/save the relativePoint argument in addition to xOfs and yOfs for frame positioning or your frames will appear at the wrong place and even off the screen.
WoW Icon update.png Patch 1.10.0 (2006-03-28): Added.