Skip to content

Commit aa49536

Browse files
authored
Merge branch 'develop' into add-getVariableCount-method
2 parents 12ad6fa + 2bfd82e commit aa49536

File tree

432 files changed

+6016
-1276
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

432 files changed

+6016
-1276
lines changed

.gitattributes

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# build config
2+
/.scrutinizer.yml export-ignore
3+
/.travis.yml export-ignore
4+
/php_cs.dist export-ignore
5+
/phpmd.xml.dist export-ignore
6+
/phpstan.neon export-ignore
7+
8+
/composer.lock export-ignore
9+
10+
# git files
11+
/.gitignore export-ignore
12+
/.gitattributes export-ignore
13+
14+
# project directories
15+
/build export-ignore
16+
/docs export-ignore
17+
/samples export-ignore
18+
19+
# tests
20+
/phpunit.xml.dist export-ignore
21+
/tests export-ignore

.scrutinizer.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
build:
2+
nodes:
3+
analysis:
4+
tests:
5+
override: [php-scrutinizer-run]
16
filter:
27
excluded_paths: [ 'vendor/*', 'tests/*', 'samples/*', 'src/PhpWord/Shared/PCLZip/*' ]
38

@@ -14,7 +19,7 @@ tools:
1419
config:
1520
ruleset: phpmd.xml.dist
1621
external_code_coverage:
17-
enabled: true
22+
enabled: false
1823
timeout: 1200
1924
php_cpd: true
2025
# php_sim: # Temporarily disabled to allow focus on things other than duplicates

.travis.yml

Lines changed: 7 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,11 @@ php:
1313

1414
matrix:
1515
include:
16-
- php: 5.6
16+
- php: 7.0
1717
env: COVERAGE=1
18-
allow_failures:
19-
- php: 7.2
2018

2119
cache:
2220
directories:
23-
- vendor
2421
- $HOME/.composer/cache
2522
- .php-cs.cache
2623

@@ -38,9 +35,9 @@ before_script:
3835
- if [ -z "$COVERAGE" ]; then phpenv config-rm xdebug.ini ; fi
3936
## Composer
4037
- composer self-update
41-
- composer install --prefer-source
38+
- travis_wait composer install --prefer-source
4239
## PHPDocumentor
43-
- mkdir -p build/docs
40+
##- mkdir -p build/docs
4441
- mkdir -p build/coverage
4542

4643
script:
@@ -55,10 +52,8 @@ script:
5552
## PHPLOC
5653
- if [ -z "$COVERAGE" ]; then ./vendor/bin/phploc src/ ; fi
5754
## PHPDocumentor
58-
- if [ -z "$COVERAGE" ]; then ./vendor/bin/phpdoc -q -d ./src -t ./build/docs --ignore "*/src/PhpWord/Shared/*/*" --template="responsive-twig" ; fi
55+
##- if [ -z "$COVERAGE" ]; then ./vendor/bin/phpdoc -q -d ./src -t ./build/docs --ignore "*/src/PhpWord/Shared/*/*" --template="responsive-twig" ; fi
5956

60-
after_script:
61-
## PHPDocumentor
62-
- bash .travis_shell_after_success.sh
63-
## Scrutinizer
64-
- if [ -n "$COVERAGE" ]; then wget https://scrutinizer-ci.com/ocular.phar && php ocular.phar code-coverage:upload --format=php-clover build/logs/clover.xml ; fi
57+
after_success:
58+
## Coveralls
59+
- if [ -n "$COVERAGE" ]; then travis_retry php vendor/bin/php-coveralls -v ; fi

.travis_shell_after_success.sh

Lines changed: 0 additions & 39 deletions
This file was deleted.

CHANGELOG.md

