Commit Graph

1207 Commits

Author SHA1 Message Date
f430301fd8 fpspreadsheet: Add cell inspector to spready demo (shows properties of selected cell).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3489 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-16 17:37:16 +00:00
62ff8bc2d0 fpspreadsheet: Initial version of reading BIFF8 shared rpn formulas. Reconstruction of string formula from shared rpn formula ok.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3488 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-15 19:29:58 +00:00
04e41843a2 fpspreadsheet: Show details on shared formulas in BIFFExplorer
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3484 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-14 22:18:04 +00:00
17a6cb61da fpspreadsheet: Add more details on DEFINEDNAME record to BIFFExplorer; add details on EXTERN* records; fix compilation issue with TIpHTMLPanel.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3483 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-14 15:47:13 +00:00
826a3e4b20 fpspreadsheet: Expand (some) details on DEFINEDNAME record in BIFFExplorer
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3480 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-13 22:54:56 +00:00
39b88796ee fpspreadsheet: cosmetic
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3479 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-13 19:26:21 +00:00
67186349be fpspreadsheet: make sure that formulas are only recalculated when needed (in particalar only once after loading a file). Rename worksheet option soCalcAfterSaving to boCalcAfterSaving and assign it to the Workbook. (Add section "Incompatible changes" to wiki).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3478 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-13 19:23:59 +00:00
2dd6598e20 fpspreadsheet: Reorganize formula recalculation code to achieve more stability against infinite loops.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3477 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-13 18:44:38 +00:00
03913876d3 fpspreadsheet: Implement automatic calculation of existing rpn formulas whenever a cell changes.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3476 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-13 14:05:29 +00:00
5bc25c482e fpspreadsheet: Clean up. Silence some hints.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3473 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-12 14:52:57 +00:00
f35eae9379 fpspreadsheet: Fix OOXML writer using incorrect color if palette index is >63. Activate color count error test for ooxml and ods.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3472 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-12 09:05:19 +00:00
495499a9e2 fpspreadsheet: Make sure that Excel's system colors are kept when colors are added to a palette. Fix BIFF 2 font color mismatch in unit test. All green again.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3471 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-11 22:39:47 +00:00
eaabdf67c1 fpspreadsheet: Make sure that biff writers do not write colors exceeding the maximum palette count. Add casse to error tests (passed, but the biff2 font color test fails now...)
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3470 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-11 15:53:06 +00:00
f92f0364d9 fpspreadsheet: Show error messages after reading/writing in the "fpsgrid" and "spready" demos.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3469 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-11 11:34:46 +00:00
ad1ae69544 fpspreadsheet: Log warning if BIFF writer tries to write more than 64 colors. More clean-up.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3468 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-11 11:16:43 +00:00
61ae361d37 fpspreadsheet: Fix font identification issue of OOXML reader for files written by fpspreadsheet.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3467 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-10 20:51:41 +00:00
68aed47788 fpspreadsheet: Some clean-up, less hints
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3466 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-10 17:59:30 +00:00
c76d1bdbff fpspreadsheet: Improved xf format detection by OOXML reader.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3465 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-10 15:16:58 +00:00
580ace3391 fpspreadsheet: Fix font assignment scrambled when OOXML reads files written by Excel 2007+
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3464 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-10 14:52:30 +00:00
c75695c301 fpspreadsheet: Convert forgotten WriteXXXX(Row,Col...) procedures to functions returning the cell used.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3463 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-10 09:22:42 +00:00
ced21b2d9c fpspreadsheet: Fix memory leak in cell memory allocation (visibile in OOXML and ODS).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3462 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-09 14:17:49 +00:00
dd08f3e7c1 fpspreadsheet: Fix ODS writing incorrect blank cells. Add blank cells to emptycelltests.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3461 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-09 13:39:15 +00:00
1e24a88116 fpspreadsheet: Fix string-to-integer conversion bug introduced by last commit
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3460 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-09 11:51:34 +00:00
a5495c97b5 fpspreadsheet: More robust evaluation of xf style attributes but the OOXML reader (check "applyXXXX" against "<>'0'" instead of "='1'")
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3459 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-09 11:14:22 +00:00
83db4e3fc4 fpspreadsheet: Add proper ifdefs around "uses clocale" in fpspreadsheet.pas
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3458 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-08 21:18:16 +00:00
755a36e055 fpspreadsheet: Write string formulas to ods files.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3457 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-08 19:14:08 +00:00
a0a19eb380 fpspreadsheet: Write OOXML string formulas. Write biff2 dimension record.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3456 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-08 19:00:27 +00:00
8f666bec13 fpspreadsheet: Fix written oversized worksheets being defective, adapt BIFF writer's WriteDimensions method to be compatible with oversized worksheets.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3455 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-08 14:30:19 +00:00
53bb7bd316 fpspreadsheet: Add "empty cell" tests having empty rows and columns before occupied cells start. Extend "empty cell" tests to OOXML format.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3452 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-08 12:39:02 +00:00
2de7d41fef fpspreadsheet: Clear error log before starting reader/writer
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3450 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-08 12:18:17 +00:00
0029891176 fpspreadsheet: Fix ODS writer beginning to write rows/columns at first used row/column instead of 0. ODS error message test active now. Separate errortests and virtualmodetests from internaltests. All tests passed (Win32, Laz trunk, fpc 2.6.4).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3449 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-08 09:02:37 +00:00
ff059e3420 fpspreadsheet: Move log list from reader/writer to workbook for easier access. Add unit test for error logging (in internaltests). Improve OOXML writer to begin writing rows only from the first existing row, not from 0. (The ODS writer still does this, therefore, it creates a huge file for the error logging test - this test is currently deactivated for ods).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3446 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-07 22:24:22 +00:00
68718a9192 fpspreadsheet: Split off common properties and methods from the custom reader/writer classes into a common TsCustomReaderWriter class. Add a logging mechanism for error messages to this common ancestor.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3445 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-07 19:41:13 +00:00
b9dc9a801f fpspreadsheet: Fix option boBufStream writing defective ods and xlsx files.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3444 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-07 12:52:26 +00:00
c575126fa0 fpspreadsheet: Implement writing of ODS files in virtual mode. Adapt demo_virtualmode_write, speed test, and unit test (--> passed).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3443 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-07 08:43:11 +00:00
2fd7d0caa1 fpspreadsheet: Reading of xlsx theme colors working (writing is not planned). xlsx reader now creates a default color palette because some xlsx files refer to colors by index although they don't contain a palette.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3442 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-06 21:52:20 +00:00
c0dbb07201 fpspreadsheet: Implementing reading of xlsx theme colors which are found in many xlsx files. Not quite correct yet.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3440 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-06 15:49:04 +00:00
5e151d64a7 fpspreadsheet: Fix missing of some cell border lines in TsWorksheetGrid
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3439 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-06 13:45:26 +00:00
ebf59489f2 fpspreadsheet: Complete database import demo. Rename dbexport to db_export_import. Fix biff2 crashing in ReadPane because of duplicate variable FWorksheet.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3434 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-06 08:50:36 +00:00
8409952071 fpspreadsheet: Add import of spreadsheet data to a database to the dbexport project (will be renamed to db_export_import). Functional, but not fully complete.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3433 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-05 23:13:39 +00:00
74f5bf26f5 fpspreadsheet: Activate virtual reading mode for OOXML reader / fpsspeedtest
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3432 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-05 21:49:23 +00:00
7e599ebd07 fpspreadsheet: Fix arithmetic overflow in ooxml writer in case of empty worksheet but existing row records. Use try-finally blocks around test cases to make sure that memory is released and temp file is deleted in case of exceptions due to failed tests. Fix memory leak in rpn formula calculation (spreadtestgui, however, still reports a lot of memory leaks).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3431 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-05 21:42:34 +00:00
d63dd1b715 fpspreadsheet: rename project1 to dbexport as it better indicates the functionaiity.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3430 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-05 13:55:58 +00:00
99569c1114 fpspreadsheet: cosmetic clean up of database virtual mode demo
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3429 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-05 13:46:42 +00:00
052b6a9224 fpspreadsheet: Rewrite all WriteXXXX methods of TsWorksheet depending on row and column indexes as functions to return the pointer to the cell created/modifed.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3426 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-05 10:59:24 +00:00
fe4b0ab8db fpspreadsheet: Add number, string and date/time tests for xlsx reading.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3425 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-05 08:25:17 +00:00
ccc593a525 fpspreadsheet: Add a new example project showing database export in virtual mode.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3423 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-04 19:46:50 +00:00
d0be6284cf fpspreadsheet: OOXML reading/writing support for frozen panes. Simplify OOXML's cell writing strategy by omitting empty cells.
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3422 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-04 19:11:17 +00:00
f0b57845bb fpspreadsheet: xlsx reading/writing support for hidden grid lines and headers
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3420 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-03 22:55:58 +00:00
b6d9f2f0f0 fpspreadsheet: Fix xlsx reader ignoring cell attributes for cells having font #1 in files not written by fps (confused by uffBold).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3419 8e941d3f-bd1b-0410-a28a-d453659cc2b4
2014-08-03 21:43:08 +00:00