ClanLib
2.3.7
|
Font description class. More...
#include <font_description.h>
Public Member Functions | |
Operations | |
CL_FontDescription & | operator= (const CL_FontDescription ©) |
Copy assignment operator. More... | |
void | clone (const CL_FontDescription ©) |
void | set_typeface_name (const CL_String &name) |
Sets the typeface name. More... | |
void | set_height (int value) |
Sets the font height. More... | |
void | set_average_width (int value) |
Sets the font average width. More... | |
void | set_escapement (float value) |
Sets the font escapement. More... | |
void | set_orientation (float value) |
Sets the font orientation. More... | |
void | set_weight (int value) |
Sets the font weight. More... | |
void | set_italic (bool setting=true) |
Sets the font italic setting. More... | |
void | set_underline (bool setting=true) |
Sets the font underline setting. More... | |
void | set_strikeout (bool setting=true) |
Sets the font strikeout setting. More... | |
void | set_fixed_pitch (bool setting=true) |
Sets the font fixed pitch setting. More... | |
void | set_anti_alias (bool setting=true) |
Sets the font anti-alias setting (defaults to true) More... | |
void | set_subpixel (bool setting=true) |
Sets the font subpixel rendering setting (defaults to true) More... | |
void | set_charset (Charset new_charset) |
Sets the font charset (defaults to charset_default) More... | |
Construction | |
CL_FontDescription () | |
Constructs a font description with default values. More... | |
virtual | ~CL_FontDescription () |
static CL_FontDescription | create_null_object () |
Create null object. More... | |
Attributes | |
enum | Charset { charset_default, charset_ansi, charset_baltic, charset_chinesebig5, charset_easteurope, charset_gb2312, charset_greek, charset_hangul, charset_mac, charset_oem, charset_russian, charset_shiftjis, charset_symbol, charset_turkish, charset_vietnamese, charset_johab, charset_arabic, charset_hebrew, charset_thai } |
bool | is_null () const |
Returns true if this object is invalid. More... | |
void | throw_if_null () const |
Throw an exception if this object is invalid. More... | |
const CL_String & | get_typeface_name () const |
Returns the typeface name. More... | |
int | get_height () const |
Returns the font height. More... | |
int | get_average_width () const |
Returns the font average width. More... | |
float | get_escapement () const |
Returns the font escapement. More... | |
float | get_orientation () const |
Returns the font orientation. More... | |
int | get_weight () const |
Returns the font weight. More... | |
bool | get_italic () const |
Returns the font italic setting. More... | |
bool | get_underline () const |
Returns the font underline setting. More... | |
bool | get_strikeout () const |
Returns the font strikeout setting. More... | |
bool | get_fixed_pitch () const |
Returns the font fixed pitch setting. More... | |
bool | get_anti_alias () const |
Get the font anti-alias setting (defaults to true) More... | |
bool | get_subpixel () const |
Get the font subpixel rendering setting (defaults to true) More... | |
Charset | get_charset () const |
Get the font charset More... | |
bool | operator== (const CL_FontDescription &other) const |
Returns true if the font is identical. More... | |
Font description class.
This class allows you to setup a more advanced description when creating a font.
CL_FontDescription::CL_FontDescription | ( | ) |
Constructs a font description with default values.
|
virtual |
void CL_FontDescription::clone | ( | const CL_FontDescription & | copy) |
|
static |
Create null object.
bool CL_FontDescription::get_anti_alias | ( | ) | const |
Get the font anti-alias setting (defaults to true)
int CL_FontDescription::get_average_width | ( | ) | const |
Returns the font average width.
Charset CL_FontDescription::get_charset | ( | ) | const |
Get the font charset
float CL_FontDescription::get_escapement | ( | ) | const |
Returns the font escapement.
bool CL_FontDescription::get_fixed_pitch | ( | ) | const |
Returns the font fixed pitch setting.
int CL_FontDescription::get_height | ( | ) | const |
Returns the font height.
bool CL_FontDescription::get_italic | ( | ) | const |
Returns the font italic setting.
float CL_FontDescription::get_orientation | ( | ) | const |
Returns the font orientation.
bool CL_FontDescription::get_strikeout | ( | ) | const |
Returns the font strikeout setting.
bool CL_FontDescription::get_subpixel | ( | ) | const |
Get the font subpixel rendering setting (defaults to true)
const CL_String& CL_FontDescription::get_typeface_name | ( | ) | const |
Returns the typeface name.
bool CL_FontDescription::get_underline | ( | ) | const |
Returns the font underline setting.
int CL_FontDescription::get_weight | ( | ) | const |
Returns the font weight.
|
inline |
Returns true if this object is invalid.
CL_FontDescription& CL_FontDescription::operator= | ( | const CL_FontDescription & | copy) |
Copy assignment operator.
bool CL_FontDescription::operator== | ( | const CL_FontDescription & | other) | const |
Returns true if the font is identical.
void CL_FontDescription::set_anti_alias | ( | bool | setting = true ) |
Sets the font anti-alias setting (defaults to true)
void CL_FontDescription::set_average_width | ( | int | value) |
Sets the font average width.
void CL_FontDescription::set_charset | ( | Charset | new_charset) |
Sets the font charset (defaults to charset_default)
new_charset | = The charset. charset_default = Use operating systems default |
void CL_FontDescription::set_escapement | ( | float | value) |
Sets the font escapement.
void CL_FontDescription::set_fixed_pitch | ( | bool | setting = true ) |
Sets the font fixed pitch setting.
void CL_FontDescription::set_height | ( | int | value) |
Sets the font height.
void CL_FontDescription::set_italic | ( | bool | setting = true ) |
Sets the font italic setting.
void CL_FontDescription::set_orientation | ( | float | value) |
Sets the font orientation.
void CL_FontDescription::set_strikeout | ( | bool | setting = true ) |
Sets the font strikeout setting.
void CL_FontDescription::set_subpixel | ( | bool | setting = true ) |
Sets the font subpixel rendering setting (defaults to true)
void CL_FontDescription::set_typeface_name | ( | const CL_String & | name) |
Sets the typeface name.
void CL_FontDescription::set_underline | ( | bool | setting = true ) |
Sets the font underline setting.
void CL_FontDescription::set_weight | ( | int | value) |
Sets the font weight.
void CL_FontDescription::throw_if_null | ( | ) | const |
Throw an exception if this object is invalid.