|
|
A class representing a charset.
KCharset () |
Default constructor
KCharset (const char *name) |
Prepares charset of given name
Parameters:
name | Name of the charset |
KCharset (const QString) |
Prepares charset of given name
Parameters:
name | Name of the charset |
KCharset (QFont::CharSet id) |
Prepares charset from Qt's charset id
Parameters:
id | Qt's id of the charset |
KCharset ( const KCharset& ) |
Copy constructor for KCharset
KCharset& operator= ( const KCharset& ) |
Assignment operator for KCharset
const char * name () |
Gives name of the charset
Returns: name of the charset
operator const char * () |
For casting KCharset into string
Returns: name of the charset
operator QString () |
For casting KCharset into QString
Returns: name of the charset
bool isDisplayable () |
Check if charset is displayable
Returns: TRUE if it is displayable
bool isDisplayable (const char *font) |
Check if charset is displayable using given font
Parameters:
family | name of the font |
Returns: TRUE if it is displayable
bool isAvailable () |
Check if charset is defined for use with KDE (in charsets classes or in charsets config files)
Returns: TRUE if it is available
bool ok () |
Check if charset is OK. In fact the same as isAvailable
Returns: TRUE if it is available
bool isRegistered () |
Check if charset is registered for use in mime messages. TRUE also for some not-yet-registered charsets (UTF-7 and UTF-8)
Returns: TRUE if it is registered
QFont & setQFont (QFont& fnt) |
Set charset of QFont to this. Should be used instead of QFont::setCharSet()
Parameters:
fnt | Font we want set charset of |
Returns: The font after setting the charset
QFont::CharSet qtCharset () |
Get QT's id of charset. Qt has id defined only for ISO-8859-* charsets, so their charset functions should not be used
Returns: The Qt font charset id
int bits () |
Get nuber of bits needed to represent a character. As for now only 8-bit characters are supported well
Returns: Number of bits per character
bool printable (int chr) |
check if character is printable in selected charset
Parameters:
chr | Character to check |
Returns: TRUE if it is printable
bool operator == (const KCharset& kch) |
compares charsets
Parameters:
kch | Character to compare to |
Returns: TRUE this and kch are the same charset
QString xCharset () |
Gets X charset identifier (last two fields of X font name)
Returns: string representing X charset name
KCharset (const KCharsetEntry *) |
For internal use only
operator const KCharsetEntry * () |
For internal use only