Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

TextNode Class Reference

#include <textNode.h>

Inheritance diagram for TextNode:

PandaNode TextEncoder TypedWritable Namable BoundedObject ReferenceCount TypedObject List of all members.

Public Member Functions

INLINE void set_wtext (const wstring &wtext)
INLINE void append_wtext (const wstring &text)
INLINE float calc_width (const wstring &line) const
INLINE wstring wordwrap_to (const wstring &wtext, float wordwrap_width, bool preserve_trailing_whitespace) const
virtual int get_unsafe_to_apply_attribs () const
virtual void apply_attribs_to_vertices (const AccumulatedAttribs &attribs, int attrib_types, GeomTransformer &transformer)
virtual CPT (TransformState) calc_tight_bounds(LPoint3f &min_point
virtual bool has_cull_callback () const
virtual bool cull_callback (CullTraverser *trav, CullTraverserData &data)
virtual BoundingVolumerecompute_internal_bound ()
virtual TypeHandle get_type () const
virtual TypeHandle force_init_type ()

Static Public Member Functions

TypeHandle get_class_type ()
void init_type ()

Public Attributes

virtual LPoint3f & max_point
virtual LPoint3f bool & found_any
virtual LPoint3f bool const
TransformState *transform 
const

Private Types

enum  Alignment { A_left, A_right, A_center }
enum  CheesyPlacement {
  CP_above, CP_below, CP_top, CP_bottom,
  CP_within
}
enum  CheesyTransform {
  CT_none, CT_mirror_x, CT_mirror_y, CT_rotate_90,
  CT_rotate_180, CT_rotate_270, CT_squash, CT_squash_mirror_y,
  CT_squash_mirror_diag, CT_small_squash, CT_small_squash_mirror_y, CT_small,
  CT_small_rotate_270, CT_tiny, CT_tiny_mirror_x, CT_tiny_rotate_270
}
enum  Flags {
  F_has_text_color = 0x00000001, F_has_wordwrap = 0x00000002, F_has_frame = 0x00000004, F_frame_as_margin = 0x00000008,
  F_has_card = 0x00000010, F_card_as_margin = 0x00000020, F_has_card_texture = 0x00000040, F_has_shadow = 0x00000080,
  F_frame_corners = 0x00000100, F_card_transp = 0x00000200, F_has_card_border = 0x00000400, F_needs_rebuild = 0x00004000,
  F_needs_measure = 0x00008000, F_small_caps = 0x00010000
}

Private Member Functions

 ~TextNode ()
INLINE int freeze ()
INLINE int thaw ()
INLINE void set_font (TextFont *font)
INLINE TextFontget_font () const
INLINE float get_line_height () const
INLINE void set_small_caps (bool small_caps)
INLINE bool get_small_caps () const
INLINE void set_small_caps_scale (float small_caps_scale)
INLINE float get_small_caps_scale () const
INLINE void set_slant (float slant)
INLINE float get_slant () const
INLINE void set_align (Alignment align_type)
INLINE Alignment get_align () const
INLINE void set_wordwrap (float width)
INLINE void clear_wordwrap ()
INLINE bool has_wordwrap () const
INLINE float get_wordwrap () const
INLINE void set_text_color (float r, float g, float b, float a)
INLINE void set_text_color (const Colorf &text_color)
INLINE void clear_text_color ()
INLINE bool has_text_color () const
INLINE Colorf get_text_color () const
INLINE void set_frame_color (float r, float g, float b, float a)
INLINE void set_frame_color (const Colorf &frame_color)
INLINE Colorf get_frame_color () const
INLINE void set_card_border (float size, float uv_portion)
INLINE void clear_card_border ()
INLINE float get_card_border_size () const
INLINE float get_card_border_uv_portion () const
INLINE bool has_card_border () const
INLINE void set_card_color (float r, float g, float b, float a)
INLINE void set_card_color (const Colorf &card_color)
INLINE Colorf get_card_color () const
INLINE void set_card_texture (Texture *card_texture)
INLINE void clear_card_texture ()
INLINE bool has_card_texture () const
INLINE Textureget_card_texture () const
INLINE void set_shadow_color (float r, float g, float b, float a)
INLINE void set_shadow_color (const Colorf &shadow_color)
INLINE Colorf get_shadow_color () const
INLINE void set_frame_as_margin (float left, float right, float bottom, float top)
INLINE void set_frame_actual (float left, float right, float bottom, float top)
INLINE void clear_frame ()
INLINE bool has_frame () const
INLINE bool is_frame_as_margin () const
INLINE LVecBase4f get_frame_as_set () const
INLINE LVecBase4f get_frame_actual () const
INLINE void set_frame_line_width (float line_width)
INLINE float get_frame_line_width () const
INLINE void set_frame_corners (bool corners)
INLINE bool get_frame_corners () const
INLINE void set_card_as_margin (float left, float right, float bottom, float top)
INLINE void set_card_actual (float left, float right, float bottom, float top)
INLINE void clear_card ()
INLINE bool has_card () const
INLINE bool is_card_as_margin () const
INLINE LVecBase4f get_card_as_set () const
INLINE LVecBase4f get_card_actual () const
INLINE LVecBase4f get_card_transformed () const
INLINE void set_shadow (float xoffset, float yoffset)
INLINE void clear_shadow ()
INLINE bool has_shadow () const
INLINE LVecBase2f get_shadow () const
INLINE void set_bin (const string &bin)
INLINE void clear_bin ()
INLINE bool has_bin () const
INLINE const string & get_bin () const
INLINE int set_draw_order (int draw_order)
INLINE int get_draw_order () const
INLINE void set_transform (const LMatrix4f &transform)
INLINE LMatrix4f get_transform () const
INLINE void set_coordinate_system (CoordinateSystem cs)
INLINE CoordinateSystem get_coordinate_system () const
INLINE void set_text (const string &text)
INLINE void set_text (const string &text, Encoding encoding)
INLINE void clear_text ()
INLINE void append_text (const string &text)
INLINE void append_unicode_char (int character)
INLINE float calc_width (int character) const
INLINE float calc_width (const string &line) const
string wordwrap_to (const string &text, float wordwrap_width, bool preserve_trailing_whitespace) const
virtual void write (ostream &out, int indent_level=0) const
INLINE float get_left () const
INLINE float get_right () const
INLINE float get_bottom () const
INLINE float get_top () const
INLINE float get_height () const
INLINE float get_width () const
INLINE LPoint3f get_upper_left_3d () const
INLINE LPoint3f get_lower_right_3d () const
INLINE int get_num_rows () const
 PT (PandaNode) generate()
INLINE void update ()
INLINE void force_update ()
INLINE void invalidate_no_measure ()
INLINE void invalidate_with_measure ()
INLINE void check_rebuild () const
INLINE void check_measure () const
void do_rebuild ()
void do_measure ()
float assemble_row (wstring::iterator &si, const wstring::iterator &send, TextFont *font, GeomNode *dest, const LMatrix4f &mat)
void measure_text (wstring::iterator si, const wstring::iterator &send, TextFont *font, LVector2f &ul, LVector2f &lr, int &num_rows)
void get_character_glyphs (int character, TextFont *font, bool &got_glyph, const TextGlyph *&glyph, const TextGlyph *&second_glyph, UnicodeLatinMap::AccentType &accent_type, int &additional_flags, float &glyph_scale, float &advance_scale)
void tack_on_accent (UnicodeLatinMap::AccentType accent_type, const LPoint3f &min_vert, const LPoint3f &max_vert, const LPoint3f &centroid, TextFont *font, GeomNode *dest, Geom *geom_array[], int &num_geoms)
bool tack_on_accent (char accent_mark, CheesyPlacement placement, CheesyTransform transform, const LPoint3f &min_vert, const LPoint3f &max_vert, const LPoint3f &centroid, TextFont *font, GeomNode *dest, Geom *geom_array[], int &num_geoms)
 PT (PandaNode) make_frame()
 PT (PandaNode) make_card()
 PT (PandaNode) make_card_with_border()
 PT (TextFont) _font
 PT (PandaNode) _internal_geom
 PT (Texture) _card_texture

Static Private Member Functions

INLINE void set_default_font (TextFont *)
INLINE TextFontget_default_font ()
void load_default_font ()
 PT (TextFont) _default_font

Private Attributes

PUBLISHED __pad0__: TextNode(const string &name)
PT(PandaNode) assemble_text(wstring floa measure_row )(wstring::iterator &si, const wstring::iterator &send, TextFont *font)
float _slant
Colorf _text_color
Colorf _shadow_color
Colorf _frame_color
Colorf _card_color
int _flags
Alignment _align
float _wordwrap_width
float _frame_width
float _card_border_size
float _card_border_uv_portion
float _small_caps_scale
LVector2f _frame_ul
LVector2f _frame_lr
LVector2f _card_ul
LVector2f _card_lr
LVector2f _shadow_offset
string _bin
int _draw_order
LMatrix4f _transform
CoordinateSystem _coordinate_system
LPoint2f _ul2d
LPoint2f _lr2d
LPoint3f _ul3d
LPoint3f _lr3d
int _num_rows

Static Private Attributes

bool _loaded_default_font
TypeHandle _type_handle

Member Enumeration Documentation

enum TextNode::Alignment [private]
 

Enumeration values:
A_left 
A_right 
A_center 

Definition at line 61 of file textNode.h.

enum TextNode::CheesyPlacement [private]
 

Enumeration values:
CP_above 
CP_below 
CP_top 
CP_bottom 
CP_within 

Definition at line 248 of file textNode.h.

enum TextNode::CheesyTransform [private]
 

Enumeration values:
CT_none 
CT_mirror_x 
CT_mirror_y 
CT_rotate_90 
CT_rotate_180 
CT_rotate_270 
CT_squash 
CT_squash_mirror_y 
CT_squash_mirror_diag 
CT_small_squash 
CT_small_squash_mirror_y 
CT_small 
CT_small_rotate_270 
CT_tiny 
CT_tiny_mirror_x 
CT_tiny_rotate_270 

Definition at line 255 of file textNode.h.

enum TextNode::Flags [private]
 

Enumeration values:
F_has_text_color 
F_has_wordwrap 
F_has_frame 
F_frame_as_margin 
F_has_card 
F_card_as_margin 
F_has_card_texture 
F_has_shadow 
F_frame_corners 
F_card_transp 
F_has_card_border 
F_needs_rebuild 
F_needs_measure 
F_small_caps 

Reimplemented from TextEncoder.

Definition at line 310 of file textNode.h.


Constructor & Destructor Documentation

TextNode::~TextNode  )  [private]
 

