Wowpedia

We have moved to Warcraft Wiki. Click here for information and the new URL.

READ MORE

Wowpedia
Advertisement

Region (inherits from ParentedObject) is an abstract widget type for anything that can occupy an area of the screen. As such, Frames, Textures and FontStrings are all various kinds of Region. Region provides most of the functions that support size, position and anchoring, including animation. It is a "real virtual" type; it cannot be instantiated, but objects can return true when asked if they are Regions.

Defined Methods

Region:SetParent(parent) - Parents this to another object. Parented objects will inherit their scale & visibility.
Region:IsDragging() - True if this Region or its Parent is being dragged. - New in 3.1.0
Region:IsMouseOver([top, bottom, left, right]) - Checks whether the mouse is over the frame (or within specified offsets).
Region:IsObjectLoaded()
Region:IsProtected() - Indicates if this object can be manipulated in certain ways by tainted code in combat or not
Region:CanChangeProtectedState()
Position & Scale
Region:GetPoint(index) - Returns the details of the indexth anchor point defined for this frame (point, relativeTo, relativePoint, xofs, yofs).
Region:SetPoint(point, relativeTo, relativePoint, ofsx, ofsy) - Defines an attachment point of this region.
Region:SetAllPoints(frame or frameName) - Defines attachment points for this region to match edges of the specified frame.
Region:ClearAllPoints() - Removes all previously-defined attachment points for this region.
Region:GetNumPoints() - Returns the number of anchor points defined for this frame.
Region:IsAnchoringRestricted()
Region:GetPointByName(name)
Region:ClearPointByName(name)
Region:AdjustPointsOffset([adjustX, adjustY]) - Shifts a region by adjusting all anchors.
Region:ClearPointsOffset() - Zeroizes the x and y offsets on all anchors.
Region:GetLeft() - Returns the distance of the region's left edge from the left side of the screen (scale dependent).
Region:GetRight() - Returns the distance of the region's right edge from the left side of the screen (scale dependent).
Region:GetTop() - Returns the distance of the region's top edge from the bottom of the screen (scale dependent).
Region:GetBottom() - Returns the distance of the region's bottom edge from the bottom of the screen (scale dependent).
Region:GetCenter() - Returns the distance of the region's middle from the bottom left of the screen (scale dependent).
Region:GetRect() - Returns the location and size (scale dependent), as shorthand for GetBottom(), GetLeft(), GetWidth() and GetHeight()
Region:GetScaledRect() - Returns the location and size in a standard coordinate space (as if effectiveScale = 1).
Region:IsRectValid() - Indicates the region has been sufficiently defined for placement on the screen.
Region:GetWidth() - Returns the width of this object (scale dependent).
Region:SetWidth(width) - Defines the width of the object (scale dependent).
Region:GetHeight() - Returns the height of this object (scale dependent).
Region:SetHeight(height) - Defines the height of the object (scale dependent).
Region:GetSize() - Returns the width and height (scale dependent).
Region:SetSize(width, height) - Defines the width and the height, as shorthand for SetWidth() and SetHeight()
Region:GetScale() - Returns the set scale (normally relative to its parent).
Region:SetScale(scale) - Defines the scale relative to an immediate parent or standard coordinate space, depending on IsIgnoringParentScale()
Region:GetEffectiveScale() - Returns the net scale, inclusive of all parents.
Region:SetIgnoreParentScale(boolean) - Directs the region to scale itself manually without inheritence.
Region:IsIgnoringParentScale() - Indicates the region scales itself manually without inheritence.
Visibility
Region:Show() - Directs the region to appear and permits its children to appear also, but not while the region's parent (if any) is hidden
Region:Hide() - Directs the region and its children to disappear
Region:SetShown(boolean) - Directs the region to appear or disappar, as an alternative to Hide() and Show()
Region:IsShown() - Indicates the region will appear, but only while its parent appears or if it has no parent
Region:IsVisible() - Indicates the region and its parent (if any) are currently appearing
Region:GetAlpha() - Returns the object's set opacity between 0 and 1 (normally relative to its parent)
Region:GetEffectiveAlpha() - Return's the net opacity, inclusive of all parents
Region:SetAlpha(alpha) - Defines the object's opacity between 0 and 1 (normally relative to its parent)
Region:SetIgnoreParentAlpha(boolean) - Directs the region to adopt a manually defined opacity uninherited from its parent
Region:IsIgnoringParentAlpha() - Indicates the region has a manually defined opacity uninherited from its parent
Animations
Region:CreateAnimationGroup() - Constructs a new AnimationGroup as a child of this Region. - New in 3.1.0
Region:GetAnimationGroups() - Returns all AnimationGroups that are children of this Region. - New in 3.1.0
Region:StopAnimating() - Halts any active Animations on the Region and its children - New in 3.1.0

Patch changes

External links

References

Advertisement