Lines changed: 47 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,16 +3,59 @@ Change Log
33
All notable changes to this project will be documented in this file.
44
This project adheres to [Semantic Versioning](http://semver.org/).
55

6-
v0.15.0 (?? ??? 2018)
6+
v0.16.0 (xx xxx 2018)
77
----------------------
88
### Added
9-
- Parsing of "align" HTML attribute - @troosan #1231
9+
10+
### Fixed
11+
- Fix regex in `cloneBlock` function @nicoder #1269
12+
- HTML Title Writer loses text when Title contains a TextRun instead a string. @begnini #1436
13+
14+
v0.15.0 (14 Jul 2018)
15+
----------------------
16+
### Added
17+
- Parsing of `align` HTML attribute - @troosan #1231
1018
- Parse formatting inside HTML lists - @troosan @samimussbach #1239 #945 #1215 #508
19+
- Parsing of CSS `direction` instruction, HTML `lang` attribute, formatting inside table cell - @troosan #1273 #1252 #1254
20+
- Add support for Track changes @Cip @troosan #354 #1262
21+
- Add support for fixed Table Layout @aoloe @ekopach @troosan #841 #1276
22+
- Add support for Cell Spacing @dox07 @troosan #1040
23+
- Add parsing of formatting inside lists @atomicalnet @troosan #594
24+
- Added support for Vertically Raised or Lowered Text (w:position) @anrikun @troosan #640
25+
- Add support for MACROBUTTON field @phryneas @troosan #1021
26+
- Add support for Hyphenation @Trainmaster #1282 (Document: `autoHyphenation`, `consecutiveHyphenLimit`, `hyphenationZone`, `doNotHyphenateCaps`, Paragraph: `suppressAutoHyphens`)
27+
- Added support for Floating Table Positioning (tblpPr) @anrikun #639
28+
- Added support for Image text wrapping distance @troosan #1310
29+
- Added parsing of CSS line-height and text-indent in HTML reader @troosan #1316
30+
- Added the ability to enable gridlines and axislabels on charts @FrankMeyer #576
31+
- Add support for table indent (tblInd) @Trainmaster #1343
32+
- Added parsing of internal links in HTML reader @lalop #1336
33+
- Several improvements to charts @JAEK-S #1332
34+
- Add parsing of html image in base64 format @jgpATs2w #1382
35+
- Added Support for Indentation & Tabs on RTF Writer. @smaug1985 #1405
36+
- Allows decimal numbers in HTML line-height style @jgpATs2w #1413
1137

1238
### Fixed
13-
- fix reading of docx default style - @troosan #1238
39+
- Fix reading of docx default style - @troosan #1238
40+
- Fix the size unit of when parsing html images - @troosan #1254
41+
- Fixed HTML parsing of nested lists - @troosan #1265
42+
- Save PNG alpha information when using remote images. @samsullivan #779
43+
- Fix parsing of `<w:br/>` tag. @troosan #1274
44+
- Bookmark are not writton as internal link in html writer @troosan #1263
45+
- It should be possible to add a Footnote in a ListItemRun @troosan #1287 #1287
46+
- Fix colspan and rowspan for tables in HTML Writer @mattbolt #1292
47+
- Fix parsing of Heading and Title formating @troosan @gthomas2 #465
48+
- Fix Dateformat typo, fix hours casing, add Month-Day-Year formats @ComputerTinker #591
49+
- Support reading of w:drawing for documents produced by word 2011+ @gthomas2 #464 #1324
50+
- Fix missing column width in ODText writer @potofcoffee #413
51+
- Disable entity loader before parsing XML to avoid XXE injection @Tom4t0 #1427
1452

53+
### Changed
54+
- Remove zend-stdlib dependency @Trainmaster #1284
55+
- The default unit for `\PhpOffice\PhpWord\Style\Image` changed from `px` to `pt`.
1556

57+
### Miscelaneous
58+
- Drop GitHub pages, switch to coveralls for code coverage analysis @czosel #1360
1659

1760
v0.14.0 (29 Dec 2017)
1861
----------------------
@@ -461,4 +504,4 @@ This is the first release after a long development hiatus in [CodePlex](https://
461504
- Basic CI with Travis - @Progi1984
462505
- Added PHPWord_Exception and exception when could not copy the template - @Progi1984
463506
- IMPROVED: Moved examples out of Classes directory - @Progi1984
464-
- IMPROVED: Advanced string replace in setValue for Template - @Esmeraldo [#49](http://phpword.codeplex.com/workitem/49)
507+
- IMPROVED: Advanced string replace in setValue for Template - @Esmeraldo [#49](http://phpword.codeplex.com/workitem/49)

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
[![Latest Stable Version](https://poser.pugx.org/phpoffice/phpword/v/stable.png)](https://packagist.org/packages/phpoffice/phpword)
44
[![Build Status](https://travis-ci.org/PHPOffice/PHPWord.svg?branch=master)](https://travis-ci.org/PHPOffice/PHPWord)
55
[![Code Quality](https://scrutinizer-ci.com/g/PHPOffice/PHPWord/badges/quality-score.png?s=b5997ce59ac2816b4514f3a38de9900f6d492c1d)](https://scrutinizer-ci.com/g/PHPOffice/PHPWord/)
6-
[![Code Coverage](https://scrutinizer-ci.com/g/PHPOffice/PHPWord/badges/coverage.png?s=742a98745725c562955440edc8d2c39d7ff5ae25)](https://scrutinizer-ci.com/g/PHPOffice/PHPWord/)
6+
[![Coverage Status](https://coveralls.io/repos/github/PHPOffice/PHPWord/badge.svg?branch=develop)](https://coveralls.io/github/PHPOffice/PHPWord?branch=develop)
77
[![Total Downloads](https://poser.pugx.org/phpoffice/phpword/downloads.png)](https://packagist.org/packages/phpoffice/phpword)
88
[![License](https://poser.pugx.org/phpoffice/phpword/license.png)](https://packagist.org/packages/phpoffice/phpword)
99
[![Join the chat at https://gitter.im/PHPOffice/PHPWord](https://img.shields.io/badge/GITTER-join%20chat-green.svg)](https://gitter.im/PHPOffice/PHPWord)

bootstrap.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* contributors, visit https://github.com/PHPOffice/PHPWord/contributors. test bootstrap
1212
*
1313
* @see https://github.com/PHPOffice/PHPWord
14-
* @copyright 2010-2017 PHPWord contributors
14+
* @copyright 2010-2018 PHPWord contributors
1515
* @license http://www.gnu.org/licenses/lgpl.txt LGPL version 3
1616
*/
1717

composer.json

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -36,19 +36,19 @@
3636
],
3737
"scripts": {
3838
"test": [
39-
"./vendor/bin/phpunit --color=always"
39+
"phpunit --color=always"
4040
],
4141
"test-no-coverage": [
42-
"./vendor/bin/phpunit --color=always --no-coverage"
42+
"phpunit --color=always --no-coverage"
4343
],
4444
"check": [
45-
"./vendor/bin/php-cs-fixer fix --ansi --dry-run --diff",
46-
"./vendor/bin/phpcs --report-width=200 --report-summary --report-full samples/ src/ tests/ --ignore=src/PhpWord/Shared/PCLZip --standard=PSR2 -n",
47-
"./vendor/bin/phpmd src/,tests/ text ./phpmd.xml.dist --exclude pclzip.lib.php",
45+
"php-cs-fixer fix --ansi --dry-run --diff",
46+
"phpcs --report-width=200 --report-summary --report-full samples/ src/ tests/ --ignore=src/PhpWord/Shared/PCLZip --standard=PSR2 -n",
47+
"phpmd src/,tests/ text ./phpmd.xml.dist --exclude pclzip.lib.php",
4848
"@test"
4949
],
5050
"fix": [
51-
"./vendor/bin/php-cs-fixer fix --ansi"
51+
"php-cs-fixer fix --ansi"
5252
]
5353
},
5454
"scripts-descriptions": {
@@ -61,19 +61,20 @@
6161
"php": "^5.3.3 || ^7.0",
6262
"ext-xml": "*",
6363
"zendframework/zend-escaper": "^2.2",
64-
"zendframework/zend-stdlib": "^2.2 || ^3.0",
65-
"phpoffice/common": "^0.2"
64+
"phpoffice/common": "^0.2.9"
6665
},
6766
"require-dev": {
68-
"phpunit/phpunit": "^4.8.36 || ^5.0",
69-
"phpdocumentor/phpdocumentor":"2.*",
70-
"squizlabs/php_codesniffer": "^2.7",
71-
"friendsofphp/php-cs-fixer": "^2.0",
67+
"ext-zip": "*",
68+
"ext-gd": "*",
69+
"phpunit/phpunit": "^4.8.36 || ^7.0",
70+
"squizlabs/php_codesniffer": "^2.9",
71+
"friendsofphp/php-cs-fixer": "^2.2",
7272
"phpmd/phpmd": "2.*",
7373
"phploc/phploc": "2.* || 3.* || 4.*",
7474
"dompdf/dompdf":"0.8.*",
7575
"tecnickcom/tcpdf": "6.*",
76-
"mpdf/mpdf": "5.* || 6.* || 7.*"
76+
"mpdf/mpdf": "5.7.4 || 6.* || 7.*",
77+
"php-coveralls/php-coveralls": "1.1.0 || ^2.0"
7778
},
7879
"suggest": {
7980
"ext-zip": "Allows writing OOXML and ODF",
@@ -89,7 +90,7 @@
8990
},
9091
"extra": {
9192
"branch-alias": {
92-
"dev-master": "0.15-dev"
93+
"dev-develop": "0.16-dev"
9394
}
9495
}
9596
}

docs/ISSUE_TEMPLATE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ This is:
44
- [ ] a feature request
55
- [ ] **not** a usage question (ask them on https://stackoverflow.com/questions/tagged/phpword)
66

7-
# Expected Behavior
7+
### Expected Behavior
88

99
Please describe the behavior you are expecting.
1010

docs/PULL_REQUEST_TEMPLATE.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@ Fixes # (issue)
66

77
### Checklist:
88

9-
- [ ] I have run `composer check` and no errors were reported
10-
- [ ] The new code is covered by unit tests
9+
- [ ] I have run `composer run-script check --timeout=0` and no errors were reported
10+
- [ ] The new code is covered by unit tests (check build/coverage for coverage report)
1111
- [ ] I have update the documentation to describe the changes

0 commit comments

Comments
 (0)