TextPropertiesManager

Inheritance:

Methods of TextPropertiesManager:

clearGraphic
void TextPropertiesManager::clear_graphic(string const &name);

Description: Removes the named TextGraphic structure from the manager.

clearProperties
void TextPropertiesManager::clear_properties(string const &name);

Description: Removes the named TextProperties structure from the manager.

getGlobalPtr
static TextPropertiesManager *TextPropertiesManager::get_global_ptr(void);

Description: Returns the pointer to the global TextPropertiesManager object.

getGraphic
TextGraphic TextPropertiesManager::get_graphic(string const &name);

Description: Returns the TextGraphic associated with the indicated name. If there was not previously a TextGraphic associated with this name, a warning is printed and then a default TextGraphic structure is associated with the name, and returned.
Call has_graphic() instead to check whether a particular name has been defined.

getProperties
TextProperties TextPropertiesManager::get_properties(string const &name);

Description: Returns the TextProperties associated with the indicated name. If there was not previously a TextProperties associated with this name, a warning is printed and then a default TextProperties structure is associated with the name, and returned.
Call has_properties() instead to check whether a particular name has been defined.

hasGraphic
bool TextPropertiesManager::has_graphic(string const &name) const;

Description: Returns true if a TextGraphic structure has been associated with the indicated name, false otherwise. Normally this means set_graphic() has been called with this name, but because get_graphic() will implicitly create a default TextGraphic structure, it may also mean simply that get_graphic() has been called with the indicated name.

hasProperties
bool TextPropertiesManager::has_properties(string const &name) const;

Description: Returns true if a TextProperties structure has been associated with the indicated name, false otherwise. Normally this means set_properties() has been called with this name, but because get_properties() will implicitly create a default TextProperties structure, it may also mean simply that get_properties() has been called with the indicated name.

setGraphic
void TextPropertiesManager::set_graphic(string const &name, TextGraphic const &graphic);

Description: Defines the TextGraphic associated with the indicated name. When the name is subsequently encountered in text embedded between \5 characters in a TextNode string, the specified graphic will be embedded in the text at that point.
If there was already a TextGraphic structure associated with this name, it is quietly replaced with the new definition.
Description: This flavor of set_graphic implicitly creates a frame for the model using the model's actual computed bounding volume, as derived from NodePath::calc_tight_bounds(). Create a TextGraphic object first if you want to have explicit control of the frame.

setProperties
void TextPropertiesManager::set_properties(string const &name, TextProperties const &properties);

Description: Defines the TextProperties associated with the indicated name. When the name is subsequently encountered in text embedded between \1 characters in a TextNode string, the following text will be rendered with these properties.
If there was already a TextProperties structure associated with this name, it is quietly replaced with the new definition.

write
void TextPropertiesManager::write(ostream &out, int indent_level = (0)) const;

Description: