From aad33420212b16c2d69501f165b002d00c7aa25f Mon Sep 17 00:00:00 2001 From: wp_xxyyzz Date: Fri, 23 May 2014 16:22:47 +0000 Subject: [PATCH] fpspreadsheet: Add info on DBCELL record to BIFFExplorer. git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@3084 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- .../reference/BIFFExplorer/bebiffgrid.pas | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/components/fpspreadsheet/reference/BIFFExplorer/bebiffgrid.pas b/components/fpspreadsheet/reference/BIFFExplorer/bebiffgrid.pas index fff9bda78..42e0c1934 100644 --- a/components/fpspreadsheet/reference/BIFFExplorer/bebiffgrid.pas +++ b/components/fpspreadsheet/reference/BIFFExplorer/bebiffgrid.pas @@ -36,6 +36,7 @@ type procedure ShowColWidth; procedure ShowCountry; procedure ShowDateMode; + procedure ShowDBCell; procedure ShowDefColWidth; procedure ShowDefRowHeight; procedure ShowDelta; @@ -342,6 +343,8 @@ begin ShowMulBlank; $00BD: ShowMulRK; + $00D7: + ShowDBCell; $00DA: ShowBookBool; $00E0: @@ -821,6 +824,31 @@ begin '0 = Base date is 1899-Dec-31, 1 = Base date is 1904-Jan-01'); end; +procedure TBIFFGrid.ShowDBCell; +var + i, n: Integer; + dw: DWord; + w: Word; + numBytes: Integer; +begin + if FFormat < sfExcel5 then exit; + + n := (Length(FBuffer) - 4) div 2; + RowCount := FixedRows + 1 + n; + + numBytes := 4; + Move(FBuffer[FBufferIndex], dw, numBytes); + ShowInRow(FCurrRow, FBufferIndex, numbytes, IntToStr(DWordLEToN(dw)), + 'Relative offset to first ROW record in the Row Block'); + + numBytes := 2; + for i:=1 to n do begin + Move(FBuffer[FBufferIndex], w, numBytes); + ShowInRow(FCurrRow, FBufferIndex, numbytes, IntToStr(WordLEToN(w)), + 'Relative offsets to calculate stream position of the first cell record in row'); + end; +end; + procedure TBIFFGrid.ShowDefColWidth; var numBytes: Integer;