public setAutoFit ( $value = self::AUTOFIT_DEFAULT, $fontScale = null, $lnSpcReduction = null ) : |
||
$value | string | |
$fontScale | float | |
$lnSpcReduction | float | |
Результат |
public function setAutoFit($value = self::AUTOFIT_DEFAULT, $fontScale = null, $lnSpcReduction = null)
{
$this->autoFit = $value;
if (!is_null($fontScale)) {
$this->fontScale = $fontScale;
}
if (!is_null($lnSpcReduction)) {
$this->lnSpcReduction = $lnSpcReduction;
}
return $this;
}
public function testGetSetAutoFit() { $object = new RichText(); $this->assertInstanceOf('PhpOffice\\PhpPresentation\\Shape\\RichText', $object->setAutoFit()); $this->assertEquals(RichText::AUTOFIT_DEFAULT, $object->getAutoFit()); $this->assertInstanceOf('PhpOffice\\PhpPresentation\\Shape\\RichText', $object->setAutoFit(RichText::AUTOFIT_NORMAL)); $this->assertEquals(RichText::AUTOFIT_NORMAL, $object->getAutoFit()); }