mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-18 16:59:09 +02:00
* fixed crash when reading properties which values are one char
* fixed crash when property values are empty git-svn-id: trunk@17848 -
This commit is contained in:
parent
e966b41e53
commit
332993241d
@ -558,6 +558,7 @@ var
|
|||||||
begin
|
begin
|
||||||
Result := TStringList.Create;
|
Result := TStringList.Create;
|
||||||
Start := Pos(':', ACommand)+1;
|
Start := Pos(':', ACommand)+1;
|
||||||
|
ACommand := ACommand + ' ';
|
||||||
|
|
||||||
|
|
||||||
WantArg := True;
|
WantArg := True;
|
||||||
@ -757,9 +758,15 @@ begin
|
|||||||
Command := LowerCase(GetCommandName(ACommand));
|
Command := LowerCase(GetCommandName(ACommand));
|
||||||
|
|
||||||
if Command = 'color' then
|
if Command = 'color' then
|
||||||
Color := ColorFromString(Args[0])
|
if Args.Count > 0 then
|
||||||
|
Color := ColorFromString(Args[0])
|
||||||
|
else
|
||||||
|
Color := clDefault
|
||||||
else if Command = 'background-color' then
|
else if Command = 'background-color' then
|
||||||
BGColor := ColorFromString(Args[0])
|
if Args.Count > 0 then
|
||||||
|
BGColor := ColorFromString(Args[0])
|
||||||
|
else
|
||||||
|
BGColor := clDefault
|
||||||
else if Command = 'background' then
|
else if Command = 'background' then
|
||||||
begin
|
begin
|
||||||
if Args.Count > 0 then BGColor := ColorFromString(Args[0]);
|
if Args.Count > 0 then BGColor := ColorFromString(Args[0]);
|
||||||
|
Loading…
Reference in New Issue
Block a user