110 Commits

Author SHA1 Message Date
Libor M
ea917c28da fix coverage 2021-01-10 14:06:19 +01:00
Libor M
a2c8d8c2d5 \PhpOffice\Common\XMLWriter -> \PhpOffice\PhpWord\Shared\XMLWriter 2021-01-02 08:26:46 +01:00
Owen Leibman
ba3d616282 Improve Test Coverage
Coverage for Writer/ODText is now 100%.
2020-04-23 17:25:56 -07:00
Owen Leibman
677e042c3a Scrutinizer Workaroun
Attempt to work around demonstrably incorrect Scrutinizer analysis
  (flags code as bug because "condition is always false"
   even though Coveralls reports that code which would be
   executed only if condition is true is indeed executed).
2020-02-06 20:41:40 -08:00
Owen Leibman
d5149b2867 Coveralls Changes
Changes to improve test coverage based on Coveralls report.
2020-02-06 19:20:13 -08:00
Owen Leibman
46c41c5ac1 More Scrutinizer Changes
Still one report that I don't understand at all, and one I'm not sure of.
2020-01-05 15:05:00 -08:00
Owen Leibman
cfa29cc1c2 Applying Scrutinizer Suggestions
I do not understand one suggestion, and I believe one is wrong.
I will add comments to my ticket once this is pushed.

One that I can discuss up front
PhpWord/Style/Paragraph indicates that Indentation must be of type
   \PhpOffice\PhpWord\Style\Indentation, but it can also be null.
   My test for instanceof ... is one of the Scrutinizer reports.
   I did not change PhpWord/Style/Paragraph, but this commit does so
   by updating @var for indentation.
