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) |
[quote=bryde;327220]snip/QUOTE]
this should work, although i would not name your frames parent or child if they are global, they will most likey interfere with some other stuff. Lua Code:
|
Thanks for the quick answer. Like I said, I'm not actively working on a project so the variable names were just chosen for easy identification.
Sadly however it's still doing what I don't want it to do :( I adjusted your code to create a colortexture in the child frame and the texture is still overflowing, using all the 800x800 instead of the 400x400 window created by it's parent: Lua Code:
As mentioned, fills the 800x800 (and that's perfect), but I only want it to render the 400x400px of the parent. The idea being that the full 800x800 texture is loaded into cache but only the 400x400 part is visible/rendered. |
Lua Code:
|
Quote:
|
I believe that method is relatively recent.
Before it was added, you would need a scrollframe container if you did not want to clip the texture manually. |
Both of those resources are very outdated. Wowpedia is where most of the updated info is. Even this site isn't exhaustively updated, but it's better than the sites you've been using.
Blizzard has recently started documenting the API themselves via the Blizzard_APIDocumentation addon. Foxlit has made an online browser for it. |
Quote:
You can also do frame:SetTopLevel(true) to make it behave like a scroll frame. SetClipsChildren will clip the children at the boundaries of the parent, but I think they're still clickable. |
All times are GMT -6. The time now is 09:57 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI