Dominik Stadler
57d746827f
Bug 66425: Avoid a ClassCastException found via oss-fuzz
...
We try to avoid throwing ClassCastException but it was possible
to trigger one here with a specially crafted input-file
Should fix https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=61162
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1911459 13f79535-47bb-0310-9956-ffa450edef68
2023-08-05 12:13:13 +00:00
PJ Fanning
dd1b0b1128
[bug-66827] add test case (that passes) - so issue is nor reproduced
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1911399 13f79535-47bb-0310-9956-ffa450edef68
2023-08-01 20:49:26 +00:00
PJ Fanning
1f446e0aef
undo last change due to broken test
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1911233 13f79535-47bb-0310-9956-ffa450edef68
2023-07-24 12:00:17 +00:00
PJ Fanning
cd2dcd3940
[github-487] Round up seconds in CellElapsedFormatter. Thanks to Anthony Schott. This closes #487
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1911228 13f79535-47bb-0310-9956-ffa450edef68
2023-07-24 10:12:46 +00:00
PJ Fanning
fa8650fbe3
[bug-66682] fix xslb reading support for formula cells of boolean type. This closes #485
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1910951 13f79535-47bb-0310-9956-ffa450edef68
2023-07-12 22:26:41 +00:00
PJ Fanning
e1bb2a73c8
[bug-66675] fix issue with writing xlsx (core properties being added twice)
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1910949 13f79535-47bb-0310-9956-ffa450edef68
2023-07-12 12:25:01 +00:00
PJ Fanning
04442923f3
[bug-62181] try to handle file where shared string loading is happening twice
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1910759 13f79535-47bb-0310-9956-ffa450edef68
2023-07-03 20:54:56 +00:00
PJ Fanning
b5153f1395
[bug-66612] get macrosheet xml (test)
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1909994 13f79535-47bb-0310-9956-ffa450edef68
2023-05-22 16:00:10 +00:00
PJ Fanning
02efb8f802
revert: [bug-66503] Add flag for Excel 4 macros in composite documents.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1908462 13f79535-47bb-0310-9956-ffa450edef68
2023-03-18 00:59:29 +00:00
PJ Fanning
c12ed0dd1b
[bug-66503] Add flag for Excel 4 macros in composite documents. Thanks to M. P. Halpin
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1908461 13f79535-47bb-0310-9956-ffa450edef68
2023-03-18 00:30:58 +00:00
Dominik Stadler
acdf2ec981
Bug 62272: Include alpha/transparency value when setting a color-value for a font
...
Use method with returns 4 bytes to use an ARGB value instead of only RGB
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1907105 13f79535-47bb-0310-9956-ffa450edef68
2023-01-30 12:19:24 +00:00
PJ Fanning
60872927bd
[bug-66433] Boolean functions should blank cells. Thanks to Patrick Böker
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1906836 13f79535-47bb-0310-9956-ffa450edef68
2023-01-20 12:03:52 +00:00
PJ Fanning
968dabd462
[bug-65543] HSSF: fix issue with incomplete SSTs. Thanks to Simon Carter.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1906434 13f79535-47bb-0310-9956-ffa450edef68
2023-01-06 23:50:54 +00:00
PJ Fanning
693c59574c
[bug-66319] do not create HSSF patriarch to find comments (only use one that pre-exists)
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1905943 13f79535-47bb-0310-9956-ffa450edef68
2022-12-12 21:09:09 +00:00
PJ Fanning
5a6df66b07
untidy hack for shared string counts that are higher than Integer.MAX_VALUE
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1905940 13f79535-47bb-0310-9956-ffa450edef68
2022-12-12 18:43:44 +00:00
PJ Fanning
efc032babc
[bug-66365] rework XSSFCell getRichStringCellValue and getStringCellValue to better support array formula results. Thanks to Espen Amble Kolstad.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1905571 13f79535-47bb-0310-9956-ffa450edef68
2022-11-28 13:05:45 +00:00
PJ Fanning
30a0a4362a
test for TIKA-3163
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1903775 13f79535-47bb-0310-9956-ffa450edef68
2022-08-30 11:10:46 +00:00
PJ Fanning
3184a18b40
[bug-66216] fix issue where pivotTable.getPivotCacheDefinition() returns null
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1903442 13f79535-47bb-0310-9956-ffa450edef68
2022-08-15 19:20:13 +00:00
PJ Fanning
ed67d48d96
[bug-66215] add test case (that shows we have issues and need fixes)
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1903440 13f79535-47bb-0310-9956-ffa450edef68
2022-08-15 18:40:25 +00:00
PJ Fanning
7301e841c7
[bug-66211] add test case
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1903393 13f79535-47bb-0310-9956-ffa450edef68
2022-08-13 15:09:18 +00:00
PJ Fanning
266619f363
revert: github ci perms
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1903174 13f79535-47bb-0310-9956-ffa450edef68
2022-08-01 17:27:45 +00:00
Andreas Beeker
c41176f207
#66115 - Some Password protected XLS files are not read
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1901996 13f79535-47bb-0310-9956-ffa450edef68
2022-06-16 22:56:47 +00:00
PJ Fanning
3f414c760c
[bug-66087] make DStar functions case insensitive
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1901229 13f79535-47bb-0310-9956-ffa450edef68
2022-05-25 10:31:07 +00:00
Dominik Stadler
f8e27ee19b
Prevent an overly large allocation when using HPSF
...
Add a sample document from fuzzing which contains invalid/oversized values
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1899749 13f79535-47bb-0310-9956-ffa450edef68
2022-04-11 13:51:31 +00:00
PJ Fanning
a8f1e7acd1
[github-321] Fix issue with rounding in DataFormatter. Thanks to Colin Wang. This closes #321
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1899680 13f79535-47bb-0310-9956-ffa450edef68
2022-04-09 12:02:55 +00:00
PJ Fanning
05e8a16543
[github-321] add test case
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1899667 13f79535-47bb-0310-9956-ffa450edef68
2022-04-08 13:08:10 +00:00
PJ Fanning
56b4313997
[bug-64536] add getDimension on XSSFSheet
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1899091 13f79535-47bb-0310-9956-ffa450edef68
2022-03-20 21:41:31 +00:00
PJ Fanning
935c8ab06a
add xssf test (width/height)
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1898944 13f79535-47bb-0310-9956-ffa450edef68
2022-03-15 09:40:48 +00:00
Dominik Stadler
7283d7ed64
Make all text-extractors always return a non-null String
...
This changes the expected exception of some test-files
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1897319 13f79535-47bb-0310-9956-ffa450edef68
2022-01-22 06:58:43 +00:00
Dominik Stadler
729d78cda6
Limit allocated elements in the PlfLfo structure for word documents
...
Use large allocation-detection here as well,
otherwise some documents can try to allocate too much memory.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1896744 13f79535-47bb-0310-9956-ffa450edef68
2022-01-06 11:10:00 +00:00
Dominik Stadler
1d630a94fc
Bug 52447: Allow HyperLinkRecord to appear as part of the RowRecordsAggregate
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1896552 13f79535-47bb-0310-9956-ffa450edef68
2021-12-30 23:03:16 +00:00
PJ Fanning
837590024f
[bug-65741] rework previous change
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1895881 13f79535-47bb-0310-9956-ffa450edef68
2021-12-13 13:12:32 +00:00
PJ Fanning
a24820e629
add data-formatter test
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1895706 13f79535-47bb-0310-9956-ffa450edef68
2021-12-08 19:27:09 +00:00
PJ Fanning
50bab16ece
add xlookup test
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1895613 13f79535-47bb-0310-9956-ffa450edef68
2021-12-06 10:10:16 +00:00
PJ Fanning
7475b1f609
[bug-65706] ignore trash parts in OOXML files
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1895370 13f79535-47bb-0310-9956-ffa450edef68
2021-11-27 10:15:39 +00:00
Dominik Stadler
7a5bc4227b
Do not fail on different count of categories and points and fix cloning charts
...
We see many cases where documents have charts with a difference here, so
downgrade the exception to a warning for now
Also handle cloning charts in workbooks where the parts have unexpected names
by making sure that the chosen part-name is not yet taken.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894676 13f79535-47bb-0310-9956-ffa450edef68
2021-11-02 13:17:53 +00:00
Dominik Stadler
0727874584
Avoid NullPointerException when cloning sheets where there is no drawing patriarch
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894450 13f79535-47bb-0310-9956-ffa450edef68
2021-10-21 14:17:31 +00:00
PJ Fanning
69eb168051
scaling issue
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894367 13f79535-47bb-0310-9956-ffa450edef68
2021-10-18 23:01:34 +00:00
PJ Fanning
005810640d
[bug-65638] Remove escaping of ampersand from headers and footers created by Excel. Thanks to Viru.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894357 13f79535-47bb-0310-9956-ffa450edef68
2021-10-18 17:15:04 +00:00
PJ Fanning
b906b72d29
[bug-59388] Set comment with option isVisible in .xlsx. Thanks to ryoii. This closes #239
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894347 13f79535-47bb-0310-9956-ffa450edef68
2021-10-18 10:48:04 +00:00
PJ Fanning
2514e4d0ab
[bug-65452] fix issue where WorkbookFactory.create(File, ...) returns null if file type not recognised
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894097 13f79535-47bb-0310-9956-ffa450edef68
2021-10-10 09:58:02 +00:00
PJ Fanning
7d47c205e9
[bug-65306] issue with shift rows that remove rows and how shared formulas are affected
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894089 13f79535-47bb-0310-9956-ffa450edef68
2021-10-10 06:39:56 +00:00
PJ Fanning
08a1f9af22
[bug-65268] issue reading shared formulas
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1894064 13f79535-47bb-0310-9956-ffa450edef68
2021-10-09 12:26:21 +00:00
PJ Fanning
bd1ea63abe
[github-254] Implement XSSFWorkbook linkExternalWorkbook. Thanks to @aspojo. This closes #254
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1893728 13f79535-47bb-0310-9956-ffa450edef68
2021-09-29 16:16:32 +00:00
PJ Fanning
abe22ef8f7
[bug-65595] Strip colour formatting in headers and footers
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1893599 13f79535-47bb-0310-9956-ffa450edef68
2021-09-24 15:05:10 +00:00
PJ Fanning
f591073698
add test for broken file (5.0.1-RC1 issues)
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1893442 13f79535-47bb-0310-9956-ffa450edef68
2021-09-19 12:45:26 +00:00
PJ Fanning
7bcf6d5a6d
add support for reading hyperlinks that have cell refs that are area references (very limited update or write support as yet)
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1892141 13f79535-47bb-0310-9956-ffa450edef68
2021-08-09 21:57:40 +00:00
PJ Fanning
cd7b6b7197
[bug-65467] support IFNA() function. Thanks to Ross Patterson
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1891876 13f79535-47bb-0310-9956-ffa450edef68
2021-07-29 16:57:03 +00:00
PJ Fanning
3aa03459a7
[bug-65464] fix issue where shared formulas can be corrupted
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1891849 13f79535-47bb-0310-9956-ffa450edef68
2021-07-28 09:36:37 +00:00
PJ Fanning
a6b9f5c006
update stress.xls
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1891729 13f79535-47bb-0310-9956-ffa450edef68
2021-07-22 17:23:00 +00:00
PJ Fanning
0678b16f14
right to left xlsx test
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1891682 13f79535-47bb-0310-9956-ffa450edef68
2021-07-20 12:43:52 +00:00
Dominik Stadler
f71833e1d9
Do not return null for POITextExtractor.getMetadataTextExtractor() for old Excel files
...
To adhere to the JavaDoc of the POITextExtractor interface which does not document a
possible null return.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1889205 13f79535-47bb-0310-9956-ffa450edef68
2021-04-26 15:12:32 +00:00
PJ Fanning
50cfe3c10e
[github-235] Fix date formatting for number cell values. Thanks to Anthony Schott. This close #235
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1889179 13f79535-47bb-0310-9956-ffa450edef68
2021-04-25 17:16:05 +00:00
PJ Fanning
e7a2df7dda
[github-234] Ensure the hours position is correct. Thanks to Anthony Schott. This closes #234
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1888804 13f79535-47bb-0310-9956-ffa450edef68
2021-04-15 22:13:09 +00:00
Dominik Stadler
4027d8ac67
Allow negative numbers in conditional part of format string
...
Closes #229
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1887802 13f79535-47bb-0310-9956-ffa450edef68
2021-03-19 09:40:10 +00:00
Nick Burch
82b5113ba9
Implement CONCAT function #65185
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1887656 13f79535-47bb-0310-9956-ffa450edef68
2021-03-14 22:53:27 +00:00
Marius Volkhart
d1c9a07860
Add the ability to edit HSLFPictureData contents
...
Pictures can now be edited by calling HSLFPictureData#setData(byte[]). The byte[] should contain the image data as an image viewer might read it.
To enable this functionality, a tighter coupling between the EscherBSERecords of the slideshow and the HSLFPictureData was required. This ensures that changes in image data size are accurately recorded in the records.
In the course of coupling the records and the HSLFPictureData, various scenarios arose where a mapping of records to pictures was non-trivial. Accordingly, the HSLFSlideShowImpl#matchPicturesAndRecords(...) function was added to perform a more sophisticated matching pass. This function is heavily exercised by org.apache.poi.hslf.usermodel.TestBugs.testFile[5] and PPTX2PNG.render[2], as well as the new TestPictures#testSlideshowWithIncorrectOffsets().
Closes #225
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1887017 13f79535-47bb-0310-9956-ffa450edef68
2021-02-28 23:16:14 +00:00
PJ Fanning
4013ffa220
[bug-65096] XLSX Streaming XML not correctly reading multiple inline Strings
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885770 13f79535-47bb-0310-9956-ffa450edef68
2021-01-21 21:04:24 +00:00
Alain Béarez
825bebdbd1
Bug 65016 - Creating a chart throws exception
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885700 13f79535-47bb-0310-9956-ffa450edef68
2021-01-19 21:33:38 +00:00
Andreas Beeker
8f2c722fd3
Integration tests - try to fix Oracle/OpenJDK vs IBM-JDK error message differences on XXE files
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885625 13f79535-47bb-0310-9956-ffa450edef68
2021-01-17 21:20:05 +00:00
Andreas Beeker
8d0e84f257
integration tests: ignore hsmf/lots-of-recipients.msg because of concurrent test errors - also takes too long to process
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885603 13f79535-47bb-0310-9956-ffa450edef68
2021-01-17 15:51:41 +00:00
Andreas Beeker
44efecf42e
integration tests: Fix handling of NullPointerExceptions for Java 16+ (again ...)
...
Refactor TestAllFiles to provide an API for mass testing
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885576 13f79535-47bb-0310-9956-ffa450edef68
2021-01-16 15:51:00 +00:00
Andreas Beeker
5e110d7216
integration tests: NullPointerExceptions contain now a description in Java 16+
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885549 13f79535-47bb-0310-9956-ffa450edef68
2021-01-16 09:55:42 +00:00
Andreas Beeker
309e657b0d
#65046 - Simplify integration tests
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885538 13f79535-47bb-0310-9956-ffa450edef68
2021-01-15 23:50:42 +00:00
Andreas Beeker
fb2a96a048
Sonar fixes
...
Fixed offset of compare picture in resize_compare.xlsx
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885280 13f79535-47bb-0310-9956-ffa450edef68
2021-01-08 22:56:05 +00:00
Dominik Stadler
622574f5f4
Bug 64450: Allow to parse a file where the relationship-id is an empty string
...
Also improve exception reporting by including more information and not
"hiding" the actual exception-cause in a log-statement.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885056 13f79535-47bb-0310-9956-ffa450edef68
2021-01-03 11:49:51 +00:00
Dominik Stadler
685af351d1
Bug 64750: Do not use CTDataValidations.getCount(), instead only rely on getDataValidationArray
...
Field "count" seems to be optional according
to the schema, so by using only the array
Apache POI can read data validations from
workbooks that do not populate the
"count" field properly.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1885011 13f79535-47bb-0310-9956-ffa450edef68
2021-01-01 15:51:19 +00:00
Dominik Stadler
b231366fb6
Bug 64986: Support missing or blank match_type for function Match
...
Excel and LibreOffice use the default value in this case
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1884959 13f79535-47bb-0310-9956-ffa450edef68
2020-12-30 21:40:12 +00:00
Dominik Stadler
42c4e7d89a
Add unfixed test for bug 64759 and make the ones fail which depend on manual opening of files in Microsoft Excel for verification
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1884957 13f79535-47bb-0310-9956-ffa450edef68
2020-12-30 21:40:01 +00:00
Dominik Stadler
a7c1d84c5d
Improve the speed of the styles-optimiser when there are many styles in a Workbook
...
Profiling showed that the call to isUserDefined() took most of the time,
so we now fetch this only once for each style and remember the result and
use it in the inner loop.
The attached sample-file took aprox. 1m30s on a decent machine, now it is down
to around 2s.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1884917 13f79535-47bb-0310-9956-ffa450edef68
2020-12-29 19:29:22 +00:00
Dominik Stadler
352f5a034c
Fix bug 64238: Make LOOKUP functions deal with empty last arg correctly
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1882827 13f79535-47bb-0310-9956-ffa450edef68
2020-10-25 07:21:45 +00:00
Tim Allison
ab2dc71a95
Bug 64667.xlsx prevent NPE loading styles table
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1880834 13f79535-47bb-0310-9956-ffa450edef68
2020-08-13 18:21:28 +00:00
PJ Fanning
a8d90aba91
[github-187] Add length validation for Excel DataValidations that are list literals. Thanks to Leo Webb. This closes #187
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1880727 13f79535-47bb-0310-9956-ffa450edef68
2020-08-09 21:15:15 +00:00
PJ Fanning
26c2049147
[bug-64508] add guard for invalid v value
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1879905 13f79535-47bb-0310-9956-ffa450edef68
2020-07-15 20:56:59 +00:00
PJ Fanning
be09639638
[github-185] Fix if function in array formulas with 2nd argument evaluating to error. Thanks to Miłosz Rembisz. This closes #185
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1879481 13f79535-47bb-0310-9956-ffa450edef68
2020-07-03 16:09:03 +00:00
PJ Fanning
f99533c56e
move docx added to wrong test dir
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1879229 13f79535-47bb-0310-9956-ffa450edef68
2020-06-26 10:41:15 +00:00
PJ Fanning
06cf5caa2d
[bug-64561] XWPFSDTContent.getText() is empty for nested SDT elements
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1879223 13f79535-47bb-0310-9956-ffa450edef68
2020-06-26 10:15:53 +00:00
Andreas Beeker
d559feb7de
64512 - Ole10Native aka embedded / object packager - handle UTF16 variants
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1878730 13f79535-47bb-0310-9956-ffa450edef68
2020-06-11 00:43:45 +00:00
PJ Fanning
b7930fc65c
[github-181] make Value function work with arrays. Thanks to Miłosz Rembisz. This closes #181
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1878541 13f79535-47bb-0310-9956-ffa450edef68
2020-06-06 09:30:30 +00:00
Dominik Stadler
d2ad752e1c
Fix bug 64420: NPE in XSSFReader for files with macro-sheets
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1877814 13f79535-47bb-0310-9956-ffa450edef68
2020-05-16 13:05:53 +00:00
PJ Fanning
af8137a6e4
[github-180] Add DateValue function. Thanks to Milosz Rembisz. This closes #180
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1877793 13f79535-47bb-0310-9956-ffa450edef68
2020-05-15 20:15:00 +00:00
Andreas Beeker
778f4f5d7d
#55505 - CountryRecord not found
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1876805 13f79535-47bb-0310-9956-ffa450edef68
2020-04-21 22:13:59 +00:00
Tim Allison
5976721660
64261 -- fix handling of drop down list when items are selected
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1875956 13f79535-47bb-0310-9956-ffa450edef68
2020-03-31 18:16:09 +00:00
Dominik Stadler
a7d96dcb73
Bug 58896 and 52834: Cache Sheet.getMergedRegions() as it seems to sometimes be the culprit for autosize taking a very long time.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1874973 13f79535-47bb-0310-9956-ffa450edef68
2020-03-08 11:17:34 +00:00
Tim Allison
636cc83665
Bug 64130 -- handle empty worksheet names in OldSheetRecord more robustly.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1873863 13f79535-47bb-0310-9956-ffa450edef68
2020-02-10 17:38:29 +00:00
Dominik Stadler
4aa8334e3b
Fix some additional file-handle-leaks reported by unit-tests via an enhanced version of the file-leak-detector
...
Also add a test for Bug 64045
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1872287 13f79535-47bb-0310-9956-ffa450edef68
2020-01-03 13:11:41 +00:00
Dominik Stadler
9f35db4f51
Bug 63940: Avoid endless loop/out of memory on string-replace with empty search string
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1872145 13f79535-47bb-0310-9956-ffa450edef68
2019-12-31 16:52:55 +00:00
Dominik Stadler
821e164041
Bug 63700: Make D* functions work with numeric result column
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1872136 13f79535-47bb-0310-9956-ffa450edef68
2019-12-31 10:41:43 +00:00
Dominik Stadler
bc0dcdf369
Fix bug 63984: AND / OR should treat missing parameters as FALSE
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1872125 13f79535-47bb-0310-9956-ffa450edef68
2019-12-30 19:57:11 +00:00
PJ Fanning
4c034f0e20
[github-164] Fix Bug in XSSFTable.setCellReferences when table is single cell. Thanks to Travis Russell. This closes #164
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1871185 13f79535-47bb-0310-9956-ffa450edef68
2019-12-11 20:07:25 +00:00
PJ Fanning
06f28db213
Bug 63768: Adjust handling of SchemaFactory
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1867484 13f79535-47bb-0310-9956-ffa450edef68
2019-09-24 18:33:37 +00:00
Andreas Beeker
27399cec83
#54803 - Error opening XLSX after saving with a Drawing using POI
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1857671 13f79535-47bb-0310-9956-ffa450edef68
2019-04-17 06:19:51 +00:00
Tim Allison
a5278ccad9
bug 63327 allow retrieval of wmf data embedded in emf
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1857136 13f79535-47bb-0310-9956-ffa450edef68
2019-04-08 19:53:21 +00:00
Greg Woolsey
30851e44a6
#63302 Formula evaluation of names with offset or row function is incorrect
...
thanks to John Lincoln White for the patch, including new unit tests.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1856644 13f79535-47bb-0310-9956-ffa450edef68
2019-03-30 18:14:14 +00:00
Greg Woolsey
edd1f4c75e
pre-release maintenance:
...
* add my key to the KEYS file
* update year in NOTICE (first release of 2019)
* remove svn:executable flag from random test data files
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1855799 13f79535-47bb-0310-9956-ffa450edef68
2019-03-19 00:35:09 +00:00
Greg Woolsey
82f9c29258
#60724 - Partial implementation for SUBTOTAL() 'ignore hidden rows' variations
...
The function still doesn't deal with auto-filtering, but it now handles variations that should skip hidden rows.
Taught the evaluation framework to know about hidden rows similar to what was already there for skipping subtotals within subtotal ranges.
Added unit test cases.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1855789 13f79535-47bb-0310-9956-ffa450edef68
2019-03-18 19:09:11 +00:00
Yegor Kozlov
6ef332b48e
Bug 61472: Convert date/time strings to numbers when evaluating formulas
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1855662 13f79535-47bb-0310-9956-ffa450edef68
2019-03-16 15:41:46 +00:00
Yegor Kozlov
c438465b08
Bug 62980: Make D* functions ignore case in headings
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1853268 13f79535-47bb-0310-9956-ffa450edef68
2019-02-09 13:00:09 +00:00
Dominik Stadler
c376d662f9
Bug 60405: Add initial support for cetab functions so some macros can be
...
parsed
Add some function-definitions for Excel 4 Macros and missing functions
found in regression tests
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1852277 13f79535-47bb-0310-9956-ffa450edef68
2019-01-27 09:57:39 +00:00
Yegor Kozlov
698d8eb006
follow-up to Bug 62904. More tests and improved evaluation of IF in array mode
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1851263 13f79535-47bb-0310-9956-ffa450edef68
2019-01-14 14:48:21 +00:00
Dominik Stadler
88b9e48287
Add reproducer for bug 60355
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1851208 13f79535-47bb-0310-9956-ffa450edef68
2019-01-13 17:13:57 +00:00
Yegor Kozlov
0cdc0ee985
Bug 63054: updated formulas in test spreadsheet to keep build happy
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1850772 13f79535-47bb-0310-9956-ffa450edef68
2019-01-08 16:36:34 +00:00
Yegor Kozlov
b85437ee88
Bug 63054: improved evaluation of array formulas with error in arguments
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1850742 13f79535-47bb-0310-9956-ffa450edef68
2019-01-08 12:54:39 +00:00
Yegor Kozlov
81033fbad0
Bug 62904: Support array arguments in IF and logical IS*** functions
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1850646 13f79535-47bb-0310-9956-ffa450edef68
2019-01-07 14:34:19 +00:00
Dominik Stadler
85d6f81076
Bug 60460: Handle null workbook or sheet names and emit #REF as Excel does
...
instead of throwing NullPointerException
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1850008 13f79535-47bb-0310-9956-ffa450edef68
2018-12-30 22:44:40 +00:00
Dominik Stadler
3c99c70acf
Add test which verifies that bug 61605 is already fixed
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1849878 13f79535-47bb-0310-9956-ffa450edef68
2018-12-28 19:52:46 +00:00
Dominik Stadler
d3dc9b0338
Bug 62629: Allow to handle files with invalid content types for pictures
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1849814 13f79535-47bb-0310-9956-ffa450edef68
2018-12-27 20:51:48 +00:00
Yegor Kozlov
9aabade3f0
Bug 62836: Implementation of Excel TREND function
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1845586 13f79535-47bb-0310-9956-ffa450edef68
2018-11-02 13:34:28 +00:00
Tim Allison
5ecbaf5563
bug 62625 -- add special handling for REFERENCE_NAME record that may only
...
contain an ascii string, against the spec in VBAMacroReader
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1845238 13f79535-47bb-0310-9956-ffa450edef68
2018-10-30 13:25:20 +00:00
Tim Allison
b5653e8829
bug 62624 -- fix npe by adding processing of module name mapping in VBAMacroReader
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1845138 13f79535-47bb-0310-9956-ffa450edef68
2018-10-29 15:48:44 +00:00
Greg Woolsey
6b433ae8b3
#62834 FormulaEvaluator.evaluateInCell() throws Exception
...
added cell type = formula check when looping through the shared formula range, to ignore any non-formula cells.
Also refactored a bit to enable passing in the evaluation context, as getCellFormula() uses it behind the scenes when evaluating a shared formula cell (has to shift the formula references based on the master cell). Review of these changes is welcome, as always.
Checked all other code referencing the "SHARED" enum, and didn't see anything else that dealt with formula cell values and thus would need to notice non-formula cells.
Added unit test based on the failing file from Bugzilla. Test failed until the fixed code was in place.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1844295 13f79535-47bb-0310-9956-ffa450edef68
2018-10-19 01:11:47 +00:00
Tim Allison
870c1b2cf5
62815 -- some numeric values not correctly extracted from xlsb
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1843553 13f79535-47bb-0310-9956-ffa450edef68
2018-10-11 14:14:07 +00:00
Alain Béarez
5199f75fe3
extract valuable code from 54470 submitted patch
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1842548 13f79535-47bb-0310-9956-ffa450edef68
2018-10-01 19:27:32 +00:00
PJ Fanning
4ad4d76241
[bug-62055] Fix XSSFImportFromXML table resize. Thanks to Leonard Kappe. This closes #99
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1825315 13f79535-47bb-0310-9956-ffa450edef68
2018-02-25 17:06:19 +00:00
PJ Fanning
e80f53af6e
[github-94] Add Range Copier. Thanks to Dragan Jovanović. This closes #94
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1824266 13f79535-47bb-0310-9956-ffa450edef68
2018-02-14 20:30:01 +00:00
Dominik Stadler
6c89a6a460
Add test which verifies that bug 61652 is not appearing any more on latest trunk
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1819769 13f79535-47bb-0310-9956-ffa450edef68
2018-01-01 14:39:08 +00:00
Yegor Kozlov
3d4acce3a7
Bug 58106: when a cell with a 'master' shared formula is removed, the next cell in the range becomes the master
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1819623 13f79535-47bb-0310-9956-ffa450edef68
2017-12-30 16:34:57 +00:00
Yegor Kozlov
176b557f0d
Bugzilla 61116: Formula evaluation fails when using matrix addition within index function call
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1819596 13f79535-47bb-0310-9956-ffa450edef68
2017-12-30 13:11:56 +00:00
Greg Woolsey
94bec76385
Implement DMAX and DSUM functions, following the pattern from DMIN.
...
Refactored the D* function enum to have instances return the function implementation instances rather than using a case construct, now that Java 8 is required.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1819376 13f79535-47bb-0310-9956-ffa450edef68
2017-12-27 22:33:03 +00:00
Yegor Kozlov
a96d86bfe8
Bug 61869: updating a cell with shared formula produces an unreadable file
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1818818 13f79535-47bb-0310-9956-ffa450edef68
2017-12-20 16:30:13 +00:00
Yegor Kozlov
0ad8c53743
Bug 61859: support for evaluating comparison operators in array mode, detect array mode from formula ptgs
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1818587 13f79535-47bb-0310-9956-ffa450edef68
2017-12-18 15:54:50 +00:00
Greg Woolsey
50ffe0de32
Bug 61882 - Some paths can create an XSSFColor instance with a null CTColor reference
...
test file
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1817797 13f79535-47bb-0310-9956-ffa450edef68
2017-12-11 17:33:00 +00:00
Greg Woolsey
8f26e2721d
Bug #61841 - Unnecessary long computation when evaluating VLOOKUP on all column reference
...
Found some optimizations in the general evaluation framework related to blank cells in rows beyond the last defined row of a sheet.
I don't see any issue with passing a bit of context down deeper into this framework, as it's all POI-internal and only had one calling path.
See the above bug for the performance analysis. Not specifically related to VLOOKUP, but improves that case by more than 2/3 as well.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1817252 13f79535-47bb-0310-9956-ffa450edef68
2017-12-06 00:15:51 +00:00
Greg Woolsey
8572d4b71c
Fixes Bug 61764 Conditional formatting rules don't evaluate properly for some multi-range rule definitions
...
Fixes Bug 61761 Conditional formatting rule evaluation doesn't like comparing cells of different types
fixed, with unit tests.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1815298 13f79535-47bb-0310-9956-ffa450edef68
2017-11-15 08:35:17 +00:00
Dominik Stadler
d4ad2ffd53
Add test-case which shows that bug 55814 is fixed already by other changes
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1814290 13f79535-47bb-0310-9956-ffa450edef68
2017-11-04 13:45:12 +00:00
PJ Fanning
06ea018e03
add test case for bug 61701
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1813864 13f79535-47bb-0310-9956-ffa450edef68
2017-10-31 09:51:51 +00:00
Dominik Stadler
88b3286345
Add test which shows that bug 51262 is fixed now
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1811595 13f79535-47bb-0310-9956-ffa450edef68
2017-10-09 19:35:32 +00:00
PJ Fanning
23ecb9a172
Numeric Array Formula and Matrix Function [from Bob95132] This closes #69
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1808297 13f79535-47bb-0310-9956-ffa450edef68
2017-09-13 23:54:36 +00:00
Greg Woolsey
d68912db25
Fixes bug #61468 , caused by a confusing OOXML spec design as noted in JavaDocs added in r1795648.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1806623 13f79535-47bb-0310-9956-ffa450edef68
2017-08-29 17:14:52 +00:00
Dominik Stadler
8f8f41a7c2
Fix 60384 and 60709: When shifting with merged regions we should correctly check if the region is moved along or needs to be removed because it is not fully kept via the shifting. This was broken by the fix for bug 59740, now additional unit tests ensure that it works better.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1805518 13f79535-47bb-0310-9956-ffa450edef68
2017-08-19 16:31:45 +00:00
Greg Woolsey
c73a4570f8
Bug 61431 - Conditional formatting evaluation ignores undefined cells
...
now evaluating based on cell references instead, and watching out for undefined cells in rules that require a cell.
Added unit test based on previously failing file.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1805245 13f79535-47bb-0310-9956-ffa450edef68
2017-08-16 23:52:27 +00:00
Greg Woolsey
3cea90e7c4
Fix data validation value list evaluation
...
One of my users found that my initial implementation was lacking a core distinction - most evaluations expect a single result, and "unwrap" 2/3D ValueEval results to a single value based on the input row/column.
However, data validation list formulas explicitly are expected to return a 2D ValueEval. This worked when the formula was simple and evaluated to a single Ptg, but only returned one value when the formula was more complex, or referenced a named range defined as a complex formula.
This change teaches WorkbookEvaluator about the distinction, by way of a new attribute for FormulaType.
There is room for discussion over how it is implemented, but this works for me.
Includes the failing workbook we had as a new unit test.
While I was in FormulaType I went ahead and removed the deprecated, unused, and redundant code marked for removal in 3.17.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1803121 13f79535-47bb-0310-9956-ffa450edef68
2017-07-26 22:19:58 +00:00
Tim Allison
d320b2ea4a
bug 61300 -- prevent really long (infinite?) loop on corrupt file
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1801989 13f79535-47bb-0310-9956-ffa450edef68
2017-07-14 20:47:40 +00:00
Tim Allison
5a9d05487d
bug 61286/bug 61287 -- allow WriteProtectRecord to have 2 bytes, and allow for HeaderFooter to be empty.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1801966 13f79535-47bb-0310-9956-ffa450edef68
2017-07-14 13:54:06 +00:00
Tim Allison
34cb860998
bug 61294 -- prevent infinite loop in IOUtils' skipFully.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1801844 13f79535-47bb-0310-9956-ffa450edef68
2017-07-13 16:20:28 +00:00
PJ Fanning
6de159d232
[Bug-61281] guard against index out of bounds in XSSFExportToXml column mapping
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1801634 13f79535-47bb-0310-9956-ffa450edef68
2017-07-11 16:38:49 +00:00
Greg Woolsey
3e6d942b95
Add file that failed regression tests as a unit test.
...
Adjust table style processing to allow for AlternateContent wrappers for table element style definitions.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799733 13f79535-47bb-0310-9956-ffa450edef68
2017-06-24 05:55:45 +00:00
Tim Allison
153821e443
bug 61045 -- allow for (and log!) extra bytes in FormatRecord.
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1799360 13f79535-47bb-0310-9956-ffa450edef68
2017-06-20 18:11:34 +00:00
Dominik Stadler
eb417057c4
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
334a7b87b4
Add missing file for test for bug 56557
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1798926 13f79535-47bb-0310-9956-ffa450edef68
2017-06-16 13:26:50 +00:00
Nick Burch
9907b69401
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
Greg Woolsey
c844803b66
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
05a6cf3263
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
Andreas Beeker
965860b116
removed invalid test file
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1795122 13f79535-47bb-0310-9956-ffa450edef68
2017-05-14 22:24:07 +00:00
Greg Woolsey
674d6ac2c9
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
Greg Woolsey
530dd0e083
61060 - teach DataFormatter about conditional formatting rules with number formats
...
Currently only implemented for XSSF, as there is no API available for HSSF conditional formatting rule number formats (if it is even in the files).
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1794084 13f79535-47bb-0310-9956-ffa450edef68
2017-05-05 17:44:58 +00:00
Javen O'Neal
acd2fa8de1
bug 61034: Call to XSSFReader.getSheetsData() returns duplicate sheets.
...
Thanks to Mauricio Eastmond for the Excel test file and unit test.
Thanks to Sebastian Wikalinski for isolating the problem and providing a patch.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1793223 13f79535-47bb-0310-9956-ffa450edef68
2017-04-29 17:27:17 +00:00
Greg Woolsey
f60ca16829
Issue #60971 , handle formula chart titles
...
implemented per issue, breaking out static text vs. formula based title getters and setters, with unit test updates and additions.
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1791025 13f79535-47bb-0310-9956-ffa450edef68
2017-04-11 20:27:23 +00:00
Andreas Beeker
1f113bc64a
Fix AIOOBE while extracting hssf pictures which are externally linked
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1790897 13f79535-47bb-0310-9956-ffa450edef68
2017-04-10 21:43:22 +00:00
Dominik Stadler
84e0fc5e42
Test for another type of xml-bomb
...
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1790473 13f79535-47bb-0310-9956-ffa450edef68
2017-04-06 21:50:03 +00:00