From 87f6a1c5162ef80b8124a367af51349a952aceb5 Mon Sep 17 00:00:00 2001 From: Graeme Geldenhuys Date: Wed, 6 Apr 2011 23:39:06 +0200 Subject: docdump: make sure all counters are 0-based It might look better for humans if counting is 1-based, but for reference with the INF file structure, lets keep all the docdump output 0-based. --- docview/src/docdump/readfonts.pas | 2 +- docview/src/docdump/readtoc.pas | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'docview') diff --git a/docview/src/docdump/readfonts.pas b/docview/src/docdump/readfonts.pas index 6b684cac..68c3bd4c 100644 --- a/docview/src/docdump/readfonts.pas +++ b/docview/src/docdump/readfonts.pas @@ -32,7 +32,7 @@ begin for i := 0 to eHdr.NumFontEntry-1 do begin AIn.Read(fnt, SizeOf(THelpFontSpec)); - AOut.WriteLn(Format(' Font Entry #%d', [i+1])); + AOut.WriteLn(Format(' Font Entry #%d', [i])); AOut.WriteLn(Format(' FontSpec.FaceName: %s', [fnt.FaceName])); AOut.WriteLn(Format(' FontSpec.Height: %4.4x (%0:d)', [fnt.Height])); AOut.WriteLn(Format(' FontSpec.Width: %4.4x (%0:d)', [fnt.Width])); diff --git a/docview/src/docdump/readtoc.pas b/docview/src/docdump/readtoc.pas index 0cfae395..8c98e31e 100644 --- a/docview/src/docdump/readtoc.pas +++ b/docview/src/docdump/readtoc.pas @@ -73,7 +73,7 @@ begin GetMem(pData, hdr.toclen); AIn.Read(pData^, hdr.toclen); pEntry := pData; - for count := 1 to hdr.ntoc do + for count := 0 to hdr.ntoc-1 do begin // AIn.Read(toc, SizeOf(TTOCEntryStart)); // FillChar(olay, SizeOf(TTOCOverlay), 0); -- cgit v1.2.3-70-g09d2