irpagan
June 23rd, 2015, 04:29
I am experiencing an issue with right anchoring and I am hoping someone can explain to me what is occurring so that I can fix it and move on. whenever I give the frame the entire width past 570px it truncates and no longer displays the scroll list overlapping.
My first assumption was that the list control was not getting the full window so I added
<frame name="fielddark" offset="7,5,7,5" hidereadonly = "false" /> to the list which lets me see the width of the list inside the frame. It is getting the full length minus what it needs for the scroll bar I *think*
My next assumption and probably the correct one was this was something I am doing, since I am not terribly worried about gutting anything since SVN is used to track changes and I can always revert if necessary I went back to basics. I removed everything but the delete button and set the right anchor
<windowclass name="char_weapons">
<margins control="0,0,0,2" />
<script file="campaign/scripts/char_weapon.lua" /><!-- -->
<sheetdata>
<genericcontrol name="ra">
<anchored width="0" height="0">
<top />
<right />
</anchored>
<invisible />
</genericcontrol>
<button_idelete name="idelete">
<anchored height="20" width="20">
<top offset="2" />
<right parent="ra" relation="absolute" anchor="left" offset="-2" />
</anchored>
</button_idelete>
</sheetdata>
</windowclass>
The result was interesting (see ra_delete_button.png) the control seems to be setting itself as if it was "insidetop" and not insidetopright, which adding position="insidetopright" did not change the result. Adding none of the right anchoring shorthand notation seemed to work here. Changing the relation didn't change anything either, which I didn't expect it would.
I tried left, now this seems to work alignment wise (see la_delete_button.png) except when I code the whole thing out I get no scroll bar, the lines overlap creating a terrible mess.
<!-- @comment: Window Class (char_weapons) -->
<windowclass name="char_weapons">
<margins control="0,0,0,2" />
<script file="campaign/scripts/char_weapon.lua" /><!-- -->
<sheetdata>
<genericcontrol name="la">
<anchored width="0" height="0">
<top />
<left />
</anchored>
<invisible />
</genericcontrol>
<button_idelete name="idelete">
<anchored height="20" width="20">
<top offset="2" />
<left parent="la" relation="relative" anchor="right" offset="2" />
</anchored>
</button_idelete>
</sheetdata>
</windowclass>
What is it I am doing incorrectly when trying to aling the control to the right? I had no issues with skills, so I am at a loss as to what is happening. Any advice would be greatly appreciated.
Regards,
-d0gb0y
My first assumption was that the list control was not getting the full window so I added
<frame name="fielddark" offset="7,5,7,5" hidereadonly = "false" /> to the list which lets me see the width of the list inside the frame. It is getting the full length minus what it needs for the scroll bar I *think*
My next assumption and probably the correct one was this was something I am doing, since I am not terribly worried about gutting anything since SVN is used to track changes and I can always revert if necessary I went back to basics. I removed everything but the delete button and set the right anchor
<windowclass name="char_weapons">
<margins control="0,0,0,2" />
<script file="campaign/scripts/char_weapon.lua" /><!-- -->
<sheetdata>
<genericcontrol name="ra">
<anchored width="0" height="0">
<top />
<right />
</anchored>
<invisible />
</genericcontrol>
<button_idelete name="idelete">
<anchored height="20" width="20">
<top offset="2" />
<right parent="ra" relation="absolute" anchor="left" offset="-2" />
</anchored>
</button_idelete>
</sheetdata>
</windowclass>
The result was interesting (see ra_delete_button.png) the control seems to be setting itself as if it was "insidetop" and not insidetopright, which adding position="insidetopright" did not change the result. Adding none of the right anchoring shorthand notation seemed to work here. Changing the relation didn't change anything either, which I didn't expect it would.
I tried left, now this seems to work alignment wise (see la_delete_button.png) except when I code the whole thing out I get no scroll bar, the lines overlap creating a terrible mess.
<!-- @comment: Window Class (char_weapons) -->
<windowclass name="char_weapons">
<margins control="0,0,0,2" />
<script file="campaign/scripts/char_weapon.lua" /><!-- -->
<sheetdata>
<genericcontrol name="la">
<anchored width="0" height="0">
<top />
<left />
</anchored>
<invisible />
</genericcontrol>
<button_idelete name="idelete">
<anchored height="20" width="20">
<top offset="2" />
<left parent="la" relation="relative" anchor="right" offset="2" />
</anchored>
</button_idelete>
</sheetdata>
</windowclass>
What is it I am doing incorrectly when trying to aling the control to the right? I had no issues with skills, so I am at a loss as to what is happening. Any advice would be greatly appreciated.
Regards,
-d0gb0y