Commit Graph

7078 Commits

Author SHA1 Message Date
Javen O'Neal
4d692223bb whitespace
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799303 13f79535-47bb-0310-9956-ffa450edef68
2017-06-20 05:51:48 +00:00
Javen O'Neal
5de40d3261 bug 52063: support 2-argument LOOKUP(lookup_value, array) function in Excel
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799302 13f79535-47bb-0310-9956-ffa450edef68
2017-06-20 05:47:56 +00:00
Dominik Stadler
2095c92402 Improve error message if we encounter invalid/unexpected files in integration tests
Adjust some tests slightly

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799178 13f79535-47bb-0310-9956-ffa450edef68
2017-06-19 11:05:20 +00:00
Dominik Stadler
66bf6c5ad7 Need to do the casting differently to make the code compile with Java 6
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799038 13f79535-47bb-0310-9956-ffa450edef68
2017-06-18 05:59:31 +00:00
Dominik Stadler
128ba623f8 Don't try to clone a chart, this makes integration-tests work for a few more documents, also the one added via bug 56557
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799037 13f79535-47bb-0310-9956-ffa450edef68
2017-06-18 05:59:25 +00:00
Dominik Stadler
bac17be565 Fix some IntelliJ warnings
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799035 13f79535-47bb-0310-9956-ffa450edef68
2017-06-18 05:59:11 +00:00
Andreas Beeker
0e57435abe #61169 - Text with Japanese characters overflows textbox
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798986 13f79535-47bb-0310-9956-ffa450edef68
2017-06-17 00:00:49 +00:00
Dominik Stadler
20f46393f7 Fix some IntelliJ warnings
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798913 13f79535-47bb-0310-9956-ffa450edef68
2017-06-16 11:35:31 +00:00
Javen O'Neal
c05e2ae644 bug 61170: add comment why we should catch exceptions in SAXHelper
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798793 13f79535-47bb-0310-9956-ffa450edef68
2017-06-15 05:08:24 +00:00
Javen O'Neal
f66153c810 bug 61170: add extra logging to SaxHelper.
Thanks to PJ Fanning for the patch!
This closes #58 on github.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798792 13f79535-47bb-0310-9956-ffa450edef68
2017-06-15 05:00:25 +00:00
Andreas Beeker
14b2d4501a #61162 - En-/decryption support for HWPF
- encryption support for HWPF
- refactor/unify EncryptionInfo handling in H**F classes
- remove Iterable interface from WorkbookRecordList - use getRecords() instead, to prevent modifications over the Iterator

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798722 13f79535-47bb-0310-9956-ffa450edef68
2017-06-14 17:21:50 +00:00
Greg Woolsey
e5c5cba87c Standardize some more common chart axis properties.
Implement the ChartAxis ss interface for date axes, which are pretty much a category axis with one extra property, a date granularity (not currently passed through, get it still from the CT* class).  Created the class and test from the category axis versions.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798414 13f79535-47bb-0310-9956-ffa450edef68
2017-06-12 05:38:41 +00:00
Greg Woolsey
8d7bab82bb Don't report data table master cells as formula cells, since POI doesn't evaluate data table formulas.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798289 13f79535-47bb-0310-9956-ffa450edef68
2017-06-10 01:04:40 +00:00
Dominik Stadler
05570364db Move one testcase with incorrect source location
remove some junit dependencies in example-code
build: do not pass junit-jar to normal compile targets to avoid introducing it as dependency again 
Reformat code, fix warnings, ...

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798202 13f79535-47bb-0310-9956-ffa450edef68
2017-06-09 12:49:01 +00:00
Dominik Stadler
938bb91c51 Bug 60374: Add test for ArrayIndexOutOfBounds on old Word Documents due to Non-Unicode
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798200 13f79535-47bb-0310-9956-ffa450edef68
2017-06-09 12:47:03 +00:00
Nick Burch
993801aa1c Update the CreateTable example to reduce the use of the raw CT classes
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797923 13f79535-47bb-0310-9956-ffa450edef68
2017-06-07 13:35:20 +00:00
Nick Burch
7b38f8c5f1 Permit table style modifications, needed for CreateTable
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797922 13f79535-47bb-0310-9956-ffa450edef68
2017-06-07 13:33:58 +00:00
Nick Burch
fd0e150a94 Make it possible to create simple XSSF sheet tables without needing CT classes directly
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797919 13f79535-47bb-0310-9956-ffa450edef68
2017-06-07 13:06:38 +00:00
Nick Burch
2ce00a5a78 XSSFTable should format numeric/date cells when used as Column Header names as Excel does, see https://stackoverflow.com/questions/44407111/apache-poi-cant-format-filled-cells-as-numeric
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797914 13f79535-47bb-0310-9956-ffa450edef68
2017-06-07 12:39:41 +00:00
Andreas Beeker
a5dda416e7 Ignore JCE restriction errors
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797856 13f79535-47bb-0310-9956-ffa450edef68
2017-06-07 06:25:56 +00:00
Andreas Beeker
20dcde37ec Handle encrypted files with known password in integration tests
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797839 13f79535-47bb-0310-9956-ffa450edef68
2017-06-06 22:21:46 +00:00
Andreas Beeker
739599059a Replace HWPFOutputStream with ByteArrayOutputStream - it doesn't add any new features
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797838 13f79535-47bb-0310-9956-ffa450edef68
2017-06-06 22:21:40 +00:00
Andreas Beeker
2b4f944883 #61162 - En-/decryption support for HWPF
Decryption for Binary RC4 and CryptoAPI (... XOR is missing)

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797837 13f79535-47bb-0310-9956-ffa450edef68
2017-06-06 22:21:11 +00:00
Javen O'Neal
b0d0f2d255 bug 58325: enable TestXSSFShape unit tests. Thanks to Dominik Stadler for the initial unit test. Thanks to PJ Fanning for discovering that the bug was fixed at some point in the past and enabling the unit tests.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797600 13f79535-47bb-0310-9956-ffa450edef68
2017-06-04 18:59:18 +00:00
Andreas Beeker
efccafd898 fix eclipse resource leak warnings
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1797043 13f79535-47bb-0310-9956-ffa450edef68
2017-05-31 14:10:18 +00:00
Javen O'Neal
4232a72208 javadocs
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1796966 13f79535-47bb-0310-9956-ffa450edef68
2017-05-31 02:46:24 +00:00
Andreas Beeker
95164e4a50 SonarQube fixes - close resources
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1796962 13f79535-47bb-0310-9956-ffa450edef68
2017-05-31 00:31:53 +00:00
Greg Woolsey
7e6007e0bd #61085 support table styles
Needed a bit more, to support table/range only border properties for "internal" vertical and horizontal borders.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1796961 13f79535-47bb-0310-9956-ffa450edef68
2017-05-31 00:22:58 +00:00
Andreas Beeker
49e47cb6e1 Bug 61119 - Fix preset shape rendering and shading
- Fixed conversion of ooxml to awt angle
- replace subclasses and reflection calls with enums
- implemented tinting/shading of preset shapes


