49
edits
No edit summary |
mNo edit summary |
||
| Line 1: | Line 1: | ||
{{widgetmethod}} __NOTOC__ | {{widgetmethod}} __NOTOC__ | ||
Returns information about the anchor points for a region. | |||
point, relativeTo, relativePoint, xOfs, yOfs = MyRegion:GetPoint(n) | point, relativeTo, relativePoint, xOfs, yOfs = MyRegion:GetPoint(n) | ||
== Arguments == | == Parameters == | ||
=== Arguments === | |||
; n | ; n | ||
: integer - number of point about which you want to retrieve info. Should be in range <tt>1 .. MyRegion:GetNumPoints()</tt> | : integer - number of point about which you want to retrieve info. Should be in range <tt>1 .. MyRegion:GetNumPoints()</tt> | ||
== Returns == | === Returns === | ||
; point | ; point | ||
: [[UITYPE FramePoint|FramePoint]] -- attachment point of frame <tt>MyFrame</tt> | : [[UITYPE FramePoint|FramePoint]] -- attachment point of frame <tt>MyFrame</tt> | ||
| Line 21: | Line 22: | ||
== Example == | == Example == | ||
point, relativeTo, relativePoint, xOfs, yOfs = MyAddon_Frame1:GetPoint() | point, relativeTo, relativePoint, xOfs, yOfs = MyAddon_Frame1:GetPoint() | ||
DEFAULT_CHAT_FRAME:AddMessage(point) | DEFAULT_CHAT_FRAME:AddMessage(point) | ||
| Line 30: | Line 30: | ||
Result: | Result: | ||
TOP | TOP | ||
MyAddon_Frame0 | MyAddon_Frame0 | ||
| Line 37: | Line 36: | ||
-10 | -10 | ||
== | == Notes == | ||
* As of 2.2 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. | * As of 2.2 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. | ||