Commit Graph

332 Commits

Author SHA1 Message Date
Thomas Fussell
dd215794db
Merge branch 'master' into issue_503_external_link 2021-01-02 14:54:31 -05:00
胡剑波
0ecad78c1d Fixed an exception thrown when parsing external links. 2020-08-25 09:00:22 +08:00
Adam Hooper
319c4197c1
Streaming: skip empty rows in has_cell()/read_cell()
Previously, an empty row would mess with the parser: if we're in an
empty row, our helper methods don't detect us as being in the "row" _or_
in the "sheetData". So `has_cell()` would return false when it
shouldn't. Similarly, `read_cell()` wouldn't skip rows; so `read_cell()`
would return an invalid cell when placed in an empty row, causing a
segfault when the caller tried to use the cell.

Callers must take care to call `has_next()` before `read_next()`. In
the future, perhaps we can make `read_next()` return a `std::optional`
and nix `has_next()` altogether?

[Closes #492]
2020-07-28 15:29:12 -04:00
Thomas Fussell
2f5934f60e
Merge pull request #447 from Crzyrndm/feature/benchmark
microbenchmarks for double<->string conversion, serialisation improvements
2020-03-20 18:02:37 -04:00
amiremohamadi
33a56b3a04 add more tests for absolute and relative column, row forms 2020-03-20 23:06:58 +03:30
JCrawfy
ee593c2673 bug fixes, move the faster serialisation into the numeric header
serialisation ends up roughly 2x improvement going from sstream to snprintf

Run on (4 X 3500 MHz CPU s)
CPU Caches:
  L1 Data 32K (x4)
  L1 Instruction 32K (x4)
  L2 Unified 262K (x4)
  L3 Unified 6291K (x1)
-------------------------------------------------------------------------------------------------------------
Benchmark                                                                   Time             CPU   Iterations
-------------------------------------------------------------------------------------------------------------
RandFloatStrs/double_from_string_sstream                                  968 ns          977 ns       640000
RandFloatStrs/double_from_string_strtod                                   272 ns          270 ns      2488889
RandFloatStrs/double_from_string_strtod_fixed                             272 ns          270 ns      2488889
RandFloatStrs/double_from_string_strtod_fixed_const_ref                   273 ns          270 ns      2488889
RandFloatStrs/double_from_string_std_from_chars                           193 ns          195 ns      3446154
RandFloatCommaStrs/double_from_string_strtod_fixed_comma_ref              272 ns          273 ns      2635294
RandFloatCommaStrs/double_from_string_strtod_fixed_comma_const_ref        276 ns          273 ns      2635294
RandFloats/string_from_double_sstream                                    1311 ns         1318 ns       497778
RandFloats/string_from_double_sstream_cached                             1076 ns         1050 ns       640000
RandFloats/string_from_double_snprintf                                    601 ns          600 ns      1120000
RandFloats/string_from_double_snprintf_fixed                              600 ns          600 ns      1120000
RandFloats/string_from_double_std_to_chars                                117 ns          117 ns      5600000
RandFloatsComma/string_from_double_snprintf_fixed_comma                   600 ns          600 ns      1120000
2020-03-01 22:01:14 +13:00
Adam Hooper
ac18fc6dde Parse inlineStr values
inlineStr XML structure is <c><is><t>. This was being parsed incorrectly
when streaming (because has_value wasn't being set to true) and when
reading the whole file (because the <t> was ignored).

[closes #445]
2020-02-25 14:32:14 -05:00
Thomas Fussell
e8ee585897
bump copyright year to 2020 2020-02-08 12:12:59 -05:00
Thomas Fussell
39503e8bf0 fix warnings and other minor issues 2019-12-26 12:52:14 -05:00
Thomas Fussell
a560756b35 use clang-format, fix some small warnings 2019-12-26 12:03:12 -05:00
JCrawfy
f2ad495326 resolve warnings, remove failing test (CI doesn't know what locale "de-DE" is?) 2019-11-18 21:45:46 +13:00
JCrawfy
97841413fa fixed more parsing errors, added test for ',' locale serialisation (it fails...) 2019-11-18 21:12:21 +13:00
JCrawfy
2eb88c23d6 move numeric utils into the public headers
resolves #398
2019-11-18 19:25:02 +13:00
Thomas Fussell
5791ca80bf
Merge pull request #396 from apthorpe/master
Added CTest support
2019-07-23 08:17:23 -04:00
Bob Apthorpe
bd84c7f576 Added CTest support 2019-07-17 12:09:07 -05:00
Thomas Fussell
90b672cf6b Merge branch 'Issue#318_fp-equality' of https://github.com/Crzyrndm/xlnt into Crzyrndm-Issue#318_fp-equality 2019-07-06 14:20:53 -04:00
Thomas Fussell
40baecdf02 Merge branch 'images' of https://github.com/kostasdizas/xlnt into kostasdizas-images 2019-07-06 14:02:24 -04:00
Thomas Fussell
123ecc95fe
Merge branch 'dev' into issue378-unicode_title 2019-06-22 10:54:20 -04:00
Thomas Fussell
1c22e9781e
Merge pull request #364 from kostasdizas/phonetics
Added support for phonetic fields
2019-06-22 10:53:09 -04:00
Thomas Fussell
b6455ff6d1
Merge pull request #356 from kostasdizas/issue353
Fixed block calculation in xlsx_producer
2019-06-22 10:52:14 -04:00
Thomas Fussell
f54a150589
Merge branch 'dev' into phonetics 2019-06-22 10:51:30 -04:00
Thomas Fussell
e11188ccd1
Merge branch 'dev' into issue378-unicode_title 2019-06-22 10:48:35 -04:00
Thomas Fussell
b1a2f6d0bf
Merge pull request #382 from kostasdizas/issue374-format
Update the format elements when setting the cell style
2019-06-22 10:43:41 -04:00
Thomas Fussell
595397994f
Merge pull request #359 from kostasdizas/issue254
Corrected the calculation and formatting of weekdays
2019-06-21 17:52:14 -04:00
Thomas Fussell
7e22fad735
Merge pull request #329 from Crzyrndm/Issue#327
Relative hyperlinks
2019-06-11 20:40:36 -04:00
Kostas Dizas
38afc61219
Update the format elements when setting the cell style. 2019-03-07 00:26:32 +00:00
Kostas Dizas
d4b36b6582
Added support for unicode sheet titles
Fixes #378
2019-02-28 20:29:17 +00:00
Kostas Dizas
36d6b9823d
Adjust merged cells when moving cells 2018-12-02 03:18:37 +00:00
Kostas Dizas
0897cc9fcb
Roundtrip test of the phonetics feature 2018-11-21 13:43:42 +00:00
Kostas Dizas
e9c23c3fc7
Add phonetic runs and properties to rich text 2018-11-21 13:43:31 +00:00
Kostas Dizas
48a865cd66
Added phonetics field visibility option on cells 2018-11-21 13:03:02 +00:00
Kostas Dizas
03198f7e40 Corrected the calculation and formatting of weekdays
and relevant unit tests
2018-10-28 20:32:46 +00:00
Kostas Dizas
5decf9cf89 Test to confirm that the row spans are calculated correctly 2018-10-20 00:07:56 +01:00
Kostas Dizas
698b40c54c Added basic support for embedded images 2018-10-12 13:52:30 +01:00
Kostas Dizas
c804b4c569 Added new feature to insert and delete rows and columns 2018-09-11 09:44:43 +01:00
Crzyrndm
e183e37ae6 remove roundoff test, add test for exponential representations
-- testing that a number with >15 significant digits rounded off to 15 failed on all tested platforms
2018-08-25 14:06:20 +12:00
Crzyrndm
1003ba507d Add a test for serialize_number_to_string
-- should allow serialisation of up to 15 significant digits
-- don't use default stringstreams, typically only get ~6 significant digits
2018-08-25 13:54:54 +12:00
Crzyrndm
875f143d74 fix parameter ordering inconsistency that could cause switching the parameters to give different results 2018-08-25 13:31:16 +12:00
Crzyrndm
4188d35caf Add tests for the other small utilities 2018-08-19 15:11:57 +12:00
Crzyrndm
9565377963 Adding tests for xlnt::detail::float_equals
-- Plenty of comments which should be useful if it becomes useful to tweak the comparison
2018-08-19 14:41:00 +12:00
Crzyrndm
94fd22f492
Merge pull request #321 from Crzyrndm/Issue#282
Don't set comment size on explicit comment overload
2018-08-05 13:05:54 +12:00
Crzyrndm
2d2f825f64 tests for the const iterators as well 2018-08-05 12:55:33 +12:00
Crzyrndm
dc7f369be9 Add relative urls to the valid hyperlink url set 2018-08-04 14:55:17 +12:00
Crzyrndm
4124dd78e0 Add tests, fix compile error (missing include) 2018-07-29 14:27:49 +12:00
Crzyrndm
d39b7a107a comment default size only set in the overloads which can't set size
- Debatable whether position should receive the same treatment
2018-07-28 13:55:56 +12:00
Thomas Fussell
cbe50f4681 Fix some issues after merge 2018-07-23 00:13:20 -04:00
Thomas Fussell
0af7ad88e1 Merge branch 'tasmail-master-shared-strings-performance' into dev
remove less than comparators

fix conflicts
2018-07-23 00:10:16 -04:00
Crzyrndm
b004d0863c address CI build failure
Issue #300
Previous CI fix didn't work, try with type aliasing instead

Issue #300
This reverts commit c87c0e3975.
gcc 6 ok, msvc 14 choked

Issue #300
noexcept(condition) doesn't seem to work on msvs 2015

Issue #300
Merge remote-tracking branch 'origin/dev-optional-no-default-ctor' into dev-resolve-simple-issues
ensure uniqueness (uglify) and undefine compatibility macro
2018-07-21 12:19:15 +12:00
Crzyrndm
07d648fe8b Implementation of optional using std::aligned_storage
Issue #300
-- test for no default constructor required enabled
-- Passes all tests locally
2018-07-21 12:19:15 +12:00
Crzyrndm
ad69e7bf11 test for overloaded operator=(T)
Issue #300
2018-07-21 12:19:14 +12:00