WoW:XML/ResizeBounds

< XML
Revision as of 04:49, 15 August 2023 by Move page script (talk | contribs) (Move page script moved page XML/ResizeBounds to XML/ResizeBounds without leaving a redirect)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

XML UI ← XML properties < ResizeBounds

ResizeBounds is a type used for setting resize contraints on a frame.

InheritanceEdit

Inherited by: none, Inherits: none, Defined in: Frame

ElementsEdit

  • <minResize> (Dimension) - lower bounds of a frames size
  • <maxResize> (Dimension) - upper bounds of a frames size

AttributesEdit

none

SummaryEdit

ResizeBounds element type facilitates the 'Layout' mechanism in the WoW UI. ResizeBounds works by setting a minimum and maximum bounds for how a frame can be resized.

ExampleEdit

<Frame name="MyFrame">
  <Size x="200" y="200"/>
  <ResizeBounds>
      <minResize x="100" y="100"/>
      <maxResize x="400" y="600"/>
  </ResizeBounds>
  <Layers>
    <Layer>
      <Texture file="MyTexture">
        <Anchors>
          <Anchor point="TOPLEFT"/>
          <Anchor point="BOTTOMRIGHT"/>
        </Anchors>
      </Texture>
    </Layer>
  </Layers>
</Frame>

This example will create a frame with size of 200,200 and not allow automatic resize to be smalle than 100,100 or larger than 400,600, drawing a texture which will stretch with the frame. And this demonstrates use of ResizeBounds using inline XML/Dimension values for 'minResize' and 'maxResize'.

DetailsEdit