Definition at line 126 of file textNode.cxx.


Member Function Documentation

INLINE void TextNode::append_text const string &  text  )  [private]
 

Reimplemented from TextEncoder.

INLINE void TextNode::append_unicode_char int  character  )  [private]
 

Reimplemented from TextEncoder.

INLINE void TextNode::append_wtext const wstring &  text  ) 
 

Reimplemented from TextEncoder.

void TextNode::apply_attribs_to_vertices const AccumulatedAttribs attribs,
int  attrib_types,
GeomTransformer transformer
[virtual]
 

Reimplemented from PandaNode.

Definition at line 455 of file textNode.cxx.

References _card_color, _flags, _frame_color, _lr3d, _shadow_color, _text_color, _transform, _ul3d, SceneGraphReducer::apply_attribs(), c, Colorf, DCAST, F_has_text_color, F_needs_measure, F_needs_rebuild, ColorAttrib::get_color(), ColorAttrib::get_color_type(), ColorScaleAttrib::get_scale(), NULL, s, ColorAttrib::T_flat, SceneGraphReducer::TT_color, SceneGraphReducer::TT_color_scale, and SceneGraphReducer::TT_transform.

float TextNode::assemble_row wstring::iterator &  si,
const wstring::iterator &  send,
TextFont font,
GeomNode dest,
const LMatrix4f &  mat
[private]
 

