# Layout Class (com.senocular.display.Layout)

**URL:** <https://forum.kirupa.com/t/layout-class-com-senocular-display-layout/262971>\
**Category:** flash\
**Created:** [June 11, 2008, 2:49pm UTC](https://forum.kirupa.com/t/layout-class-com-senocular-display-layout/262971 "2008-06-11T14:49:51Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![pensamente](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/pensamente/32/1208_2.png) [@pensamente](https://forum.kirupa.com/u/pensamente)\
**Post date:** [June 11, 2008, 2:49pm UTC](https://forum.kirupa.com/t/layout-class-com-senocular-display-layout/262971/1 "2008-06-11T14:49:51Z")

</div>

hi,

i’m having some problems when using the class. It just won’t behave as it should, distorting the contents. I’ll pos the fla, plus code, plus swf…

[AS]stage.align = StageAlign.TOP\_LEFT;  
stage.scaleMode = StageScaleMode.NO\_SCALE;

import com.senocular.display.Layout;

var SL:Layout = new Layout(stage);

// TOPBAR - align: top  
var align\_1:Layout = new Layout(topBar, true);  
align\_1.top = 0;  
SL.addChild(align\_1);

var align\_2:Layout = new Layout(topBar.BGtop, true);  
align\_2.percentWidth = 1;  
SL.addChild(align\_2);

// TOPBAR - align: bot  
var align\_3:Layout = new Layout(botBar, true);  
align\_3.bottom = 0;  
SL.addChild(align\_3);

var align\_4:Layout = new Layout(botBar.BGbot, true);  
align\_4.percentWidth = 1;  
SL.addChild(align\_4);

SL.draw();[/AS]

really can’t figure out what’s wrong here…  
:stare:  
thnks

am
