Thread Tools Display Modes
Prev Previous Post   Next Post Next
03-14-18, 01:02 AM   #1
bryde
A Defias Bandit
Join Date: Mar 2018
Posts: 3
Larger childframe not overflowing parentframe

Hello everybody,
I'd like to know if it's possible to force a childframe to be "fully there" (in size) but it's texture not overflowing the boundaries of it's parentframe.
I don't have a project that requires this as of right now, but basically let's assume something like

Code:
parent = CreateFrame("Frame", nil, UIParent)
parent:SetSize(400,400)
parent:SetPoint("center")

child = CreateFrame("Frame", nil, parent)
child:SetSize(800,800)
child:SetPoint("Center")
if I set a texture for the background of the child, it'll draw the whole texture, but I'd like it to only paint within the parents boundries. I know I could work around the issue with the rectangle function and stuff, but that doesn't seem feasible in some cases. For example zoomed-in maps where you want to change the view with WASD or something, you'd have to reload the whole texture every time rather than just loading it once and manipulating it's x/y coordinates. Is there any way to do that?
  Reply With Quote
 

WoWInterface » Developer Discussions » Lua/XML Help » Larger childframe not overflowing parentframe


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off