Definition at line 706 of file textNode.cxx.

References UnicodeLatinMap::AccentType, GeomNode::add_geom(), UnicodeLatinMap::AF_turned, UnicodeLatinMap::AT_none, Geom::calc_tight_bounds(), found_any, TextGlyph::get_advance(), get_character_glyphs(), TextFont::get_space_advance(), TextGlyph::get_state(), NULL, PT(), tack_on_accent(), and Geom::transform_vertices().

INLINE float TextNode::calc_width const wstring &  line  )  const
 

INLINE float TextNode::calc_width const string &  line  )  const [private]
 

INLINE float TextNode::calc_width int  character  )  const [private]
 

Referenced by PGEntry::keystroke(), PGEntry::press(), and PGEntry::update_cursor().

INLINE void TextNode::check_measure  )  const [private]
 

Referenced by recompute_internal_bound().

INLINE void TextNode::check_rebuild  )  const [private]
 

Referenced by cull_callback().

INLINE void TextNode::clear_bin  )  [private]
 

INLINE void TextNode::clear_card  )  [private]
 

INLINE void TextNode::clear_card_border  )  [private]
 

INLINE void TextNode::clear_card_texture  )  [private]
 

INLINE void TextNode::clear_frame  )  [private]
 

INLINE void TextNode::clear_shadow  )  [private]
 

