-
-
Notifications
You must be signed in to change notification settings - Fork 640
Open
Description
Here is a snippet of code:
/**
* Apply styles from array.
*
* <code>
* $spreadsheet->getActiveSheet()->getStyle('B2')->getFont()->applyFromArray(
* [
* 'name' => 'Arial',
* 'bold' => TRUE,
* 'italic' => FALSE,
* 'underline' => \PhpOffice\PhpSpreadsheet\Style\Font::UNDERLINE_DOUBLE,
* 'strikethrough' => FALSE,
* 'color' => [
* 'rgb' => '808080'
* ]
* ]
* );
* </code>
*
* @param array{name?: string, latin?: string, eastAsian?: string, complexScript?: string, bold?: bool, italic?: bool, superscript?: bool, subscript?: bool, underline?: bool|string, strikethrough?: bool, color?: string[], size?: ?int, chartColor?: ChartColor, scheme?: string, cap?: string, autoColor?: bool} $styleArray Array containing style information
*
* @return $this
*/
public function applyFromArray(array $styleArray): staticExpected behavior
public applyFromArray(name?: string, latin?: string, eastAsian?: string, complexScript?: string, bold?: bool, italic?: bool, superscript?: bool, subscript?: bool, underline?: bool|string, strikethrough?: bool, color?: string[], size?: ?int, chartColor?: ChartColor, scheme?: string, cap?: string, autoColor?: bool) : $this
Actual behavior
public applyFromArray(ChartColor, scheme?: string, cap?: string, autoColor?: bool} $styleArray) : $this
It seems like the part before ChartColor has been dropped. Maybe the result is too long? However, my testing indicates that, no matter how I rearrange and/or add things, the truncation is always at ChartColor.
Steps to reproduce the problem
- See below for links to project, affected source code, PhpDocumentor result.
Your environment
Windows 11
- Version used: 3.9.0
- Install method phar
- PHP version 8.4
- Operating system and version (e.g. Ubuntu 20.04, Windows 10): Windows 11
- Link to your project: https://github.com/PHPOffice/PhpSpreadsheet
- Attach code that is involved
- Excerpted above. Source code is at: https://github.com/PHPOffice/PhpSpreadsheet/blob/master/src/PhpSpreadsheet/Style/Font.php
- Documentation page with the problem is at: https://phpoffice.github.io/PhpSpreadsheet/classes/PhpOffice-PhpSpreadsheet-Style-Font.html
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels