diff --git a/components/fpspreadsheet/fpstypes.pas b/components/fpspreadsheet/fpstypes.pas index 909ce24f1..93b51181d 100644 --- a/components/fpspreadsheet/fpstypes.pas +++ b/components/fpspreadsheet/fpstypes.pas @@ -569,23 +569,8 @@ type end; -procedure InitFormatRecord(out AValue: TsCellFormat); - - implementation -{ Utilities } - -procedure InitFormatRecord(out AValue: TsCellFormat); -begin - AValue.Name := ''; - AValue.NumberFormatStr := ''; - FillChar(AValue, SizeOf(AValue), 0); - AValue.BorderStyles := DEFAULT_BORDERSTYLES; - AValue.Background := EMPTY_FILL; -end; - - { TsCellFormatList } constructor TsCellFormatList.Create(AAllowDuplicates: Boolean); diff --git a/components/fpspreadsheet/fpsutils.pas b/components/fpspreadsheet/fpsutils.pas index 34d92860f..3c219a4dc 100644 --- a/components/fpspreadsheet/fpsutils.pas +++ b/components/fpspreadsheet/fpsutils.pas @@ -150,6 +150,7 @@ procedure SplitHyperlink(AValue: String; out ATarget, ABookmark: String); procedure InitCell(out ACell: TCell); overload; procedure InitCell(ARow, ACol: Cardinal; out ACell: TCell); overload; +procedure InitFormatRecord(out AValue: TsCellFormat); procedure AppendToStream(AStream: TStream; const AString: String); inline; overload; procedure AppendToStream(AStream: TStream; const AString1, AString2: String); inline; overload; @@ -2080,6 +2081,18 @@ begin ACell.Col := ACol; end; +{@@ ---------------------------------------------------------------------------- + Initializes the fields of a TsCellFormaRecord +-------------------------------------------------------------------------------} +procedure InitFormatRecord(out AValue: TsCellFormat); +begin + AValue.Name := ''; + AValue.NumberFormatStr := ''; + FillChar(AValue, SizeOf(AValue), 0); + AValue.BorderStyles := DEFAULT_BORDERSTYLES; + AValue.Background := EMPTY_FILL; +end; + {@@ ---------------------------------------------------------------------------- Appends a string to a stream diff --git a/components/fpspreadsheet/tests/spreadtestcli.lpi b/components/fpspreadsheet/tests/spreadtestcli.lpi index 81be348f3..55a0600b4 100644 --- a/components/fpspreadsheet/tests/spreadtestcli.lpi +++ b/components/fpspreadsheet/tests/spreadtestcli.lpi @@ -13,7 +13,6 @@ <UseAppBundle Value="False"/> <ResourceType Value="res"/> - <Icon Value="-1"/> </General> <i18n> <EnableI18N LFM="False"/> @@ -70,7 +69,7 @@ <PackageName Value="LCLBase"/> </Item1> </RequiredPackages> - <Units Count="22"> + <Units Count="23"> <Unit0> <Filename Value="spreadtestcli.lpr"/> <IsPartOfProject Value="True"/> @@ -159,8 +158,12 @@ <Unit21> <Filename Value="commenttests.pas"/> <IsPartOfProject Value="True"/> - <UnitName Value="commenttests"/> </Unit21> + <Unit22> + <Filename Value="enumeratortests.pas"/> + <IsPartOfProject Value="True"/> + <UnitName Value="enumeratortests"/> + </Unit22> </Units> </ProjectOptions> <CompilerOptions> diff --git a/components/fpspreadsheet/tests/spreadtestcli.lpr b/components/fpspreadsheet/tests/spreadtestcli.lpr index 53b0987a5..0efc4253d 100644 --- a/components/fpspreadsheet/tests/spreadtestcli.lpr +++ b/components/fpspreadsheet/tests/spreadtestcli.lpr @@ -15,7 +15,7 @@ uses formattests, colortests, emptycelltests, insertdeletetests, errortests, numberstests, fonttests, formulatests, numformatparsertests, optiontests, virtualmodetests, dbexporttests, sortingtests, copytests, celltypetests, - commenttests; + commenttests, enumeratortests; const ShortOpts = 'ac:dhlpr:x';