INLINE void TextNode::clear_text  )  [private]
 

Reimplemented from TextEncoder.

INLINE void TextNode::clear_text_color  )  [private]
 

INLINE void TextNode::clear_wordwrap  )  [private]
 

virtual TextNode::CPT TransformState   )  [virtual]
 

Reimplemented from PandaNode.

Referenced by tack_on_accent().

bool TextNode::cull_callback CullTraverser trav,
CullTraverserData data
[virtual]
 

Reimplemented from PandaNode.

Definition at line 582 of file textNode.cxx.

References check_rebuild(), data, NULL, and CullTraverser::traverse().

void TextNode::do_measure  )  [private]
 

Definition at line 651 of file textNode.cxx.

References _flags, _lr2d, _lr3d, _num_rows, _transform, _ul2d, _ul3d, _wordwrap_width, F_needs_measure, get_default_font(), get_font(), TextEncoder::get_wtext(), TextEncoder::has_text(), has_wordwrap(), measure_text(), NULL, and TextFont::wordwrap_to().

void TextNode::do_rebuild  )  [private]
 

Definition at line 637 of file textNode.cxx.

References _flags, F_needs_measure, and F_needs_rebuild.

virtual TypeHandle TextNode::force_init_type void   )  [inline, virtual]
 

Reimplemented from PandaNode.

Definition at line 365 of file textNode.h.

References PandaNode::get_class_type(), and PandaNode::init_type().

INLINE void TextNode::force_update  )  [private]
 

INLINE int TextNode::freeze  )  [private]
 

INLINE Alignment TextNode::get_align  )  const [private]
 

Referenced by PGEntry::setup(), and PGEntry::update_text().

INLINE const string& TextNode::get_bin  )  const [private]
 

INLINE float TextNode::get_bottom  )  const [private]
 

INLINE LVecBase4f TextNode::get_card_actual  )  const [private]
 

Referenced by PGButton::setup(), and write().

INLINE LVecBase4f TextNode::get_card_as_set  )  const [private]
 

Referenced by write().

INLINE float TextNode::get_card_border_size  )  const [private]
 

INLINE float TextNode::get_card_border_uv_portion  )  const [private]
 

INLINE Colorf TextNode::get_card_color  )  const [private]
 

INLINE Texture* TextNode::get_card_texture  )  const [private]
 

INLINE LVecBase4f TextNode::get_card_transformed  )  const [private]
 

void TextNode::get_character_glyphs int  character,
TextFont font,
bool &  got_glyph,
const TextGlyph *&  glyph,
const TextGlyph *&  second_glyph,
UnicodeLatinMap::AccentType accent_type,
int &  additional_flags,
float &  glyph_scale,
float &  advance_scale
[private]
 

Definition at line 1008 of file textNode.cxx.

References UnicodeLatinMap::Entry::_accent_type, UnicodeLatinMap::Entry::_additional_flags, UnicodeLatinMap::Entry::_ascii_additional, UnicodeLatinMap::Entry::_ascii_equiv, UnicodeLatinMap::Entry::_toupper_character, UnicodeLatinMap::AF_ligature, UnicodeLatinMap::AF_smallcap, UnicodeLatinMap::AT_none, TextFont::get_glyph(), get_small_caps(), get_small_caps_scale(), ligature_advance_scale, UnicodeLatinMap::look_up(), and NULL.

Referenced by assemble_row().

TypeHandle TextNode::get_class_type void   )  [inline, static]
 

Reimplemented from TextEncoder.

Definition at line 353 of file textNode.h.