git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1796823 13f79535-47bb-0310-9956-ffa450edef68
2017-05-30 09:33:28 +00:00
Javen O'Neal
b3c6907741 bug 61059: fix NamePtg to read unsigned shorts instead of signed shorts, avoiding a AIOOBE when a workbook contains more than 32k Names. Thanks to Travis Burtrum for the patch.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1796466 13f79535-47bb-0310-9956-ffa450edef68
2017-05-28 01:17:16 +00:00
Greg Woolsey
479b45ced9 Bug 60898 - XSSFColor's getARGB() method returns a wrong color value when a workbook has a custom indexed color
Missed this test.  As part of the work I noticed the Enum was missing some values defined in the OOXML spec, so I added them.

I've updated the test to reflect that those values are no longer invalid.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1796360 13f79535-47bb-0310-9956-ffa450edef68
2017-05-26 23:37:04 +00:00
Greg Woolsey
586cf38f1c Bug 60898 - XSSFColor's getARGB() method returns a wrong color value when a workbook has a custom indexed color
teach XSSFColor and most things that create instances about indexed colors.

Null is a valid value for IndexedColorMap instances - the existing built-in default colors are used.

Whenever a workbook style is accessible in the call hierarchy its color mappings are passed down now.

Thanks for the unit test in the issue, it now passes.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1796359 13f79535-47bb-0310-9956-ffa450edef68
2017-05-26 23:14:48 +00:00
Dominik Stadler
d868026959 Bug 61063: Add a RefListEval to handle UnionPtg and implement it for Rank(), may be missing for other functions where ArrayEval is currently handled
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795963 13f79535-47bb-0310-9956-ffa450edef68
2017-05-23 21:13:02 +00:00
Dominik Stadler
8564aa7bb6 Reformat code somewhat
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795962 13f79535-47bb-0310-9956-ffa450edef68
2017-05-23 21:12:50 +00:00
Javen O'Neal
7881d05743 github-55: document that CellReference#isRowWithinRange(String rowNum, SpreadsheetVersion ss) expects rowNum to be parseable as an integer
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795681 13f79535-47bb-0310-9956-ffa450edef68
2017-05-20 21:04:14 +00:00
Javen O'Neal
4ff23197e9 bug 61110: remove deprecated, misspelled CellReference#isRowWithnRange and #isColumnWithnRange methods
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795680 13f79535-47bb-0310-9956-ffa450edef68
2017-05-20 20:22:24 +00:00
Greg Woolsey
2d2aa5196a #61085 support table styles
Added more features - this allows a client app to fully display table styling without resorting to CT* classes, and has some helper logic for the additional processing needed for things like regional/area borders.

