SPRAAK
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
Functions
utf8.c File Reference

Handling of UTF-8 encoded data. More...

Functions

size_t spr_utf8_len (const char *str)
 
char * spr_utf8_next (const char *str)
 
char * spr_utf8_nextN (const char *str, int N)
 
char * spr_utf8_prev (const char *str)
 
char * spr_utf8_get_advance (int *utf_chr, const char *str)
 
char * spr_utf8_check (const char *str, SprMsgId *routine)
 
int spr_utf8_chr_len (unsigned int chr)
 
char * spr_utf8_chr_put_advance (char *str, unsigned int chr)
 

Detailed Description

Handling of UTF-8 encoded data.

This module provides a minimalistic set of routines to handle UTF-8 encoded text.

Author
Kris Demuynck
Date
10/03/2008
Bug:
Only the spr_utf8_check() routine checks for correctly encoded utf-8 data, all other routines only detect badly encoded utf-8 data if this poses a real problem (or if this can be done with very little overhead).