INLINE CoordinateSystem TextNode::get_coordinate_system  )  const [private]
 

INLINE TextFont* TextNode::get_default_font  )  [static, private]
 

Referenced by do_measure().

INLINE int TextNode::get_draw_order  )  const [private]
 

INLINE TextFont* TextNode::get_font  )  const [private]
 

Referenced by do_measure().

INLINE LVecBase4f TextNode::get_frame_actual  )  const [private]
 

Referenced by write().

INLINE LVecBase4f TextNode::get_frame_as_set  )  const [private]
 

Referenced by write().

INLINE Colorf TextNode::get_frame_color  )  const [private]
 

INLINE bool TextNode::get_frame_corners  )  const [private]
 

Referenced by write().

INLINE float TextNode::get_frame_line_width  )  const [private]
 

INLINE float TextNode::get_height  )  const [private]
 

INLINE float TextNode::get_left  )  const [private]
 

Referenced by PGEntry::update_text().

INLINE float TextNode::get_line_height  )  const [private]
 

Referenced by PGEntry::setup(), and PGEntry::update_cursor().

INLINE LPoint3f TextNode::get_lower_right_3d  )  const [private]
 

INLINE int TextNode::get_num_rows  )  const [private]
 

INLINE float TextNode::get_right  )  const [private]
 

INLINE LVecBase2f TextNode::get_shadow  )  const [private]
 

INLINE Colorf TextNode::get_shadow_color  )  const [private]
 

INLINE float TextNode::get_slant  )  const [private]
 

INLINE bool TextNode::get_small_caps  )  const [private]
 

Referenced by get_character_glyphs().

INLINE float TextNode::get_small_caps_scale  )  const [private]
 

Referenced by get_character_glyphs().

INLINE Colorf TextNode::get_text_color  )  const [private]
 

INLINE float TextNode::get_top  )  const [private]
 

INLINE LMatrix4f TextNode::get_transform  )  const [private]
 

Reimplemented from PandaNode.

Referenced by PGEntry::setup().

virtual TypeHandle TextNode::get_type void   )  const [inline, virtual]
 

Reimplemented from PandaNode.

Definition at line 362 of file textNode.h.

References PandaNode::get_class_type().

int TextNode::get_unsafe_to_apply_attribs  )  const [virtual]
 

Reimplemented from PandaNode.

Definition at line 433 of file textNode.cxx.

References SceneGraphReducer::TT_other, and SceneGraphReducer::TT_tex_matrix.

INLINE LPoint3f TextNode::get_upper_left_3d  )  const [private]
 

INLINE float TextNode::get_width  )  const [private]
 

INLINE float TextNode::get_wordwrap  )  const [private]
 

INLINE bool TextNode::has_bin  )  const [private]
 

Referenced by write().

INLINE bool TextNode::has_card  )  const [private]
 

Referenced by write().

INLINE bool TextNode::has_card_border  )  const [private]
 

INLINE bool TextNode::has_card_texture  )  const [private]
 

bool TextNode::has_cull_callback  )  const [virtual]
 

Reimplemented from PandaNode.

Definition at line 558 of file textNode.cxx.

INLINE bool TextNode::has_frame  )  const [private]
 

Referenced by write().

INLINE bool TextNode::has_shadow  )  const [private]
 

Referenced by write().

INLINE bool TextNode::has_text_color  )  const [private]
 

Referenced by write().

INLINE bool TextNode::has_wordwrap  )  const [private]
 

Referenced by do_measure(), and write().

void TextNode::init_type void   )  [inline, static]
 

Reimplemented from TextEncoder.

Definition at line 356 of file textNode.h.

References TextEncoder::get_class_type(), PandaNode::get_class_type(), PandaNode::init_type(), and register_type().

Referenced by init_libtext().

INLINE void TextNode::invalidate_no_measure  )  [private]
 

INLINE void TextNode::invalidate_with_measure  )  [private]
 

INLINE bool TextNode::is_card_as_margin  )  const [private]
 

Referenced by write().

INLINE bool TextNode::is_frame_as_margin  )  const [private]
 

Referenced by write().

void TextNode::load_default_font  )  [static, private]
 

Definition at line 1699 of file textNode.cxx.

References _loaded_default_font, FontPool::load_font(), and text_default_font.

