Qx v0.5.8
Qt Extensions Library
Loading...
Searching...
No Matches
Qx::Char Class Reference

The Char class is a collection of static functions pertaining to character types.

#include <qx/core/qx-char.h>

Static Public Member Functions

static int compare (QChar cOne, QChar cTwo, Qt::CaseSensitivity cs=Qt::CaseSensitive)
 
static bool isHexNumber (QChar hexNum)
 
static bool isSpace (char chr)
 
static bool isSpace (const QChar &ch)
 
static bool isSpace (signed char ch)
 
static bool isSpace (unsigned char ch)
 
static bool isSpace (wchar_t ch)
 

Member Function Documentation

◆ compare()

int Qx::Char::compare ( QChar cOne,
QChar cTwo,
Qt::CaseSensitivity cs = Qt::CaseSensitive )
static

Compares cOne with cTwo and returns an integer less than, equal to, or greater than zero if cOne is less than, equal to, or greater than cTwo.

If cs is Qt::CaseSensitive, the comparison is case sensitive; otherwise the comparison is case insensitive.

Case sensitive comparison is based exclusively on the numeric Unicode values of the characters and is very fast, but is not always what a human would expect.

◆ isHexNumber()

bool Qx::Char::isHexNumber ( QChar hexNum)
static

Returns true if hexNum is a numeric digit, or a letter A through F (case-insensitive); otherwise returns false.

◆ isSpace() [1/5]

bool Qx::Char::isSpace ( char ch)
static

Returns true if ch is a whitespace character as classified by the current locale; otherwise, returns false.

This function, along with its overloads provide a standard interface through which to check if a character is a whitespace character, which can be useful for templates.

◆ isSpace() [2/5]

bool Qx::Char::isSpace ( const QChar & ch)
static

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆ isSpace() [3/5]

bool Qx::Char::isSpace ( signed char ch)
static

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆ isSpace() [4/5]

bool Qx::Char::isSpace ( unsigned char ch)
static

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

◆ isSpace() [5/5]

bool Qx::Char::isSpace ( wchar_t ch)
static

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.


The documentation for this class was generated from the following files: