UNDERLINE_NONE
UNDERLINE_NONE = 'none'
$parent : \PhpOffice\PhpSpreadsheet\Spreadsheet|\PhpOffice\PhpSpreadsheet\Style\Style
Parent. Only used for supervisor.
$color : \PhpOffice\PhpSpreadsheet\Style\Color
Foreground color.
__construct(boolean $isSupervisor = false, boolean $isConditional = false)
Create a new Font.
boolean | $isSupervisor | Flag indicating if this is a supervisor or not Leave this value at default unless you understand exactly what its ramifications are |
boolean | $isConditional | Flag indicating if this is a conditional style or not Leave this value at default unless you understand exactly what its ramifications are |
bindParent(\PhpOffice\PhpSpreadsheet\Spreadsheet|\PhpOffice\PhpSpreadsheet\Style\Style $parent, null|string $parentPropertyName = null) : \PhpOffice\PhpSpreadsheet\Style\Supervisor
Bind parent. Only used for supervisor.
\PhpOffice\PhpSpreadsheet\Spreadsheet|\PhpOffice\PhpSpreadsheet\Style\Style | $parent | |
null|string | $parentPropertyName |
getActiveSheet() : \PhpOffice\PhpSpreadsheet\Worksheet\Worksheet
Get the currently active sheet. Only used for supervisor.
getSharedComponent() : \PhpOffice\PhpSpreadsheet\Style\Font
Get the shared style component for the currently active cell in currently active sheet.
Only used for style supervisor.
applyFromArray(array $pStyles) : \PhpOffice\PhpSpreadsheet\Style\Font
Apply styles from array.
$spreadsheet->getActiveSheet()->getStyle('B2')->getFont()->applyFromArray(
[
'name' => 'Arial',
'bold' => TRUE,
'italic' => FALSE,
'underline' => \PhpOffice\PhpSpreadsheet\Style\Font::UNDERLINE_DOUBLE,
'strikethrough' => FALSE,
'color' => [
'rgb' => '808080'
]
]
);
array | $pStyles | Array containing style information |
setName(string $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Name.
string | $pValue |
setSize(float $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Size.
float | $pValue |
setBold(boolean $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Bold.
boolean | $pValue |
setItalic(boolean $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Italic.
boolean | $pValue |
setSuperscript(boolean $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Superscript.
boolean | $pValue |
setSubscript(boolean $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Subscript.
boolean | $pValue |
setUnderline(boolean|string $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Underline.
boolean|string | $pValue | \PhpOffice\PhpSpreadsheet\Style\Font underline type If a boolean is passed, then TRUE equates to UNDERLINE_SINGLE, false equates to UNDERLINE_NONE |
setStrikethrough(boolean $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Strikethrough.
boolean | $pValue |
getColor() : \PhpOffice\PhpSpreadsheet\Style\Color
Get Color.
setColor(\PhpOffice\PhpSpreadsheet\Style\Color $pValue) : \PhpOffice\PhpSpreadsheet\Style\Font
Set Color.
\PhpOffice\PhpSpreadsheet\Style\Color | $pValue |