void TextNode::measure_text wstring::iterator  si,
const wstring::iterator &  send,
TextFont font,
LVector2f &  ul,
LVector2f &  lr,
int &  num_rows
[private]
 

Definition at line 953 of file textNode.cxx.

References _align, A_left, A_right, TextFont::get_line_height(), and measure_row.

Referenced by do_measure().

TextNode::PT TextFont   )  [static, private]
 

TextNode::PT Texture   )  [private]
 

TextNode::PT PandaNode   )  [private]
 

TextNode::PT TextFont   )  [private]
 

TextNode::PT PandaNode   )  [private]
 

TextNode::PT PandaNode   )  [private]
 

TextNode::PT PandaNode   )  [private]
 

TextNode::PT PandaNode   )  [private]
 

Referenced by assemble_row(), and tack_on_accent().

BoundingVolume * TextNode::recompute_internal_bound  )  [virtual]
 

Reimplemented from PandaNode.

Definition at line 603 of file textNode.cxx.

References _lr3d, _ul3d, GeometricBoundingVolume::around(), check_measure(), DCAST, NULL, and PandaNode::recompute_internal_bound().

INLINE void TextNode::set_align Alignment  align_type  )  [private]
 

INLINE void TextNode::set_bin const string &  bin  )  [private]
 

INLINE void TextNode::set_card_actual float  left,
float  right,
float  bottom,
float  top
[private]
 

INLINE void TextNode::set_card_as_margin float  left,
float  right,
float  bottom,
float  top
[private]
 

INLINE void TextNode::set_card_border float  size,
float  uv_portion
[private]
 

INLINE void TextNode::set_card_color const Colorf card_color  )  [private]
 

INLINE void TextNode::set_card_color float  r,
float  g,
float  b,
float  a
[private]
 

INLINE void TextNode::set_card_texture Texture card_texture  )  [private]
 

INLINE void TextNode::set_coordinate_system CoordinateSystem  cs  )  [private]
 

INLINE void TextNode::set_default_font TextFont  )  [static, private]
 

INLINE int TextNode::set_draw_order int  draw_order  )  [private]
 

INLINE void TextNode::set_font TextFont font  )  [private]
 

INLINE void TextNode::set_frame_actual float  left,
float  right,
float  bottom,
float  top
[private]
 

INLINE void TextNode::set_frame_as_margin float  left,
float  right,
float  bottom,
float  top
[private]
 

INLINE void TextNode::set_frame_color const Colorf frame_color  )  [private]
 

INLINE void TextNode::set_frame_color float  r,
float  g,
float  b,
float  a
[private]
 

INLINE void TextNode::set_frame_corners bool  corners  )  [private]
 

INLINE void TextNode::set_frame_line_width float  line_width  )  [private]
 

INLINE void TextNode::set_shadow float  xoffset,
float  yoffset
[private]
 

INLINE void TextNode::set_shadow_color const Colorf shadow_color  )  [private]
 

INLINE void TextNode::set_shadow_color float  r,
float  g,
float  b,
float  a
[private]
 

INLINE void TextNode::set_slant float  slant  )  [private]
 

INLINE void TextNode::set_small_caps bool  small_caps  )  [private]
 

INLINE void TextNode::set_small_caps_scale float  small_caps_scale  )  [private]
 

INLINE void TextNode::set_text const string &  text,
Encoding  encoding
[private]
 

Reimplemented from TextEncoder.

INLINE void TextNode::set_text const string &  text  )  [private]
 

Reimplemented from TextEncoder.

Referenced by PGButton::setup().

INLINE void TextNode::set_text_color const Colorf text_color  )  [private]
 

INLINE void TextNode::set_text_color float  r,
float  g,
float  b,
float  a
[private]
 

INLINE void TextNode::set_transform const LMatrix4f &  transform  )  [private]
 

INLINE void TextNode::set_wordwrap float  width  )  [private]
 

INLINE void TextNode::set_wtext const wstring &  wtext  ) 
 

Reimplemented from TextEncoder.

Referenced by PGEntry::update_text().

bool TextNode::tack_on_accent char  accent_mark,
CheesyPlacement  placement,
CheesyTransform  transform,
const LPoint3f &  min_vert,
const LPoint3f &  max_vert,
const LPoint3f &  centroid,
TextFont font,
GeomNode dest,
Geom geom_array[],
int &  num_geoms
[private]
 

