Implement a number of features implemented in PhpWord,
but not yet supported in PhpWord ODT Writer.
1. Add default file to tests/PhpWord/_includes/XmlDocument.php to make it
considerably easier to test ODT changes (and Word2007 changes involving
files other that document.xml).
2. Page break before each section.
3. Page numbering start.
4. Font style for Headings.
5. Alignment for images.
6. Paragraph style for TextRun.
7. "Hide grammatical errors" for whole document.
8. Page layout for each section.
9. For each page layout, support user-specified page width, page height,
orientation, margin top, margin bottom, margin left, margin right.
10. Page header and footer.
11. Named colors.
12. NoProof font style.
13. Paragraph Style - spaceBefore, spaceAfter, lineHeight, pageBreakBefore,
indentation, text alignment.
14. Tab stops.
15. Basic support for some Fields (DATE, PAGE, NUMPAGES).
16. Link had an error in how it was handling internal links (needs leading #).
17. In addition to tests for all the above, added some tests for Tables.
Item 11 above needs 1 module from Pull Request 1775, which is targeted
for v0.18.0 but not yet merged, so the relevant module is also here.
Item 15 above needs 1 module from Pull Request 1774, which is targeted
for v0.18.0 but not yet merged, so the relevant module is also here.
Testing change from Pull Request 1771 is included here, but was
merged after my fork.
\Symfony\Component\Process\Process refuses being passed a string
with version > 5, which is installed with PHP > 7.2.5.
It also refuses being passed an array with version < 3.3, which is
installed with PHP < 5.5.9.
Solved by checking if Process::fromShellCommandLine() exists, which
was introduced in version 4.2.0.
\Symfony\Component\Process\Process refuses being passed a string
with version > 5, which is installed with PHP > 7.2.5.
It also refuses being passed an array with version < 3.3, which is
installed with PHP < 5.5.9.
Solved by checking if Process::fromShellCommandLine() exists, which
was introduced in version 4.2.0.
1. Codes meant to be in hex are specified in decimal.
Consequently characters which don't need escaping are escaped.
2. Special handling (prepend backslash) needed for {, }, and .
RTF docs generated with those characters cannot be opened in Word.
3. Tab character needs to be escaped as \tab.
RTF docs drop these characters.
While running test suite, found that Writer/RTF/ElementTest was coded
only for Unix line endings, and fails on Windows. Changed so that it
would work on either.
1. Codes meant to be in hex are specified in decimal.
Consequently characters which don't need escaping are escaped.
2. Special handling (prepend backslash) needed for {, }, and \.
RTF docs generated with those characters cannot be opened in Word.
3. Tab character needs to be escaped as \tab.
RTF docs drop these characters.
While running test suite, found that Writer/RTF/ElementTest was coded
only for Unix line endings, and fails on Windows. Changed so that it
would work on either.