mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-27 16:20:35 +02:00
Adds more encoding conversion support, patch from bug #23446
git-svn-id: trunk@39536 -
This commit is contained in:
parent
f1d9d42341
commit
dac086ca0f
@ -6527,6 +6527,14 @@ begin
|
||||
Result:=KOI8ToUTF8(s);
|
||||
Encoded := true;
|
||||
end
|
||||
else if AFrom = EncodingUCS2LE then begin
|
||||
Result := UCS2LEToUTF8(s);
|
||||
Encoded := true;
|
||||
end
|
||||
else if AFrom = EncodingUCS2BE then begin
|
||||
Result := UCS2BEToUTF8(s);
|
||||
Encoded := true;
|
||||
end
|
||||
else if (AFrom=SysEnc) and Assigned(ConvertAnsiToUTF8) then begin
|
||||
Result:=ConvertAnsiToUTF8(s);
|
||||
Encoded := true;
|
||||
@ -6621,6 +6629,14 @@ begin
|
||||
Result:=UTF8ToKOI8(Result);
|
||||
Encoded := true;
|
||||
end
|
||||
else if ATo = EncodingUCS2LE then begin
|
||||
Result := UTF8ToUCS2LE(Result);
|
||||
Encoded := true;
|
||||
end
|
||||
else if ATo = EncodingUCS2BE then begin
|
||||
Result := UTF8ToUCS2BE(Result);
|
||||
Encoded := true;
|
||||
end
|
||||
else if (ATo=SysEnc) and Assigned(ConvertUTF8ToAnsi) then begin
|
||||
Result:=ConvertUTF8ToAnsi(Result);
|
||||
Encoded := true;
|
||||
|
Loading…
Reference in New Issue
Block a user