You've already forked lazarus-ccr
fpspreadsheet: Put numerical data of the TCell record into a variant record --> further reduction of memory consumption per cell (now by 70% of original TCell).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3898 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@ -38,11 +38,14 @@ object Form1: TForm1
|
||||
TabOrder = 0
|
||||
end
|
||||
object LblCancel: TLabel
|
||||
Left = 208
|
||||
Height = 30
|
||||
Left = 184
|
||||
Height = 39
|
||||
Top = 6
|
||||
Width = 309
|
||||
Width = 576
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = False
|
||||
Caption = 'Press ESC to cancel when current file is completely written.'#13#10'This may take some time...'
|
||||
Layout = tlCenter
|
||||
ParentColor = False
|
||||
Visible = False
|
||||
end
|
||||
|
@ -37,8 +37,8 @@ type
|
||||
|
||||
{@@ Cell structure for TsWorksheet
|
||||
The cell record contains information on the location of the cell (row and
|
||||
column index), on the value contained (number, date, text, ...), and on
|
||||
formatting.
|
||||
column index), on the value contained (number, date, text, ...), on
|
||||
formatting, etc.
|
||||
|
||||
Never suppose that all *Value fields are valid,
|
||||
only one of the ContentTypes is valid. For other fields
|
||||
@ -46,9 +46,11 @@ type
|
||||
|
||||
@see ReadAsUTF8Text }
|
||||
TCell = record
|
||||
{ Location of the cell }
|
||||
Worksheet: TsWorksheet;
|
||||
Col: Cardinal; // zero-based
|
||||
Row: Cardinal; // zero-based
|
||||
(*
|
||||
ContentType: TCellContentType;
|
||||
{ Possible values for the cells }
|
||||
FormulaValue: string;
|
||||
@ -57,12 +59,25 @@ type
|
||||
DateTimeValue: TDateTime;
|
||||
BoolValue: Boolean;
|
||||
ErrorValue: TsErrorValue;
|
||||
SharedFormulaBase: PCell; // Cell containing the shared formula
|
||||
MergeBase: PCell; // Upper left cell if a merged range
|
||||
*)
|
||||
{ Index of format record }
|
||||
FormatIndex: Integer;
|
||||
{ Status flags }
|
||||
CalcState: TsCalcState;
|
||||
{ Special information }
|
||||
SharedFormulaBase: PCell; // Cell containing the shared formula
|
||||
MergeBase: PCell; // Upper left cell of a merged range
|
||||
{ Cell content }
|
||||
UTF8StringValue: String; // strings cannot be part of a variant record
|
||||
FormulaValue: String;
|
||||
case ContentType: TCellContentType of // must be at the end of the declaration
|
||||
cctEmpty : (); // has no data at all
|
||||
cctFormula : (); // UTF8StringValue is outside the variant record
|
||||
cctNumber : (Numbervalue: Double);
|
||||
cctUTF8String : (); // FormulaValue is outside the variant record
|
||||
cctDateTime : (DateTimevalue: TDateTime);
|
||||
cctBool : (BoolValue: boolean);
|
||||
cctError : (ErrorValue: TsErrorValue);
|
||||
end;
|
||||
|
||||
{@@ The record TRow contains information about a spreadsheet row:
|
||||
|
Reference in New Issue
Block a user