2020-01-05 13:52:20 -08:00
Owen Leibman
e24b2e1ba7 ODT Changes
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.
2020-01-05 10:27:45 -08:00
troosan
f91863ed64 Add RTL aligning of tables 2019-01-03 11:33:56 +01:00
troosan
ccf291234e Avoid warning if variable is null 2018-12-28 20:32:10 +01:00
Alex Morozov
c2b54cc343 add support for hidden text (#1527)
* added hidden text word 2007
* update changelog
* update documentation
* added unit test
* docx reader
* html reader/writer
* odt writer
* updated samples
2018-12-08 23:21:59 +01:00
troosan
da43a880e3 Address scrutinizer issues 2018-06-03 00:32:21 +02:00
troosan
d9ddc162a3 write column width in ODT writer 2018-06-03 00:32:20 +02:00
troosan
bb70eb0b4c fix docx parsing 2018-03-18 12:37:39 +01:00
troosan
77f2b16bc1 update copyright to 2018 2018-03-08 23:52:25 +01:00
Frank Liepert
6a6497956d Allow to set "autoHyphenation" setting (#1282)
* Allow to set "autoHyphenation" for document
* Allow to set "consecutiveHyphenLimit" for document
* Allow to set "hyphenationZone" for document
* Allow to set "doNotHyphenateCaps" for document
* Allow to set "suppressAutoHyphens" for paragraph
* randomize the tempDir more
* Word2007 parsing title formatting (#1297)
* Improve Title parsing
- Title should be able to contain TextRun
- Style 'Title' should be treated the same with as Heading
- Add tests for Heading/Title reader
* update the documentation and the changelog
* PHP 7.2 build should not fail anymore
* fix parsing of footnotes and endnotes
* add method to remove an element from a section
* add method to allow sorting of sections
2018-03-06 22:19:39 +01:00
troosan
604e60cae9
Add support for Track changes (#1262)
* add changed information to HTML writer
* add missing writeFontStyle
* refactor track changes
* set the style
* update documentation and release note
* Update the changelog and doc
* fix scrutinizer issues
2018-02-09 21:49:11 +01:00
troosan
23bc837666 Scrutinizer fixes 2017-11-26 17:54:47 +01:00
troosan
355027d854 PHP-CS fix, improve code coverage 2017-11-26 00:11:09 +01:00
Michael Spahn
5d928db916 Implement PageBreak for odt writer 2017-11-25 23:44:45 +01:00
troosan
b22208f810 format 2017-11-16 23:09:56 +01:00
troosan
bc4750dd7c
Merge pull request #1060 from Mord1n/patch-1
ODT Writer automatic-styles should be closed before opening master-styles.
2017-11-16 23:08:13 +01:00
troosan
1b9c1d921b format 2017-11-07 23:13:41 +01:00
troosan
75bf84fa48
Merge pull request #887 from taophp/patch-1
Fix division by zero
2017-11-07 22:34:49 +01:00
troosan
0459670a9c
Enable php-cs-fixer in build & fix resulting warnings (#1099)
* enable php 7.1 build
* upgrade to dompdf/dompdf 0.8.*
* update phpunit & hide output during tests
* run code coverage analysis on 1 build only
* Add php-cs
* Update Copyright
2017-11-04 22:44:12 +01:00
troosan
0beeb275fe Add support for changing the document language (#1108) 2017-09-27 00:40:08 +02:00
Mord1n
a55405e655 Update Styles.php
automatic-styles should be closed before opening master-styles.

This will prevent issue that styles wont work in future if you implement styling for ODT writer....
2017-05-18 16:25:05 +02:00
Stéphane Mourey
1a1b362f40 Update Paragraph.php 2016-12-13 21:51:44 +01:00
Stéphane Mourey
23e19a2d47 Fix division by zero
See #886
2016-09-12 16:43:21 +02:00
Roman Syroeshko
2bcfacfbf9 Updated copyright. 2016-07-31 12:35:08 +04:00
Roman Syroeshko
508d6194fc Fixed build. 2016-06-13 20:31:33 +04:00
Roman Syroeshko
ebbb3a525e #483. Output escaping for ODF. 2016-06-13 20:14:54 +04:00
Roman Syroeshko
f359825cb7 Reviewed and merged #658. 2016-01-23 19:16:34 +04:00
Roman Syroeshko
43fb23d896 Copyright update. 2015-12-05 21:26:01 +04:00
Roman Syroeshko
cc305bcb11 Fixed broken paragraph alignment for OpenXml. 2015-02-21 17:43:46 +04:00
Roman Syroeshko
8056b6926c [CHANGED] Docblock for pass-by-reference parameters. 2014-07-03 16:11:15 +04:00
Roman Syroeshko
d0a609bc95 [CHANGED] Added "@return" annotation where it as missed. 2014-07-03 15:40:24 +04:00
Ivan Lanin
384107e7cf Ability to define document protection and new Metadata subnamespace 2014-06-16 11:58:05 +07:00
Ivan Lanin
8c2b099dbc Merge Shared\Drawing and Shared\Font into Shared\Converter 2014-06-14 10:54:33 +07:00
Ivan Lanin
63d53ac910 Use section "style" instead of "settings" for consistency 2014-06-08 16:44:46 +07:00
Ivan Lanin
893843969f Refactor elements to move set relation Id from container to element 2014-06-08 03:00:53 +07:00
Ivan Lanin
9839222492 QA: Additional unit tests 2014-05-31 22:28:13 +07:00
Ivan Lanin
991016a48b Additional writer test 2014-05-24 10:05:39 +07:00
Ivan Lanin
3569271277 Word2007 Writer: Enable the missing custom document properties writer 2014-05-21 19:20:13 +07:00
Ivan Lanin
ac23e90ef4 ODT Reader: Ability to read standard and custom document properties 2014-05-20 18:00:00 +07:00
Ivan Lanin
930d8de462 ODT Writer: Enable title element and custom document properties 2014-05-20 14:53:02 +07:00
Ivan Lanin
553371f088 Type hinting and docblock update 2014-05-19 14:27:55 +07:00
Ivan Lanin
7d9bcd46d4 ODT: New Image and Table style writer 2014-05-18 21:15:35 +07:00
Ivan Lanin
970c6a24eb Bug fixes for last commit 2014-05-18 16:48:15 +07:00
Ivan Lanin
410ce4bffe ODT: Enable section and column 2014-05-18 16:29:56 +07:00