public function PHPExcel_Style_Alignment::setHorizontal in Loft Data Grids 6.2
Same name and namespace in other branches
- 7.2 vendor/phpoffice/phpexcel/Classes/PHPExcel/Style/Alignment.php \PHPExcel_Style_Alignment::setHorizontal()
* Set Horizontal * *
Parameters
string $pValue: * @return PHPExcel_Style_Alignment
1 call to PHPExcel_Style_Alignment::setHorizontal()
- PHPExcel_Style_Alignment::applyFromArray in vendor/
phpoffice/ phpexcel/ Classes/ PHPExcel/ Style/ Alignment.php - * Apply styles from array * * <code> * $objPHPExcel->getActiveSheet()->getStyle('B2')->getAlignment()->applyFromArray( * array( * 'horizontal' => PHPExcel_Style_Alignment::HORIZONTAL_CENTER, …
File
- vendor/
phpoffice/ phpexcel/ Classes/ PHPExcel/ Style/ Alignment.php, line 223
Class
- PHPExcel_Style_Alignment
- PHPExcel_Style_Alignment
Code
public function setHorizontal($pValue = PHPExcel_Style_Alignment::HORIZONTAL_GENERAL) {
if ($pValue == '') {
$pValue = PHPExcel_Style_Alignment::HORIZONTAL_GENERAL;
}
if ($this->_isSupervisor) {
$styleArray = $this
->getStyleArray(array(
'horizontal' => $pValue,
));
$this
->getActiveSheet()
->getStyle($this
->getSelectedCells())
->applyFromArray($styleArray);
}
else {
$this->_horizontal = $pValue;
}
return $this;
}