Skip to content

Commit 505cc76

Browse files
author
Roman Syroeshko
committed
Fixed build.
1 parent 94c0d02 commit 505cc76

39 files changed

+92
-92
lines changed

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ This project adheres to [Semantic Versioning](http://semver.org/).
88
Place announcement text here.
99

1010
### Added
11-
- Introduced the ``\PhpOffice\PhpWord\SimpleType\ST_JcTable`` simple type. - @RomanSyroeshko
12-
- Introduced the ``\PhpOffice\PhpWord\SimpleType\ST_Jc`` simple type. - @RomanSyroeshko
11+
- Introduced the ``\PhpOffice\PhpWord\SimpleType\JcTable`` simple type. - @RomanSyroeshko
12+
- Introduced the ``\PhpOffice\PhpWord\SimpleType\Jc`` simple type. - @RomanSyroeshko
1313

1414
### Changed
1515
- Improved error message for the case when ``autoload.php`` is not found. - @RomanSyroeshko #371

docs/styles.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ Paragraph
6363

6464
Available Paragraph style options:
6565

66-
- ``alignment``. Supports all alignment modes provided by third edition of ISO/IEC 29500 standard. See ``\PhpOffice\PhpWord\SimpleType\ST_Jc`` class for the details.
66+
- ``alignment``. Supports all alignment modes provided by third edition of ISO/IEC 29500 standard. See ``\PhpOffice\PhpWord\SimpleType\Jc`` class for the details.
6767
- ``basedOn``. Parent style.
6868
- ``hanging``. Hanging by how much.
6969
- ``indent``. Indent by how much.
@@ -84,7 +84,7 @@ Table
8484

8585
Available Table style options:
8686

87-
- ``alignment``. Supports all alignment modes provided by third edition of ISO/IEC 29500 standard. See ``\PhpOffice\PhpWord\SimpleType\ST_JcTable`` class for the details.
87+
- ``alignment``. Supports all alignment modes provided by third edition of ISO/IEC 29500 standard. See ``\PhpOffice\PhpWord\SimpleType\JcTable`` class for the details.
8888
- ``bgColor``. Background color, e.g. '9966CC'.
8989
- ``border(Top|Right|Bottom|Left)Color``. Border color, e.g. '9966CC'.
9090
- ``border(Top|Right|Bottom|Left)Size``. Border size in twips.
@@ -115,7 +115,7 @@ Image
115115

116116
Available Image style options:
117117

118-
- ``alignment``. See ``\PhpOffice\PhpWord\SimpleType\ST_Jc`` class for the details.
118+
- ``alignment``. See ``\PhpOffice\PhpWord\SimpleType\Jc`` class for the details.
119119
- ``height``. Height in pixels.
120120
- ``marginLeft``. Left margin in inches, can be negative.
121121
- ``marginTop``. Top margin in inches, can be negative.
@@ -129,7 +129,7 @@ Numbering level
129129

130130
Available NumberingLevel style options:
131131

132-
- ``alignment``. Supports all alignment modes provided by third edition of ISO/IEC 29500 standard. See ``\PhpOffice\PhpWord\SimpleType\ST_Jc`` class for the details.
132+
- ``alignment``. Supports all alignment modes provided by third edition of ISO/IEC 29500 standard. See ``\PhpOffice\PhpWord\SimpleType\Jc`` class for the details.
133133
- ``font``. Font name.
134134
- ``format``. Numbering format bullet\|decimal\|upperRoman\|lowerRoman\|upperLetter\|lowerLetter.
135135
- ``hanging``. See paragraph style.

samples/Sample_01_SimpleText.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
echo date('H:i:s') , ' Create new PhpWord object' , EOL;
66
$phpWord = new \PhpOffice\PhpWord\PhpWord();
77
$phpWord->addFontStyle('rStyle', array('bold' => true, 'italic' => true, 'size' => 16, 'allCaps' => true, 'doubleStrikethrough' => true));
8-
$phpWord->addParagraphStyle('pStyle', array('alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::CENTER, 'spaceAfter' => 100));
8+
$phpWord->addParagraphStyle('pStyle', array('alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER, 'spaceAfter' => 100));
99
$phpWord->addTitleStyle(1, array('bold' => true), array('spaceAfter' => 240));
1010

1111
// New portrait section

samples/Sample_08_ParagraphPagination.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
$phpWord = new \PhpOffice\PhpWord\PhpWord();
77
$phpWord->setDefaultParagraphStyle(
88
array(
9-
'alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::BOTH,
9+
'alignment' => \PhpOffice\PhpWord\SimpleType\Jc::BOTH,
1010
'spaceAfter' => \PhpOffice\PhpWord\Shared\Converter::pointToTwip(12),
1111
'spacing' => 120,
1212
)

samples/Sample_09_Tables.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
$section->addTextBreak(1);
2727
$section->addText(htmlspecialchars('Fancy table', ENT_COMPAT, 'UTF-8'), $header);
2828

29-
$styleTable = array('borderSize' => 6, 'borderColor' => '006699', 'cellMargin' => 80, 'alignment' => \PhpOffice\PhpWord\SimpleType\ST_JcTable::CENTER);
29+
$styleTable = array('borderSize' => 6, 'borderColor' => '006699', 'cellMargin' => 80, 'alignment' => \PhpOffice\PhpWord\SimpleType\JcTable::CENTER);
3030
$styleFirstRow = array('borderBottomSize' => 18, 'borderBottomColor' => '0000FF', 'bgColor' => '66BBFF');
3131
$styleCell = array('valign' => 'center');
3232
$styleCellBTLR = array('valign' => 'center', 'textDirection' => \PhpOffice\PhpWord\Style\Cell::TEXT_DIR_BTLR);
@@ -58,7 +58,7 @@
5858
$cellRowSpan = array('vMerge' => 'restart', 'valign' => 'center', 'bgColor' => 'FFFF00');
5959
$cellRowContinue = array('vMerge' => 'continue');
6060
$cellColSpan = array('gridSpan' => 2, 'valign' => 'center');
61-
$cellHCentered = array('alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::CENTER);
61+
$cellHCentered = array('alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER);
6262
$cellVCentered = array('valign' => 'center');
6363

6464
$phpWord->addTableStyle('Colspan Rowspan', $styleTable);
@@ -89,10 +89,10 @@
8989
$section->addTextBreak(2);
9090
$section->addText(htmlspecialchars('Nested table in a centered and 50% width table.', ENT_COMPAT, 'UTF-8'), $header);
9191

92-
$table = $section->addTable(array('width' => 50 * 50, 'unit' => 'pct', 'alignment' => \PhpOffice\PhpWord\SimpleType\ST_JcTable::CENTER));
92+
$table = $section->addTable(array('width' => 50 * 50, 'unit' => 'pct', 'alignment' => \PhpOffice\PhpWord\SimpleType\JcTable::CENTER));
9393
$cell = $table->addRow()->addCell();
9494
$cell->addText(htmlspecialchars('This cell contains nested table.', ENT_COMPAT, 'UTF-8'));
95-
$innerCell = $cell->addTable(array('alignment' => \PhpOffice\PhpWord\SimpleType\ST_JcTable::CENTER))->addRow()->addCell();
95+
$innerCell = $cell->addTable(array('alignment' => \PhpOffice\PhpWord\SimpleType\JcTable::CENTER))->addRow()->addCell();
9696
$innerCell->addText(htmlspecialchars('Inside nested table', ENT_COMPAT, 'UTF-8'));
9797

9898
// Save file

samples/Sample_12_HeaderFooter.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
$textrun = $cell->addTextRun();
1818
$textrun->addText(htmlspecialchars('This is the header with ', ENT_COMPAT, 'UTF-8'));
1919
$textrun->addLink('https://github.com/PHPOffice/PHPWord', htmlspecialchars('PHPWord on GitHub', ENT_COMPAT, 'UTF-8'));
20-
$table->addCell(4500)->addImage('resources/PhpWord.png', array('width' => 80, 'height' => 80, 'alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::END));
20+
$table->addCell(4500)->addImage('resources/PhpWord.png', array('width' => 80, 'height' => 80, 'alignment' => \PhpOffice\PhpWord\SimpleType\Jc::END));
2121

2222
// Add header for all other pages
2323
$subsequent = $section->addHeader();
@@ -26,7 +26,7 @@
2626

2727
// Add footer
2828
$footer = $section->addFooter();
29-
$footer->addPreserveText(htmlspecialchars('Page {PAGE} of {NUMPAGES}.', ENT_COMPAT, 'UTF-8'), null, array('alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::CENTER));
29+
$footer->addPreserveText(htmlspecialchars('Page {PAGE} of {NUMPAGES}.', ENT_COMPAT, 'UTF-8'), null, array('alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER));
3030
$footer->addLink('https://github.com/PHPOffice/PHPWord', htmlspecialchars('PHPWord on GitHub', ENT_COMPAT, 'UTF-8'));
3131

3232
// Write some text

samples/Sample_13_Images.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
$section->addTextBreak(2);
1313

1414
$section->addText(htmlspecialchars('Local image with styles:', ENT_COMPAT, 'UTF-8'));
15-
$section->addImage('resources/_earth.jpg', array('width' => 210, 'height' => 210, 'alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::CENTER));
15+
$section->addImage('resources/_earth.jpg', array('width' => 210, 'height' => 210, 'alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER));
1616
$section->addTextBreak(2);
1717

1818
// Remote image

samples/Sample_21_TableRowRules.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
$table1 = $section->addTable(array('cellMargin' => 0, 'cellMarginRight' => 0, 'cellMarginBottom' => 0, 'cellMarginLeft' => 0));
2323
$table1->addRow(3750);
2424
$cell1 = $table1->addCell(null, array('valign' => 'top', 'borderSize' => 30, 'borderColor' => 'ff0000'));
25-
$cell1->addImage('./resources/_earth.jpg', array('width' => 250, 'height' => 250, 'alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::CENTER));
25+
$cell1->addImage('./resources/_earth.jpg', array('width' => 250, 'height' => 250, 'alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER));
2626

2727
$section->addTextBreak();
2828
$section->addText(
@@ -43,7 +43,7 @@
4343
);
4444
$table2->addRow(3750, array('exactHeight' => true));
4545
$cell2 = $table2->addCell(null, array('valign' => 'top', 'borderSize' => 30, 'borderColor' => '00ff00'));
46-
$cell2->addImage('./resources/_earth.jpg', array('width' => 250, 'height' => 250, 'alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::CENTER));
46+
$cell2->addImage('./resources/_earth.jpg', array('width' => 250, 'height' => 250, 'alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER));
4747

4848
$section->addTextBreak();
4949
$section->addText(

samples/Sample_25_TextBox.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
// In section
1111
$textbox = $section->addTextBox(
1212
array(
13-
'alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::CENTER,
13+
'alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER,
1414
'width' => 400,
1515
'height' => 150,
1616
'borderSize' => 1,

samples/Sample_27_Field.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
$section->addText(htmlspecialchars('Number of pages field:', ENT_COMPAT, 'UTF-8'));
2020
$section->addField('NUMPAGES', array('format' => 'Arabic', 'numformat' => '0,00'), array('PreserveFormat'));
2121

22-
$textrun = $section->addTextRun(array('alignment' => \PhpOffice\PhpWord\SimpleType\ST_Jc::CENTER));
22+
$textrun = $section->addTextRun(array('alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER));
2323
$textrun->addText(htmlspecialchars('This is the date of lunar calendar ', ENT_COMPAT, 'UTF-8'));
2424
$textrun->addField('DATE', array('dateformat' => 'd-M-yyyy H:mm:ss'), array('PreserveFormat', 'LunarCalendar'));
2525
$textrun->addText(htmlspecialchars(' written in a textrun.', ENT_COMPAT, 'UTF-8'));

0 commit comments

Comments
 (0)