You've already forked lazarus-ccr
fpspreadsheet: Move conditional format list from worksheet to workbook (to facilitate handling for ODS).
git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7503 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
@@ -194,6 +194,7 @@ function CombineTextAndRichTextParams(AText: String;
|
||||
procedure SplitTextAndRichTextParams(AValue: String;
|
||||
out AText: String; out ARichText: TsRichTextParams);
|
||||
function SplitStr(const AText: String; ADelimiter: Char): TStringArray;
|
||||
function SafeQuoteStr(AString: String): String;
|
||||
function UnquoteStr(AString: String): String;
|
||||
|
||||
function InitSearchParams(ASearchText: String = ''; AOptions: TsSearchOptions = [];
|
||||
@@ -2371,6 +2372,25 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
{@@ ----------------------------------------------------------------------------
|
||||
Makes sure that the string is encloed by quotes (").
|
||||
Avoids duplicate quotation.
|
||||
-------------------------------------------------------------------------------}
|
||||
function SafeQuoteStr(AString: String): String;
|
||||
begin
|
||||
if AString = '' then
|
||||
Result := '""'
|
||||
else
|
||||
if Length(AString) = 1 then
|
||||
Result := '"' + AString + '"'
|
||||
else
|
||||
begin
|
||||
Result := AString;
|
||||
if AString[1] <> '"' then Result := '"' + Result;
|
||||
if AString[Length(AString)] <> '"' then Result := Result + '"';
|
||||
end;
|
||||
end;
|
||||
|
||||
{@@ ----------------------------------------------------------------------------
|
||||
Removes quotation characters which enclose a string
|
||||
-------------------------------------------------------------------------------}
|
||||
|
Reference in New Issue
Block a user