SequentialLayout
160808
function add() {
    var modifier = new Modifier({
        size: [200, 80],
        align: [0, 0],
        origin: [0, 0],
        transform: Transform.translate(100, 210)
    });

    var layout = new ({
        direction: Utility.Direction.X
    });

    var item1 = new ImageSurface({
        size: [80, 80],
        content: './images/famous_logo.png'
    });

    var item2 = new Surface({
        size: [120, 80],
        content: 'Example',
        properties: {
            textAlign: 'center',
            lineHeight: '80px',
            backgroundColor: '#eaeaea'
        }
    });

    layout.sequenceFrom([item1, item2]);
    ctx.add(modifier).add(layout);
}
310890
private void checkLayout()
    {
        Dimension dim = getLayoutDimension();
        if (currentDimension == null || !currentDimension.equals(dim)) //the dimension has changed
        {
            createLayout(dim);
            //containing box for the new viewport
            viewport.setContainingBlockBox(owner);
            if (owner instanceof BlockBox)
                viewport.clipByBlock((BlockBox) owner);
            
            owner.removeAllSubBoxes();
            owner.addSubBox(viewport);
            currentDimension = new Dimension(dim);
        }
    }
137493
private static void initLayout() {
		Log.info("Initializing Layout...");
		try {
			conf.getLayout().init();
			configContext.setLayout(conf.getLayout());
			Log.info(conf.getLayout().getClass().getName() + " Initialized.");
		} catch (InitializationException e) {
			Log.error("There is a problem in the layout: ", conf.getLayout().getClass().getName(), " you configured.",
					ErrorGuide.getGuide(ErrorGuide.LAYOUT_ERROR));
			terminate();
			throw new InitializationException(INIT_FAILED);
		}

	}
1313995
public void setLayout(java.lang.String layout) {
        getStateHelper().put(PropertyKeys.layout, layout);
    }
1248567
private void callDoLayout(Container container)
    {
        container.doLayout();
        int n = container.getComponentCount();
        for (int i=0; i<n; i++)
        {
            Component component = container.getComponent(i);
            if (component instanceof Container)
            {
                Container subContainer = (Container)component;
                callDoLayout(subContainer);
            }
        }
    }
733005
private void installLayout(JRootPane root) {
        if (layoutManager == null) {
            layoutManager = createLayoutManager();
        }

        savedOldLayout = root.getLayout();
        root.setLayout(layoutManager);
    }
43264
private void initLayout() {

        VerticalLayout page = new VerticalLayout();
        setContent(page);
        page.setId("page");

        page.addComponent(headerLayout);
        initLayoutHeader();

        page.addComponent(mainTab);


        initLayoutFooter();
        page.addComponent(layoutFooter);

    }
1222964
protected void setLayoutToStartSegment(int segmentLength,
                                          int priority,
                                          boolean isPooled,
                                          boolean isExchange,
                                          int packetNumber,
                                          int segmentType,
                                          int conversationId,
                                          int requestNumber,
                                          long totalLength)
   {
      if (tc.isEntryEnabled()) SibTr.entry(this, tc, "setLayoutToStartSegment", new Object[]{""+segmentLength, ""+priority, ""+isPooled, ""+isExchange, ""+packetNumber, ""+segmentType, ""+conversationId, ""+requestNumber, ""+totalLength});
      setLayoutToConversation(segmentLength, priority, isPooled, isExchange, packetNumber, segmentType, conversationId, requestNumber, null, null);
      segmentedTransmissionHeaderFields.totalLength = totalLength;
      segmentedTransmissionHeaderFields.segmentType = segmentType;
      transmissionRemaining = segmentLength;
      primaryHeaderFields.segmentType = JFapChannelConstants.SEGMENT_SEGMENTED_FLOW_START;      
      layout = JFapChannelConstants.XMIT_SEGMENT_START;
      if (tc.isEntryEnabled()) SibTr.exit(this, tc, "setLayoutToStartSegment");
   }
1297759
public function afterLayout() {
         // run through algorithm
         $compressed = $this->_html($this->getView()->Blocks->get('content'));

         // set html content
         $this->getView()->Blocks->set('content', $compressed);
     }
1099700
public void setAutomaticLayout(boolean enable) {
        if (enable) {
            this.setAutomaticLayout(AutomaticLayout.RankDirection.TopBottom, 300, 600, 200, false);
        } else {
            this.automaticLayout = null;
        }
    }
