PHPRtfLite_Table::addColumn PHP Method

addColumn() public method

adds column
public addColumn ( float $width ) : PHPRtfLite_Table_Column
$width float column width
return PHPRtfLite_Table_Column
    public function addColumn($width)
    {
        $column = new PHPRtfLite_Table_Column($this, $this->getColumnsCount() + 1, $width);
        $this->_columns[] = $column;
        return $column;
    }

Usage Example

コード例 #1
0
ファイル: TableTest.php プロジェクト: jfrank1500/curso_php
 /**
  * test addColumn
  * @depends testAddColumnList
  */
 public function testAddColumn(PHPRtfLite_Table $table)
 {
     $table->addColumn(7);
     $this->assertEquals(3, $table->getColumnsCount());
     return $table;
 }