PhpExt : Layout [ class tree ] [ index ] [ all elements ]

Class: PhpExt_Layout_ColumnLayout

Source Location: /PhpExt/Layout/ColumnLayout.php

Class PhpExt_Layout_ColumnLayout

Class Overview

This is the layout style of choice for creating structural layouts in a multi-column format where the width of each column can be specified as a percentage or fixed width, but the height is allowed to vary based on the content.

ColumnLayout does not have any direct config options (other than inherited ones), but it does support a specific config property of columnWidth that can be included in the config of any panel added to it. The layout will use the width (if pixels) or columnWidth (if percent) of each panel during layout to determine how to size each panel. If width or columnWidth is not specified for a given panel, its width will default to the panel's width (or auto).

The width property is always evaluated as pixels, and must be a number greater than or equal to 1. The columnWidth property is always evaluated as a percentage, and must be a decimal value greater than 0 and less than 1 (e.g., .25).

The basic rules for specifying column widths are pretty simple. The logic makes two passes through the set of contained panels. During the first layout pass, all panels that either have a fixed width or none specified (auto) are skipped, but their widths are subtracted from the overall container width. During the second pass, all panels with columnWidths are assigned pixel widths in proportion to their percentages based on the total remaining container width. In other words, percentage width panels are designed to fill the space left over by all the fixed-width or auto-width panels. Because of this, while you can specify any number of columns with different percentages, the columnWidths must always add up to 1 (or 100%) when added together, otherwise your layout may not render as expected.

Located in /PhpExt/Layout/ColumnLayout.php [line 32]

PhpExt_Object
   |
   --PhpExt_Layout_ContainerLayout
      |
      --PhpExt_Layout_ColumnLayout
Author(s):
API Tags:
See:  PhpExt_Layout_ColumnLayoutData

Methods

[ Top ]
Inherited Properties, Constants, and Methods
Inherited Properties Inherited Methods Inherited Constants

Inherited From PhpExt_Layout_ContainerLayout

PhpExt_Layout_ContainerLayout::$_validLayoutDataClassNames

Inherited From PhpExt_Object

PhpExt_Object::$_extClassName
PhpExt_Object::$_extConfigProperties
PhpExt_Object::$_validExtConfigProperties
PhpExt_Object::$_varName

Inherited From PhpExt_Layout_ContainerLayout

PhpExt_Layout_ContainerLayout::__construct()
PhpExt_Layout_ContainerLayout::addValidLayoutDataClassName()
PhpExt_Layout_ContainerLayout::addValidLayoutProperties()
Adds the layout specific valid properties
PhpExt_Layout_ContainerLayout::getExtraCssClass()
An optional extra CSS class that will be added to the container (defaults to ''). This can be useful for adding customized styles to the container or any of its children using standard CSS rules.
PhpExt_Layout_ContainerLayout::getLayoutKey()
Returns the internal config string for the layout.
PhpExt_Layout_ContainerLayout::getRenderHidden()
True to hide each contained item on render (defaults to false).
PhpExt_Layout_ContainerLayout::getValidLayoutDataClassNames()
PhpExt_Layout_ContainerLayout::getValidLayoutProperties()
Gets the layout specific valid properties
PhpExt_Layout_ContainerLayout::setExtraCssClass()
An optional extra CSS class that will be added to the container (defaults to ''). This can be useful for adding customized styles to the container or any of its children using standard CSS rules.
PhpExt_Layout_ContainerLayout::setRenderHidden()
True to hide each contained item on render (defaults to false).

Inherited From PhpExt_Object

PhpExt_Object::__construct()
PhpExt_Object::addValidConfigProperties()
PhpExt_Object::createMethodSignature()
PhpExt_Object::getConfigParams()
PhpExt_Object::getExtConfigProperty()
PhpExt_Object::getJavascript()
PhpExt_Object::getMethodInvokeStm()
PhpExt_Object::isExtObject()
PhpExt_Object::paramToString()
PhpExt_Object::setExtClassInfo()
PhpExt_Object::setExtConfigProperty()
PhpExt_Object::__get()
PhpExt_Object::__set()

Inherited From PhpExt_Layout_ContainerLayout

PhpExt_Layout_ContainerLayout::LAYOUT_ABSOLUTE
PhpExt_Layout_ContainerLayout::LAYOUT_ACCORDION
PhpExt_Layout_ContainerLayout::LAYOUT_ANCHOR
PhpExt_Layout_ContainerLayout::LAYOUT_BORDER
PhpExt_Layout_ContainerLayout::LAYOUT_CARD
PhpExt_Layout_ContainerLayout::LAYOUT_COLUMN
PhpExt_Layout_ContainerLayout::LAYOUT_DEFAULT
PhpExt_Layout_ContainerLayout::LAYOUT_FIT
PhpExt_Layout_ContainerLayout::LAYOUT_FORM
PhpExt_Layout_ContainerLayout::LAYOUT_TAB
PhpExt_Layout_ContainerLayout::LAYOUT_TABLE

[ Top ]
Method Summary
PhpExt_Layout_ColumnLayout   __construct()  
string   getLayoutKey()   Returns the internal config string for the layout.

[ Top ]
Methods
Constructor __construct  [line 44]

  PhpExt_Layout_ColumnLayout __construct( )


API Tags:
Access:  public


Redefinition of:
PhpExt_Layout_ContainerLayout::__construct()

[ Top ]
getLayoutKey  [line 40]

  string getLayoutKey( )

Returns the internal config string for the layout.


API Tags:
See:  PhpExt_Layout_ContainerLayout::LAYOUT_COLUMN;
Access:  public


Redefinition of:
PhpExt_Layout_ContainerLayout::getLayoutKey()
Returns the internal config string for the layout.

[ Top ]

Documentation generated on Fri, 08 Aug 2008 15:51:26 -0500 by phpDocumentor 1.4.0