System.WideStrUtils.ConvertStreamFromAnsiToUTF8
Delphi
procedure ConvertStreamFromAnsiToUTF8(Src, Dst : TStream; cp : Integer);
C++
extern DELPHI_PACKAGE void __fastcall ConvertStreamFromAnsiToUTF8(System::Classes::TStream* Src, System::Classes::TStream* Dst, int cp = 0x0);
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
procedure function |
public | System.WideStrUtils.pas System.WideStrUtils.hpp |
System.WideStrUtils | System.WideStrUtils |
Description
Converts a stream from ANSI to UTF-8 encoding.
ConvertStreamFromAnsiToUTF8 converts an input stream specified by Src to an output stream specified by Dst. The function assumes that the input stream contains text encoded in ANSI and converts it to UTF-8. Optionally, the code page of the input ANSI stream is specified.
If the specified code page is CP_UTF8 then a direct copy is made; otherwise a conversion is performed.