As far as I can tell I only added stuff, didn't change any existing behavior.

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795648 13f79535-47bb-0310-9956-ffa450edef68
2017-05-20 04:05:32 +00:00
Javen O'Neal
284f7d19c5 github-55: NumberFormatException if XSSFName.setNameName is set with a long name that looks similar to a cell address. Thanks to Thomas S @Millie4Ever
This closes #55 on github.
https://github.com/apache/poi/pull/55

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795595 13f79535-47bb-0310-9956-ffa450edef68
2017-05-19 08:26:41 +00:00
Javen O'Neal
0b767886bf replace "String.indexOf(String) >= 1" with "String.contains(String)"
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795296 13f79535-47bb-0310-9956-ffa450edef68
2017-05-16 10:53:15 +00:00
Javen O'Neal
f701e81a64 github-25: add enable locking and tab color in SXSSFSheet. Thanks to Danilo Rangel. This closes #25.
https://github.com/apache/poi/pull/25

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795277 13f79535-47bb-0310-9956-ffa450edef68
2017-05-16 08:38:58 +00:00
Javen O'Neal
b6f78f8d57 github-32: speed up Irr() Excel formula computation by replacing Math.pow() with multiplication. Thanks to Daniel Kuan! This closes #32.
https://github.com/apache/poi/pull/32

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795266 13f79535-47bb-0310-9956-ffa450edef68
2017-05-16 03:18:17 +00:00
Javen O'Neal
be5106a1d7 github-43: add disabled unit test showing a problem with ROUNDUP(3987*0.2, 2). Thanks to @FishMeat.
https://github.com/apache/poi/pull/43

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795265 13f79535-47bb-0310-9956-ffa450edef68
2017-05-16 03:04:12 +00:00
Nick Burch
fec503f1de Javadoc fixes
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795261 13f79535-47bb-0310-9956-ffa450edef68
2017-05-16 02:50:35 +00:00
Javen O'Neal
b527f96daa github-52: add ExcelToHtmlConverter method that works on InputStreams. Thanks to Tony Zeng! This closes #52.
https://github.com/apache/poi/pull/52

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795256 13f79535-47bb-0310-9956-ffa450edef68
2017-05-16 00:58:01 +00:00
Javen O'Neal
fac98b5bef github-53: fix NPE when iterating over paragraphs in certain *.docx files. Thanks to Praful Kumar Vaishnav! This closes #53.
https://github.com/apache/poi/pull/53

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795254 13f79535-47bb-0310-9956-ffa450edef68
2017-05-16 00:41:25 +00:00
Javen O'Neal
5c62492ffb github-54: when adding a picture to an XSSFWorkbook, reduce memory consumption by 100x and increase speed by 10x based on OpenJDK JMH benchmarking. Thanks to Tim Helmstedt! This closes #54.
https://github.com/apache/poi/pull/54

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795252 13f79535-47bb-0310-9956-ffa450edef68
2017-05-15 23:27:21 +00:00
Andreas Beeker
8c1346b138 Add ASL header and exclude table preset from rat-check
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795137 13f79535-47bb-0310-9956-ffa450edef68
2017-05-15 06:30:06 +00:00
Andreas Beeker
90dca20bd2 #52117 - Invalid "last printed" summary field value - added helper method to identify undefined dates
HPSF: fixed uid listing in Section.toString()
HPSF: moved timestamp based "utility" methods to Filetime class
HPSF: preserve original datastream for unchanged property sets

git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795123 13f79535-47bb-0310-9956-ffa450edef68
2017-05-14 22:25:33 +00:00
Greg Woolsey
bf83a00457 tweak to use platform line separator so tests can pass on Windows as well as Linux.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795026 13f79535-47bb-0310-9956-ffa450edef68
2017-05-12 22:13:30 +00:00
Greg Woolsey
0cdc064b0c git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795002 13f79535-47bb-0310-9956-ffa450edef68 2017-05-12 18:01:32 +00:00