[Overview][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'LazUTF8' (#lazutils)

UTF8ToConsole

Converts a UTF-8-encoded string to console (OEM) encoding.

Declaration

Source position: lazutf8.pas line 55

function UTF8ToConsole(

  const s: string

):string;

Arguments

s

  

UTF-8-encode input values.

Function result

OEM-encoded value for the string.

Description

UTF8ToConsole converts a UTF-8-encoded string to console (OEM) encoding as used in Write and WriteLn. The implementation is platform specific.

For the Windows environment, either UTF8ToSys or UTF8ToWinCP is used to convert the value to the codepage or character set needed in RTL. The Windows CharToOem API is used to prepare the return value. In UNIX-like environments, UTF8ToSys is used to get the return value .

See also

UTF8ToSys

  

Ensures UTF-8 characters (or format settings) are converted to the system code page.

UTF8ToWinCP

  

Converts the UTF-8-encoded string to the Windows code page encoding.


Version 4.0 Generated 2025-05-03 Home