Defines | Functions

nsUnicharUtils.h File Reference

#include "nsStringGlue.h"
Include dependency graph for nsUnicharUtils.h:
This graph shows which files directly or indirectly include this file:

Defines

#define IS_CJ_CHAR(u)

Functions

void ToLowerCase (nsAString &)
void ToUpperCase (nsAString &)
void ToLowerCase (const nsAString &aSource, nsAString &aDest)
void ToUpperCase (const nsAString &aSource, nsAString &aDest)
PRUnichar ToLowerCase (PRUnichar)
PRUnichar ToUpperCase (PRUnichar)
PRUnichar ToTitleCase (PRUnichar)
void ToLowerCase (const PRUnichar *, PRUnichar *, PRUint32)
void ToUpperCase (const PRUnichar *, PRUnichar *, PRUint32)
PRBool IsUpperCase (PRUnichar c)
PRBool IsLowerCase (PRUnichar c)
PRInt32 CaseInsensitiveCompare (const PRUnichar *a, const PRUnichar *b, PRUint32 len)
PRInt32 CaseInsensitiveCompare (const char *aLeft, const char *aRight, PRUint32 aLeftBytes, PRUint32 aRightBytes)
PRBool CaseInsensitiveUTF8CharsEqual (const char *aLeft, const char *aRight, const char *aLeftEnd, const char *aRightEnd, const char **aLeftNext, const char **aRightNext, PRBool *aErr)
 This function determines whether the UTF-8 sequence pointed to by aLeft is case-insensitively-equal to the UTF-8 sequence pointed to by aRight.

Define Documentation

#define IS_CJ_CHAR (   u  ) 
Value:
((0x2e80u <= (u) && (u) <= 0x312fu) || \
   (0x3190u <= (u) && (u) <= 0xabffu) || \
   (0xf900u <= (u) && (u) <= 0xfaffu) || \
   (0xff00u <= (u) && (u) <= 0xffefu) )

Function Documentation

PRInt32 CaseInsensitiveCompare ( const PRUnichar a,
const PRUnichar b,
PRUint32  len 
)
PRInt32 CaseInsensitiveCompare ( const char *  aLeft,
const char *  aRight,
PRUint32  aLeftBytes,
PRUint32  aRightBytes 
)
PRBool CaseInsensitiveUTF8CharsEqual ( const char *  aLeft,
const char *  aRight,
const char *  aLeftEnd,
const char *  aRightEnd,
const char **  aLeftNext,
const char **  aRightNext,
PRBool aErr 
)

This function determines whether the UTF-8 sequence pointed to by aLeft is case-insensitively-equal to the UTF-8 sequence pointed to by aRight.

aLeftEnd marks the first memory location past aLeft that is not part of aLeft; aRightEnd similarly marks the end of aRight.

The function assumes that aLeft < aLeftEnd and aRight < aRightEnd.

The function stores the addresses of the next characters in the sequence into aLeftNext and aRightNext. It's up to the caller to make sure that the returned pointers are valid -- i.e. the function may return aLeftNext >= aLeftEnd or aRightNext >= aRightEnd.

If the function encounters invalid text, it sets aErr to true and returns false, possibly leaving aLeftNext and aRightNext uninitialized. If the function returns true, aErr is guaranteed to be false and both aLeftNext and aRightNext are guaranteed to be initialized.

PRBool IsLowerCase ( PRUnichar  c  )  [inline]
PRBool IsUpperCase ( PRUnichar  c  )  [inline]
PRUnichar ToLowerCase ( PRUnichar   ) 
void ToLowerCase ( const PRUnichar ,
PRUnichar ,
PRUint32   
)
void ToLowerCase ( nsAString  ) 
void ToLowerCase ( const nsAString aSource,
nsAString aDest 
)
PRUnichar ToTitleCase ( PRUnichar   ) 
void ToUpperCase ( const PRUnichar ,
PRUnichar ,
PRUint32   
)
void ToUpperCase ( nsAString  ) 
PRUnichar ToUpperCase ( PRUnichar   ) 
void ToUpperCase ( const nsAString aSource,
nsAString aDest 
)