Definition at line 1231 of file textNode.cxx.

References GeomNode::add_geom(), CP_above, CP_below, CP_bottom, CP_top, CP_within, CPT(), CT_mirror_x, CT_mirror_y, CT_none, CT_rotate_180, CT_rotate_270, CT_rotate_90, CT_small, CT_small_rotate_270, CT_small_squash, CT_small_squash_mirror_y, CT_squash, CT_squash_mirror_diag, CT_squash_mirror_y, CT_tiny, CT_tiny_mirror_x, CT_tiny_rotate_270, found_any, TextFont::get_glyph(), TextGlyph::get_state(), NULL, PT(), small_accent_scale, small_squash_accent_scale_x, small_squash_accent_scale_y, squash_accent_scale_x, squash_accent_scale_y, t, and tiny_accent_scale.

void TextNode::tack_on_accent UnicodeLatinMap::AccentType  accent_type,
const LPoint3f &  min_vert,
const LPoint3f &  max_vert,
const LPoint3f &  centroid,
TextFont font,
GeomNode dest,
Geom geom_array[],
int &  num_geoms
[private]
 

Definition at line 1086 of file textNode.cxx.

References UnicodeLatinMap::AT_acute, UnicodeLatinMap::AT_breve, UnicodeLatinMap::AT_caron, UnicodeLatinMap::AT_cedilla, UnicodeLatinMap::AT_circumflex, UnicodeLatinMap::AT_circumflex_below, UnicodeLatinMap::AT_comma_below, UnicodeLatinMap::AT_diaeresis, UnicodeLatinMap::AT_diaeresis_below, UnicodeLatinMap::AT_dot_above, UnicodeLatinMap::AT_dot_below, UnicodeLatinMap::AT_grave, UnicodeLatinMap::AT_inverted_breve, UnicodeLatinMap::AT_line_below, UnicodeLatinMap::AT_macron, UnicodeLatinMap::AT_ogonek, UnicodeLatinMap::AT_ring_above, UnicodeLatinMap::AT_ring_below, UnicodeLatinMap::AT_stroke, UnicodeLatinMap::AT_tilde, UnicodeLatinMap::AT_tilde_below, CP_above, CP_below, CP_bottom, CP_top, CP_within, CT_mirror_x, CT_mirror_y, CT_none, CT_small_rotate_270, CT_small_squash, CT_small_squash_mirror_y, CT_squash, CT_squash_mirror_diag, CT_squash_mirror_y, CT_tiny, CT_tiny_mirror_x, and CT_tiny_rotate_270.

Referenced by assemble_row().

INLINE int TextNode::thaw  )  [private]
 

INLINE void TextNode::update  )  [private]
 

INLINE wstring TextNode::wordwrap_to const wstring &  wtext,
float  wordwrap_width,
bool  preserve_trailing_whitespace
const
 

string TextNode::wordwrap_to const string &  text,
float  wordwrap_width,
bool  preserve_trailing_whitespace
const [private]
 

Definition at line 139 of file textNode.cxx.

References TextEncoder::decode_text(), TextEncoder::encode_wtext(), and NULL.

Referenced by PGEntry::keystroke(), PGEntry::press(), and PGEntry::update_text().

void TextNode::write ostream &  out,
int  indent_level = 0
const [private, virtual]
 

Reimplemented from PandaNode.

Definition at line 155 of file textNode.cxx.

References _bin, _card_color, _coordinate_system, _draw_order, _frame_color, _frame_width, _shadow_color, _shadow_offset, _text_color, _transform, _wordwrap_width, A_center, A_left, A_right, decompose_matrix(), get_card_actual(), get_card_as_set(), get_frame_actual(), get_frame_as_set(), get_frame_corners(), Namable::get_name(), TextEncoder::get_text(), has_bin(), has_card(), has_frame(), has_shadow(), has_text_color(), has_wordwrap(), indent(), is_card_as_margin(), is_frame_as_margin(), NULL, and scale.


Member Data Documentation

PUBLISHED TextNode::__pad0__ [private]
 

Reimplemented from TextEncoder.

Definition at line 58 of file textNode.h.

