Skip to content

Commit 2919ce7

Browse files
authored
PhpOffice\PhpPresentation\Style\TextStyle : Fixed typo for default indent (#857)
1 parent 54b5b38 commit 2919ce7

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

docs/changes/1.2.0.md

+1
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
- `createDrawingShape` has no container defined by [@Progi1984](https://github.com/Progi1984) fixing [#820](https://github.com/PHPOffice/PHPPresentation/pull/820) in [#845](https://github.com/PHPOffice/PHPPresentation/pull/845)
2727
- ODPresentation Reader : Read differents units for margin by [@Progi1984](https://github.com/Progi1984) fixing [#830](https://github.com/PHPOffice/PHPPresentation/pull/830) in [#847](https://github.com/PHPOffice/PHPPresentation/pull/847)
2828
- PowerPoint2007 Reader : Fixed loading of fonts by [@ag3202](https://github.com/ag3202) and [@Progi1984](https://github.com/Progi1984) in [#851](https://github.com/PHPOffice/PHPPresentation/pull/851)
29+
- PhpOffice\PhpPresentation\Style\TextStyle : Fixed typo for default indent by [@Progi1984](https://github.com/Progi1984) in [#857](https://github.com/PHPOffice/PHPPresentation/pull/857)
2930

3031
## Miscellaneous
3132
- CI: Added ODFValidator by [@Progi1984](https://github.com/Progi1984) fixing [#678](https://github.com/PHPOffice/PHPWord/issues/678) in [#653](https://github.com/PHPOffice/PHPWord/pull/653)

src/PhpPresentation/Style/TextStyle.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ public function __construct(bool $default = true)
5353
$oRTParagraphBody = new RichTextParagraph();
5454
$oRTParagraphBody->getAlignment()
5555
->setHorizontal(Alignment::HORIZONTAL_CENTER)
56-
->setIndent(-324900 / 9525)
56+
->setIndent(-342900 / 9525)
5757
->setMarginLeft(342900 / 9525);
5858
$oRTParagraphBody->getFont()->setSize(32)->setColor($oColorTX1);
5959
$this->bodyStyle[1] = $oRTParagraphBody;

tests/PhpPresentation/Tests/Style/TextStyleTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public function testConstructDefaultTrue(): void
4242
$oParagraph = $object->getBodyStyleAtLvl(1);
4343
self::assertInstanceOf('PhpOffice\PhpPresentation\Shape\RichText\Paragraph', $oParagraph);
4444
self::assertEquals(Alignment::HORIZONTAL_CENTER, $oParagraph->getAlignment()->getHorizontal());
45-
self::assertEquals((-324900 / 9525), $oParagraph->getAlignment()->getIndent());
45+
self::assertEquals((-342900 / 9525), $oParagraph->getAlignment()->getIndent());
4646
self::assertEquals(0, $oParagraph->getAlignment()->getMarginLeft());
4747
self::assertEquals(32, $oParagraph->getFont()->getSize());
4848
/** @var SchemeColor $color */

0 commit comments

Comments
 (0)