foobar2000 SDK  2015-01-14
Namespaces | Functions | Variables
utf8.cpp File Reference

Go to the source code of this file.

Namespaces

 pfc
 

Functions

static bool pfc::check_end_of_string (const char *ptr)
 
bool pfc::is_lower_ascii (const char *param)
 
bool pfc::is_valid_utf8 (const char *param, t_size max=~0)
 
t_size pfc::skip_utf8_chars (const char *ptr, t_size count) throw ()
 
unsigned pfc::strcpy_utf8_truncate (const char *src, char *out, unsigned maxbytes)
 
t_size pfc::strlen_utf8 (const char *s, t_size num=~0) throw ()
 
t_size pfc::utf16_decode_char (const char16_t *p_source, unsigned *p_out, t_size p_source_length=~0) throw ()
 
t_size pfc::utf16_decode_char (const wchar_t *p_source, unsigned *p_out, t_size p_source_length=~0) throw ()
 
t_size pfc::utf16_encode_char (unsigned c, char16_t *out) throw ()
 
t_size pfc::utf16_encode_char (unsigned c, wchar_t *out) throw ()
 
t_size pfc::utf8_char_len (const char *s, t_size max=~0) throw ()
 
t_size pfc::utf8_char_len_from_header (char c) throw ()
 
t_size pfc::utf8_chars_to_bytes (const char *string, t_size count) throw ()
 
t_size pfc::utf8_decode_char (const char *src, unsigned &out, t_size src_bytes) throw ()
 
t_size pfc::utf8_decode_char (const char *src, unsigned &out) throw ()
 
t_size pfc::utf8_encode_char (unsigned c, char *out) throw ()
 
unsigned pfc::utf8_get_char (const char *src)
 
t_size pfc::wide_decode_char (const wchar_t *p_source, unsigned *p_out, t_size p_source_length=~0) throw ()
 
t_size pfc::wide_encode_char (unsigned c, wchar_t *out) throw ()
 

Variables

static const t_uint8 pfc::mask_tab [6] ={0x80,0xE0,0xF0,0xF8,0xFC,0xFE}
 
static const t_uint8 pfc::val_tab [6] ={0,0xC0,0xE0,0xF0,0xF8,0xFC}