`setStrikethrough()` did not set the font

Fixes #403
This commit is contained in:
Adrien Crivelli 2018-03-04 21:39:32 +01:00
parent bdc95b14bf
commit 6e2447d933
No known key found for this signature in database
GPG Key ID: B182FD79DC6DE92E
2 changed files with 3 additions and 1 deletions

View File

@ -21,6 +21,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- Read printing area correctly when skipping some sheets - [#371](https://github.com/PHPOffice/PhpSpreadsheet/issues/371)
- Avoid incorrectly overwriting calculated value type - [#394](https://github.com/PHPOffice/PhpSpreadsheet/issues/394)
- Select correct cell when calling freezePane - [#389](https://github.com/PHPOffice/PhpSpreadsheet/issues/389)
- `setStrikethrough()` did not set the font - [#403](https://github.com/PHPOffice/PhpSpreadsheet/issues/403)
## [1.1.0] - 2018-01-28

View File

@ -484,8 +484,9 @@ class Font extends Supervisor
if ($pValue == '') {
$pValue = false;
}
if ($this->isSupervisor) {
$styleArray = $this->getStyleArray(['strike' => $pValue]);
$styleArray = $this->getStyleArray(['strikethrough' => $pValue]);
$this->getActiveSheet()->getStyle($this->getSelectedCells())->applyFromArray($styleArray);
} else {
$this->strikethrough = $pValue;