Alignment TextNode::_align [private]
 

Definition at line 328 of file textNode.h.

Referenced by measure_text().

string TextNode::_bin [private]
 

Definition at line 339 of file textNode.h.

Referenced by write().

float TextNode::_card_border_size [private]
 

Definition at line 331 of file textNode.h.

float TextNode::_card_border_uv_portion [private]
 

Definition at line 332 of file textNode.h.

Colorf TextNode::_card_color [private]
 

Definition at line 308 of file textNode.h.

Referenced by apply_attribs_to_vertices(), and write().

LVector2f TextNode::_card_lr [private]
 

Definition at line 336 of file textNode.h.

LVector2f TextNode::_card_ul [private]
 

Definition at line 336 of file textNode.h.

CoordinateSystem TextNode::_coordinate_system [private]
 

Definition at line 343 of file textNode.h.

Referenced by write().

int TextNode::_draw_order [private]
 

Definition at line 340 of file textNode.h.

Referenced by write().

int TextNode::_flags [private]
 

Reimplemented from TextEncoder.

Definition at line 327 of file textNode.h.

Referenced by apply_attribs_to_vertices(), do_measure(), and do_rebuild().

Colorf TextNode::_frame_color [private]
 

Definition at line 307 of file textNode.h.

Referenced by apply_attribs_to_vertices(), and write().

LVector2f TextNode::_frame_lr [private]
 

Definition at line 335 of file textNode.h.

LVector2f TextNode::_frame_ul [private]
 

Definition at line 335 of file textNode.h.

float TextNode::_frame_width [private]
 

Definition at line 330 of file textNode.h.

Referenced by write().

bool TextNode::_loaded_default_font [static, private]
 

Definition at line 350 of file textNode.h.

Referenced by load_default_font().

LPoint2f TextNode::_lr2d [private]
 

Definition at line 345 of file textNode.h.

Referenced by do_measure().

LPoint3f TextNode::_lr3d [private]
 

Definition at line 346 of file textNode.h.

Referenced by apply_attribs_to_vertices(), do_measure(), and recompute_internal_bound().

int TextNode::_num_rows [private]
 

Definition at line 347 of file textNode.h.

Referenced by do_measure().

Colorf TextNode::_shadow_color [private]
 

Definition at line 306 of file textNode.h.

Referenced by apply_attribs_to_vertices(), and write().

LVector2f TextNode::_shadow_offset [private]
 

Definition at line 337 of file textNode.h.

Referenced by write().

float TextNode::_slant [private]
 

Definition at line 302 of file textNode.h.

float TextNode::_small_caps_scale [private]
 

Definition at line 333 of file textNode.h.

Colorf TextNode::_text_color [private]
 

Definition at line 305 of file textNode.h.

Referenced by apply_attribs_to_vertices(), and write().

LMatrix4f TextNode::_transform [private]
 

Definition at line 342 of file textNode.h.

Referenced by apply_attribs_to_vertices(), do_measure(), and write().

TypeHandle TextNode::_type_handle [static, private]
 

Reimplemented from TextEncoder.

Definition at line 54 of file textNode.cxx.

LPoint2f TextNode::_ul2d [private]
 

Definition at line 345 of file textNode.h.

Referenced by do_measure().

LPoint3f TextNode::_ul3d [private]
 

Definition at line 346 of file textNode.h.

Referenced by apply_attribs_to_vertices(), do_measure(), and recompute_internal_bound().

float TextNode::_wordwrap_width [private]
 

Definition at line 329 of file textNode.h.

Referenced by do_measure(), and write().

virtual LPoint3f bool const TransformState* transform TextNode::const
 

Reimplemented from PandaNode.

Definition at line 217 of file textNode.h.

virtual LPoint3f bool& TextNode::found_any
 

Reimplemented from PandaNode.

Definition at line 217 of file textNode.h.

Referenced by assemble_row(), and tack_on_accent().

virtual LPoint3f& TextNode::max_point
 

Reimplemented from PandaNode.

Definition at line 217 of file textNode.h.

float TextNode::measure_row [private]
 

Definition at line 906 of file textNode.cxx.

Referenced by measure_text().


The documentation for this class was generated from the following files:
Generated on Fri Apr 18 00:13:40 2003 for Panda by doxygen1.3