822713
private void init(){

        // Create the Empty Layout
        LinearLayout container = new LinearLayout(getContext());
        mIcon = new ImageView(getContext());
        mMessage = new TextView(getContext());
        mAction = new TextView(getContext());
        mProgress = new ProgressBar(getContext());

        // Setup the layout
        LayoutParams containerParams = new LayoutParams(WRAP_CONTENT, WRAP_CONTENT);
        container.setGravity(Gravity.CENTER);
        container.setOrientation(LinearLayout.VERTICAL);
        containerParams.addRule(RelativeLayout.CENTER_IN_PARENT);

        // Setup the Icon
        if(mEmptyIcon > 0) {
            mIcon.setImageResource(mEmptyIcon);
        }else{
            mIcon.setVisibility(View.GONE);
        }

        mIcon.setPadding(0, 0, 0, mEmptyIconPadding);
        if (mEmptyIconColor != -1) {
            mIcon.setColorFilter(mEmptyIconColor, PorterDuff.Mode.SRC_IN);
        }
        int width = mEmptyIconSize == -1 ? WRAP_CONTENT : mEmptyIconSize;
        int height = mEmptyIconSize == -1 ? WRAP_CONTENT : mEmptyIconSize;
        LinearLayout.LayoutParams iconParams = new LinearLayout.LayoutParams(width, height);
        container.addView(mIcon, iconParams);

        // Setup the message
        LinearLayout.LayoutParams msgParams = new LinearLayout.LayoutParams(WRAP_CONTENT, WRAP_CONTENT);
        mMessage.setGravity(Gravity.CENTER);
        mMessage.setTextSize(TypedValue.COMPLEX_UNIT_PX, mEmptyMessageTextSize);
        mMessage.setTextColor(mEmptyMessageColor);
        mMessage.setText(mEmptyMessage);

        // Add to the layout
        container.addView(mMessage, msgParams);

        // Setup the Action Label
        LinearLayout.LayoutParams actionParams = new LinearLayout.LayoutParams(WRAP_CONTENT, WRAP_CONTENT);
        actionParams.topMargin = getResources().getDimensionPixelSize(R.dimen.activity_padding);
        int padding = (int) SizeUtils.dpToPx(getContext(), 8);
        mAction.setText(mEmptyActionText);
        mAction.setTextColor(mEmptyActionColor);
        mAction.setTextSize(TypedValue.COMPLEX_UNIT_PX, mEmptyActionTextSize);
        mAction.setAllCaps(true);
        mAction.setPadding(padding, padding, padding, padding);
        mAction.setVisibility(TextUtils.isEmpty(mEmptyActionText) ? View.GONE : View.VISIBLE);
        UIUtils.setBackground(mAction, UIUtils.getSelectableItemBackground(getContext()));
        mAction.setOnClickListener(new OnClickListener() {
            @Override
            public void onClick(View v) {
                if (mActionClickListener != null) mActionClickListener.onClick(v);
            }
        });

        if(!isInEditMode()){
            FontLoader.apply(mMessage, mEmptyMessageTypeface);
            FontLoader.apply(mAction, Face.ROBOTO_MEDIUM);
        }

        container.addView(mAction, actionParams);

        LinearLayout.LayoutParams progressParams = new LinearLayout.LayoutParams(WRAP_CONTENT, WRAP_CONTENT);
        mProgress.setVisibility(View.GONE);

        container.addView(mProgress, progressParams);

        // Add to view
        addView(container, containerParams);

        // Switch the states
        if(mState == STATE_LOADING){
            setLoading();
        }
    }
699679
protected void initLayout()
  {
    setOpaque( false );
    setBorder( BorderFactory.createLineBorder( Scheme.active().getWindowBorder() ) );

    GridBagLayout gridBag = new GridBagLayout();
    JPanel pane = new JPanel();
    pane.addMouseListener( this );
    pane.addMouseMotionListener( this );
    pane.setLayout( gridBag );
    GridBagConstraints c = new GridBagConstraints();

    _viewer = new HtmlViewer();
    _viewer.setText( _strHelpText );
    _viewer.setBorder( BorderFactory.createEmptyBorder( 0, 10, 0, 10 ) );
    _viewer.addMouseListener( this );
    _viewer.addMouseMotionListener( this );
    _scroller = new JScrollPane( _viewer );
    _scroller.setBorder( BorderFactory.createEmptyBorder( 0, 0, 0, 0 ) );
    _scroller.setMaximumSize( calcMaximumViewerSize() );
    _viewer.setBackground( Scheme.active().getTooltipBackground() );

    c.anchor = GridBagConstraints.CENTER;
    c.fill = GridBagConstraints.BOTH;
    c.gridx = 0;
    c.gridy = 0;
    c.gridwidth = GridBagConstraints.REMAINDER;
    c.gridheight = GridBagConstraints.REMAINDER;
    c.weightx = 1;
    c.weighty = 1;
    pane.add( _scroller, c );

    _editorKeyListener = new EditorKeyListener();

    add( pane );

    addSeparator();

    addMouseListener( this );
    addMouseMotionListener( this );
  }
920659
def init_layout(self):
        
        super(AndroidSurfaceView, self).init_layout()

        # Force layout using the default params
        if not self.layout_params:
            self.set_layout({})
112302
function(){
      for( var i = 0; i < depths.length; i++ ){
        var eles = depths[i];

        for( var j = 0; j < eles.length; j++ ){
          var ele = eles[j];

          ele._private.scratch.BreadthFirstLayout = {
            depth: i,
            index: j
          };
        }
      }
    }
90268
function handleLayout(layoutObj) {
      view.currentLayout = layoutObj.layout;
      self.handle('onLayout', view);
      delete view.currentLayout;
    }
830722
private void __addLayoutSection(String name, String section, boolean def) {
        Map<String, String> m = def ? layoutSections0 : layoutSections;
        if (m.containsKey(name)) return;
        m.put(name, section);
    }
100198
public void setButtonLayout(final Layout layout) {
		RadioButtonSelectModel model = getOrCreateComponentModel();
		model.layout = layout;
		model.numColumns = 0;
	}