annotate Veneer.xml @ 87:27db212af783

- polished position management code; goes something like: - core:Reanchor() to soft fix all anchors - module:Reanchor() or core:InternalReanchor(module) to position a specific set of neighboring frames
author Nenue
date Wed, 19 Oct 2016 16:51:17 -0400
parents 16b300d96724
children b107b4df7eb6
rev   line source
Nenue@47 1 <Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/
Nenue@47 2 ..\FrameXML\UI.xsd">
Nenue@84 3
Nenue@84 4 <Script file="Veneer.lua" />
Nenue@84 5
Nenue@0 6 <Font name="VeneerFont" />
Nenue@0 7
Nenue@0 8 <Font name="VeneerFont_Small" font="Fonts\FRIZQT__.TTF" outline="NORMAL" height="16" />
Nenue@75 9
Nenue@0 10 <Font name="VeneerFont_Large" font="Fonts\FRIZQT__.TTF" outline="NORMAL" height="24" />
Nenue@75 11 <Font name="VeneerNumberFontSmall" font="Fonts\ARIALN.ttf" outline="NORMAL" height="12" />
Nenue@61 12 <Font name="VeneerNumberFont" font="Fonts\ARIALN.ttf" outline="NORMAL" height="14" />
Nenue@61 13 <Font name="VeneerNumberFontLarge" font="Fonts\ARIALN.ttf" outline="NORMAL" height="24" />
Nenue@75 14 <Font name="VeneerHeaderFont" font="Fonts\FRIZQT__.TTF" outline="THICK" height="14" />
Nenue@75 15 <Font name="VeneerHeader2Font" font="Fonts\FRIZQT__.TTF" outline="THICK" height="14">
Nenue@75 16 <Color a="1" r="1" g="0.4" b="0" />
Nenue@75 17 </Font>
Nenue@0 18
Nenue@0 19
Nenue@84 20 <Frame name="VeneerMixinScripts" virtual="true">
Nenue@84 21 <Scripts>
Nenue@84 22 <OnLoad method="OnLoad" />
Nenue@84 23 <OnEvent method="OnEvent" />
Nenue@84 24 <OnUpdate method="OnUpdate" />
Nenue@84 25 <OnShow method="OnShow" />
Nenue@84 26 <OnHide method="OnHide" />
Nenue@84 27 <OnMouseDown method="OnMouseDown" />
Nenue@84 28 <OnSizeChanged method="OnSizeChanged" />
Nenue@84 29 </Scripts>
Nenue@84 30 </Frame>
Nenue@84 31
Nenue@84 32 <Frame name="Veneer" inherits="VeneerMixinScripts" mixin="VeneerCore" hidden="true" enableMouse="true" movable="true" frameStrata="DIALOG">
Nenue@0 33 <Size x="400" y="400" />
Nenue@0 34 <Anchors>
Nenue@0 35 <Anchor point="CENTER" relativePoint="CENTER" x="0" y="0" />
Nenue@0 36 </Anchors>
Nenue@0 37 <Scripts>
Nenue@84 38 <OnDragStart method="OnDragStart" />
Nenue@84 39 <OnDragStop method="OnDragStop" />
Nenue@0 40 </Scripts>
Nenue@0 41 <Layers>
Nenue@0 42 <Layer level="BACKGROUND">
Nenue@0 43 <Texture setAllPoints="true">
Nenue@0 44 <Color r="0" g="0" b="0" a="0.7" />
Nenue@0 45 </Texture>
Nenue@0 46 </Layer>
Nenue@0 47 <Layer level="ARTWORK">
Nenue@0 48 <FontString name="$parentHeader" parentKey="header" inherits="VeneerFontHighlightLarge" text="Veneer">
Nenue@0 49 <Anchors>
Nenue@0 50 <Anchor point="TOPLEFT" x="3" y="-4" />
Nenue@0 51 </Anchors>
Nenue@0 52 </FontString>
Nenue@0 53 </Layer>
Nenue@0 54 </Layers>
Nenue@0 55 <Frames>
Nenue@0 56 <Button name="$parentCloseButton" parentKey="close" text="X">
Nenue@0 57 <ButtonText inherits="SystemFont_Small" />
Nenue@0 58 <Scripts>
Nenue@0 59 <OnClick>
Nenue@0 60 self:GetParent():Close()
Nenue@0 61 </OnClick>
Nenue@0 62 </Scripts>
Nenue@0 63 <Size x="24" y="24" />
Nenue@0 64 <Anchors>
Nenue@0 65 <Anchor point="TOPRIGHT" x="-5" y="-5" />
Nenue@0 66 </Anchors>
Nenue@0 67 <NormalTexture parentKey="normal" setAllPoints="true">
Nenue@0 68 <Color a="1" r="0" g="0" b="0" />
Nenue@0 69 </NormalTexture>
Nenue@0 70 <PushedTexture setAllPoints="true">
Nenue@0 71 <Color a="1" r="1" g="0" b="0" />
Nenue@0 72 </PushedTexture>
Nenue@0 73 <HighlightTexture setAllPoints="true" alphaMode="ADD">
Nenue@0 74 <Color a=".5" r="1" g=".7" b="0.5" />
Nenue@0 75 </HighlightTexture>
Nenue@0 76 </Button>
Nenue@0 77 <Button name="$parentGuidesButton" parentKey="guides" text="Guides">
Nenue@0 78 <ButtonText inherits="SystemFont_Small" />
Nenue@0 79 <Scripts>
Nenue@0 80 <OnClick>
Nenue@0 81 self:GetParent():ToggleGuides(self)
Nenue@0 82 </OnClick>
Nenue@0 83 </Scripts>
Nenue@0 84 <Size x="36" y="24" />
Nenue@0 85 <Anchors>
Nenue@0 86 <Anchor point="RIGHT" relativePoint="LEFT" relativeTo="$parentCloseButton" x="-5" y="0" />
Nenue@0 87 </Anchors>
Nenue@0 88 <NormalTexture parentKey="normal" setAllPoints="true">
Nenue@0 89 <Color a="1" r="0" g="0" b="0" />
Nenue@0 90 </NormalTexture>
Nenue@0 91 <PushedTexture setAllPoints="true">
Nenue@0 92 <Color a="1" r="1" g="0" b="0" />
Nenue@0 93 </PushedTexture>
Nenue@0 94 <HighlightTexture setAllPoints="true" alphaMode="ADD">
Nenue@0 95 <Color a=".5" r="1" g=".7" b="0.5" />
Nenue@0 96 </HighlightTexture>
Nenue@0 97 </Button>
Nenue@0 98 </Frames>
Nenue@0 99 </Frame>
Nenue@0 100
Nenue@72 101 <Frame name="VeneerTemplate" virtual="true">
Nenue@72 102 <Layers>
Nenue@74 103 <Layer level="BORDER">
Nenue@72 104 <Texture parentKey="bg" setAllPoints="true" parentArray="configLayers" />
Nenue@72 105 </Layer>
Nenue@72 106 <Layer level="OVERLAY">
Nenue@72 107 <FontString parentKey="label" inherits="VeneerNumberFontLarge" parentArray="configLayers">
Nenue@72 108 <Anchors>
Nenue@72 109 <Anchor point="TOPLEFT" />
Nenue@72 110 </Anchors>
Nenue@72 111 </FontString>
Nenue@72 112 </Layer>
Nenue@72 113 </Layers>
Nenue@72 114 <Frames>
Nenue@72 115 <Button parentKey="resize" parentArray="configLayers">
Nenue@72 116 <Size x="48" y="16" />
Nenue@72 117 <Anchors>
Nenue@72 118 <Anchor point="BOTTOMRIGHT" />
Nenue@72 119 </Anchors>
Nenue@72 120 <NormalTexture setAllPoints="true">
Nenue@72 121 <Color a="1" r="1" g="1" b="1" />
Nenue@72 122 </NormalTexture>
Nenue@72 123 <PushedTexture>
Nenue@72 124 <Color a="1" r="1" g="0.5" b="1" />
Nenue@72 125 </PushedTexture>
Nenue@72 126 </Button>
Nenue@72 127 </Frames>
Nenue@72 128 </Frame>
Nenue@72 129
Nenue@0 130
Nenue@75 131
Nenue@80 132 <Frame name="VeneerStatusBarTemplate" virtual="true" hidden="true" inherits="VeneerMixinScripts">
Nenue@80 133 <Scripts>
Nenue@80 134 <OnShow>
Nenue@80 135 if self.OnShow then self:OnShow() end
Nenue@80 136 if self.Header:IsVisible() then
Nenue@80 137 self.ProgressBG:ClearAllPoints()
Nenue@80 138 self.ProgressBG:SetPoint('TOP', self.GlowLine, 'BOTTOM', 0, -1)
Nenue@80 139 self.ProgressBG:SetPoint('LEFT')
Nenue@80 140 self.ProgressBG:SetPoint('RIGHT')
Nenue@80 141 self.ProgressBG:SetPoint('BOTTOM')
Nenue@80 142 else
Nenue@80 143 self.ProgressBG:ClearAllPoints()
Nenue@80 144 self.ProgressBG:SetAllPoints(self)
Nenue@80 145 end
Nenue@80 146 </OnShow>
Nenue@80 147 <OnSizeChanged>
Nenue@80 148 </OnSizeChanged>
Nenue@80 149 </Scripts>
Nenue@80 150 <Layers>
Nenue@80 151 <Layer level="BACKGROUND">
Nenue@80 152 <Texture parentKey="UnderLay">
Nenue@75 153
Nenue@80 154 </Texture>
Nenue@80 155 </Layer>
Nenue@80 156 <Layer level="BORDER">
Nenue@80 157 <Texture parentKey="ProgressBG" setAllPoints="true">
Nenue@80 158 <Color a=".7" r="0" g="0" b="0" />
Nenue@80 159 </Texture>
Nenue@80 160 <Texture parentKey="GlowLine" atlas="AftLevelup-GlowLine" useAtlasSize="false">
Nenue@80 161 <Size y="3" />
Nenue@80 162 <Anchors>
Nenue@80 163 <Anchor point="TOPLEFT" x="-27" y="-11" />
Nenue@80 164 <Anchor point="RIGHT" x="27" y="0" />
Nenue@80 165 </Anchors>
Nenue@80 166 </Texture>
Nenue@80 167 </Layer>
Nenue@80 168 <Layer level="ARTWORK">
Nenue@80 169 <Texture parentKey="ProgressBar">
Nenue@80 170 <Anchors>
Nenue@80 171 <Anchor point="BOTTOMLEFT" />
Nenue@80 172 </Anchors>
Nenue@80 173 <Color a="1" r=".7" g=".7" b=".7" />
Nenue@80 174 </Texture>
Nenue@80 175 </Layer>
Nenue@80 176 <Layer level="OVERLAY" >
Nenue@80 177 <FontString parentKey="Header" inherits="VeneerNumberFontSmall">
Nenue@80 178 <Anchors>
Nenue@80 179 <Anchor point="TOP" />
Nenue@80 180 </Anchors>
Nenue@80 181 </FontString>
Nenue@80 182 <FontString parentKey="Level" inherits="GameFontNormal">
Nenue@80 183 <Anchors>
Nenue@81 184 <Anchor point="TOP" x="0" y="14" />
Nenue@80 185 </Anchors>
Nenue@80 186 </FontString>
Nenue@80 187 <FontString parentKey="ProgressText" inherits="VeneerNumberFont">
Nenue@80 188 <Anchors>
Nenue@80 189 <Anchor point="CENTER" relativeKey="$parent.ProgressBG" />
Nenue@80 190 </Anchors>
Nenue@80 191 </FontString>
Nenue@80 192 </Layer>
Nenue@80 193 </Layers>
Nenue@80 194 </Frame>
Nenue@75 195
Nenue@80 196
Nenue@0 197
Nenue@0 198 </Ui>