Crazy Eddie's GUI System
0.8.4
|
Class that encapsulates information for a text component. More...
Public Member Functions | |
TextComponent (const TextComponent &obj) | |
TextComponent & | operator= (const TextComponent &other) |
const String & | getText () const |
Return the text set for this TextComponent. | |
String | getEffectiveText (const Window &wnd) const |
const String & | getTextVisual () const |
return text string with visual ordering of glyphs. | |
String | getEffectiveVisualText (const Window &wnd) const |
void | setText (const String &text) |
Set the text string for this TextComponent. | |
const String & | getFont () const |
Return the name of the font set to be used when rendering this TextComponent. | |
String | getEffectiveFont (const Window &wnd) const |
void | setFont (const String &font) |
Set the name of a font to be used when rendering this TextComponent. | |
VerticalTextFormatting | getVerticalFormatting (const Window &wnd) const |
Return the current vertical formatting setting for this TextComponent. | |
void | setVerticalFormatting (VerticalTextFormatting fmt) |
Set the vertical formatting setting for this TextComponent. | |
HorizontalTextFormatting | getHorizontalFormatting (const Window &wnd) const |
Return the current horizontal formatting setting for this TextComponent. | |
void | setHorizontalFormatting (HorizontalTextFormatting fmt) |
Set the horizontal formatting setting for this TextComponent. | |
void | setHorizontalFormattingPropertySource (const String &property_name) |
Set the name of a property that will be used to obtain the horizontal formatting to use for this ImageryComponent. | |
void | setVerticalFormattingPropertySource (const String &property_name) |
Set the name of a property that will be used to obtain the vertical formatting to use for this ImageryComponent. | |
void | writeXMLToStream (XMLSerializer &xml_stream) const |
Writes an xml representation of this TextComponent to out_stream. | |
bool | isTextFetchedFromProperty () const |
Return whether this TextComponent fetches it's text string via a property on the target window. | |
const String & | getTextPropertySource () const |
Return the name of the property that will be used to determine the text string to render for this TextComponent. | |
void | setTextPropertySource (const String &property) |
Set the name of the property that will be used to determine the text string to render for this TextComponent. | |
bool | isFontFetchedFromProperty () const |
Return whether this TextComponent fetches it's font via a property on the target window. | |
const String & | getFontPropertySource () const |
Return the name of the property that will be used to determine the font to use for rendering the text string for this TextComponent. | |
void | setFontPropertySource (const String &property) |
Set the name of the property that will be used to determine the font to use for rendering the text string of this TextComponent. | |
float | getHorizontalTextExtent (const Window &window) const |
return the horizontal pixel extent of the formatted rendered string. | |
float | getVerticalTextExtent (const Window &window) const |
return the vertical pixel extent of the formatted rendered string. | |
bool | handleFontRenderSizeChange (Window &window, const Font *font) const |
perform any processing required due to the given font having changed. | |
Protected Member Functions | |
void | render_impl (Window &srcWindow, Rectf &destRect, const CEGUI::ColourRect *modColours, const Rectf *clipper, bool clipToDisplay) const |
Function to do main render caching work. | |
void | setupStringFormatter (const Window &window, const RenderedString &rendered_string) const |
helper to set up an appropriate FormattedRenderedString | |
const Font * | getFontObject (const Window &window) const |
helper to get the font object to use |
Class that encapsulates information for a text component.
const String& CEGUI::TextComponent::getFont | ( | ) | const |
Return the name of the font set to be used when rendering this TextComponent.
const String& CEGUI::TextComponent::getFontPropertySource | ( | ) | const |
Return the name of the property that will be used to determine the font to use for rendering the text string for this TextComponent.
HorizontalTextFormatting CEGUI::TextComponent::getHorizontalFormatting | ( | const Window & | wnd | ) | const |
Return the current horizontal formatting setting for this TextComponent.
const String& CEGUI::TextComponent::getText | ( | ) | const |
Return the text set for this TextComponent.
const String& CEGUI::TextComponent::getTextPropertySource | ( | ) | const |
Return the name of the property that will be used to determine the text string to render for this TextComponent.
const String& CEGUI::TextComponent::getTextVisual | ( | ) | const |
return text string with visual ordering of glyphs.
VerticalTextFormatting CEGUI::TextComponent::getVerticalFormatting | ( | const Window & | wnd | ) | const |
Return the current vertical formatting setting for this TextComponent.
bool CEGUI::TextComponent::isFontFetchedFromProperty | ( | ) | const |
Return whether this TextComponent fetches it's font via a property on the target window.
bool CEGUI::TextComponent::isTextFetchedFromProperty | ( | ) | const |
Return whether this TextComponent fetches it's text string via a property on the target window.
void CEGUI::TextComponent::setFont | ( | const String & | font | ) |
Set the name of a font to be used when rendering this TextComponent.
font | String containing name of a font |
void CEGUI::TextComponent::setFontPropertySource | ( | const String & | property | ) |
Set the name of the property that will be used to determine the font to use for rendering the text string of this TextComponent.
property | String object holding the name of a Propery. The property should access a valid font name. |
Set the horizontal formatting setting for this TextComponent.
fmt | One of the HorizontalTextFormatting enumerated values. |
void CEGUI::TextComponent::setText | ( | const String & | text | ) |
Set the text string for this TextComponent.
text | String containing text to set on the TextComponent. |
void CEGUI::TextComponent::setTextPropertySource | ( | const String & | property | ) |
Set the name of the property that will be used to determine the text string to render for this TextComponent.
property | String object holding the name of a Propery. The property can contain any text string to render. |
Set the vertical formatting setting for this TextComponent.
fmt | One of the VerticalTextFormatting enumerated values. |
void CEGUI::TextComponent::writeXMLToStream | ( | XMLSerializer & | xml_stream | ) | const |
Writes an xml representation of this TextComponent to out_stream.
xml_stream | Stream where xml data should be output. |