Open main menu
Home
Random
Log in
Settings
About AddOn Studio
Disclaimers
AddOn Studio
Search
Editing
WoW:API Region SetPoint
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Details == * Behavior of this function with multiple anchors is complex. Generally, you can override points by setting them again (so repeated assignment to the "TOPLEFT" point of a frame would move the frame, unless other anchor points interfere). If you're repositioning a frame, call <code>obj:[[API Region ClearAllPoints|ClearAllPoints]]()</code> to eliminate unwanted interactions. * Offset units are relative to the screen's effective scale. WoW's screen always has a height of 768 units, while screen width varies with aspect ratio. * <tt>ofsx</tt> and <tt>ofsy</tt> must both be passed as arguments for either to take effect; they default to 0 only when neither is given. That is, <tt>foo:SetPoint(bar, 40)</tt> will ignore the 40 rather than treat it as (+40,+0). * Secure frames will silently ignore calls to this function if the relative frame is a [[API FontString|FontString]]. === Edge definitions === The edge "points" (TOP, RIGHT, BOTTOM, LEFT) are not actual points, but... edges. To fully define a region position using edges alone, you will need to define all four (as opposed to using corners, where you only need two) edges. Therefore, defining an edge does not necessarily place a region relative to the center of that edge (For example, if you define TOP and RIGHT, the region will be placed at the TOPRIGHT corner). However, by default a region is "pulled" to the center if the number of points defined is insufficient. Example: Region:ClearAllPoints(); Region:SetPoint("TOP", relativeframe); Region:SetWidth(100); Region:SetHeight(100); will place ''Region'' to the top center of the ''relativeframe'' while adding a Region:SetPoint("RIGHT", relativeframe); will place ''Region'' in the top right corner and now ''Region'' is fully defined.
Summary:
Please note that all contributions to AddOn Studio are considered to be released under the Creative Commons Attribution-NonCommercial-ShareAlike (see
AddOn Studio Wiki:Copyrights
for details).
Submissions must be written by you, or copied from a public domain or similar free resource (see
AddOn Studio Wiki:Copyrights
for details).
Cancel
Editing help
(opens in new window)
Close
Loading editor…