mirror of
https://github.com/Sneed-Group/Poodletooth-iLand
synced 2024-12-25 20:52:26 -06:00
7439 lines
389 KiB
Text
7439 lines
389 KiB
Text
1412103361
|
|
2 2
|
|
9 libp3text 4 z_GL 12 panda3d.core
|
|
341
|
|
363 29 upcast_to_TypedReferenceCount 0 12 704 39 TextFont::upcast_to_TypedReferenceCount 0 1 10 43
|
|
upcast from TextFont to TypedReferenceCount
|
|
67
|
|
TypedReferenceCount *TextFont::upcast_to_TypedReferenceCount(void);
|
|
|
|
364 20 downcast_to_TextFont 0 12 705 41 TypedReferenceCount::downcast_to_TextFont 0 1 11 45
|
|
downcast from TypedReferenceCount to TextFont
|
|
58
|
|
TextFont *TypedReferenceCount::downcast_to_TextFont(void);
|
|
|
|
365 17 upcast_to_Namable 0 12 704 27 TextFont::upcast_to_Namable 0 1 12 31
|
|
upcast from TextFont to Namable
|
|
43
|
|
Namable *TextFont::upcast_to_Namable(void);
|
|
|
|
366 20 downcast_to_TextFont 0 12 706 29 Namable::downcast_to_TextFont 0 1 13 33
|
|
downcast from Namable to TextFont
|
|
46
|
|
TextFont *Namable::downcast_to_TextFont(void);
|
|
|
|
367 9 ~TextFont 0 6 704 19 TextFont::~TextFont 0 0 228
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::Destructor
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
34
|
|
virtual TextFont::~TextFont(void);
|
|
|
|
368 9 make_copy 0 6 704 19 TextFont::make_copy 0 1 1 0
|
|
66
|
|
virtual PointerTo< TextFont > TextFont::make_copy(void) const = 0;
|
|
|
|
369 8 is_valid 0 4 704 18 TextFont::is_valid 0 1 2 787
|
|
// Filename: textFont.I
|
|
// Created by: drose (08Feb02)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::is_valid
|
|
// Access: Published
|
|
// Description: Returns true if the font is valid and ready to use,
|
|
// false otherwise.
|
|
////////////////////////////////////////////////////////////////////
|
|
43
|
|
inline bool TextFont::is_valid(void) const;
|
|
|
|
370 22 operator typecast bool 0 132 704 32 TextFont::operator typecast bool 0 1 9 308
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::operator bool
|
|
// Access: Published
|
|
// Description: Returns true if the font is valid and ready to use,
|
|
// false otherwise.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline bool TextFont::operator typecast bool(void) const;
|
|
|
|
371 15 get_line_height 0 4 704 25 TextFont::get_line_height 0 1 3 296
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::get_line_height
|
|
// Access: Published
|
|
// Description: Returns the number of units high each line of text
|
|
// is.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline float TextFont::get_line_height(void) const;
|
|
|
|
372 15 set_line_height 0 4 704 25 TextFont::set_line_height 0 1 4 296
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::set_line_height
|
|
// Access: Published
|
|
// Description: Changes the number of units high each line of text
|
|
// is.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline void TextFont::set_line_height(float line_height);
|
|
|
|
373 17 get_space_advance 0 4 704 27 TextFont::get_space_advance 0 1 5 271
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::get_space_advance
|
|
// Access: Published
|
|
// Description: Returns the number of units wide a space is.
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline float TextFont::get_space_advance(void) const;
|
|
|
|
374 17 set_space_advance 0 4 704 27 TextFont::set_space_advance 0 1 6 271
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::set_space_advance
|
|
// Access: Published
|
|
// Description: Changes the number of units wide a space is.
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline void TextFont::set_space_advance(float space_advance);
|
|
|
|
375 5 write 0 6 704 15 TextFont::write 0 1 7 223
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::write
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
67
|
|
virtual void TextFont::write(ostream &out, int indent_level) const;
|
|
|
|
376 14 get_class_type 0 4 704 24 TextFont::get_class_type 0 1 8 0
|
|
49
|
|
static TypeHandle TextFont::get_class_type(void);
|
|
|
|
377 8 is_empty 0 4 709 25 DynamicTextPage::is_empty 0 1 14 298
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextPage::is_empty
|
|
// Access: Published
|
|
// Description: Returns true if the page has no glyphs, false
|
|
// otherwise.
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
inline bool DynamicTextPage::is_empty(void) const;
|
|
|
|
378 14 get_class_type 0 4 709 31 DynamicTextPage::get_class_type 0 1 15 0
|
|
56
|
|
static TypeHandle DynamicTextPage::get_class_type(void);
|
|
|
|
379 16 ~DynamicTextPage 0 4 709 33 DynamicTextPage::~DynamicTextPage 0 0 0
|
|
40
|
|
DynamicTextPage::~DynamicTextPage(void);
|
|
|
|
380 18 upcast_to_TextFont 0 12 711 35 DynamicTextFont::upcast_to_TextFont 0 1 65 39
|
|
upcast from DynamicTextFont to TextFont
|
|
52
|
|
TextFont *DynamicTextFont::upcast_to_TextFont(void);
|
|
|
|
381 27 downcast_to_DynamicTextFont 0 12 704 37 TextFont::downcast_to_DynamicTextFont 0 1 66 41
|
|
downcast from TextFont to DynamicTextFont
|
|
61
|
|
DynamicTextFont *TextFont::downcast_to_DynamicTextFont(void);
|
|
|
|
382 22 upcast_to_FreetypeFont 0 12 711 39 DynamicTextFont::upcast_to_FreetypeFont 0 1 67 43
|
|
upcast from DynamicTextFont to FreetypeFont
|
|
60
|
|
FreetypeFont *DynamicTextFont::upcast_to_FreetypeFont(void);
|
|
|
|
383 27 downcast_to_DynamicTextFont 0 12 712 41 FreetypeFont::downcast_to_DynamicTextFont 0 1 68 45
|
|
downcast from FreetypeFont to DynamicTextFont
|
|
65
|
|
DynamicTextFont *FreetypeFont::downcast_to_DynamicTextFont(void);
|
|
|
|
384 15 DynamicTextFont 0 4 711 32 DynamicTextFont::DynamicTextFont 0 4 16 17 18 19 1057
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::Constructor
|
|
// Access: Published
|
|
// Description: The constructor expects the name of some font file
|
|
// that FreeType can read, along with face_index,
|
|
// indicating which font within the file to load
|
|
// (usually 0).
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::Constructor
|
|
// Access: Published
|
|
// Description: This constructor accepts a table of data representing
|
|
// the font file, loaded from some source other than a
|
|
// filename on disk.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::Copy Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
239
|
|
DynamicTextFont::DynamicTextFont(Filename const &font_filename, int face_index = (0));
|
|
DynamicTextFont::DynamicTextFont(char const *font_data, int data_length, int face_index);
|
|
DynamicTextFont::DynamicTextFont(DynamicTextFont const ©);
|
|
|
|
385 16 ~DynamicTextFont 0 6 711 33 DynamicTextFont::~DynamicTextFont 0 0 236
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::Destructor
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
48
|
|
virtual DynamicTextFont::~DynamicTextFont(void);
|
|
|
|
386 9 make_copy 0 6 711 26 DynamicTextFont::make_copy 0 1 20 262
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::make_copy
|
|
// Access: Published
|
|
// Description: Returns a new copy of the same font.
|
|
////////////////////////////////////////////////////////////////////
|
|
69
|
|
virtual PointerTo< TextFont > DynamicTextFont::make_copy(void) const;
|
|
|
|
387 8 get_name 0 4 711 25 DynamicTextFont::get_name 0 1 21 860
|
|
// Filename: dynamicTextFont.I
|
|
// Created by: drose (08Feb02)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_name
|
|
// Access: Published
|
|
// Description: Disambiguates the get_name() method between that
|
|
// inherited from TextFont and that inherited from
|
|
// FreetypeFont.
|
|
////////////////////////////////////////////////////////////////////
|
|
73
|
|
inline basic_string< char > const &DynamicTextFont::get_name(void) const;
|
|
|
|
388 14 set_point_size 0 4 711 31 DynamicTextFont::set_point_size 0 1 22 591
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_point_size
|
|
// Access: Published
|
|
// Description: Sets the point size of the font. This controls the
|
|
// apparent size of the font onscreen. By convention, a
|
|
// 10 point font is about 1 screen unit high.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
////////////////////////////////////////////////////////////////////
|
|
62
|
|
inline bool DynamicTextFont::set_point_size(float point_size);
|
|
|
|
389 14 get_point_size 0 4 711 31 DynamicTextFont::get_point_size 0 1 23 266
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_point_size
|
|
// Access: Published
|
|
// Description: Returns the point size of the font.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline float DynamicTextFont::get_point_size(void) const;
|
|
|
|
390 19 set_pixels_per_unit 0 4 711 36 DynamicTextFont::set_pixels_per_unit 0 1 24 776
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_pixels_per_unit
|
|
// Access: Published
|
|
// Description: Set the resolution of the texture map, and hence the
|
|
// clarity of the resulting font. This sets the number
|
|
// of pixels in the texture map that are used for each
|
|
// onscreen unit.
|
|
//
|
|
// Setting this number larger results in an easier to
|
|
// read font, but at the cost of more texture memory.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
////////////////////////////////////////////////////////////////////
|
|
72
|
|
inline bool DynamicTextFont::set_pixels_per_unit(float pixels_per_unit);
|
|
|
|
391 19 get_pixels_per_unit 0 4 711 36 DynamicTextFont::get_pixels_per_unit 0 1 25 323
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_pixels_per_unit
|
|
// Access: Published
|
|
// Description: Returns the resolution of the texture map. See
|
|
// set_pixels_per_unit().
|
|
////////////////////////////////////////////////////////////////////
|
|
62
|
|
inline float DynamicTextFont::get_pixels_per_unit(void) const;
|
|
|
|
392 16 set_scale_factor 0 4 711 33 DynamicTextFont::set_scale_factor 0 1 26 979
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_scale_factor
|
|
// Access: Published
|
|
// Description: Sets the factor by which the font is rendered larger
|
|
// by the FreeType library before being filtered down to
|
|
// its actual size in the texture as specified by
|
|
// set_pixels_per_unit(). This may be set to a number
|
|
// larger than 1.0 to improve the font's antialiasing
|
|
// (since FreeType doesn't really do a swell job of
|
|
// antialiasing by itself). There is some performance
|
|
// implication for setting this different than 1.0, but
|
|
// it is probably small.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
////////////////////////////////////////////////////////////////////
|
|
66
|
|
inline bool DynamicTextFont::set_scale_factor(float scale_factor);
|
|
|
|
393 16 get_scale_factor 0 4 711 33 DynamicTextFont::get_scale_factor 0 1 27 313
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_scale_factor
|
|
// Access: Published
|
|
// Description: Returns the antialiasing scale factor. See
|
|
// set_scale_factor().
|
|
////////////////////////////////////////////////////////////////////
|
|
59
|
|
inline float DynamicTextFont::get_scale_factor(void) const;
|
|
|
|
394 20 set_native_antialias 0 4 711 37 DynamicTextFont::set_native_antialias 0 1 28 833
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_native_antialias
|
|
// Access: Published
|
|
// Description: Sets whether the Freetype library's built-in
|
|
// antialias mode is enabled. There are two unrelated
|
|
// ways to achieve antialiasing: with Freetype's native
|
|
// antialias mode, and with the use of a scale_factor
|
|
// greater than one. By default, both modes are
|
|
// enabled.
|
|
//
|
|
// At low resolutions, some fonts may do better with one
|
|
// mode or the other. In general, Freetype's native
|
|
// antialiasing will produce less blurry results, but
|
|
// may introduce more artifacts.
|
|
////////////////////////////////////////////////////////////////////
|
|
73
|
|
inline void DynamicTextFont::set_native_antialias(bool native_antialias);
|
|
|
|
395 20 get_native_antialias 0 4 711 37 DynamicTextFont::get_native_antialias 0 1 29 345
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_native_antialias
|
|
// Access: Published
|
|
// Description: Returns whether Freetype's built-in antialias mode is
|
|
// enabled. See set_native_antialias().
|
|
////////////////////////////////////////////////////////////////////
|
|
62
|
|
inline bool DynamicTextFont::get_native_antialias(void) const;
|
|
|
|
396 19 get_font_pixel_size 0 4 711 36 DynamicTextFont::get_font_pixel_size 0 1 30 715
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_font_pixel_size
|
|
// Access: Published
|
|
// Description: This is used to report whether the requested pixel
|
|
// size is being only approximated by a fixed-pixel-size
|
|
// font. This returns 0 in the normal case, in which a
|
|
// scalable font is used, or the fixed-pixel-size font
|
|
// has exactly the requested pixel size.
|
|
//
|
|
// If this returns non-zero, it is the pixel size of the
|
|
// font that we are using to approximate our desired
|
|
// size.
|
|
////////////////////////////////////////////////////////////////////
|
|
60
|
|
inline int DynamicTextFont::get_font_pixel_size(void) const;
|
|
|
|
397 15 get_line_height 0 4 711 32 DynamicTextFont::get_line_height 0 1 31 303
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_line_height
|
|
// Access: Published
|
|
// Description: Returns the number of units high each line of text
|
|
// is.
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline float DynamicTextFont::get_line_height(void) const;
|
|
|
|
398 17 get_space_advance 0 4 711 34 DynamicTextFont::get_space_advance 0 1 32 278
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_space_advance
|
|
// Access: Published
|
|
// Description: Returns the number of units wide a space is.
|
|
////////////////////////////////////////////////////////////////////
|
|
60
|
|
inline float DynamicTextFont::get_space_advance(void) const;
|
|
|
|
399 18 set_texture_margin 0 4 711 35 DynamicTextFont::set_texture_margin 0 1 33 476
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_texture_margin
|
|
// Access: Published
|
|
// Description: Sets the number of pixels of padding that is added
|
|
// around the border of each glyph before adding it to
|
|
// the texture map. This reduces the bleed in from
|
|
// neighboring glyphs in the texture map.
|
|
////////////////////////////////////////////////////////////////////
|
|
68
|
|
inline void DynamicTextFont::set_texture_margin(int texture_margin);
|
|
|
|
400 18 get_texture_margin 0 4 711 35 DynamicTextFont::get_texture_margin 0 1 34 400
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_texture_margin
|
|
// Access: Published
|
|
// Description: Returns the number of pixels of padding that is added
|
|
// around the border of each glyph in the texture map.
|
|
// See set_texture_margin().
|
|
////////////////////////////////////////////////////////////////////
|
|
59
|
|
inline int DynamicTextFont::get_texture_margin(void) const;
|
|
|
|
401 15 set_poly_margin 0 4 711 32 DynamicTextFont::set_poly_margin 0 1 35 794
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_poly_margin
|
|
// Access: Published
|
|
// Description: Sets the number of pixels of padding that is included
|
|
// around each glyph in the generated polygons. This
|
|
// helps prevent the edges of the glyphs from being cut
|
|
// off at small minifications. It is not related to the
|
|
// amount of extra pixels reserved in the texture map
|
|
// (but it should be set somewhat smaller than this
|
|
// number, which is controlled by set_texture_margin(),
|
|
// to prevent bleed-in from neighboring letters in the
|
|
// texture).
|
|
////////////////////////////////////////////////////////////////////
|
|
64
|
|
inline void DynamicTextFont::set_poly_margin(float poly_margin);
|
|
|
|
402 15 get_poly_margin 0 4 711 32 DynamicTextFont::get_poly_margin 0 1 36 390
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_poly_margin
|
|
// Access: Published
|
|
// Description: Returns the number of pixels of padding that is
|
|
// included around each glyph in the generated polygons.
|
|
// See set_poly_margin().
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline float DynamicTextFont::get_poly_margin(void) const;
|
|
|
|
403 13 set_page_size 0 4 711 30 DynamicTextFont::set_page_size 0 1 37 323
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_page_size
|
|
// Access: Published
|
|
// Description: Sets the x, y size of the textures that are created
|
|
// for the DynamicTextFont.
|
|
////////////////////////////////////////////////////////////////////
|
|
67
|
|
inline void DynamicTextFont::set_page_size(int x_size, int y_size);
|
|
|
|
404 15 get_page_x_size 0 4 711 32 DynamicTextFont::get_page_x_size 0 1 38 347
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_page_x_size
|
|
// Access: Published
|
|
// Description: Returns the x size of the textures that are created
|
|
// for the DynamicTextFont. See set_page_size().
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline int DynamicTextFont::get_page_x_size(void) const;
|
|
|
|
405 15 get_page_y_size 0 4 711 32 DynamicTextFont::get_page_y_size 0 1 39 347
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_page_y_size
|
|
// Access: Published
|
|
// Description: Returns the y size of the textures that are created
|
|
// for the DynamicTextFont. See set_page_size().
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline int DynamicTextFont::get_page_y_size(void) const;
|
|
|
|
406 13 set_minfilter 0 4 711 30 DynamicTextFont::set_minfilter 0 1 40 324
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_minfilter
|
|
// Access: Published
|
|
// Description: Sets the filter type used when minimizing the
|
|
// textures created for this font.
|
|
////////////////////////////////////////////////////////////////////
|
|
71
|
|
inline void DynamicTextFont::set_minfilter(Texture::FilterType filter);
|
|
|
|
407 13 get_minfilter 0 4 711 30 DynamicTextFont::get_minfilter 0 1 41 327
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_minfilter
|
|
// Access: Published
|
|
// Description: Returns the filter type used when minimizing the
|
|
// textures created for this font.
|
|
////////////////////////////////////////////////////////////////////
|
|
70
|
|
inline Texture::FilterType DynamicTextFont::get_minfilter(void) const;
|
|
|
|
408 13 set_magfilter 0 4 711 30 DynamicTextFont::set_magfilter 0 1 42 323
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_magfilter
|
|
// Access: Published
|
|
// Description: Sets the filter type used when enlarging the
|
|
// textures created for this font.
|
|
////////////////////////////////////////////////////////////////////
|
|
71
|
|
inline void DynamicTextFont::set_magfilter(Texture::FilterType filter);
|
|
|
|
409 13 get_magfilter 0 4 711 30 DynamicTextFont::get_magfilter 0 1 43 326
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_magfilter
|
|
// Access: Published
|
|
// Description: Returns the filter type used when enlarging the
|
|
// textures created for this font.
|
|
////////////////////////////////////////////////////////////////////
|
|
70
|
|
inline Texture::FilterType DynamicTextFont::get_magfilter(void) const;
|
|
|
|
410 22 set_anisotropic_degree 0 4 711 39 DynamicTextFont::set_anisotropic_degree 0 1 44 482
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_anisotropic_degree
|
|
// Access: Published
|
|
// Description: Enables or disables anisotropic filtering on the
|
|
// textures created for this font. The default value is
|
|
// specified by the text-anisotropic-degree variable.
|
|
// See Texture::set_anisotropic_degree().
|
|
////////////////////////////////////////////////////////////////////
|
|
76
|
|
inline void DynamicTextFont::set_anisotropic_degree(int anisotropic_degree);
|
|
|
|
411 22 get_anisotropic_degree 0 4 711 39 DynamicTextFont::get_anisotropic_degree 0 1 45 361
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_anisotropic_degree
|
|
// Access: Published
|
|
// Description: Returns the current anisotropic degree for textures
|
|
// created for this font. See set_anisotropic_degree().
|
|
////////////////////////////////////////////////////////////////////
|
|
63
|
|
inline int DynamicTextFont::get_anisotropic_degree(void) const;
|
|
|
|
412 15 set_render_mode 0 4 711 32 DynamicTextFont::set_render_mode 0 1 46 477
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_render_mode
|
|
// Access: Published
|
|
// Description: Specifies the way the glyphs on this particular font
|
|
// are generated. The default is RM_texture, which is
|
|
// the only mode supported for bitmap fonts. Other modes
|
|
// are possible for most modern fonts.
|
|
////////////////////////////////////////////////////////////////////
|
|
79
|
|
inline void DynamicTextFont::set_render_mode(TextFont::RenderMode render_mode);
|
|
|
|
413 15 get_render_mode 0 4 711 32 DynamicTextFont::get_render_mode 0 1 47 338
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_render_mode
|
|
// Access: Published
|
|
// Description: Returns the way the glyphs on this particular font
|
|
// are generated. See set_render_mode().
|
|
////////////////////////////////////////////////////////////////////
|
|
73
|
|
inline TextFont::RenderMode DynamicTextFont::get_render_mode(void) const;
|
|
|
|
414 17 set_winding_order 0 4 711 34 DynamicTextFont::set_winding_order 0 1 48 539
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_winding_order
|
|
// Access: Published
|
|
// Description: Specifies an explicitly winding order on this
|
|
// particular font. This is only necessary if the
|
|
// render_mode is RM_polygon or RM_solid, and only if
|
|
// FreeType appears to guess wrong on this font.
|
|
// Normally, you should leave this at WO_default.
|
|
////////////////////////////////////////////////////////////////////
|
|
85
|
|
inline void DynamicTextFont::set_winding_order(TextFont::WindingOrder winding_order);
|
|
|
|
415 17 get_winding_order 0 4 711 34 DynamicTextFont::get_winding_order 0 1 49 288
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_winding_order
|
|
// Access: Published
|
|
// Description: Returns the winding order set via set_winding_order().
|
|
////////////////////////////////////////////////////////////////////
|
|
77
|
|
inline TextFont::WindingOrder DynamicTextFont::get_winding_order(void) const;
|
|
|
|
416 6 set_fg 0 4 711 23 DynamicTextFont::set_fg 0 1 50 832
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_fg
|
|
// Access: Published
|
|
// Description: Changes the color of the foreground pixels of the
|
|
// font as they are rendered into the font texture. The
|
|
// default is (1, 1, 1, 1), or opaque white, which
|
|
// allows text created with the font to be colored
|
|
// individually. Normally, you would not change this
|
|
// unless you really need a particular color effect to
|
|
// appear in the font itself.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline void DynamicTextFont::set_fg(LVecBase4f const &fg);
|
|
|
|
417 6 get_fg 0 4 711 23 DynamicTextFont::get_fg 0 1 51 369
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_fg
|
|
// Access: Published
|
|
// Description: Returns the color of the foreground pixels of the
|
|
// font as they are rendered into the font texture.
|
|
// See set_fg().
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline LVecBase4f const &DynamicTextFont::get_fg(void) const;
|
|
|
|
418 6 set_bg 0 4 711 23 DynamicTextFont::set_bg 0 1 52 1079
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_bg
|
|
// Access: Published
|
|
// Description: Changes the color of the background pixels of the
|
|
// font as they are rendered into the font texture. The
|
|
// default is (1, 1, 1, 0), or transparent white, which
|
|
// allows text created with the font to be colored
|
|
// individually. (Note that it should not generally be
|
|
// (0, 0, 0, 0), which would tend to bleed into the
|
|
// foreground color, unless you have also specified a
|
|
// outline color of (0, 0, 0, 1)) .
|
|
//
|
|
// Normally, you would not change this unless you really
|
|
// need a particular color effect to appear in the font
|
|
// itself.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline void DynamicTextFont::set_bg(LVecBase4f const &bg);
|
|
|
|
419 6 get_bg 0 4 711 23 DynamicTextFont::get_bg 0 1 53 369
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_bg
|
|
// Access: Published
|
|
// Description: Returns the color of the background pixels of the
|
|
// font as they are rendered into the font texture.
|
|
// See set_bg().
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline LVecBase4f const &DynamicTextFont::get_bg(void) const;
|
|
|
|
420 11 set_outline 0 4 711 28 DynamicTextFont::set_outline 0 1 54 1150
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_outline
|
|
// Access: Published
|
|
// Description: Sets up the font to have an outline around each font
|
|
// letter. This is achieved via a Gaussian post-process
|
|
// as each letter is generated; there is some runtime
|
|
// cost for this effect, but it is minimal as each
|
|
// letter is normally generated only once and then
|
|
// cached.
|
|
//
|
|
// The color is the desired color of the outline, width
|
|
// is the number of points beyond the letter that the
|
|
// outline extends (a typical font is 10 points high),
|
|
// and feather is a number in the range 0.0 .. 1.0 that
|
|
// controls the softness of the outline. Set the width
|
|
// to 0.0 to disable the outline.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
////////////////////////////////////////////////////////////////////
|
|
118
|
|
inline void DynamicTextFont::set_outline(LVecBase4f const &outline_color, float outline_width, float outline_feather);
|
|
|
|
421 17 get_outline_color 0 4 711 34 DynamicTextFont::get_outline_color 0 1 55 382
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_outline_color
|
|
// Access: Published
|
|
// Description: Returns the color of the outline pixels of the
|
|
// font as they are rendered into the font texture.
|
|
// See set_outline().
|
|
////////////////////////////////////////////////////////////////////
|
|
72
|
|
inline LVecBase4f const &DynamicTextFont::get_outline_color(void) const;
|
|
|
|
422 17 get_outline_width 0 4 711 34 DynamicTextFont::get_outline_width 0 1 56 383
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_outline_width
|
|
// Access: Published
|
|
// Description: Returns the width of the outline pixels of the
|
|
// font, as the number of points beyond each letter.
|
|
// See set_outline().
|
|
////////////////////////////////////////////////////////////////////
|
|
60
|
|
inline float DynamicTextFont::get_outline_width(void) const;
|
|
|
|
423 19 get_outline_feather 0 4 711 36 DynamicTextFont::get_outline_feather 0 1 57 380
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_outline_feather
|
|
// Access: Published
|
|
// Description: Returns the softness of the outline pixels of the
|
|
// font, as a value in the range 0.0 to 1.0.
|
|
// See set_outline().
|
|
////////////////////////////////////////////////////////////////////
|
|
62
|
|
inline float DynamicTextFont::get_outline_feather(void) const;
|
|
|
|
424 14 get_tex_format 0 4 711 31 DynamicTextFont::get_tex_format 0 1 58 389
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_tex_format
|
|
// Access: Published
|
|
// Description: Returns the texture format used to render the
|
|
// individual pages. This is set automatically
|
|
// according to the colors selected.
|
|
////////////////////////////////////////////////////////////////////
|
|
67
|
|
inline Texture::Format DynamicTextFont::get_tex_format(void) const;
|
|
|
|
425 13 get_num_pages 0 4 711 30 DynamicTextFont::get_num_pages 0 1 59 607
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_num_pages
|
|
// Access: Published
|
|
// Description: Returns the number of pages associated with the font.
|
|
// Initially, the font has zero pages; when the first
|
|
// piece of text is rendered with the font, it will add
|
|
// additional pages as needed. Each page is a Texture
|
|
// object that contains the images for each of the
|
|
// glyphs currently in use somewhere.
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
int DynamicTextFont::get_num_pages(void) const;
|
|
|
|
426 8 get_page 0 4 711 25 DynamicTextFont::get_page 0 1 60 595
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_page
|
|
// Access: Published
|
|
// Description: Returns the nth page associated with the font.
|
|
// Initially, the font has zero pages; when the first
|
|
// piece of text is rendered with the font, it will add
|
|
// additional pages as needed. Each page is a Texture
|
|
// object that contains the images for each of the
|
|
// glyphs currently in use somewhere.
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
DynamicTextPage *DynamicTextFont::get_page(int n) const;
|
|
|
|
427 15 garbage_collect 0 4 711 32 DynamicTextFont::garbage_collect 0 1 61 388
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::garbage_collect
|
|
// Access: Published
|
|
// Description: Removes all of the glyphs from the font that are no
|
|
// longer being used by any Geoms. Returns the number
|
|
// of glyphs removed.
|
|
////////////////////////////////////////////////////////////////////
|
|
43
|
|
int DynamicTextFont::garbage_collect(void);
|
|
|
|
428 5 clear 0 4 711 22 DynamicTextFont::clear 0 1 62 699
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::clear
|
|
// Access: Published
|
|
// Description: Drops all the glyphs out of the cache and frees any
|
|
// association with any previously-generated pages.
|
|
//
|
|
// Calling this frequently can result in wasted texture
|
|
// memory, as any previously rendered text will still
|
|
// keep a pointer to the old, previously-generated
|
|
// pages. As long as the previously rendered text
|
|
// remains around, the old pages will also remain
|
|
// around.
|
|
////////////////////////////////////////////////////////////////////
|
|
34
|
|
void DynamicTextFont::clear(void);
|
|
|
|
429 5 write 0 6 711 22 DynamicTextFont::write 0 1 63 230
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::write
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
74
|
|
virtual void DynamicTextFont::write(ostream &out, int indent_level) const;
|
|
|
|
430 14 get_class_type 0 4 711 31 DynamicTextFont::get_class_type 0 1 64 0
|
|
56
|
|
static TypeHandle DynamicTextFont::get_class_type(void);
|
|
|
|
431 8 has_font 0 4 713 18 FontPool::has_font 0 1 69 969
|
|
// These functions take string parameters instead of Filenames
|
|
// because the parameters may not be entirely an actual filename:
|
|
// they may be a filename followed by a face index.
|
|
|
|
// Filename: fontPool.I
|
|
// Created by: drose (31Jan03)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::has_font
|
|
// Access: Public, Static
|
|
// Description: Returns true if the font has ever been loaded,
|
|
// false otherwise.
|
|
////////////////////////////////////////////////////////////////////
|
|
76
|
|
static inline bool FontPool::has_font(basic_string< char > const &filename);
|
|
|
|
432 11 verify_font 0 4 713 21 FontPool::verify_font 0 1 70 590
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::verify_font
|
|
// Access: Public, Static
|
|
// Description: Loads the given filename up into a font, if it has
|
|
// not already been loaded, and returns true to indicate
|
|
// success, or false to indicate failure. If this
|
|
// returns true, it is guaranteed that a subsequent call
|
|
// to load_font() with the same font name will
|
|
// return a valid Font pointer.
|
|
////////////////////////////////////////////////////////////////////
|
|
79
|
|
static inline bool FontPool::verify_font(basic_string< char > const &filename);
|
|
|
|
433 9 load_font 0 4 713 19 FontPool::load_font 0 1 71 524
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::load_font
|
|
// Access: Public, Static
|
|
// Description: Loads the given filename up into a font, if it has
|
|
// not already been loaded, and returns the new font.
|
|
// If a font with the same filename was previously
|
|
// loaded, returns that one instead. If the font
|
|
// file cannot be found, returns NULL.
|
|
////////////////////////////////////////////////////////////////////
|
|
82
|
|
static inline TextFont *FontPool::load_font(basic_string< char > const &filename);
|
|
|
|
434 8 add_font 0 4 713 18 FontPool::add_font 0 1 72 422
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::add_font
|
|
// Access: Public, Static
|
|
// Description: Adds the indicated already-loaded font to the
|
|
// pool. The font will always replace any
|
|
// previously-loaded font in the pool that had the
|
|
// same filename.
|
|
////////////////////////////////////////////////////////////////////
|
|
92
|
|
static inline void FontPool::add_font(basic_string< char > const &filename, TextFont *font);
|
|
|
|
435 12 release_font 0 4 713 22 FontPool::release_font 0 1 73 537
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::release_font
|
|
// Access: Public, Static
|
|
// Description: Removes the indicated font from the pool,
|
|
// indicating it will never be loaded again; the font
|
|
// may then be freed. If this function is never called,
|
|
// a reference count will be maintained on every font
|
|
// every loaded, and fonts will never be freed.
|
|
////////////////////////////////////////////////////////////////////
|
|
80
|
|
static inline void FontPool::release_font(basic_string< char > const &filename);
|
|
|
|
436 17 release_all_fonts 0 4 713 27 FontPool::release_all_fonts 0 1 74 321
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::release_all_fonts
|
|
// Access: Public, Static
|
|
// Description: Releases all fonts in the pool and restores the
|
|
// pool to the empty state.
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
static inline void FontPool::release_all_fonts(void);
|
|
|
|
437 15 garbage_collect 0 4 713 25 FontPool::garbage_collect 0 1 75 465
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::garbage_collect
|
|
// Access: Public, Static
|
|
// Description: Releases only those fonts in the pool that have a
|
|
// reference count of exactly 1; i.e. only those
|
|
// fonts that are not being used outside of the pool.
|
|
// Returns the number of fonts released.
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
static inline int FontPool::garbage_collect(void);
|
|
|
|
438 13 list_contents 0 4 713 23 FontPool::list_contents 0 1 76 312
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::list_contents
|
|
// Access: Public, Static
|
|
// Description: Lists the contents of the font pool to the
|
|
// indicated output stream.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
static inline void FontPool::list_contents(ostream &out);
|
|
|
|
439 5 write 0 4 713 15 FontPool::write 0 1 77 307
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::write
|
|
// Access: Published, Static
|
|
// Description: Lists the contents of the font pool to the
|
|
// indicated output stream.
|
|
////////////////////////////////////////////////////////////////////
|
|
42
|
|
static void FontPool::write(ostream &out);
|
|
|
|
440 9 ~FontPool 0 4 713 19 FontPool::~FontPool 0 0 0
|
|
26
|
|
FontPool::~FontPool(void);
|
|
|
|
441 14 get_class_type 0 4 714 29 GeomTextGlyph::get_class_type 0 1 78 0
|
|
54
|
|
static TypeHandle GeomTextGlyph::get_class_type(void);
|
|
|
|
442 14 StaticTextFont 0 4 716 30 StaticTextFont::StaticTextFont 0 2 79 80 680
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: StaticTextFont::Constructor
|
|
// Access: Published
|
|
// Description: The constructor expects the root node to a model
|
|
// generated via egg-mkfont, which consists of a set of
|
|
// models, one per each character in the font.
|
|
//
|
|
// If a CoordinateSystem value is specified, it informs
|
|
// the font of the coordinate system in which this model
|
|
// was generated. "up" in this coordinate system will
|
|
// be the direction of the top of the letters.
|
|
////////////////////////////////////////////////////////////////////
|
|
88
|
|
StaticTextFont::StaticTextFont(PandaNode *font_def, CoordinateSystem cs = (CS_default));
|
|
|
|
443 14 get_class_type 0 4 716 30 StaticTextFont::get_class_type 0 1 81 0
|
|
55
|
|
static TypeHandle StaticTextFont::get_class_type(void);
|
|
|
|
444 15 ~StaticTextFont 0 4 716 31 StaticTextFont::~StaticTextFont 0 0 0
|
|
38
|
|
StaticTextFont::~StaticTextFont(void);
|
|
|
|
445 14 TextProperties 0 4 717 30 TextProperties::TextProperties 0 2 82 83 459
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::Copy Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
97
|
|
TextProperties::TextProperties(void);
|
|
TextProperties::TextProperties(TextProperties const ©);
|
|
|
|
446 10 operator = 0 4 717 26 TextProperties::operator = 0 1 84 239
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::Copy Assignment Operator
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
60
|
|
void TextProperties::operator =(TextProperties const ©);
|
|
|
|
447 11 operator == 0 4 717 27 TextProperties::operator == 0 1 85 226
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::operator ==
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
68
|
|
bool TextProperties::operator ==(TextProperties const &other) const;
|
|
|
|
448 11 operator != 0 4 717 27 TextProperties::operator != 0 1 86 716
|
|
// Filename: textProperties.I
|
|
// Created by: drose (06Apr04)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::operator !=
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
75
|
|
inline bool TextProperties::operator !=(TextProperties const &other) const;
|
|
|
|
449 5 clear 0 4 717 21 TextProperties::clear 0 1 87 377
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear
|
|
// Access: Published
|
|
// Description: Unsets all properties that have been specified so
|
|
// far, and resets the TextProperties structure to its
|
|
// initial empty state.
|
|
////////////////////////////////////////////////////////////////////
|
|
33
|
|
void TextProperties::clear(void);
|
|
|
|
450 16 is_any_specified 0 4 717 32 TextProperties::is_any_specified 0 1 88 317
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::is_any_specified
|
|
// Access: Published
|
|
// Description: Returns true if any properties have been specified,
|
|
// false otherwise.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline bool TextProperties::is_any_specified(void) const;
|
|
|
|
451 16 set_default_font 0 4 717 32 TextProperties::set_default_font 0 1 89 382
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_default_font
|
|
// Access: Published, Static
|
|
// Description: Specifies the default font to be used for any
|
|
// TextNode whose font is uninitialized or NULL. See
|
|
// set_font().
|
|
////////////////////////////////////////////////////////////////////
|
|
64
|
|
static inline void TextProperties::set_default_font(TextFont *);
|
|
|
|
452 16 get_default_font 0 4 717 32 TextProperties::get_default_font 0 1 90 382
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_default_font
|
|
// Access: Published, Static
|
|
// Description: Specifies the default font to be used for any
|
|
// TextNode whose font is uninitialized or NULL. See
|
|
// set_font().
|
|
////////////////////////////////////////////////////////////////////
|
|
63
|
|
static inline TextFont *TextProperties::get_default_font(void);
|
|
|
|
453 8 set_font 0 4 717 24 TextProperties::set_font 0 1 91 404
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_font
|
|
// Access: Published
|
|
// Description: Sets the font that will be used when making text. If
|
|
// this is set to NULL, the default font will be used,
|
|
// which can be set via set_default_font().
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline void TextProperties::set_font(TextFont *font);
|
|
|
|
454 10 clear_font 0 4 717 26 TextProperties::clear_font 0 1 92 264
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_font
|
|
// Access: Published
|
|
// Description: Restores the default font to the text.
|
|
////////////////////////////////////////////////////////////////////
|
|
45
|
|
inline void TextProperties::clear_font(void);
|
|
|
|
455 8 has_font 0 4 717 24 TextProperties::has_font 0 1 93 223
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_font
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
49
|
|
inline bool TextProperties::has_font(void) const;
|
|
|
|
456 8 get_font 0 4 717 24 TextProperties::get_font 0 1 94 337
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_font
|
|
// Access: Published
|
|
// Description: Returns the font currently in use, if any. If no
|
|
// font is in use, this returns the default font.
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
inline TextFont *TextProperties::get_font(void) const;
|
|
|
|
457 14 set_small_caps 0 4 717 30 TextProperties::set_small_caps 0 1 95 1137
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_small_caps
|
|
// Access: Published
|
|
// Description: Sets the small_caps flag. When this is set,
|
|
// lowercase letters are generated as scaled-down
|
|
// versions of their uppercase equivalents. This is
|
|
// particularly useful to set for fonts that do not have
|
|
// lowercase letters.
|
|
//
|
|
// It is also a good idea to set this for a (dynamic)
|
|
// font that has already implemented lowercase letters
|
|
// as scaled-down versions of their uppercase
|
|
// equivalents, since without this flag the texture
|
|
// memory may needlessly duplicate equivalent glyphs for
|
|
// upper and lowercase letters. Setting this flag
|
|
// causes the texture memory to share the mixed-case
|
|
// letters.
|
|
//
|
|
// The amount by which the lowercase letters are scaled
|
|
// is specified by set_small_caps_scale().
|
|
////////////////////////////////////////////////////////////////////
|
|
60
|
|
inline void TextProperties::set_small_caps(bool small_caps);
|
|
|
|
458 16 clear_small_caps 0 4 717 32 TextProperties::clear_small_caps 0 1 96 231
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_small_caps
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline void TextProperties::clear_small_caps(void);
|
|
|
|
459 14 has_small_caps 0 4 717 30 TextProperties::has_small_caps 0 1 97 229
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_small_caps
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline bool TextProperties::has_small_caps(void) const;
|
|
|
|
460 14 get_small_caps 0 4 717 30 TextProperties::get_small_caps 0 1 98 281
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_small_caps
|
|
// Access: Published
|
|
// Description: Returns the small_caps flag. See set_small_caps().
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline bool TextProperties::get_small_caps(void) const;
|
|
|
|
461 20 set_small_caps_scale 0 4 717 36 TextProperties::set_small_caps_scale 0 1 99 481
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_small_caps_scale
|
|
// Access: Published
|
|
// Description: Sets the scale factor applied to lowercase letters
|
|
// from their uppercase equivalents, when the small_caps
|
|
// flag is in effect. See set_small_caps(). Normally,
|
|
// this will be a number less than one.
|
|
////////////////////////////////////////////////////////////////////
|
|
73
|
|
inline void TextProperties::set_small_caps_scale(float small_caps_scale);
|
|
|
|
462 22 clear_small_caps_scale 0 4 717 38 TextProperties::clear_small_caps_scale 0 1 100 237
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_small_caps_scale
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline void TextProperties::clear_small_caps_scale(void);
|
|
|
|
463 20 has_small_caps_scale 0 4 717 36 TextProperties::has_small_caps_scale 0 1 101 235
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_small_caps_scale
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline bool TextProperties::has_small_caps_scale(void) const;
|
|
|
|
464 20 get_small_caps_scale 0 4 717 36 TextProperties::get_small_caps_scale 0 1 102 463
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_small_caps_scale
|
|
// Access: Published
|
|
// Description: Returns the scale factor applied to lowercase letters
|
|
// from their uppercase equivalents, when the small_caps
|
|
// flag is in effect. See set_small_caps() and
|
|
// set_small_caps_scale().
|
|
////////////////////////////////////////////////////////////////////
|
|
62
|
|
inline float TextProperties::get_small_caps_scale(void) const;
|
|
|
|
465 9 set_slant 0 4 717 25 TextProperties::set_slant 0 1 103 301
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_slant
|
|
// Access: Published
|
|
// Description: Specifies the factor by which the text slants to the
|
|
// right.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline void TextProperties::set_slant(float slant);
|
|
|
|
466 11 clear_slant 0 4 717 27 TextProperties::clear_slant 0 1 104 227
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_slant
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline void TextProperties::clear_slant(void);
|
|
|
|
467 9 has_slant 0 4 717 25 TextProperties::has_slant 0 1 105 224
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_slant
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
inline bool TextProperties::has_slant(void) const;
|
|
|
|
468 9 get_slant 0 4 717 25 TextProperties::get_slant 0 1 106 314
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_slant
|
|
// Access: Published
|
|
// Description: Returns the factor by which the text is specified to
|
|
// slant to the right.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline float TextProperties::get_slant(void) const;
|
|
|
|
469 14 set_underscore 0 4 717 30 TextProperties::set_underscore 0 1 107 433
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_underscore
|
|
// Access: Published
|
|
// Description: Sets the underscore flag. When this is set,
|
|
// the text is underscored with a one-pixel line the
|
|
// same color as the text foreground, drawn at the
|
|
// baseline.
|
|
////////////////////////////////////////////////////////////////////
|
|
60
|
|
inline void TextProperties::set_underscore(bool underscore);
|
|
|
|
470 16 clear_underscore 0 4 717 32 TextProperties::clear_underscore 0 1 108 231
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_underscore
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline void TextProperties::clear_underscore(void);
|
|
|
|
471 14 has_underscore 0 4 717 30 TextProperties::has_underscore 0 1 109 229
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_underscore
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline bool TextProperties::has_underscore(void) const;
|
|
|
|
472 14 get_underscore 0 4 717 30 TextProperties::get_underscore 0 1 110 281
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_underscore
|
|
// Access: Published
|
|
// Description: Returns the underscore flag. See set_underscore().
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline bool TextProperties::get_underscore(void) const;
|
|
|
|
473 21 set_underscore_height 0 4 717 37 TextProperties::set_underscore_height 0 1 111 447
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_underscore_height
|
|
// Access: Published
|
|
// Description: Specifies the vertical height of the underscore,
|
|
// relative to the text baseline. This only has meaning
|
|
// if the underscore mode is enabled with
|
|
// set_underscore().
|
|
////////////////////////////////////////////////////////////////////
|
|
75
|
|
inline void TextProperties::set_underscore_height(float underscore_height);
|
|
|
|
474 23 clear_underscore_height 0 4 717 39 TextProperties::clear_underscore_height 0 1 112 239
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_underscore_height
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline void TextProperties::clear_underscore_height(void);
|
|
|
|
475 21 has_underscore_height 0 4 717 37 TextProperties::has_underscore_height 0 1 113 236
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_underscore_height
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
62
|
|
inline bool TextProperties::has_underscore_height(void) const;
|
|
|
|
476 21 get_underscore_height 0 4 717 37 TextProperties::get_underscore_height 0 1 114 329
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_underscore_height
|
|
// Access: Published
|
|
// Description: Returns the vertical height of the underscore; see
|
|
// set_underscore_height().
|
|
////////////////////////////////////////////////////////////////////
|
|
63
|
|
inline float TextProperties::get_underscore_height(void) const;
|
|
|
|
477 9 set_align 0 4 717 25 TextProperties::set_align 0 1 115 297
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_align
|
|
// Access: Published
|
|
// Description: Specifies the alignment of the text within its
|
|
// margins.
|
|
////////////////////////////////////////////////////////////////////
|
|
76
|
|
inline void TextProperties::set_align(TextProperties::Alignment align_type);
|
|
|
|
478 11 clear_align 0 4 717 27 TextProperties::clear_align 0 1 116 270
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_align
|
|
// Access: Published
|
|
// Description: Restores the default alignment of the text.
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline void TextProperties::clear_align(void);
|
|
|
|
479 9 has_align 0 4 717 25 TextProperties::has_align 0 1 117 224
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_align
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
inline bool TextProperties::has_align(void) const;
|
|
|
|
480 9 get_align 0 4 717 25 TextProperties::get_align 0 1 118 224
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_align
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
71
|
|
inline TextProperties::Alignment TextProperties::get_align(void) const;
|
|
|
|
481 10 set_indent 0 4 717 26 TextProperties::set_indent 0 1 119 395
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_indent
|
|
// Access: Published
|
|
// Description: Specifies the amount of extra space that is inserted
|
|
// before the first character of each line. This can be
|
|
// thought of as a left margin.
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline void TextProperties::set_indent(float indent);
|
|
|
|
482 12 clear_indent 0 4 717 28 TextProperties::clear_indent 0 1 120 318
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_indent
|
|
// Access: Published
|
|
// Description: Removes the indent setting from the text. Text
|
|
// will be as wide as it is.
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
inline void TextProperties::clear_indent(void);
|
|
|
|
483 10 has_indent 0 4 717 26 TextProperties::has_indent 0 1 121 225
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_indent
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline bool TextProperties::has_indent(void) const;
|
|
|
|
484 10 get_indent 0 4 717 26 TextProperties::get_indent 0 1 122 225
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_indent
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
52
|
|
inline float TextProperties::get_indent(void) const;
|
|
|
|
485 12 set_wordwrap 0 4 717 28 TextProperties::set_wordwrap 0 1 123 400
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_wordwrap
|
|
// Access: Published
|
|
// Description: Sets the text up to automatically wordwrap when it
|
|
// exceeds the indicated width. This can be thought of
|
|
// as a right margin or margin width.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline void TextProperties::set_wordwrap(float wordwrap);
|
|
|
|
486 14 clear_wordwrap 0 4 717 30 TextProperties::clear_wordwrap 0 1 124 322
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_wordwrap
|
|
// Access: Published
|
|
// Description: Removes the wordwrap setting from the text. Text
|
|
// will be as wide as it is.
|
|
////////////////////////////////////////////////////////////////////
|
|
49
|
|
inline void TextProperties::clear_wordwrap(void);
|
|
|
|
487 12 has_wordwrap 0 4 717 28 TextProperties::has_wordwrap 0 1 125 227
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_wordwrap
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline bool TextProperties::has_wordwrap(void) const;
|
|
|
|
488 12 get_wordwrap 0 4 717 28 TextProperties::get_wordwrap 0 1 126 227
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_wordwrap
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
inline float TextProperties::get_wordwrap(void) const;
|
|
|
|
489 32 set_preserve_trailing_whitespace 0 4 717 48 TextProperties::set_preserve_trailing_whitespace 0 1 127 671
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_preserve_trailing_whitespace
|
|
// Access: Published
|
|
// Description: Sets the preserve_trailing_whitespace flag. When
|
|
// this is set, trailing whitespace at the end of the
|
|
// line is not stripped when the text is wordwrapped (it
|
|
// is stripped by default). Since the trailing
|
|
// whitespace is invisible, this is important primarily
|
|
// for determining the proper width of a frame or card
|
|
// behind the text.
|
|
////////////////////////////////////////////////////////////////////
|
|
96
|
|
inline void TextProperties::set_preserve_trailing_whitespace(bool preserve_trailing_whitespace);
|
|
|
|
490 34 clear_preserve_trailing_whitespace 0 4 717 50 TextProperties::clear_preserve_trailing_whitespace 0 1 128 249
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_preserve_trailing_whitespace
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
69
|
|
inline void TextProperties::clear_preserve_trailing_whitespace(void);
|
|
|
|
491 32 has_preserve_trailing_whitespace 0 4 717 48 TextProperties::has_preserve_trailing_whitespace 0 1 129 247
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_preserve_trailing_whitespace
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
73
|
|
inline bool TextProperties::has_preserve_trailing_whitespace(void) const;
|
|
|
|
492 32 get_preserve_trailing_whitespace 0 4 717 48 TextProperties::get_preserve_trailing_whitespace 0 1 130 352
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_preserve_trailing_whitespace
|
|
// Access: Published
|
|
// Description: Returns the preserve_trailing_whitespace flag. See
|
|
// set_preserve_trailing_whitespace().
|
|
////////////////////////////////////////////////////////////////////
|
|
73
|
|
inline bool TextProperties::get_preserve_trailing_whitespace(void) const;
|
|
|
|
493 14 set_text_color 0 4 717 30 TextProperties::set_text_color 0 2 131 132 460
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_text_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_text_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
153
|
|
inline void TextProperties::set_text_color(float r, float g, float b, float a);
|
|
inline void TextProperties::set_text_color(LVecBase4f const &text_color);
|
|
|
|
494 16 clear_text_color 0 4 717 32 TextProperties::clear_text_color 0 1 133 352
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_text_color
|
|
// Access: Published
|
|
// Description: Removes the text color specification; the text will
|
|
// be colored whatever it was in the source font file.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline void TextProperties::clear_text_color(void);
|
|
|
|
495 14 has_text_color 0 4 717 30 TextProperties::has_text_color 0 1 134 229
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_text_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline bool TextProperties::has_text_color(void) const;
|
|
|
|
496 14 get_text_color 0 4 717 30 TextProperties::get_text_color 0 1 135 229
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_text_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline LVecBase4f TextProperties::get_text_color(void) const;
|
|
|
|
497 16 set_shadow_color 0 4 717 32 TextProperties::set_shadow_color 0 2 136 137 464
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
159
|
|
inline void TextProperties::set_shadow_color(float r, float g, float b, float a);
|
|
inline void TextProperties::set_shadow_color(LVecBase4f const &shadow_color);
|
|
|
|
498 18 clear_shadow_color 0 4 717 34 TextProperties::clear_shadow_color 0 1 138 273
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_shadow_color
|
|
// Access: Published
|
|
// Description: Removes the shadow color specification.
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline void TextProperties::clear_shadow_color(void);
|
|
|
|
499 16 has_shadow_color 0 4 717 32 TextProperties::has_shadow_color 0 1 139 231
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline bool TextProperties::has_shadow_color(void) const;
|
|
|
|
500 16 get_shadow_color 0 4 717 32 TextProperties::get_shadow_color 0 1 140 231
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
63
|
|
inline LVecBase4f TextProperties::get_shadow_color(void) const;
|
|
|
|
501 10 set_shadow 0 4 717 26 TextProperties::set_shadow 0 2 141 142 796
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_shadow
|
|
// Access: Published
|
|
// Description: Specifies that the text should be drawn with a
|
|
// shadow, by creating a second copy of the text and
|
|
// offsetting it slightly behind the first.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_shadow
|
|
// Access: Published
|
|
// Description: Specifies that the text should be drawn with a
|
|
// shadow, by creating a second copy of the text and
|
|
// offsetting it slightly behind the first.
|
|
////////////////////////////////////////////////////////////////////
|
|
142
|
|
inline void TextProperties::set_shadow(float xoffset, float yoffset);
|
|
inline void TextProperties::set_shadow(LVecBase2f const &shadow_offset);
|
|
|
|
502 12 clear_shadow 0 4 717 28 TextProperties::clear_shadow 0 1 143 303
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_shadow
|
|
// Access: Published
|
|
// Description: Specifies that a shadow will not be drawn behind the
|
|
// text.
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
inline void TextProperties::clear_shadow(void);
|
|
|
|
503 10 has_shadow 0 4 717 26 TextProperties::has_shadow 0 1 144 225
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_shadow
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline bool TextProperties::has_shadow(void) const;
|
|
|
|
504 10 get_shadow 0 4 717 26 TextProperties::get_shadow 0 1 145 371
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_shadow
|
|
// Access: Published
|
|
// Description: Returns the offset of the shadow as set by
|
|
// set_shadow(). It is an error to call this if
|
|
// has_shadow() is false.
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline LVector2f TextProperties::get_shadow(void) const;
|
|
|
|
505 7 set_bin 0 4 717 23 TextProperties::set_bin 0 1 146 649
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_bin
|
|
// Access: Published
|
|
// Description: Names the CullBin that the text geometry should be
|
|
// assigned to. If this is set, then a CullBinAttrib
|
|
// will be created to explicitly place each component in
|
|
// the named bin.
|
|
//
|
|
// The draw_order value will also be passed to each
|
|
// CullBinAttrib as appropriate; this is particularly
|
|
// useful if this names a CullBinFixed, e.g. "fixed".
|
|
////////////////////////////////////////////////////////////////////
|
|
69
|
|
inline void TextProperties::set_bin(basic_string< char > const &bin);
|
|
|
|
506 9 clear_bin 0 4 717 25 TextProperties::clear_bin 0 1 147 420
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_bin
|
|
// Access: Published
|
|
// Description: Removes the effect of a previous call to
|
|
// set_bin(). Text will be drawn in whatever bin
|
|
// it would like to be drawn in, with no explicit
|
|
// ordering.
|
|
////////////////////////////////////////////////////////////////////
|
|
44
|
|
inline void TextProperties::clear_bin(void);
|
|
|
|
507 7 has_bin 0 4 717 23 TextProperties::has_bin 0 1 148 324
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_bin
|
|
// Access: Published
|
|
// Description: Returns true if an explicit drawing bin has been
|
|
// set via set_bin(), false otherwise.
|
|
////////////////////////////////////////////////////////////////////
|
|
48
|
|
inline bool TextProperties::has_bin(void) const;
|
|
|
|
508 7 get_bin 0 4 717 23 TextProperties::get_bin 0 1 149 323
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_bin
|
|
// Access: Published
|
|
// Description: Returns the drawing bin set with set_bin(), or empty
|
|
// string if no bin has been set.
|
|
////////////////////////////////////////////////////////////////////
|
|
71
|
|
inline basic_string< char > const &TextProperties::get_bin(void) const;
|
|
|
|
509 14 set_draw_order 0 4 717 30 TextProperties::set_draw_order 0 1 150 771
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_draw_order
|
|
// Access: Published
|
|
// Description: Sets the drawing order of text created by the
|
|
// TextNode. This is actually the draw order of the
|
|
// card and frame. The shadow is drawn at
|
|
// _draw_order+1, and the text at _draw_order+2.
|
|
//
|
|
// This affects the sorting order assigned to the nodes
|
|
// as they are created, and also is passed to whatever
|
|
// bin may be assigned via set_bin().
|
|
//
|
|
// The return value is the first unused draw_order
|
|
// number, e.g. _draw_order + 3.
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline int TextProperties::set_draw_order(int draw_order);
|
|
|
|
510 16 clear_draw_order 0 4 717 32 TextProperties::clear_draw_order 0 1 151 232
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_draw_order
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline void TextProperties::clear_draw_order(void);
|
|
|
|
511 14 has_draw_order 0 4 717 30 TextProperties::has_draw_order 0 1 152 229
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_draw_order
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline bool TextProperties::has_draw_order(void) const;
|
|
|
|
512 14 get_draw_order 0 4 717 30 TextProperties::get_draw_order 0 1 153 282
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_draw_order
|
|
// Access: Published
|
|
// Description: Returns the drawing order set with set_draw_order().
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
inline int TextProperties::get_draw_order(void) const;
|
|
|
|
513 13 set_tab_width 0 4 717 29 TextProperties::set_tab_width 0 1 154 409
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_tab_width
|
|
// Access: Published
|
|
// Description: Sets the width of each tab stop, in screen units. A
|
|
// tab character embedded in the text will advance the
|
|
// horizontal position to the next tab stop.
|
|
////////////////////////////////////////////////////////////////////
|
|
59
|
|
inline void TextProperties::set_tab_width(float tab_width);
|
|
|
|
514 15 clear_tab_width 0 4 717 31 TextProperties::clear_tab_width 0 1 155 231
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_tab_width
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
inline void TextProperties::clear_tab_width(void);
|
|
|
|
515 13 has_tab_width 0 4 717 29 TextProperties::has_tab_width 0 1 156 228
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_tab_width
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
inline bool TextProperties::has_tab_width(void) const;
|
|
|
|
516 13 get_tab_width 0 4 717 29 TextProperties::get_tab_width 0 1 157 271
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_tab_width
|
|
// Access: Published
|
|
// Description: Returns the width set via set_tab_width().
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline float TextProperties::get_tab_width(void) const;
|
|
|
|
517 15 set_glyph_scale 0 4 717 31 TextProperties::set_glyph_scale 0 1 158 962
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_glyph_scale
|
|
// Access: Published
|
|
// Description: Specifies the factor by which to scale each letter of
|
|
// the text as it is placed, in addition to any scales
|
|
// inherited from the node or from set_text_scale().
|
|
// This can be used (possibly in conjunction with
|
|
// set_glyph_shift()) to implement superscripting or
|
|
// subscripting.
|
|
//
|
|
// The glyph scale is cumulative when applied to nested
|
|
// TextProperties. It is intended primarily for
|
|
// implementing superscripts, not for scaling the text
|
|
// in general. See also set_text_scale(), which is
|
|
// intended primarily for scaling the text in general,
|
|
// and is not cumulative.
|
|
////////////////////////////////////////////////////////////////////
|
|
63
|
|
inline void TextProperties::set_glyph_scale(float glyph_scale);
|
|
|
|
518 17 clear_glyph_scale 0 4 717 33 TextProperties::clear_glyph_scale 0 1 159 233
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_glyph_scale
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
52
|
|
inline void TextProperties::clear_glyph_scale(void);
|
|
|
|
519 15 has_glyph_scale 0 4 717 31 TextProperties::has_glyph_scale 0 1 160 230
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_glyph_scale
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline bool TextProperties::has_glyph_scale(void) const;
|
|
|
|
520 15 get_glyph_scale 0 4 717 31 TextProperties::get_glyph_scale 0 1 161 322
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_glyph_scale
|
|
// Access: Published
|
|
// Description: Returns the scale factor of each letter as specified
|
|
// by set_glyph_scale().
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline float TextProperties::get_glyph_scale(void) const;
|
|
|
|
521 15 set_glyph_shift 0 4 717 31 TextProperties::set_glyph_shift 0 1 162 471
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_glyph_shift
|
|
// Access: Published
|
|
// Description: Specifies a vertical amount to shift each letter of
|
|
// the text as it is placed. This can be used (possibly
|
|
// in conjunction with set_glyph_scale()) to implement
|
|
// superscripting or subscripting.
|
|
////////////////////////////////////////////////////////////////////
|
|
63
|
|
inline void TextProperties::set_glyph_shift(float glyph_shift);
|
|
|
|
522 17 clear_glyph_shift 0 4 717 33 TextProperties::clear_glyph_shift 0 1 163 233
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_glyph_shift
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
52
|
|
inline void TextProperties::clear_glyph_shift(void);
|
|
|
|
523 15 has_glyph_shift 0 4 717 31 TextProperties::has_glyph_shift 0 1 164 230
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_glyph_shift
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline bool TextProperties::has_glyph_shift(void) const;
|
|
|
|
524 15 get_glyph_shift 0 4 717 31 TextProperties::get_glyph_shift 0 1 165 324
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_glyph_shift
|
|
// Access: Published
|
|
// Description: Returns the vertical shift of each letter as
|
|
// specified by set_glyph_shift().
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline float TextProperties::get_glyph_shift(void) const;
|
|
|
|
525 14 set_text_scale 0 4 717 30 TextProperties::set_text_scale 0 1 166 580
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_text_scale
|
|
// Access: Published
|
|
// Description: Specifies the factor by which to scale the text, in
|
|
// addition to any scalings imposed by the node, as well
|
|
// as in addition to the glyph scale.
|
|
//
|
|
// The text scale is not cumulative when applied to
|
|
// nested TextProperties. See also set_glyph_scale(),
|
|
// which is cumulative.
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline void TextProperties::set_text_scale(float text_scale);
|
|
|
|
526 16 clear_text_scale 0 4 717 32 TextProperties::clear_text_scale 0 1 167 232
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_text_scale
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline void TextProperties::clear_text_scale(void);
|
|
|
|
527 14 has_text_scale 0 4 717 30 TextProperties::has_text_scale 0 1 168 229
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_text_scale
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline bool TextProperties::has_text_scale(void) const;
|
|
|
|
528 14 get_text_scale 0 4 717 30 TextProperties::get_text_scale 0 1 169 317
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_text_scale
|
|
// Access: Published
|
|
// Description: Returns the scale factor of the text as specified
|
|
// by set_text_scale().
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline float TextProperties::get_text_scale(void) const;
|
|
|
|
529 14 add_properties 0 4 717 30 TextProperties::add_properties 0 1 170 374
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::add_properties
|
|
// Access: Published
|
|
// Description: Sets any properties that are explicitly specified in
|
|
// other on this object. Leaves other properties
|
|
// unchanged.
|
|
////////////////////////////////////////////////////////////////////
|
|
65
|
|
void TextProperties::add_properties(TextProperties const &other);
|
|
|
|
530 5 write 0 4 717 21 TextProperties::write 0 2 171 172 220
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::write
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
71
|
|
void TextProperties::write(ostream &out, int indent_level = (0)) const;
|
|
|
|
531 14 get_class_type 0 4 717 30 TextProperties::get_class_type 0 1 173 0
|
|
55
|
|
static TypeHandle TextProperties::get_class_type(void);
|
|
|
|
532 15 ~TextProperties 0 4 717 31 TextProperties::~TextProperties 0 0 0
|
|
38
|
|
TextProperties::~TextProperties(void);
|
|
|
|
533 11 TextGraphic 0 4 719 24 TextGraphic::TextGraphic 0 3 174 175 176 1160
|
|
// Filename: textGraphic.I
|
|
// Created by: drose (18Aug06)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
225
|
|
inline TextGraphic::TextGraphic(void);
|
|
inline TextGraphic::TextGraphic(NodePath const &model, LVecBase4f const &frame);
|
|
inline TextGraphic::TextGraphic(NodePath const &model, float left, float right, float bottom, float top);
|
|
|
|
534 9 get_model 0 4 719 22 TextGraphic::get_model 0 1 177 320
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::get_model
|
|
// Access: Published
|
|
// Description: Returns the NodePath associated with the graphic,
|
|
// that renders the desired image.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline NodePath TextGraphic::get_model(void) const;
|
|
|
|
535 9 set_model 0 4 719 22 TextGraphic::set_model 0 1 178 387
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::set_model
|
|
// Access: Published
|
|
// Description: Changes the NodePath associated with the graphic.
|
|
// This NodePath should contain geometry that will
|
|
// render the desired graphic image.
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline void TextGraphic::set_model(NodePath const &model);
|
|
|
|
536 9 get_frame 0 4 719 22 TextGraphic::get_frame 0 1 179 786
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::get_frame
|
|
// Access: Published
|
|
// Description: Returns the frame specified for the graphic. This is
|
|
// the amount of space that will be reserved for the
|
|
// graphic when it is embedded in a text paragraph, in
|
|
// the form (left, right, bottom, top).
|
|
//
|
|
// The actual graphic, as rendered by the NodePath
|
|
// specified via set_model(), should more or less fit
|
|
// within this rectangle. It is not required to fit
|
|
// completely within it, but if it does not, it may
|
|
// visually overlap with nearby text.
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline LVecBase4f TextGraphic::get_frame(void) const;
|
|
|
|
537 9 set_frame 0 4 719 22 TextGraphic::set_frame 0 2 180 181 660
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::set_frame
|
|
// Access: Published
|
|
// Description: Specifies the (left, right, bottom, top) bounding
|
|
// frame for the graphic. See get_frame().
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::set_frame
|
|
// Access: Published
|
|
// Description: Specifies the (left, right, bottom, top) bounding
|
|
// frame for the graphic. See get_frame().
|
|
////////////////////////////////////////////////////////////////////
|
|
146
|
|
inline void TextGraphic::set_frame(LVecBase4f const &frame);
|
|
inline void TextGraphic::set_frame(float left, float right, float bottom, float top);
|
|
|
|
538 17 get_instance_flag 0 4 719 30 TextGraphic::get_instance_flag 0 1 182 282
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::get_instance_flag
|
|
// Access: Published
|
|
// Description: Returns the instance_flag. See set_instance_flag().
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline bool TextGraphic::get_instance_flag(void) const;
|
|
|
|
539 17 set_instance_flag 0 4 719 30 TextGraphic::set_instance_flag 0 1 183 664
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::set_instance_flag
|
|
// Access: Published
|
|
// Description: Sets the instance_flag. When this is true, the
|
|
// graphic is directly instanced to the scene graph
|
|
// whenever it appears; when it is false, the graphic is
|
|
// copied. The default is false, which is best for most
|
|
// applications. You might need to set it true for
|
|
// special kinds of "graphics" like interactive
|
|
// elements, for instance a PGEntry.
|
|
////////////////////////////////////////////////////////////////////
|
|
63
|
|
inline void TextGraphic::set_instance_flag(bool instance_flag);
|
|
|
|
540 12 ~TextGraphic 0 4 719 25 TextGraphic::~TextGraphic 0 0 0
|
|
32
|
|
TextGraphic::~TextGraphic(void);
|
|
|
|
541 14 set_properties 0 4 720 37 TextPropertiesManager::set_properties 0 1 184 707
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::set_properties
|
|
// Access: Published
|
|
// 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.
|
|
////////////////////////////////////////////////////////////////////
|
|
111
|
|
void TextPropertiesManager::set_properties(basic_string< char > const &name, TextProperties const &properties);
|
|
|
|
542 14 get_properties 0 4 720 37 TextPropertiesManager::get_properties 0 1 185 668
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::get_properties
|
|
// Access: Published
|
|
// 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.
|
|
////////////////////////////////////////////////////////////////////
|
|
87
|
|
TextProperties TextPropertiesManager::get_properties(basic_string< char > const &name);
|
|
|
|
543 14 has_properties 0 4 720 37 TextPropertiesManager::has_properties 0 1 186 687
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::has_properties
|
|
// Access: Published
|
|
// 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.
|
|
////////////////////////////////////////////////////////////////////
|
|
83
|
|
bool TextPropertiesManager::has_properties(basic_string< char > const &name) const;
|
|
|
|
544 16 clear_properties 0 4 720 39 TextPropertiesManager::clear_properties 0 1 187 316
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::clear_properties
|
|
// Access: Published
|
|
// Description: Removes the named TextProperties structure from the
|
|
// manager.
|
|
////////////////////////////////////////////////////////////////////
|
|
79
|
|
void TextPropertiesManager::clear_properties(basic_string< char > const &name);
|
|
|
|
545 11 set_graphic 0 4 720 34 TextPropertiesManager::set_graphic 0 2 188 189 1277
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::set_graphic
|
|
// Access: Published
|
|
// 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.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::set_graphic
|
|
// Access: Published
|
|
// 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.
|
|
////////////////////////////////////////////////////////////////////
|
|
200
|
|
void TextPropertiesManager::set_graphic(basic_string< char > const &name, TextGraphic const &graphic);
|
|
void TextPropertiesManager::set_graphic(basic_string< char > const &name, NodePath const &model);
|
|
|
|
546 11 get_graphic 0 4 720 34 TextPropertiesManager::get_graphic 0 1 190 653
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::get_graphic
|
|
// Access: Published
|
|
// 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.
|
|
////////////////////////////////////////////////////////////////////
|
|
81
|
|
TextGraphic TextPropertiesManager::get_graphic(basic_string< char > const &name);
|
|
|
|
547 11 has_graphic 0 4 720 34 TextPropertiesManager::has_graphic 0 1 191 669
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::has_graphic
|
|
// Access: Published
|
|
// 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.
|
|
////////////////////////////////////////////////////////////////////
|
|
80
|
|
bool TextPropertiesManager::has_graphic(basic_string< char > const &name) const;
|
|
|
|
548 13 clear_graphic 0 4 720 36 TextPropertiesManager::clear_graphic 0 1 192 310
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::clear_graphic
|
|
// Access: Published
|
|
// Description: Removes the named TextGraphic structure from the
|
|
// manager.
|
|
////////////////////////////////////////////////////////////////////
|
|
76
|
|
void TextPropertiesManager::clear_graphic(basic_string< char > const &name);
|
|
|
|
549 5 write 0 4 720 28 TextPropertiesManager::write 0 2 193 194 228
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::write
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
78
|
|
void TextPropertiesManager::write(ostream &out, int indent_level = (0)) const;
|
|
|
|
550 14 get_global_ptr 0 4 720 37 TextPropertiesManager::get_global_ptr 0 1 195 325
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::get_global_ptr
|
|
// Access: Published, Static
|
|
// Description: Returns the pointer to the global TextPropertiesManager
|
|
// object.
|
|
////////////////////////////////////////////////////////////////////
|
|
74
|
|
static TextPropertiesManager *TextPropertiesManager::get_global_ptr(void);
|
|
|
|
551 13 TextAssembler 0 4 721 28 TextAssembler::TextAssembler 0 2 196 197 459
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::Copy Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
108
|
|
TextAssembler::TextAssembler(TextEncoder *encoder);
|
|
TextAssembler::TextAssembler(TextAssembler const ©);
|
|
|
|
552 10 operator = 0 4 721 25 TextAssembler::operator = 0 1 198 239
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::Copy Assignment Operator
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
void TextAssembler::operator =(TextAssembler const ©);
|
|
|
|
553 14 ~TextAssembler 0 4 721 29 TextAssembler::~TextAssembler 0 0 225
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::Destructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
36
|
|
TextAssembler::~TextAssembler(void);
|
|
|
|
554 5 clear 0 4 721 20 TextAssembler::clear 0 1 199 268
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::clear
|
|
// Access: Published
|
|
// Description: Reinitializes the contents of the TextAssembler.
|
|
////////////////////////////////////////////////////////////////////
|
|
32
|
|
void TextAssembler::clear(void);
|
|
|
|
555 14 set_usage_hint 0 4 721 29 TextAssembler::set_usage_hint 0 1 200 1061
|
|
// Filename: textAssembler.I
|
|
// Created by: drose (06Apr04)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_usage_hint
|
|
// Access: Published
|
|
// Description: Specifies the UsageHint that will be applied to
|
|
// generated geometry. The default is UH_static, which
|
|
// is probably the right setting, but if you know the
|
|
// TextNode's geometry will have a short lifespan, it
|
|
// may be better to set it to UH_stream. See
|
|
// geomEnums.h.
|
|
////////////////////////////////////////////////////////////////////
|
|
75
|
|
inline void TextAssembler::set_usage_hint(GeomEnums::UsageHint usage_hint);
|
|
|
|
556 14 get_usage_hint 0 4 721 29 TextAssembler::get_usage_hint 0 1 201 334
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_usage_hint
|
|
// Access: Published
|
|
// Description: Returns the UsageHint that will be applied to
|
|
// generated geometry. See set_usage_hint().
|
|
////////////////////////////////////////////////////////////////////
|
|
70
|
|
inline GeomEnums::UsageHint TextAssembler::get_usage_hint(void) const;
|
|
|
|
557 12 set_max_rows 0 4 721 27 TextAssembler::set_max_rows 0 1 202 557
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_max_rows
|
|
// Access: Published
|
|
// Description: If max_rows is greater than zero, no more than
|
|
// max_rows will be accepted. Text beyond that will be
|
|
// truncated.
|
|
//
|
|
// Setting this will not truncate text immediately. You
|
|
// must follow this up with a call to set_wtext() to
|
|
// truncate the existing text.
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
inline void TextAssembler::set_max_rows(int max_rows);
|
|
|
|
558 12 get_max_rows 0 4 721 27 TextAssembler::get_max_rows 0 1 203 371
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_max_rows
|
|
// Access: Published
|
|
// Description: If max_rows is greater than zero, no more than
|
|
// max_rows will be accepted. Text beyond that will be
|
|
// truncated.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline int TextAssembler::get_max_rows(void) const;
|
|
|
|
559 17 set_dynamic_merge 0 4 721 32 TextAssembler::set_dynamic_merge 0 1 204 313
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_dynamic_merge
|
|
// Access: Published
|
|
// Description: Sets the dynamic_merge flag. See
|
|
// TextNode::set_flatten_flags().
|
|
////////////////////////////////////////////////////////////////////
|
|
65
|
|
inline void TextAssembler::set_dynamic_merge(bool dynamic_merge);
|
|
|
|
560 17 get_dynamic_merge 0 4 721 32 TextAssembler::get_dynamic_merge 0 1 205 316
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_dynamic_merge
|
|
// Access: Published
|
|
// Description: Returns the dynamic_merge flag. See
|
|
// TextNode::set_flatten_flags().
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline bool TextAssembler::get_dynamic_merge(void) const;
|
|
|
|
561 18 set_multiline_mode 0 4 721 33 TextAssembler::set_multiline_mode 0 1 206 346
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_multiline_mode
|
|
// Access: Published
|
|
// Description: Sets the multiline mode flag. Set the multiline
|
|
// mode to allow text to wrap. It defaults to true.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline void TextAssembler::set_multiline_mode(bool flag);
|
|
|
|
562 18 get_multiline_mode 0 4 721 33 TextAssembler::get_multiline_mode 0 1 207 318
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_multiline_mode
|
|
// Access: Published
|
|
// Description: Returns the multline_mode flag. See
|
|
// TextNode::set_multiline_mode().
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline bool TextAssembler::get_multiline_mode(void) const;
|
|
|
|
563 14 set_properties 0 4 721 29 TextAssembler::set_properties 0 1 208 384
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_properties
|
|
// Access: Published
|
|
// Description: Specifies the default TextProperties that are applied
|
|
// to the text in the absence of any nested property
|
|
// change sequences.
|
|
////////////////////////////////////////////////////////////////////
|
|
76
|
|
inline void TextAssembler::set_properties(TextProperties const &properties);
|
|
|
|
564 14 get_properties 0 4 721 29 TextAssembler::get_properties 0 3 209 210 211 1102
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_properties
|
|
// Access: Published
|
|
// Description: Returns the default TextProperties that are applied
|
|
// to the text in the absence of any nested property
|
|
// change sequences.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_properties
|
|
// Access: Published
|
|
// Description: Returns the TextProperties in effect for the object
|
|
// at the indicated position in the pre-wordwrapped
|
|
// string.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_properties
|
|
// Access: Published
|
|
// Description: Returns the TextProperties in effect for the object
|
|
// at the indicated position in the indicated row.
|
|
////////////////////////////////////////////////////////////////////
|
|
224
|
|
inline TextProperties const &TextAssembler::get_properties(void) const;
|
|
inline TextProperties const &TextAssembler::get_properties(int n) const;
|
|
inline TextProperties const &TextAssembler::get_properties(int r, int c) const;
|
|
|
|
565 9 set_wtext 0 4 721 24 TextAssembler::set_wtext 0 1 212 629
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_wtext
|
|
// Access: Published
|
|
// Description: Accepts a new text string and associated properties
|
|
// structure, and precomputes the wordwrapping layout
|
|
// appropriately. After this call,
|
|
// get_wordwrapped_wtext() and get_num_rows() can be
|
|
// called.
|
|
//
|
|
// The return value is true if all the text is accepted,
|
|
// or false if some was truncated (see set_max_rows()).
|
|
////////////////////////////////////////////////////////////////////
|
|
68
|
|
bool TextAssembler::set_wtext(basic_string< wchar_t > const &wtext);
|
|
|
|
566 11 set_wsubstr 0 4 721 26 TextAssembler::set_wsubstr 0 1 213 956
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_wsubstr
|
|
// Access: Published
|
|
// Description: Replaces the 'count' characters from 'start' of the
|
|
// current text with the indicated replacement text. If
|
|
// the replacement text does not have count characters,
|
|
// the length of the string will be changed accordingly.
|
|
//
|
|
// The substring may include nested formatting
|
|
// characters, but they must be self-contained and
|
|
// self-closed. The formatting characters are not
|
|
// literally saved in the internal string; they are
|
|
// parsed at the time of the set_wsubstr() call.
|
|
//
|
|
// The return value is true if all the text is accepted,
|
|
// or false if some was truncated (see set_max_rows()).
|
|
////////////////////////////////////////////////////////////////////
|
|
92
|
|
bool TextAssembler::set_wsubstr(basic_string< wchar_t > const &wtext, int start, int count);
|
|
|
|
567 15 get_plain_wtext 0 4 721 30 TextAssembler::get_plain_wtext 0 1 214 702
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_plain_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text, without any embedded properties characters. If
|
|
// there is an embedded graphic object, a zero value is
|
|
// inserted in that position.
|
|
//
|
|
// This string has the same length as
|
|
// get_num_characters(), and the characters in this
|
|
// string correspond one-to-one with the characters
|
|
// returned by get_character(n).
|
|
////////////////////////////////////////////////////////////////////
|
|
67
|
|
basic_string< wchar_t > TextAssembler::get_plain_wtext(void) const;
|
|
|
|
568 27 get_wordwrapped_plain_wtext 0 4 721 42 TextAssembler::get_wordwrapped_plain_wtext 0 1 215 837
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_wordwrapped_plain_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text, with newlines inserted according to the
|
|
// wordwrapping. The string will contain no embedded
|
|
// properties characters. If there is an embedded
|
|
// graphic object, a zero value is inserted in that
|
|
// position.
|
|
//
|
|
// This string has the same number of newline characters
|
|
// as get_num_rows(), and the characters in this string
|
|
// correspond one-to-one with the characters returned by
|
|
// get_character(r, c).
|
|
////////////////////////////////////////////////////////////////////
|
|
79
|
|
basic_string< wchar_t > TextAssembler::get_wordwrapped_plain_wtext(void) const;
|
|
|
|
569 9 get_wtext 0 4 721 24 TextAssembler::get_wtext 0 1 216 547
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text.
|
|
//
|
|
// The string will contain embedded properties
|
|
// characters, which may not exactly match the embedded
|
|
// properties characters of the original string, but it
|
|
// will encode the same way.
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
basic_string< wchar_t > TextAssembler::get_wtext(void) const;
|
|
|
|
570 21 get_wordwrapped_wtext 0 4 721 36 TextAssembler::get_wordwrapped_wtext 0 1 217 1004
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_wordwrapped_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text, with newlines inserted according to the
|
|
// wordwrapping.
|
|
//
|
|
// The string will contain embedded properties
|
|
// characters, which may not exactly match the embedded
|
|
// properties characters of the original string, but it
|
|
// will encode the same way.
|
|
//
|
|
// Embedded properties characters will be closed before
|
|
// every newline, then reopened (if necessary) on the
|
|
// subsequent character following the newline. This
|
|
// means it will be safe to divide the text up at the
|
|
// newline characters and treat each line as an
|
|
// independent piece.
|
|
////////////////////////////////////////////////////////////////////
|
|
73
|
|
basic_string< wchar_t > TextAssembler::get_wordwrapped_wtext(void) const;
|
|
|
|
571 8 calc_r_c 0 4 721 23 TextAssembler::calc_r_c 0 0 715
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_r_c
|
|
// Access: Published
|
|
// Description: Computes the row and column index of the nth
|
|
// character or graphic object in the text. Fills r and
|
|
// c accordingly.
|
|
//
|
|
// Returns true if the nth character is valid and has a
|
|
// corresponding r and c position, false otherwise (for
|
|
// instance, a soft-hyphen character, or a newline
|
|
// character, may not have a corresponding position).
|
|
// In either case, r and c will be filled in sensibly.
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
bool TextAssembler::calc_r_c(int &r, int &c, int n) const;
|
|
|
|
572 6 calc_r 0 4 721 21 TextAssembler::calc_r 0 1 218 630
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_r
|
|
// Access: Published
|
|
// Description: Computes the row index of the nth character or
|
|
// graphic object in the text and returns it.
|
|
//
|
|
// If the nth character is not a normal printable
|
|
// character with a position in the wordwrapped string,
|
|
// returns -1 (for instance, a soft-hyphen character, or
|
|
// a newline character, may not have a corresponding
|
|
// position).
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline int TextAssembler::calc_r(int n) const;
|
|
|
|
573 6 calc_c 0 4 721 21 TextAssembler::calc_c 0 1 219 633
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_c
|
|
// Access: Published
|
|
// Description: Computes the column index of the nth character or
|
|
// graphic object in the text and returns it.
|
|
//
|
|
// If the nth character is not a normal printable
|
|
// character with a position in the wordwrapped string,
|
|
// returns -1 (for instance, a soft-hyphen character, or
|
|
// a newline character, may not have a corresponding
|
|
// position).
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline int TextAssembler::calc_c(int n) const;
|
|
|
|
574 10 calc_index 0 4 721 25 TextAssembler::calc_index 0 1 220 586
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_index
|
|
// Access: Published
|
|
// Description: Computes the character index of the character at the
|
|
// rth row and cth column position. This is the inverse
|
|
// of calc_r_c().
|
|
//
|
|
// It is legal for c to exceed the index number of the
|
|
// last column by 1, and it is legal for r to exceed the
|
|
// index number of the last row by 1, if c is 0.
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
int TextAssembler::calc_index(int r, int c) const;
|
|
|
|
575 18 get_num_characters 0 4 721 33 TextAssembler::get_num_characters 0 1 221 312
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_num_characters
|
|
// Access: Published
|
|
// Description: Returns the number of characters of text, before
|
|
// wordwrapping.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline int TextAssembler::get_num_characters(void) const;
|
|
|
|
576 13 get_character 0 4 721 28 TextAssembler::get_character 0 2 222 223 864
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_character
|
|
// Access: Published
|
|
// Description: Returns the character at the indicated position in
|
|
// the pre-wordwrapped string. If the object at this
|
|
// position is a graphic object instead of a character,
|
|
// returns 0.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_character
|
|
// Access: Published
|
|
// Description: Returns the character at the indicated position in
|
|
// the indicated row. If the object at this position is
|
|
// a graphic object instead of a character, returns 0.
|
|
////////////////////////////////////////////////////////////////////
|
|
122
|
|
inline wchar_t TextAssembler::get_character(int n) const;
|
|
inline wchar_t TextAssembler::get_character(int r, int c) const;
|
|
|
|
577 11 get_graphic 0 4 721 26 TextAssembler::get_graphic 0 2 224 225 893
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_graphic
|
|
// Access: Published
|
|
// Description: Returns the graphic object at the indicated position
|
|
// in the pre-wordwrapped string. If the object at this
|
|
// position is a character instead of a graphic object,
|
|
// returns NULL.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_graphic
|
|
// Access: Published
|
|
// Description: Returns the graphic object at the indicated position
|
|
// in the indicated row. If the object at this position
|
|
// is a character instead of a graphic object, returns
|
|
// NULL.
|
|
////////////////////////////////////////////////////////////////////
|
|
140
|
|
inline TextGraphic const *TextAssembler::get_graphic(int n) const;
|
|
inline TextGraphic const *TextAssembler::get_graphic(int r, int c) const;
|
|
|
|
578 9 get_width 0 4 721 24 TextAssembler::get_width 0 2 226 227 677
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_width
|
|
// Access: Published
|
|
// Description: Returns the width of the character or object at the
|
|
// indicated position in the pre-wordwrapped string.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_width
|
|
// Access: Published
|
|
// Description: Returns the width of the character or object at the
|
|
// indicated position in the indicated row.
|
|
////////////////////////////////////////////////////////////////////
|
|
110
|
|
inline float TextAssembler::get_width(int n) const;
|
|
inline float TextAssembler::get_width(int r, int c) const;
|
|
|
|
579 12 get_num_rows 0 4 721 27 TextAssembler::get_num_rows 0 1 228 327
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_num_rows
|
|
// Access: Published
|
|
// Description: Returns the number of rows of text after it has all
|
|
// been wordwrapped and assembled.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline int TextAssembler::get_num_rows(void) const;
|
|
|
|
580 12 get_num_cols 0 4 721 27 TextAssembler::get_num_cols 0 1 229 315
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_num_cols
|
|
// Access: Published
|
|
// Description: Returns the number of characters and/or graphic
|
|
// objects in the nth row.
|
|
////////////////////////////////////////////////////////////////////
|
|
52
|
|
inline int TextAssembler::get_num_cols(int r) const;
|
|
|
|
581 8 get_xpos 0 4 721 23 TextAssembler::get_xpos 0 1 230 582
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_xpos
|
|
// Access: Published
|
|
// Description: Returns the x position of the origin of the character
|
|
// or graphic object at the indicated position in the
|
|
// indicated row.
|
|
//
|
|
// It is legal for c to exceed the index number of the
|
|
// last column by 1, and it is legal for r to exceed the
|
|
// index number of the last row by 1, if c is 0.
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
float TextAssembler::get_xpos(int r, int c) const;
|
|
|
|
582 8 get_ypos 0 4 721 23 TextAssembler::get_ypos 0 1 231 484
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_ypos
|
|
// Access: Published
|
|
// Description: Returns the y position of the origin of all of the
|
|
// characters or graphic objects in the indicated row.
|
|
//
|
|
// It is legal for r to exceed the index number of the
|
|
// last row by 1. The value of c is presently ignored.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline float TextAssembler::get_ypos(int r, int c) const;
|
|
|
|
583 13 assemble_text 0 4 721 28 TextAssembler::assemble_text 0 1 232 523
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::assemble_text
|
|
// Access: Published
|
|
// Description: Actually assembles all of the text into a GeomNode,
|
|
// and returns the node (or possibly a parent of the
|
|
// node, to keep the shadow separate). Once this has
|
|
// been called, you may query the extents of the text
|
|
// via get_ul(), get_lr().
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
PointerTo< PandaNode > TextAssembler::assemble_text(void);
|
|
|
|
584 6 get_ul 0 4 721 21 TextAssembler::get_ul 0 1 233 315
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_ul
|
|
// Access: Published
|
|
// Description: Returns the upper-left corner of the assembled text,
|
|
// in 2-d text coordinates.
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline LVector2f const &TextAssembler::get_ul(void) const;
|
|
|
|
585 6 get_lr 0 4 721 21 TextAssembler::get_lr 0 1 234 316
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_lr
|
|
// Access: Published
|
|
// Description: Returns the lower-right corner of the assembled text,
|
|
// in 2-d text coordinates.
|
|
////////////////////////////////////////////////////////////////////
|
|
58
|
|
inline LVector2f const &TextAssembler::get_lr(void) const;
|
|
|
|
586 10 calc_width 0 4 721 25 TextAssembler::calc_width 0 2 235 236 1093
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_width
|
|
// Access: Private, Static
|
|
// Description: Returns the width of a single character, according to
|
|
// its associated font.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_width
|
|
// Access: Published, Static
|
|
// Description: Returns the width of a single character, according to
|
|
// its associated font. This also correctly calculates
|
|
// the width of cheesy ligatures and accented
|
|
// characters, which may not exist in the font as such.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_width
|
|
// Access: Published, Static
|
|
// Description: Returns the width of a single TextGraphic image.
|
|
////////////////////////////////////////////////////////////////////
|
|
194
|
|
static float TextAssembler::calc_width(wchar_t character, TextProperties const &properties);
|
|
static float TextAssembler::calc_width(TextGraphic const *graphic, TextProperties const &properties);
|
|
|
|
587 19 has_exact_character 0 4 721 34 TextAssembler::has_exact_character 0 1 237 1045
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::has_exact_character
|
|
// Access: Published, Static
|
|
// Description: Returns true if the named character exists in the
|
|
// font exactly as named, false otherwise. Note that
|
|
// because Panda can assemble glyphs together
|
|
// automatically using cheesy accent marks, this is not
|
|
// a reliable indicator of whether a suitable glyph can
|
|
// be rendered for the character. For that, use
|
|
// has_character() instead.
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// but returns false for characters that would render
|
|
// with the "invalid glyph". It also returns false for
|
|
// characters that would be synthesized within Panda,
|
|
// but see has_character().
|
|
////////////////////////////////////////////////////////////////////
|
|
100
|
|
static bool TextAssembler::has_exact_character(wchar_t character, TextProperties const &properties);
|
|
|
|
588 13 has_character 0 4 721 28 TextAssembler::has_character 0 1 238 733
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::has_character
|
|
// Access: Published, Static
|
|
// Description: Returns true if the named character exists in the
|
|
// font or can be synthesized by Panda, false otherwise.
|
|
// (Panda can synthesize some accented characters by
|
|
// combining similar-looking glyphs from the font.)
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// but returns false for characters that would render
|
|
// with the "invalid glyph".
|
|
////////////////////////////////////////////////////////////////////
|
|
94
|
|
static bool TextAssembler::has_character(wchar_t character, TextProperties const &properties);
|
|
|
|
589 13 is_whitespace 0 4 721 28 TextAssembler::is_whitespace 0 1 239 1131
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::is_whitespace
|
|
// Access: Published, Static
|
|
// Description: Returns true if the indicated character represents
|
|
// whitespace in the font, or false if anything visible
|
|
// will be rendered for it.
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// and returns false for any other characters, including
|
|
// characters that do not exist in the font (these would
|
|
// be rendered with the "invalid glyph", which is
|
|
// visible).
|
|
//
|
|
// Note that this function can be reliably used to
|
|
// identify Unicode whitespace characters only if the
|
|
// font has all of the whitespace characters defined.
|
|
// It will return false for any character not in the
|
|
// font, even if it is an official Unicode whitespace
|
|
// character.
|
|
////////////////////////////////////////////////////////////////////
|
|
94
|
|
static bool TextAssembler::is_whitespace(wchar_t character, TextProperties const &properties);
|
|
|
|
590 19 upcast_to_PandaNode 0 12 722 29 TextNode::upcast_to_PandaNode 0 1 357 33
|
|
upcast from TextNode to PandaNode
|
|
47
|
|
PandaNode *TextNode::upcast_to_PandaNode(void);
|
|
|
|
591 20 downcast_to_TextNode 0 12 723 31 PandaNode::downcast_to_TextNode 0 1 358 35
|
|
downcast from PandaNode to TextNode
|
|
48
|
|
TextNode *PandaNode::downcast_to_TextNode(void);
|
|
|
|
592 21 upcast_to_TextEncoder 0 12 722 31 TextNode::upcast_to_TextEncoder 0 1 359 35
|
|
upcast from TextNode to TextEncoder
|
|
51
|
|
TextEncoder *TextNode::upcast_to_TextEncoder(void);
|
|
|
|
593 20 downcast_to_TextNode 0 12 724 33 TextEncoder::downcast_to_TextNode 0 1 360 37
|
|
downcast from TextEncoder to TextNode
|
|
50
|
|
TextNode *TextEncoder::downcast_to_TextNode(void);
|
|
|
|
594 24 upcast_to_TextProperties 0 12 722 34 TextNode::upcast_to_TextProperties 0 1 361 38
|
|
upcast from TextNode to TextProperties
|
|
57
|
|
TextProperties *TextNode::upcast_to_TextProperties(void);
|
|
|
|
595 20 downcast_to_TextNode 0 12 717 36 TextProperties::downcast_to_TextNode 0 1 362 40
|
|
downcast from TextProperties to TextNode
|
|
53
|
|
TextNode *TextProperties::downcast_to_TextNode(void);
|
|
|
|
596 8 TextNode 0 4 722 18 TextNode::TextNode 0 2 240 241 855
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::Copy Constructor
|
|
// Access: Published
|
|
// Description: It's sort of a copy constructor: it copies the
|
|
// indicated TextProperties, without copying a complete
|
|
// TextNode.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::Copy Constructor
|
|
// Access: Published
|
|
// Description: OK, this is a true copy constructor.
|
|
////////////////////////////////////////////////////////////////////
|
|
135
|
|
TextNode::TextNode(basic_string< char > const &name);
|
|
TextNode::TextNode(basic_string< char > const &name, TextProperties const ©);
|
|
|
|
597 9 ~TextNode 0 6 722 19 TextNode::~TextNode 0 0 219
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::Destructor
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
34
|
|
virtual TextNode::~TextNode(void);
|
|
|
|
598 15 get_line_height 0 4 722 25 TextNode::get_line_height 0 1 242 994
|
|
// Filename: textNode.I
|
|
// Created by: drose (13Mar02)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_line_height
|
|
// Access: Published
|
|
// Description: Returns the number of units high each line of text
|
|
// is. This is based on the font. Note that it is
|
|
// possible for the text to include nested font change
|
|
// commands, in which case the value of this method is
|
|
// questionable.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline float TextNode::get_line_height(void) const;
|
|
|
|
599 12 set_max_rows 0 4 722 22 TextNode::set_max_rows 0 1 243 439
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_max_rows
|
|
// Access: Published
|
|
// Description: Sets the maximum number of rows that may be formatted
|
|
// by the TextNode. If more text than this is
|
|
// attempted, it will be truncated and has_overflow()
|
|
// will return true.
|
|
////////////////////////////////////////////////////////////////////
|
|
49
|
|
inline void TextNode::set_max_rows(int max_rows);
|
|
|
|
600 14 clear_max_rows 0 4 722 24 TextNode::clear_max_rows 0 1 244 323
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_max_rows
|
|
// Access: Published
|
|
// Description: Resets the TextNode's default behavior of not
|
|
// limiting the number of rows of text.
|
|
////////////////////////////////////////////////////////////////////
|
|
43
|
|
inline void TextNode::clear_max_rows(void);
|
|
|
|
601 12 has_max_rows 0 4 722 22 TextNode::has_max_rows 0 1 245 342
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_max_rows
|
|
// Access: Published
|
|
// Description: Returns true if a limit on the height of the TextNode
|
|
// has been set via set_max_rows(), false otherwise.
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
inline bool TextNode::has_max_rows(void) const;
|
|
|
|
602 12 get_max_rows 0 4 722 22 TextNode::get_max_rows 0 1 246 315
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_max_rows
|
|
// Access: Published
|
|
// Description: Returns the limit on the height of the TextNode
|
|
// specified by set_max_rows().
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline int TextNode::get_max_rows(void) const;
|
|
|
|
603 12 has_overflow 0 4 722 22 TextNode::has_overflow 0 1 247 364
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_overflow
|
|
// Access: Published
|
|
// Description: Returns true if the last text set on the text node
|
|
// exceeded the max_rows constraint, or false if it all
|
|
// fit.
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
inline bool TextNode::has_overflow(void) const;
|
|
|
|
604 15 set_frame_color 0 4 722 25 TextNode::set_frame_color 0 2 248 249 450
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
144
|
|
inline void TextNode::set_frame_color(float r, float g, float b, float a);
|
|
inline void TextNode::set_frame_color(LVecBase4f const &frame_color);
|
|
|
|
605 15 get_frame_color 0 4 722 25 TextNode::get_frame_color 0 1 250 224
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline LVecBase4f TextNode::get_frame_color(void) const;
|
|
|
|
606 15 set_card_border 0 4 722 25 TextNode::set_card_border 0 1 251 224
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_border
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
68
|
|
inline void TextNode::set_card_border(float size, float uv_portion);
|
|
|
|
607 17 clear_card_border 0 4 722 27 TextNode::clear_card_border 0 1 252 226
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_card_border
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline void TextNode::clear_card_border(void);
|
|
|
|
608 20 get_card_border_size 0 4 722 30 TextNode::get_card_border_size 0 1 253 229
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_border_size
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline float TextNode::get_card_border_size(void) const;
|
|
|
|
609 26 get_card_border_uv_portion 0 4 722 36 TextNode::get_card_border_uv_portion 0 1 254 235
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_border_uv_portion
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
62
|
|
inline float TextNode::get_card_border_uv_portion(void) const;
|
|
|
|
610 15 has_card_border 0 4 722 25 TextNode::has_card_border 0 1 255 224
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_card_border
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
inline bool TextNode::has_card_border(void) const;
|
|
|
|
611 14 set_card_color 0 4 722 24 TextNode::set_card_color 0 2 256 257 448
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
141
|
|
inline void TextNode::set_card_color(float r, float g, float b, float a);
|
|
inline void TextNode::set_card_color(LVecBase4f const &card_color);
|
|
|
|
612 14 get_card_color 0 4 722 24 TextNode::get_card_color 0 1 258 223
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline LVecBase4f TextNode::get_card_color(void) const;
|
|
|
|
613 16 set_card_texture 0 4 722 26 TextNode::set_card_texture 0 1 259 225
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_texture
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
62
|
|
inline void TextNode::set_card_texture(Texture *card_texture);
|
|
|
|
614 18 clear_card_texture 0 4 722 28 TextNode::clear_card_texture 0 1 260 227
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_card_texture
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
inline void TextNode::clear_card_texture(void);
|
|
|
|
615 16 has_card_texture 0 4 722 26 TextNode::has_card_texture 0 1 261 225
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_card_texture
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline bool TextNode::has_card_texture(void) const;
|
|
|
|
616 16 get_card_texture 0 4 722 26 TextNode::get_card_texture 0 1 262 225
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_texture
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
55
|
|
inline Texture *TextNode::get_card_texture(void) const;
|
|
|
|
617 19 set_frame_as_margin 0 4 722 29 TextNode::set_frame_as_margin 0 1 263 526
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_as_margin
|
|
// Access: Published
|
|
// Description: Specifies that a border will be drawn around the text
|
|
// when it is next created. The parameters are the
|
|
// amount of additional padding to insert between the
|
|
// frame and the text in each dimension, and all should
|
|
// generally be positive.
|
|
////////////////////////////////////////////////////////////////////
|
|
92
|
|
inline void TextNode::set_frame_as_margin(float left, float right, float bottom, float top);
|
|
|
|
618 16 set_frame_actual 0 4 722 26 TextNode::set_frame_actual 0 1 264 599
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_actual
|
|
// Access: Published
|
|
// Description: Similar to set_frame_as_margin, except the frame is
|
|
// specified in actual coordinate units (relative to
|
|
// the text's origin), irrespective of the size of the
|
|
// text. The left and bottom coordinates should
|
|
// generally be negative, while the right and top
|
|
// coordinates should generally be positive.
|
|
////////////////////////////////////////////////////////////////////
|
|
89
|
|
inline void TextNode::set_frame_actual(float left, float right, float bottom, float top);
|
|
|
|
619 11 clear_frame 0 4 722 21 TextNode::clear_frame 0 1 265 296
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_frame
|
|
// Access: Published
|
|
// Description: Specifies that a border will not be drawn around the
|
|
// text.
|
|
////////////////////////////////////////////////////////////////////
|
|
40
|
|
inline void TextNode::clear_frame(void);
|
|
|
|
620 9 has_frame 0 4 722 19 TextNode::has_frame 0 1 266 218
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_frame
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
44
|
|
inline bool TextNode::has_frame(void) const;
|
|
|
|
621 18 is_frame_as_margin 0 4 722 28 TextNode::is_frame_as_margin 0 1 267 675
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::is_frame_as_margin
|
|
// Access: Published
|
|
// Description: If this is true, the frame was set via a call to
|
|
// set_frame_as_margin(), and the dimension of the frame
|
|
// as returned by get_frame_as_set() represent a margin
|
|
// all around the text. If false, then the frame was
|
|
// set via a call to set_frame_actual(), and the
|
|
// dimensions of the frame as returned by
|
|
// get_frame_as_set() are relative to the text's origin.
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline bool TextNode::is_frame_as_margin(void) const;
|
|
|
|
622 16 get_frame_as_set 0 4 722 26 TextNode::get_frame_as_set 0 1 268 529
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_as_set
|
|
// Access: Published
|
|
// Description: Returns the dimensions of the frame as set by
|
|
// set_frame_as_margin() or set_frame_actual(). Use
|
|
// is_frame_actual() to determine how to interpret the
|
|
// values returned by this function. It is an error to
|
|
// call this if has_frame() is false.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline LVecBase4f TextNode::get_frame_as_set(void) const;
|
|
|
|
623 16 get_frame_actual 0 4 722 26 TextNode::get_frame_actual 0 1 269 767
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_actual
|
|
// Access: Published
|
|
// Description: Returns the actual dimensions of the frame around the
|
|
// text. If the frame was set via set_frame_as_margin(),
|
|
// the result returned by this function reflects the
|
|
// size of the current text; if the frame was set via
|
|
// set_frame_actual(), this returns the values
|
|
// actually set.
|
|
//
|
|
// If the text has no frame at all, this returns the
|
|
// dimensions of the text itself, as if the frame were
|
|
// set with a margin of 0, 0, 0, 0.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline LVecBase4f TextNode::get_frame_actual(void) const;
|
|
|
|
624 20 set_frame_line_width 0 4 722 30 TextNode::set_frame_line_width 0 1 270 320
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_line_width
|
|
// Access: Published
|
|
// Description: Specifies the thickness of the lines that will be
|
|
// used to draw the frame.
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline void TextNode::set_frame_line_width(float line_width);
|
|
|
|
625 20 get_frame_line_width 0 4 722 30 TextNode::get_frame_line_width 0 1 271 318
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_line_width
|
|
// Access: Published
|
|
// Description: Returns the thickness of the lines that will be
|
|
// used to draw the frame.
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline float TextNode::get_frame_line_width(void) const;
|
|
|
|
626 17 set_frame_corners 0 4 722 27 TextNode::set_frame_corners 0 1 272 470
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_corners
|
|
// Access: Published
|
|
// Description: Enables or disables the drawing of corners for the
|
|
// frame. These are extra points drawn at each of the
|
|
// four corners, to soften the ugly edges generated when
|
|
// the line width is greater than one.
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
inline void TextNode::set_frame_corners(bool corners);
|
|
|
|
627 17 get_frame_corners 0 4 722 27 TextNode::get_frame_corners 0 1 273 226
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_corners
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
52
|
|
inline bool TextNode::get_frame_corners(void) const;
|
|
|
|
628 18 set_card_as_margin 0 4 722 28 TextNode::set_card_as_margin 0 1 274 587
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_as_margin
|
|
// Access: Published
|
|
// Description: Specifies that a (possibly opaque or semitransparent)
|
|
// card will be held behind the text when it is next
|
|
// created. Like set_frame_as_margin, the parameters are
|
|
// the amount of additional padding to insert around the
|
|
// text in each dimension, and all should generally be
|
|
// positive.
|
|
////////////////////////////////////////////////////////////////////
|
|
91
|
|
inline void TextNode::set_card_as_margin(float left, float right, float bottom, float top);
|
|
|
|
629 15 set_card_actual 0 4 722 25 TextNode::set_card_actual 0 1 275 596
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_actual
|
|
// Access: Published
|
|
// Description: Similar to set_card_as_margin, except the card is
|
|
// specified in actual coordinate units (relative to
|
|
// the text's origin), irrespective of the size of the
|
|
// text. The left and bottom coordinates should
|
|
// generally be negative, while the right and top
|
|
// coordinates should generally be positive.
|
|
////////////////////////////////////////////////////////////////////
|
|
88
|
|
inline void TextNode::set_card_actual(float left, float right, float bottom, float top);
|
|
|
|
630 14 set_card_decal 0 4 722 24 TextNode::set_card_decal 0 1 276 455
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_decal
|
|
// Access: Published
|
|
// Description: Sets the card_decal flag. When this is true, the
|
|
// text is decalled onto the card, which is necessary if
|
|
// the TextNode is to be rendered in the 3-d world
|
|
// without putting it in a bin.
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
inline void TextNode::set_card_decal(bool card_decal);
|
|
|
|
631 10 clear_card 0 4 722 20 TextNode::clear_card 0 1 277 293
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_card
|
|
// Access: Published
|
|
// Description: Specifies that a card will not be drawn behind the
|
|
// text.
|
|
////////////////////////////////////////////////////////////////////
|
|
39
|
|
inline void TextNode::clear_card(void);
|
|
|
|
632 8 has_card 0 4 722 18 TextNode::has_card 0 1 278 217
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_card
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
43
|
|
inline bool TextNode::has_card(void) const;
|
|
|
|
633 14 get_card_decal 0 4 722 24 TextNode::get_card_decal 0 1 279 275
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_decal
|
|
// Access: Published
|
|
// Description: Returns the card_decal flag. See set_card_decal().
|
|
////////////////////////////////////////////////////////////////////
|
|
49
|
|
inline bool TextNode::get_card_decal(void) const;
|
|
|
|
634 17 is_card_as_margin 0 4 722 27 TextNode::is_card_as_margin 0 1 280 666
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::is_card_as_margin
|
|
// Access: Published
|
|
// Description: If this is true, the card was set via a call to
|
|
// set_card_as_margin(), and the dimension of the card
|
|
// as returned by get_card_as_set() represent a margin
|
|
// all around the text. If false, then the card was
|
|
// set via a call to set_card_actual(), and the
|
|
// dimensions of the card as returned by
|
|
// get_card_as_set() are relative to the text's origin.
|
|
////////////////////////////////////////////////////////////////////
|
|
52
|
|
inline bool TextNode::is_card_as_margin(void) const;
|
|
|
|
635 15 get_card_as_set 0 4 722 25 TextNode::get_card_as_set 0 1 281 523
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_as_set
|
|
// Access: Published
|
|
// Description: Returns the dimensions of the card as set by
|
|
// set_card_as_margin() or set_card_actual(). Use
|
|
// is_card_actual() to determine how to interpret the
|
|
// values returned by this function. It is an error to
|
|
// call this if has_card() is false.
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline LVecBase4f TextNode::get_card_as_set(void) const;
|
|
|
|
636 15 get_card_actual 0 4 722 25 TextNode::get_card_actual 0 1 282 759
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_actual
|
|
// Access: Published
|
|
// Description: Returns the actual dimensions of the card around the
|
|
// text. If the card was set via set_card_as_margin(),
|
|
// the result returned by this function reflects the
|
|
// size of the current text; if the card was set via
|
|
// set_card_actual(), this returns the values
|
|
// actually set.
|
|
//
|
|
// If the text has no card at all, this returns the
|
|
// dimensions of the text itself, as if the card were
|
|
// set with a margin of 0, 0, 0, 0.
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline LVecBase4f TextNode::get_card_actual(void) const;
|
|
|
|
637 20 get_card_transformed 0 4 722 30 TextNode::get_card_transformed 0 1 283 529
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_transformed
|
|
// Access: Published
|
|
// Description: Returns the actual card dimensions, transformed by
|
|
// the matrix set by set_transform(). This returns the
|
|
// card dimensions in actual coordinates as seen by the
|
|
// rest of the world. Also see get_upper_left_3d() and
|
|
// get_lower_right_3d().
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline LVecBase4f TextNode::get_card_transformed(void) const;
|
|
|
|
638 13 set_transform 0 4 722 23 TextNode::set_transform 0 1 284 314
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_transform
|
|
// Access: Published
|
|
// Description: Sets an additional transform that is applied to the
|
|
// entire text paragraph.
|
|
////////////////////////////////////////////////////////////////////
|
|
64
|
|
inline void TextNode::set_transform(LMatrix4f const &transform);
|
|
|
|
639 13 get_transform 0 4 722 23 TextNode::get_transform 0 1 285 222
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_transform
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline LMatrix4f TextNode::get_transform(void) const;
|
|
|
|
640 21 set_coordinate_system 0 4 722 31 TextNode::set_coordinate_system 0 1 286 316
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_coordinate_system
|
|
// Access: Published
|
|
// Description: Specifies the coordinate system in which the text
|
|
// will be generated.
|
|
////////////////////////////////////////////////////////////////////
|
|
65
|
|
inline void TextNode::set_coordinate_system(CoordinateSystem cs);
|
|
|
|
641 21 get_coordinate_system 0 4 722 31 TextNode::get_coordinate_system 0 1 287 230
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_coordinate_system
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
68
|
|
inline CoordinateSystem TextNode::get_coordinate_system(void) const;
|
|
|
|
642 14 set_usage_hint 0 4 722 24 TextNode::set_usage_hint 0 1 288 567
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_usage_hint
|
|
// Access: Published
|
|
// Description: Specifies the UsageHint that will be applied to
|
|
// generated geometry. The default is UH_static, which
|
|
// is probably the right setting, but if you know the
|
|
// TextNode's geometry will have a short lifespan, it
|
|
// may be better to set it to UH_stream. See
|
|
// geomEnums.h.
|
|
////////////////////////////////////////////////////////////////////
|
|
70
|
|
inline void TextNode::set_usage_hint(GeomEnums::UsageHint usage_hint);
|
|
|
|
643 14 get_usage_hint 0 4 722 24 TextNode::get_usage_hint 0 1 289 329
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_usage_hint
|
|
// Access: Published
|
|
// Description: Returns the UsageHint that will be applied to
|
|
// generated geometry. See set_usage_hint().
|
|
////////////////////////////////////////////////////////////////////
|
|
65
|
|
inline GeomEnums::UsageHint TextNode::get_usage_hint(void) const;
|
|
|
|
644 17 set_flatten_flags 0 4 722 27 TextNode::set_flatten_flags 0 1 290 2201
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_flatten_flags
|
|
// Access: Published
|
|
// Description: Sets the flatten flags. This should be a union of
|
|
// the TextNode::FlattenFlags options. This controls
|
|
// the degree of flattening performed on the TextNode's
|
|
// internal geometry (i.e. the scene graph returned by
|
|
// generate()) each time the text is changed. In
|
|
// general, more flattening means a more optimal result,
|
|
// but it will take more time to generate.
|
|
//
|
|
// The choice may be any of these three:
|
|
//
|
|
// FF_none - No flatten operation is called. The
|
|
// letters are left as independent Geoms.
|
|
//
|
|
// FF_light - A flatten_light() operation is called.
|
|
// The attributes are applied to the vertices, but no
|
|
// nodes are removed.
|
|
//
|
|
// FF_medium - A flatten_medium() operation is called.
|
|
// The attributes are applied to the vertices, and a few
|
|
// trivial nodes are removed.
|
|
//
|
|
// FF_strong - A flatten_strong() operation is called.
|
|
// The attributes are applied to the vertices, and the
|
|
// resulting nodes are aggressively combined into as few
|
|
// nodes as possible.
|
|
//
|
|
// In addition to the above choices, you may optionally
|
|
// include the following flag:
|
|
//
|
|
// FF_dynamic_merge - Copy the geoms into a single
|
|
// GeomVertexData as we go, instead of relying on the
|
|
// flatten operation at the end. This pre-flattens the
|
|
// text considerably, and may obviate the need for
|
|
// flatten altogether; it also tends to improve
|
|
// performance considerably even if you do call flatten.
|
|
// However, it is not as fast as not calling flatten at
|
|
// all.
|
|
//
|
|
// The default is taken from the text-flatten and
|
|
// text-dynamic-merge config variables.
|
|
////////////////////////////////////////////////////////////////////
|
|
59
|
|
inline void TextNode::set_flatten_flags(int flatten_flags);
|
|
|
|
645 17 get_flatten_flags 0 4 722 27 TextNode::get_flatten_flags 0 1 291 279
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_flatten_flags
|
|
// Access: Published
|
|
// Description: Returns the flatten flags. See set_flatten_flags().
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline int TextNode::get_flatten_flags(void) const;
|
|
|
|
646 8 set_font 0 4 722 18 TextNode::set_font 0 1 292 544
|
|
// These methods are inherited from TextProperties, but we override
|
|
// here so we can flag the TextNode as dirty when they have been
|
|
// changed.
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_font
|
|
// Access: Published
|
|
// Description: Sets the font that will be used when making text. If
|
|
// this is set to NULL, the default font will be used,
|
|
// which can be set via set_default_font().
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
inline void TextNode::set_font(TextFont *font);
|
|
|
|
647 10 clear_font 0 4 722 20 TextNode::clear_font 0 1 293 256
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_font
|
|
// Access: Published
|
|
// Description: Resets the font to the default font.
|
|
////////////////////////////////////////////////////////////////////
|
|
39
|
|
inline void TextNode::clear_font(void);
|
|
|
|
648 14 set_small_caps 0 4 722 24 TextNode::set_small_caps 0 1 294 1131
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_small_caps
|
|
// Access: Published
|
|
// Description: Sets the small_caps flag. When this is set,
|
|
// lowercase letters are generated as scaled-down
|
|
// versions of their uppercase equivalents. This is
|
|
// particularly useful to set for fonts that do not have
|
|
// lowercase letters.
|
|
//
|
|
// It is also a good idea to set this for a (dynamic)
|
|
// font that has already implemented lowercase letters
|
|
// as scaled-down versions of their uppercase
|
|
// equivalents, since without this flag the texture
|
|
// memory may needlessly duplicate equivalent glyphs for
|
|
// upper and lowercase letters. Setting this flag
|
|
// causes the texture memory to share the mixed-case
|
|
// letters.
|
|
//
|
|
// The amount by which the lowercase letters are scaled
|
|
// is specified by set_small_caps_scale().
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
inline void TextNode::set_small_caps(bool small_caps);
|
|
|
|
649 16 clear_small_caps 0 4 722 26 TextNode::clear_small_caps 0 1 295 226
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_small_caps
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
45
|
|
inline void TextNode::clear_small_caps(void);
|
|
|
|
650 20 set_small_caps_scale 0 4 722 30 TextNode::set_small_caps_scale 0 1 296 475
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_small_caps_scale
|
|
// Access: Published
|
|
// Description: Sets the scale factor applied to lowercase letters
|
|
// from their uppercase equivalents, when the small_caps
|
|
// flag is in effect. See set_small_caps(). Normally,
|
|
// this will be a number less than one.
|
|
////////////////////////////////////////////////////////////////////
|
|
67
|
|
inline void TextNode::set_small_caps_scale(float small_caps_scale);
|
|
|
|
651 22 clear_small_caps_scale 0 4 722 32 TextNode::clear_small_caps_scale 0 1 297 232
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_small_caps_scale
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline void TextNode::clear_small_caps_scale(void);
|
|
|
|
652 9 set_slant 0 4 722 19 TextNode::set_slant 0 1 298 218
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_slant
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
45
|
|
inline void TextNode::set_slant(float slant);
|
|
|
|
653 11 clear_slant 0 4 722 21 TextNode::clear_slant 0 1 299 221
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_slant
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
40
|
|
inline void TextNode::clear_slant(void);
|
|
|
|
654 9 set_align 0 4 722 19 TextNode::set_align 0 1 300 218
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_align
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
70
|
|
inline void TextNode::set_align(TextProperties::Alignment align_type);
|
|
|
|
655 11 clear_align 0 4 722 21 TextNode::clear_align 0 1 301 221
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_align
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
40
|
|
inline void TextNode::clear_align(void);
|
|
|
|
656 10 set_indent 0 4 722 20 TextNode::set_indent 0 1 302 389
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_indent
|
|
// Access: Published
|
|
// Description: Specifies the amount of extra space that is inserted
|
|
// before the first character of each line. This can be
|
|
// thought of as a left margin.
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
inline void TextNode::set_indent(float indent);
|
|
|
|
657 12 clear_indent 0 4 722 22 TextNode::clear_indent 0 1 303 222
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_indent
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
41
|
|
inline void TextNode::clear_indent(void);
|
|
|
|
658 12 set_wordwrap 0 4 722 22 TextNode::set_wordwrap 0 1 304 394
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_wordwrap
|
|
// Access: Published
|
|
// Description: Sets the text up to automatically wordwrap when it
|
|
// exceeds the indicated width. This can be thought of
|
|
// as a right margin or margin width.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
inline void TextNode::set_wordwrap(float wordwrap);
|
|
|
|
659 14 clear_wordwrap 0 4 722 24 TextNode::clear_wordwrap 0 1 305 320
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_wordwrap
|
|
// Access: Published
|
|
// Description: Removes the wordwrap setting from the TextNode. Text
|
|
// will be as wide as it is.
|
|
////////////////////////////////////////////////////////////////////
|
|
43
|
|
inline void TextNode::clear_wordwrap(void);
|
|
|
|
660 14 set_text_color 0 4 722 24 TextNode::set_text_color 0 2 306 307 448
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_text_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_text_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
141
|
|
inline void TextNode::set_text_color(float r, float g, float b, float a);
|
|
inline void TextNode::set_text_color(LVecBase4f const &text_color);
|
|
|
|
661 16 clear_text_color 0 4 722 26 TextNode::clear_text_color 0 1 308 346
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_text_color
|
|
// Access: Published
|
|
// Description: Removes the text color specification; the text will
|
|
// be colored whatever it was in the source font file.
|
|
////////////////////////////////////////////////////////////////////
|
|
45
|
|
inline void TextNode::clear_text_color(void);
|
|
|
|
662 16 set_shadow_color 0 4 722 26 TextNode::set_shadow_color 0 2 309 310 452
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
147
|
|
inline void TextNode::set_shadow_color(float r, float g, float b, float a);
|
|
inline void TextNode::set_shadow_color(LVecBase4f const &shadow_color);
|
|
|
|
663 18 clear_shadow_color 0 4 722 28 TextNode::clear_shadow_color 0 1 311 228
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
47
|
|
inline void TextNode::clear_shadow_color(void);
|
|
|
|
664 10 set_shadow 0 4 722 20 TextNode::set_shadow 0 2 312 313 784
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_shadow
|
|
// Access: Published
|
|
// Description: Specifies that the text should be drawn with a
|
|
// shadow, by creating a second copy of the text and
|
|
// offsetting it slightly behind the first.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_shadow
|
|
// Access: Published
|
|
// Description: Specifies that the text should be drawn with a
|
|
// shadow, by creating a second copy of the text and
|
|
// offsetting it slightly behind the first.
|
|
////////////////////////////////////////////////////////////////////
|
|
130
|
|
inline void TextNode::set_shadow(float xoffset, float yoffset);
|
|
inline void TextNode::set_shadow(LVecBase2f const &shadow_offset);
|
|
|
|
665 12 clear_shadow 0 4 722 22 TextNode::clear_shadow 0 1 314 297
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_shadow
|
|
// Access: Published
|
|
// Description: Specifies that a shadow will not be drawn behind the
|
|
// text.
|
|
////////////////////////////////////////////////////////////////////
|
|
41
|
|
inline void TextNode::clear_shadow(void);
|
|
|
|
666 7 set_bin 0 4 722 17 TextNode::set_bin 0 1 315 672
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_bin
|
|
// Access: Published
|
|
// Description: Names the GeomBin that the TextNode geometry should
|
|
// be assigned to. If this is set, then a
|
|
// GeomBinTransition will be created to explicitly place
|
|
// each component in the named bin.
|
|
//
|
|
// The draw_order value will also be passed to each
|
|
// GeomBinTransition as appropriate; this is
|
|
// particularly useful if this names a GeomBinFixed,
|
|
// e.g. "fixed".
|
|
////////////////////////////////////////////////////////////////////
|
|
63
|
|
inline void TextNode::set_bin(basic_string< char > const &bin);
|
|
|
|
667 9 clear_bin 0 4 722 19 TextNode::clear_bin 0 1 316 414
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_bin
|
|
// Access: Published
|
|
// Description: Removes the effect of a previous call to
|
|
// set_bin(). Text will be drawn in whatever bin
|
|
// it would like to be drawn in, with no explicit
|
|
// ordering.
|
|
////////////////////////////////////////////////////////////////////
|
|
38
|
|
inline void TextNode::clear_bin(void);
|
|
|
|
668 14 set_draw_order 0 4 722 24 TextNode::set_draw_order 0 1 317 765
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_draw_order
|
|
// Access: Published
|
|
// Description: Sets the drawing order of text created by the
|
|
// TextMaker. This is actually the draw order of the
|
|
// card and frame. The shadow is drawn at
|
|
// _draw_order+1, and the text at _draw_order+2.
|
|
//
|
|
// This affects the sorting order assigned to the arcs
|
|
// as they are created, and also is passed to whatever
|
|
// bin may be assigned via set_bin().
|
|
//
|
|
// The return value is the first unused draw_order
|
|
// number, e.g. _draw_order + 3.
|
|
////////////////////////////////////////////////////////////////////
|
|
52
|
|
inline int TextNode::set_draw_order(int draw_order);
|
|
|
|
669 16 clear_draw_order 0 4 722 26 TextNode::clear_draw_order 0 1 318 226
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_draw_order
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
45
|
|
inline void TextNode::clear_draw_order(void);
|
|
|
|
670 13 set_tab_width 0 4 722 23 TextNode::set_tab_width 0 1 319 403
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_tab_width
|
|
// Access: Published
|
|
// Description: Sets the width of each tab stop, in screen units. A
|
|
// tab character embedded in the text will advance the
|
|
// horizontal position to the next tab stop.
|
|
////////////////////////////////////////////////////////////////////
|
|
53
|
|
inline void TextNode::set_tab_width(float tab_width);
|
|
|
|
671 15 clear_tab_width 0 4 722 25 TextNode::clear_tab_width 0 1 320 225
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_tab_width
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
44
|
|
inline void TextNode::clear_tab_width(void);
|
|
|
|
672 15 set_glyph_scale 0 4 722 25 TextNode::set_glyph_scale 0 1 321 467
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_glyph_scale
|
|
// Access: Published
|
|
// Description: Specifies the factor by which to scale each letter of
|
|
// the text as it is placed. This can be used (possibly
|
|
// in conjunction with set_glyph_shift()) to implement
|
|
// superscripting or subscripting.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline void TextNode::set_glyph_scale(float glyph_scale);
|
|
|
|
673 17 clear_glyph_scale 0 4 722 27 TextNode::clear_glyph_scale 0 1 322 227
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_glyph_scale
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline void TextNode::clear_glyph_scale(void);
|
|
|
|
674 15 set_glyph_shift 0 4 722 25 TextNode::set_glyph_shift 0 1 323 465
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_glyph_shift
|
|
// Access: Published
|
|
// Description: Specifies a vertical amount to shift each letter of
|
|
// the text as it is placed. This can be used (possibly
|
|
// in conjunction with set_glyph_scale()) to implement
|
|
// superscripting or subscripting.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline void TextNode::set_glyph_shift(float glyph_shift);
|
|
|
|
675 17 clear_glyph_shift 0 4 722 27 TextNode::clear_glyph_shift 0 1 324 227
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_glyph_shift
|
|
// Access: Published
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline void TextNode::clear_glyph_shift(void);
|
|
|
|
676 8 set_text 0 4 722 18 TextNode::set_text 0 2 325 326 1146
|
|
// These methods are inherited from TextEncoder, but we override
|
|
// here so we can flag the TextNode as dirty when they have been
|
|
// changed.
|
|
|
|
// These methods are inherited from TextEncoder, but we override
|
|
// here so we can flag the TextNode as dirty when they have been
|
|
// changed.
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_text
|
|
// Access: Published
|
|
// Description: Changes the text that is displayed under the
|
|
// TextNode.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_text
|
|
// Access: Published
|
|
// Description: The two-parameter version of set_text() accepts an
|
|
// explicit encoding; the text is immediately decoded
|
|
// and stored as a wide-character string. Subsequent
|
|
// calls to get_text() will return the same text
|
|
// re-encoded using whichever encoding is specified by
|
|
// set_encoding().
|
|
////////////////////////////////////////////////////////////////////
|
|
163
|
|
inline void TextNode::set_text(basic_string< char > const &text);
|
|
inline void TextNode::set_text(basic_string< char > const &text, TextEncoder::Encoding encoding);
|
|
|
|
677 10 clear_text 0 4 722 20 TextNode::clear_text 0 1 327 255
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_text
|
|
// Access: Published
|
|
// Description: Removes the text from the TextNode.
|
|
////////////////////////////////////////////////////////////////////
|
|
39
|
|
inline void TextNode::clear_text(void);
|
|
|
|
678 11 append_text 0 4 722 21 TextNode::append_text 0 1 328 297
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::append_text
|
|
// Access: Published
|
|
// Description: Appends the indicates string to the end of the stored
|
|
// text.
|
|
////////////////////////////////////////////////////////////////////
|
|
68
|
|
inline void TextNode::append_text(basic_string< char > const &text);
|
|
|
|
679 19 append_unicode_char 0 4 722 29 TextNode::append_unicode_char 0 1 329 377
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::append_unicode_char
|
|
// Access: Published
|
|
// Description: Appends a single character to the end of the stored
|
|
// text. This may be a wide character, up to 16 bits in
|
|
// Unicode.
|
|
////////////////////////////////////////////////////////////////////
|
|
61
|
|
inline void TextNode::append_unicode_char(wchar_t character);
|
|
|
|
680 20 get_wordwrapped_text 0 4 722 30 TextNode::get_wordwrapped_text 0 1 330 598
|
|
// After the text has been set, you can query this to determine how
|
|
// it will be wordwrapped.
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_wordwrapped_text
|
|
// Access: Public
|
|
// Description: Returns a string that represents the contents of the
|
|
// text, as it has been formatted by wordwrap rules.
|
|
//
|
|
// In earlier versions, this did not contain any
|
|
// embedded special characters like \1 or \3; now it
|
|
// does.
|
|
////////////////////////////////////////////////////////////////////
|
|
71
|
|
inline basic_string< char > TextNode::get_wordwrapped_text(void) const;
|
|
|
|
681 10 calc_width 0 4 722 20 TextNode::calc_width 0 3 331 332 333 1400
|
|
// These methods calculate the width of a single character or a line
|
|
// of text in the current font.
|
|
|
|
// These methods calculate the width of a single character or a line
|
|
// of text in the current font.
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::calc_width
|
|
// Access: Published
|
|
// Description: Returns the width of a line of text of arbitrary
|
|
// characters. The line should not include the newline
|
|
// character.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::calc_width
|
|
// Access: Published
|
|
// Description: Returns the width of a single character of the font,
|
|
// or 0.0 if the character is not known. This may be a
|
|
// wide character (greater than 255).
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::calc_width
|
|
// Access: Published
|
|
// Description: Returns the width of a line of text of arbitrary
|
|
// characters. The line should not include the newline
|
|
// character or any embedded control characters like \1
|
|
// or \3.
|
|
////////////////////////////////////////////////////////////////////
|
|
198
|
|
float TextNode::calc_width(wchar_t character) const;
|
|
inline float TextNode::calc_width(basic_string< char > const &line) const;
|
|
float TextNode::calc_width(basic_string< wchar_t > const &line) const;
|
|
|
|
682 19 has_exact_character 0 4 722 29 TextNode::has_exact_character 0 1 334 1032
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_exact_character
|
|
// Access: Published
|
|
// Description: Returns true if the named character exists in the
|
|
// font exactly as named, false otherwise. Note that
|
|
// because Panda can assemble glyphs together
|
|
// automatically using cheesy accent marks, this is not
|
|
// a reliable indicator of whether a suitable glyph can
|
|
// be rendered for the character. For that, use
|
|
// has_character() instead.
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// but returns false for characters that would render
|
|
// with the "invalid glyph". It also returns false for
|
|
// characters that would be synthesized within Panda,
|
|
// but see has_character().
|
|
////////////////////////////////////////////////////////////////////
|
|
60
|
|
bool TextNode::has_exact_character(wchar_t character) const;
|
|
|
|
683 13 has_character 0 4 722 23 TextNode::has_character 0 1 335 720
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_character
|
|
// Access: Published
|
|
// Description: Returns true if the named character exists in the
|
|
// font or can be synthesized by Panda, false otherwise.
|
|
// (Panda can synthesize some accented characters by
|
|
// combining similar-looking glyphs from the font.)
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// but returns false for characters that would render
|
|
// with the "invalid glyph".
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
bool TextNode::has_character(wchar_t character) const;
|
|
|
|
684 13 is_whitespace 0 4 722 23 TextNode::is_whitespace 0 1 336 1118
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::is_whitespace
|
|
// Access: Published
|
|
// Description: Returns true if the indicated character represents
|
|
// whitespace in the font, or false if anything visible
|
|
// will be rendered for it.
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// and returns false for any other characters, including
|
|
// characters that do not exist in the font (these would
|
|
// be rendered with the "invalid glyph", which is
|
|
// visible).
|
|
//
|
|
// Note that this function can be reliably used to
|
|
// identify Unicode whitespace characters only if the
|
|
// font has all of the whitespace characters defined.
|
|
// It will return false for any character not in the
|
|
// font, even if it is an official Unicode whitespace
|
|
// character.
|
|
////////////////////////////////////////////////////////////////////
|
|
54
|
|
bool TextNode::is_whitespace(wchar_t character) const;
|
|
|
|
685 9 set_wtext 0 4 722 19 TextNode::set_wtext 0 1 337 497
|
|
// Direct support for wide-character strings.
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_wtext
|
|
// Access: Published
|
|
// Description: Changes the text that is displayed under the
|
|
// TextNode, with a wide text. This automatically sets
|
|
// the string reported by get_text() to the 8-bit
|
|
// encoded version of the same string.
|
|
////////////////////////////////////////////////////////////////////
|
|
70
|
|
inline void TextNode::set_wtext(basic_string< wchar_t > const &wtext);
|
|
|
|
686 12 append_wtext 0 4 722 22 TextNode::append_wtext 0 1 338 360
|
|
// Direct support for wide-character strings.
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::append_wtext
|
|
// Access: Published
|
|
// Description: Appends the indicates string to the end of the stored
|
|
// wide-character text.
|
|
////////////////////////////////////////////////////////////////////
|
|
72
|
|
inline void TextNode::append_wtext(basic_string< wchar_t > const &text);
|
|
|
|
687 21 get_wordwrapped_wtext 0 4 722 31 TextNode::get_wordwrapped_wtext 0 1 339 507
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_wordwrapped_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text, as it has been formatted by wordwrap rules.
|
|
//
|
|
// In earlier versions, this did not contain any
|
|
// embedded special characters like \1 or \3; now it
|
|
// does.
|
|
////////////////////////////////////////////////////////////////////
|
|
75
|
|
inline basic_string< wchar_t > TextNode::get_wordwrapped_wtext(void) const;
|
|
|
|
688 6 output 0 6 722 16 TextNode::output 0 1 340 222
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::output
|
|
// Access: Public, Virtual
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
50
|
|
virtual void TextNode::output(ostream &out) const;
|
|
|
|
689 5 write 0 6 722 15 TextNode::write 0 2 341 342 223
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::write
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
73
|
|
virtual void TextNode::write(ostream &out, int indent_level = (0)) const;
|
|
|
|
690 8 get_left 0 4 722 18 TextNode::get_left 0 1 343 472
|
|
// The following functions return information about the text that
|
|
// was last built (and is currently visible).
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_left
|
|
// Access: Published
|
|
// Description: Returns the leftmost extent of the text in local 2-d
|
|
// coordinates, unmodified by the set_transform()
|
|
// matrix.
|
|
////////////////////////////////////////////////////////////////////
|
|
44
|
|
inline float TextNode::get_left(void) const;
|
|
|
|
691 9 get_right 0 4 722 19 TextNode::get_right 0 1 344 474
|
|
// The following functions return information about the text that
|
|
// was last built (and is currently visible).
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_right
|
|
// Access: Published
|
|
// Description: Returns the rightmost extent of the text in local 2-d
|
|
// coordinates, unmodified by the set_transform()
|
|
// matrix.
|
|
////////////////////////////////////////////////////////////////////
|
|
45
|
|
inline float TextNode::get_right(void) const;
|
|
|
|
692 10 get_bottom 0 4 722 20 TextNode::get_bottom 0 1 345 363
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_bottom
|
|
// Access: Published
|
|
// Description: Returns the bottommost extent of the text in local
|
|
// 2-d coordinates, unmodified by the set_transform()
|
|
// matrix.
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline float TextNode::get_bottom(void) const;
|
|
|
|
693 7 get_top 0 4 722 17 TextNode::get_top 0 1 346 357
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_top
|
|
// Access: Published
|
|
// Description: Returns the topmost extent of the text in local 2-d
|
|
// coordinates, unmodified by the set_transform()
|
|
// matrix.
|
|
////////////////////////////////////////////////////////////////////
|
|
43
|
|
inline float TextNode::get_top(void) const;
|
|
|
|
694 10 get_height 0 4 722 20 TextNode::get_height 0 1 347 297
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_height
|
|
// Access: Published
|
|
// Description: Returns the net height of the text in local 2-d
|
|
// coordinates.
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline float TextNode::get_height(void) const;
|
|
|
|
695 9 get_width 0 4 722 19 TextNode::get_width 0 1 348 295
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_width
|
|
// Access: Published
|
|
// Description: Returns the net width of the text in local 2-d
|
|
// coordinates.
|
|
////////////////////////////////////////////////////////////////////
|
|
45
|
|
inline float TextNode::get_width(void) const;
|
|
|
|
696 17 get_upper_left_3d 0 4 722 27 TextNode::get_upper_left_3d 0 1 349 395
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_upper_left_3d
|
|
// Access: Published
|
|
// Description: Returns the upper-left extent of the text object,
|
|
// after it has been transformed into 3-d space by
|
|
// applying the set_transform() matrix.
|
|
////////////////////////////////////////////////////////////////////
|
|
56
|
|
inline LPoint3f TextNode::get_upper_left_3d(void) const;
|
|
|
|
697 18 get_lower_right_3d 0 4 722 28 TextNode::get_lower_right_3d 0 1 350 397
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_lower_right_3d
|
|
// Access: Published
|
|
// Description: Returns the lower-right extent of the text object,
|
|
// after it has been transformed into 3-d space by
|
|
// applying the set_transform() matrix.
|
|
////////////////////////////////////////////////////////////////////
|
|
57
|
|
inline LPoint3f TextNode::get_lower_right_3d(void) const;
|
|
|
|
698 12 get_num_rows 0 4 722 22 TextNode::get_num_rows 0 1 351 394
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_num_rows
|
|
// Access: Published
|
|
// Description: Returns the number of rows of text that were
|
|
// generated. This counts word-wrapped rows as well as
|
|
// rows generated due to embedded newlines.
|
|
////////////////////////////////////////////////////////////////////
|
|
46
|
|
inline int TextNode::get_num_rows(void) const;
|
|
|
|
699 8 generate 0 4 722 18 TextNode::generate 0 1 352 403
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::generate
|
|
// Access: Published
|
|
// Description: Generates the text, according to the parameters
|
|
// indicated within the TextNode, and returns a Node
|
|
// that may be parented within the tree to represent it.
|
|
////////////////////////////////////////////////////////////////////
|
|
48
|
|
PointerTo< PandaNode > TextNode::generate(void);
|
|
|
|
700 6 update 0 4 722 16 TextNode::update 0 1 353 442
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::update
|
|
// Access: Published
|
|
// Description: Can be called after the TextNode has been fully
|
|
// configured, to force the node to recompute its text
|
|
// immediately, rather than waiting for it to be drawn.
|
|
// This call is optional.
|
|
////////////////////////////////////////////////////////////////////
|
|
35
|
|
inline void TextNode::update(void);
|
|
|
|
701 12 force_update 0 4 722 22 TextNode::force_update 0 1 354 537
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::force_update
|
|
// Access: Published
|
|
// Description: Forces the TextNode to recompute itself now, even if
|
|
// it believes nothing has changed. Normally, this
|
|
// should not need to be called, but it may be useful if
|
|
// some properties change outside of the TextNode's
|
|
// knowledge (for instance, within the font).
|
|
////////////////////////////////////////////////////////////////////
|
|
41
|
|
inline void TextNode::force_update(void);
|
|
|
|
702 17 get_internal_geom 0 4 722 27 TextNode::get_internal_geom 0 1 355 637
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_internal_geom
|
|
// Access: Published
|
|
// Description: Returns the actual node that is used internally to
|
|
// render the text, if the TextNode is parented within
|
|
// the scene graph.
|
|
//
|
|
// In general, you should not call this method. Call
|
|
// generate() instead if you want to get a handle to
|
|
// geometry that represents the text. This method is
|
|
// provided as a debugging aid only.
|
|
////////////////////////////////////////////////////////////////////
|
|
51
|
|
PandaNode *TextNode::get_internal_geom(void) const;
|
|
|
|
703 14 get_class_type 0 4 722 24 TextNode::get_class_type 0 1 356 0
|
|
49
|
|
static TypeHandle TextNode::get_class_type(void);
|
|
|
|
362
|
|
1 14 Dtool_z_GLcT7z 0 7 11 728 367 14 Dtool_z_GLcT7z 0 1 4 this 3 726
|
|
2 14 Dtool_z_GL9LaW 0 6 12 729 0 14 Dtool_z_GL9LaW 787 // Filename: textFont.I
|
|
// Created by: drose (08Feb02)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::is_valid
|
|
// Access: Published
|
|
// Description: Returns true if the font is valid and ready to use,
|
|
// false otherwise.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 726
|
|
3 14 Dtool_z_GLA_Bt 0 6 14 730 0 14 Dtool_z_GLA_Bt 296 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::get_line_height
|
|
// Access: Published
|
|
// Description: Returns the number of units high each line of text
|
|
// is.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 726
|
|
4 14 Dtool_z_GLMJXZ 0 4 15 731 0 14 Dtool_z_GLMJXZ 296 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::set_line_height
|
|
// Access: Published
|
|
// Description: Changes the number of units high each line of text
|
|
// is.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 728 11 line_height 1 730
|
|
5 14 Dtool_z_GL1YDr 0 6 16 730 0 14 Dtool_z_GL1YDr 271 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::get_space_advance
|
|
// Access: Published
|
|
// Description: Returns the number of units wide a space is.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 726
|
|
6 14 Dtool_z_GLHPSY 0 4 17 731 0 14 Dtool_z_GLHPSY 271 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::set_space_advance
|
|
// Access: Published
|
|
// Description: Changes the number of units wide a space is.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 728 13 space_advance 1 730
|
|
7 14 Dtool_z_GLFEoh 0 4 18 731 0 14 Dtool_z_GLFEoh 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::write
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 726 3 out 1 732 12 indent_level 1 734
|
|
8 14 Dtool_z_GL_pT1 0 7 19 736 0 14 Dtool_z_GL_pT1 0 0
|
|
9 14 Dtool_z_GLBetZ 0 6 13 729 0 14 Dtool_z_GLBetZ 308 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextFont::operator bool
|
|
// Access: Published
|
|
// Description: Returns true if the font is valid and ready to use,
|
|
// false otherwise.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 726
|
|
10 14 Dtool_z_GL2Y6t 0 7 3 737 0 14 Dtool_z_GL2Y6t 0 1 4 this 3 728
|
|
11 14 Dtool_z_GLUGAk 0 7 4 728 367 14 Dtool_z_GLUGAk 0 1 4 this 3 737
|
|
12 14 Dtool_z_GLSvLG 0 6 6 738 0 14 Dtool_z_GLSvLG 0 1 4 this 3 728
|
|
13 14 Dtool_z_GL5Y1p 0 7 7 728 367 14 Dtool_z_GL5Y1p 0 1 4 this 3 738
|
|
14 14 Dtool_z_GLgQhV 0 6 22 729 0 14 Dtool_z_GLgQhV 298 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextPage::is_empty
|
|
// Access: Published
|
|
// Description: Returns true if the page has no glyphs, false
|
|
// otherwise.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 739
|
|
15 14 Dtool_z_GLtUbq 0 7 23 736 0 14 Dtool_z_GLtUbq 0 0
|
|
16 14 Dtool_z_GLDyqM 0 7 31 743 385 14 Dtool_z_GLDyqM 233 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::Copy Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 copy 1 741
|
|
17 14 Dtool_z_GLOkXk 0 7 31 743 385 14 Dtool_z_GLOkXk 435 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::Constructor
|
|
// Access: Published
|
|
// Description: The constructor expects the name of some font file
|
|
// that FreeType can read, along with face_index,
|
|
// indicating which font within the file to load
|
|
// (usually 0).
|
|
//////////////////////////////////////////////////////////////////// 2 13 font_filename 1 744 10 face_index 1 734
|
|
18 14 Dtool_z_GL8io2 0 7 31 743 385 14 Dtool_z_GL8io2 435 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::Constructor
|
|
// Access: Published
|
|
// Description: The constructor expects the name of some font file
|
|
// that FreeType can read, along with face_index,
|
|
// indicating which font within the file to load
|
|
// (usually 0).
|
|
//////////////////////////////////////////////////////////////////// 1 13 font_filename 1 744
|
|
19 14 Dtool_z_GLK5pQ 0 7 31 743 385 14 Dtool_z_GLK5pQ 385 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::Constructor
|
|
// Access: Published
|
|
// Description: This constructor accepts a table of data representing
|
|
// the font file, loaded from some source other than a
|
|
// filename on disk.
|
|
//////////////////////////////////////////////////////////////////// 3 9 font_data 1 747 11 data_length 1 734 10 face_index 1 734
|
|
20 14 Dtool_z_GL9LWv 0 7 33 728 367 14 Dtool_z_GL9LWv 262 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::make_copy
|
|
// Access: Published
|
|
// Description: Returns a new copy of the same font.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
21 14 Dtool_z_GL_u_H 0 6 34 747 0 14 Dtool_z_GL_u_H 860 // Filename: dynamicTextFont.I
|
|
// Created by: drose (08Feb02)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_name
|
|
// Access: Published
|
|
// Description: Disambiguates the get_name() method between that
|
|
// inherited from TextFont and that inherited from
|
|
// FreetypeFont.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
22 14 Dtool_z_GLHMaP 0 6 35 729 0 14 Dtool_z_GLHMaP 591 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_point_size
|
|
// Access: Published
|
|
// Description: Sets the point size of the font. This controls the
|
|
// apparent size of the font onscreen. By convention, a
|
|
// 10 point font is about 1 screen unit high.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 10 point_size 1 730
|
|
23 14 Dtool_z_GLcaBi 0 6 36 730 0 14 Dtool_z_GLcaBi 266 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_point_size
|
|
// Access: Published
|
|
// Description: Returns the point size of the font.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
24 14 Dtool_z_GLwHlG 0 6 37 729 0 14 Dtool_z_GLwHlG 776 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_pixels_per_unit
|
|
// Access: Published
|
|
// Description: Set the resolution of the texture map, and hence the
|
|
// clarity of the resulting font. This sets the number
|
|
// of pixels in the texture map that are used for each
|
|
// onscreen unit.
|
|
//
|
|
// Setting this number larger results in an easier to
|
|
// read font, but at the cost of more texture memory.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 15 pixels_per_unit 1 730
|
|
25 14 Dtool_z_GL7_b_ 0 6 38 730 0 14 Dtool_z_GL7_b_ 323 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_pixels_per_unit
|
|
// Access: Published
|
|
// Description: Returns the resolution of the texture map. See
|
|
// set_pixels_per_unit().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
26 14 Dtool_z_GLmves 0 6 39 729 0 14 Dtool_z_GLmves 979 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_scale_factor
|
|
// Access: Published
|
|
// Description: Sets the factor by which the font is rendered larger
|
|
// by the FreeType library before being filtered down to
|
|
// its actual size in the texture as specified by
|
|
// set_pixels_per_unit(). This may be set to a number
|
|
// larger than 1.0 to improve the font's antialiasing
|
|
// (since FreeType doesn't really do a swell job of
|
|
// antialiasing by itself). There is some performance
|
|
// implication for setting this different than 1.0, but
|
|
// it is probably small.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 12 scale_factor 1 730
|
|
27 14 Dtool_z_GL2S6E 0 6 40 730 0 14 Dtool_z_GL2S6E 313 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_scale_factor
|
|
// Access: Published
|
|
// Description: Returns the antialiasing scale factor. See
|
|
// set_scale_factor().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
28 14 Dtool_z_GL_XCc 0 4 41 731 0 14 Dtool_z_GL_XCc 833 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_native_antialias
|
|
// Access: Published
|
|
// Description: Sets whether the Freetype library's built-in
|
|
// antialias mode is enabled. There are two unrelated
|
|
// ways to achieve antialiasing: with Freetype's native
|
|
// antialias mode, and with the use of a scale_factor
|
|
// greater than one. By default, both modes are
|
|
// enabled.
|
|
//
|
|
// At low resolutions, some fonts may do better with one
|
|
// mode or the other. In general, Freetype's native
|
|
// antialiasing will produce less blurry results, but
|
|
// may introduce more artifacts.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 16 native_antialias 1 729
|
|
29 14 Dtool_z_GL4rqO 0 6 42 729 0 14 Dtool_z_GL4rqO 345 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_native_antialias
|
|
// Access: Published
|
|
// Description: Returns whether Freetype's built-in antialias mode is
|
|
// enabled. See set_native_antialias().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
30 14 Dtool_z_GLpAyj 0 6 43 734 0 14 Dtool_z_GLpAyj 715 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_font_pixel_size
|
|
// Access: Published
|
|
// Description: This is used to report whether the requested pixel
|
|
// size is being only approximated by a fixed-pixel-size
|
|
// font. This returns 0 in the normal case, in which a
|
|
// scalable font is used, or the fixed-pixel-size font
|
|
// has exactly the requested pixel size.
|
|
//
|
|
// If this returns non-zero, it is the pixel size of the
|
|
// font that we are using to approximate our desired
|
|
// size.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
31 14 Dtool_z_GLSLGS 0 6 44 730 0 14 Dtool_z_GLSLGS 303 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_line_height
|
|
// Access: Published
|
|
// Description: Returns the number of units high each line of text
|
|
// is.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
32 14 Dtool_z_GLIitQ 0 6 45 730 0 14 Dtool_z_GLIitQ 278 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_space_advance
|
|
// Access: Published
|
|
// Description: Returns the number of units wide a space is.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
33 14 Dtool_z_GL_M4T 0 4 46 731 0 14 Dtool_z_GL_M4T 476 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_texture_margin
|
|
// Access: Published
|
|
// Description: Sets the number of pixels of padding that is added
|
|
// around the border of each glyph before adding it to
|
|
// the texture map. This reduces the bleed in from
|
|
// neighboring glyphs in the texture map.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 14 texture_margin 1 734
|
|
34 14 Dtool_z_GL_YB2 0 6 47 734 0 14 Dtool_z_GL_YB2 400 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_texture_margin
|
|
// Access: Published
|
|
// Description: Returns the number of pixels of padding that is added
|
|
// around the border of each glyph in the texture map.
|
|
// See set_texture_margin().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
35 14 Dtool_z_GLksfM 0 4 48 731 0 14 Dtool_z_GLksfM 794 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_poly_margin
|
|
// Access: Published
|
|
// Description: Sets the number of pixels of padding that is included
|
|
// around each glyph in the generated polygons. This
|
|
// helps prevent the edges of the glyphs from being cut
|
|
// off at small minifications. It is not related to the
|
|
// amount of extra pixels reserved in the texture map
|
|
// (but it should be set somewhat smaller than this
|
|
// number, which is controlled by set_texture_margin(),
|
|
// to prevent bleed-in from neighboring letters in the
|
|
// texture).
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 11 poly_margin 1 730
|
|
36 14 Dtool_z_GLZyNh 0 6 49 730 0 14 Dtool_z_GLZyNh 390 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_poly_margin
|
|
// Access: Published
|
|
// Description: Returns the number of pixels of padding that is
|
|
// included around each glyph in the generated polygons.
|
|
// See set_poly_margin().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
37 14 Dtool_z_GLmkww 0 4 50 731 0 14 Dtool_z_GLmkww 323 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_page_size
|
|
// Access: Published
|
|
// Description: Sets the x, y size of the textures that are created
|
|
// for the DynamicTextFont.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 743 6 x_size 1 734 6 y_size 1 734
|
|
38 14 Dtool_z_GL_gFL 0 6 51 734 0 14 Dtool_z_GL_gFL 347 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_page_x_size
|
|
// Access: Published
|
|
// Description: Returns the x size of the textures that are created
|
|
// for the DynamicTextFont. See set_page_size().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
39 14 Dtool_z_GL_Qme 0 6 52 734 0 14 Dtool_z_GL_Qme 347 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_page_y_size
|
|
// Access: Published
|
|
// Description: Returns the y size of the textures that are created
|
|
// for the DynamicTextFont. See set_page_size().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
40 14 Dtool_z_GL72Sw 0 4 53 731 0 14 Dtool_z_GL72Sw 324 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_minfilter
|
|
// Access: Published
|
|
// Description: Sets the filter type used when minimizing the
|
|
// textures created for this font.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 6 filter 1 748
|
|
41 14 Dtool_z_GL_eoM 0 6 54 748 0 14 Dtool_z_GL_eoM 327 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_minfilter
|
|
// Access: Published
|
|
// Description: Returns the filter type used when minimizing the
|
|
// textures created for this font.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
42 14 Dtool_z_GLXnyK 0 4 55 731 0 14 Dtool_z_GLXnyK 323 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_magfilter
|
|
// Access: Published
|
|
// Description: Sets the filter type used when enlarging the
|
|
// textures created for this font.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 6 filter 1 748
|
|
43 14 Dtool_z_GLNvIn 0 6 56 748 0 14 Dtool_z_GLNvIn 326 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_magfilter
|
|
// Access: Published
|
|
// Description: Returns the filter type used when enlarging the
|
|
// textures created for this font.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
44 14 Dtool_z_GLD2hS 0 4 57 731 0 14 Dtool_z_GLD2hS 482 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_anisotropic_degree
|
|
// Access: Published
|
|
// Description: Enables or disables anisotropic filtering on the
|
|
// textures created for this font. The default value is
|
|
// specified by the text-anisotropic-degree variable.
|
|
// See Texture::set_anisotropic_degree().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 18 anisotropic_degree 1 734
|
|
45 14 Dtool_z_GLgQMP 0 6 58 734 0 14 Dtool_z_GLgQMP 361 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_anisotropic_degree
|
|
// Access: Published
|
|
// Description: Returns the current anisotropic degree for textures
|
|
// created for this font. See set_anisotropic_degree().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
46 14 Dtool_z_GLgBU9 0 4 59 731 0 14 Dtool_z_GLgBU9 477 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_render_mode
|
|
// Access: Published
|
|
// Description: Specifies the way the glyphs on this particular font
|
|
// are generated. The default is RM_texture, which is
|
|
// the only mode supported for bitmap fonts. Other modes
|
|
// are possible for most modern fonts.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 11 render_mode 1 707
|
|
47 14 Dtool_z_GLp8Mu 0 6 60 707 0 14 Dtool_z_GLp8Mu 338 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_render_mode
|
|
// Access: Published
|
|
// Description: Returns the way the glyphs on this particular font
|
|
// are generated. See set_render_mode().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
48 14 Dtool_z_GLCL6g 0 4 61 731 0 14 Dtool_z_GLCL6g 539 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_winding_order
|
|
// Access: Published
|
|
// Description: Specifies an explicitly winding order on this
|
|
// particular font. This is only necessary if the
|
|
// render_mode is RM_polygon or RM_solid, and only if
|
|
// FreeType appears to guess wrong on this font.
|
|
// Normally, you should leave this at WO_default.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 13 winding_order 1 708
|
|
49 14 Dtool_z_GL03wM 0 6 62 708 0 14 Dtool_z_GL03wM 288 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_winding_order
|
|
// Access: Published
|
|
// Description: Returns the winding order set via set_winding_order().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
50 14 Dtool_z_GLsYD9 0 4 63 731 0 14 Dtool_z_GLsYD9 832 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_fg
|
|
// Access: Published
|
|
// Description: Changes the color of the foreground pixels of the
|
|
// font as they are rendered into the font texture. The
|
|
// default is (1, 1, 1, 1), or opaque white, which
|
|
// allows text created with the font to be colored
|
|
// individually. Normally, you would not change this
|
|
// unless you really need a particular color effect to
|
|
// appear in the font itself.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 2 fg 1 749
|
|
51 14 Dtool_z_GLHrUn 0 6 64 749 0 14 Dtool_z_GLHrUn 369 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_fg
|
|
// Access: Published
|
|
// Description: Returns the color of the foreground pixels of the
|
|
// font as they are rendered into the font texture.
|
|
// See set_fg().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
52 14 Dtool_z_GLs4AW 0 4 65 731 0 14 Dtool_z_GLs4AW 1079 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_bg
|
|
// Access: Published
|
|
// Description: Changes the color of the background pixels of the
|
|
// font as they are rendered into the font texture. The
|
|
// default is (1, 1, 1, 0), or transparent white, which
|
|
// allows text created with the font to be colored
|
|
// individually. (Note that it should not generally be
|
|
// (0, 0, 0, 0), which would tend to bleed into the
|
|
// foreground color, unless you have also specified a
|
|
// outline color of (0, 0, 0, 1)) .
|
|
//
|
|
// Normally, you would not change this unless you really
|
|
// need a particular color effect to appear in the font
|
|
// itself.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 743 2 bg 1 749
|
|
53 14 Dtool_z_GLHLRA 0 6 66 749 0 14 Dtool_z_GLHLRA 369 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_bg
|
|
// Access: Published
|
|
// Description: Returns the color of the background pixels of the
|
|
// font as they are rendered into the font texture.
|
|
// See set_bg().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
54 14 Dtool_z_GLMu9w 0 4 67 731 0 14 Dtool_z_GLMu9w 1150 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::set_outline
|
|
// Access: Published
|
|
// Description: Sets up the font to have an outline around each font
|
|
// letter. This is achieved via a Gaussian post-process
|
|
// as each letter is generated; there is some runtime
|
|
// cost for this effect, but it is minimal as each
|
|
// letter is normally generated only once and then
|
|
// cached.
|
|
//
|
|
// The color is the desired color of the outline, width
|
|
// is the number of points beyond the letter that the
|
|
// outline extends (a typical font is 10 points high),
|
|
// and feather is a number in the range 0.0 .. 1.0 that
|
|
// controls the softness of the outline. Set the width
|
|
// to 0.0 to disable the outline.
|
|
//
|
|
// This should only be called before any characters have
|
|
// been requested out of the font, or immediately after
|
|
// calling clear().
|
|
//////////////////////////////////////////////////////////////////// 4 4 this 3 743 13 outline_color 1 749 13 outline_width 1 730 15 outline_feather 1 730
|
|
55 14 Dtool_z_GLU6Ic 0 6 68 749 0 14 Dtool_z_GLU6Ic 382 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_outline_color
|
|
// Access: Published
|
|
// Description: Returns the color of the outline pixels of the
|
|
// font as they are rendered into the font texture.
|
|
// See set_outline().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
56 14 Dtool_z_GL792V 0 6 69 730 0 14 Dtool_z_GL792V 383 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_outline_width
|
|
// Access: Published
|
|
// Description: Returns the width of the outline pixels of the
|
|
// font, as the number of points beyond each letter.
|
|
// See set_outline().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
57 14 Dtool_z_GLkdIP 0 6 70 730 0 14 Dtool_z_GLkdIP 380 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_outline_feather
|
|
// Access: Published
|
|
// Description: Returns the softness of the outline pixels of the
|
|
// font, as a value in the range 0.0 to 1.0.
|
|
// See set_outline().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
58 14 Dtool_z_GLjKzm 0 6 71 752 0 14 Dtool_z_GLjKzm 389 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_tex_format
|
|
// Access: Published
|
|
// Description: Returns the texture format used to render the
|
|
// individual pages. This is set automatically
|
|
// according to the colors selected.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
59 14 Dtool_z_GLnWpf 0 6 72 734 0 14 Dtool_z_GLnWpf 607 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_num_pages
|
|
// Access: Published
|
|
// Description: Returns the number of pages associated with the font.
|
|
// Initially, the font has zero pages; when the first
|
|
// piece of text is rendered with the font, it will add
|
|
// additional pages as needed. Each page is a Texture
|
|
// object that contains the images for each of the
|
|
// glyphs currently in use somewhere.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 741
|
|
60 14 Dtool_z_GL72Ni 0 7 73 753 379 14 Dtool_z_GL72Ni 595 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::get_page
|
|
// Access: Published
|
|
// Description: Returns the nth page associated with the font.
|
|
// Initially, the font has zero pages; when the first
|
|
// piece of text is rendered with the font, it will add
|
|
// additional pages as needed. Each page is a Texture
|
|
// object that contains the images for each of the
|
|
// glyphs currently in use somewhere.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 741 1 n 1 734
|
|
61 14 Dtool_z_GLqlNW 0 6 74 734 0 14 Dtool_z_GLqlNW 388 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::garbage_collect
|
|
// Access: Published
|
|
// Description: Removes all of the glyphs from the font that are no
|
|
// longer being used by any Geoms. Returns the number
|
|
// of glyphs removed.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 743
|
|
62 14 Dtool_z_GLH6z6 0 4 75 731 0 14 Dtool_z_GLH6z6 699 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::clear
|
|
// Access: Published
|
|
// Description: Drops all the glyphs out of the cache and frees any
|
|
// association with any previously-generated pages.
|
|
//
|
|
// Calling this frequently can result in wasted texture
|
|
// memory, as any previously rendered text will still
|
|
// keep a pointer to the old, previously-generated
|
|
// pages. As long as the previously rendered text
|
|
// remains around, the old pages will also remain
|
|
// around.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 743
|
|
63 14 Dtool_z_GLOAFU 0 4 76 731 0 14 Dtool_z_GLOAFU 230 ////////////////////////////////////////////////////////////////////
|
|
// Function: DynamicTextFont::write
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 741 3 out 1 732 12 indent_level 1 734
|
|
64 14 Dtool_z_GLKwHA 0 7 77 736 0 14 Dtool_z_GLKwHA 0 0
|
|
65 14 Dtool_z_GLIC2L 0 7 26 728 367 14 Dtool_z_GLIC2L 0 1 4 this 3 743
|
|
66 14 Dtool_z_GLM4UK 0 7 27 743 385 14 Dtool_z_GLM4UK 0 1 4 this 3 728
|
|
67 14 Dtool_z_GLGSLy 0 6 29 754 0 14 Dtool_z_GLGSLy 0 1 4 this 3 743
|
|
68 14 Dtool_z_GLHtRh 0 7 30 743 385 14 Dtool_z_GLHtRh 0 1 4 this 3 754
|
|
69 14 Dtool_z_GLx__8 0 6 79 729 0 14 Dtool_z_GLx__8 787 // Filename: fontPool.I
|
|
// Created by: drose (31Jan03)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::has_font
|
|
// Access: Public, Static
|
|
// Description: Returns true if the font has ever been loaded,
|
|
// false otherwise.
|
|
//////////////////////////////////////////////////////////////////// 1 8 filename 1 747
|
|
70 14 Dtool_z_GLE_Sp 0 6 80 729 0 14 Dtool_z_GLE_Sp 590 ////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::verify_font
|
|
// Access: Public, Static
|
|
// Description: Loads the given filename up into a font, if it has
|
|
// not already been loaded, and returns true to indicate
|
|
// success, or false to indicate failure. If this
|
|
// returns true, it is guaranteed that a subsequent call
|
|
// to load_font() with the same font name will
|
|
// return a valid Font pointer.
|
|
//////////////////////////////////////////////////////////////////// 1 8 filename 1 747
|
|
71 14 Dtool_z_GL8KSz 0 7 81 728 367 14 Dtool_z_GL8KSz 524 ////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::load_font
|
|
// Access: Public, Static
|
|
// Description: Loads the given filename up into a font, if it has
|
|
// not already been loaded, and returns the new font.
|
|
// If a font with the same filename was previously
|
|
// loaded, returns that one instead. If the font
|
|
// file cannot be found, returns NULL.
|
|
//////////////////////////////////////////////////////////////////// 1 8 filename 1 747
|
|
72 14 Dtool_z_GLWzk8 0 4 82 731 0 14 Dtool_z_GLWzk8 422 ////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::add_font
|
|
// Access: Public, Static
|
|
// Description: Adds the indicated already-loaded font to the
|
|
// pool. The font will always replace any
|
|
// previously-loaded font in the pool that had the
|
|
// same filename.
|
|
//////////////////////////////////////////////////////////////////// 2 8 filename 1 747 4 font 1 728
|
|
73 14 Dtool_z_GLJw6N 0 4 83 731 0 14 Dtool_z_GLJw6N 537 ////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::release_font
|
|
// Access: Public, Static
|
|
// Description: Removes the indicated font from the pool,
|
|
// indicating it will never be loaded again; the font
|
|
// may then be freed. If this function is never called,
|
|
// a reference count will be maintained on every font
|
|
// every loaded, and fonts will never be freed.
|
|
//////////////////////////////////////////////////////////////////// 1 8 filename 1 747
|
|
74 14 Dtool_z_GLxfGL 0 4 84 731 0 14 Dtool_z_GLxfGL 321 ////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::release_all_fonts
|
|
// Access: Public, Static
|
|
// Description: Releases all fonts in the pool and restores the
|
|
// pool to the empty state.
|
|
//////////////////////////////////////////////////////////////////// 0
|
|
75 14 Dtool_z_GLc8Aj 0 6 85 734 0 14 Dtool_z_GLc8Aj 465 ////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::garbage_collect
|
|
// Access: Public, Static
|
|
// Description: Releases only those fonts in the pool that have a
|
|
// reference count of exactly 1; i.e. only those
|
|
// fonts that are not being used outside of the pool.
|
|
// Returns the number of fonts released.
|
|
//////////////////////////////////////////////////////////////////// 0
|
|
76 14 Dtool_z_GLUKZ4 0 4 86 731 0 14 Dtool_z_GLUKZ4 312 ////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::list_contents
|
|
// Access: Public, Static
|
|
// Description: Lists the contents of the font pool to the
|
|
// indicated output stream.
|
|
//////////////////////////////////////////////////////////////////// 1 3 out 1 732
|
|
77 14 Dtool_z_GLV6yK 0 4 87 731 0 14 Dtool_z_GLV6yK 307 ////////////////////////////////////////////////////////////////////
|
|
// Function: FontPool::write
|
|
// Access: Published, Static
|
|
// Description: Lists the contents of the font pool to the
|
|
// indicated output stream.
|
|
//////////////////////////////////////////////////////////////////// 1 3 out 1 732
|
|
78 14 Dtool_z_GLCi_Z 0 7 91 736 0 14 Dtool_z_GLCi_Z 0 0
|
|
79 14 Dtool_z_GLeDAx 0 7 93 757 444 14 Dtool_z_GLeDAx 680 ////////////////////////////////////////////////////////////////////
|
|
// Function: StaticTextFont::Constructor
|
|
// Access: Published
|
|
// Description: The constructor expects the root node to a model
|
|
// generated via egg-mkfont, which consists of a set of
|
|
// models, one per each character in the font.
|
|
//
|
|
// If a CoordinateSystem value is specified, it informs
|
|
// the font of the coordinate system in which this model
|
|
// was generated. "up" in this coordinate system will
|
|
// be the direction of the top of the letters.
|
|
//////////////////////////////////////////////////////////////////// 2 8 font_def 1 755 2 cs 1 756
|
|
80 14 Dtool_z_GL_cW_ 0 7 93 757 444 14 Dtool_z_GL_cW_ 680 ////////////////////////////////////////////////////////////////////
|
|
// Function: StaticTextFont::Constructor
|
|
// Access: Published
|
|
// Description: The constructor expects the root node to a model
|
|
// generated via egg-mkfont, which consists of a set of
|
|
// models, one per each character in the font.
|
|
//
|
|
// If a CoordinateSystem value is specified, it informs
|
|
// the font of the coordinate system in which this model
|
|
// was generated. "up" in this coordinate system will
|
|
// be the direction of the top of the letters.
|
|
//////////////////////////////////////////////////////////////////// 1 8 font_def 1 755
|
|
81 14 Dtool_z_GLqq7s 0 7 94 736 0 14 Dtool_z_GLqq7s 0 0
|
|
82 14 Dtool_z_GLZcXD 0 7 98 758 532 14 Dtool_z_GLZcXD 226 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 0
|
|
83 14 Dtool_z_GLthC2 0 7 98 758 532 14 Dtool_z_GLthC2 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::Copy Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 copy 1 759
|
|
84 14 Dtool_z_GLk70w 0 6 99 758 0 14 Dtool_z_GLk70w 239 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::Copy Assignment Operator
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 4 copy 1 759
|
|
85 14 Dtool_z_GLQIiN 0 6 100 729 0 14 Dtool_z_GLQIiN 226 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::operator ==
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 759 5 other 1 759
|
|
86 14 Dtool_z_GLRqc8 0 6 101 729 0 14 Dtool_z_GLRqc8 716 // Filename: textProperties.I
|
|
// Created by: drose (06Apr04)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::operator !=
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 759 5 other 1 759
|
|
87 14 Dtool_z_GL1GAn 0 4 102 731 0 14 Dtool_z_GL1GAn 377 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear
|
|
// Access: Published
|
|
// Description: Unsets all properties that have been specified so
|
|
// far, and resets the TextProperties structure to its
|
|
// initial empty state.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
88 14 Dtool_z_GLK3ac 0 6 103 729 0 14 Dtool_z_GLK3ac 317 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::is_any_specified
|
|
// Access: Published
|
|
// Description: Returns true if any properties have been specified,
|
|
// false otherwise.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
89 14 Dtool_z_GLlPdf 0 4 104 731 0 14 Dtool_z_GLlPdf 382 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_default_font
|
|
// Access: Published, Static
|
|
// Description: Specifies the default font to be used for any
|
|
// TextNode whose font is uninitialized or NULL. See
|
|
// set_font().
|
|
//////////////////////////////////////////////////////////////////// 1 6 param0 0 728
|
|
90 14 Dtool_z_GLaGgR 0 7 105 728 367 14 Dtool_z_GLaGgR 382 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_default_font
|
|
// Access: Published, Static
|
|
// Description: Specifies the default font to be used for any
|
|
// TextNode whose font is uninitialized or NULL. See
|
|
// set_font().
|
|
//////////////////////////////////////////////////////////////////// 0
|
|
91 14 Dtool_z_GLLLTe 0 4 106 731 0 14 Dtool_z_GLLLTe 404 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_font
|
|
// Access: Published
|
|
// Description: Sets the font that will be used when making text. If
|
|
// this is set to NULL, the default font will be used,
|
|
// which can be set via set_default_font().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 4 font 1 728
|
|
92 14 Dtool_z_GL_wmu 0 4 107 731 0 14 Dtool_z_GL_wmu 264 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_font
|
|
// Access: Published
|
|
// Description: Restores the default font to the text.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
93 14 Dtool_z_GLzzFD 0 6 108 729 0 14 Dtool_z_GLzzFD 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_font
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
94 14 Dtool_z_GLaRE2 0 7 109 728 367 14 Dtool_z_GLaRE2 337 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_font
|
|
// Access: Published
|
|
// Description: Returns the font currently in use, if any. If no
|
|
// font is in use, this returns the default font.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
95 14 Dtool_z_GLIHvI 0 4 110 731 0 14 Dtool_z_GLIHvI 1137 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_small_caps
|
|
// Access: Published
|
|
// Description: Sets the small_caps flag. When this is set,
|
|
// lowercase letters are generated as scaled-down
|
|
// versions of their uppercase equivalents. This is
|
|
// particularly useful to set for fonts that do not have
|
|
// lowercase letters.
|
|
//
|
|
// It is also a good idea to set this for a (dynamic)
|
|
// font that has already implemented lowercase letters
|
|
// as scaled-down versions of their uppercase
|
|
// equivalents, since without this flag the texture
|
|
// memory may needlessly duplicate equivalent glyphs for
|
|
// upper and lowercase letters. Setting this flag
|
|
// causes the texture memory to share the mixed-case
|
|
// letters.
|
|
//
|
|
// The amount by which the lowercase letters are scaled
|
|
// is specified by set_small_caps_scale().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 10 small_caps 1 729
|
|
96 14 Dtool_z_GLjTKU 0 4 111 731 0 14 Dtool_z_GLjTKU 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_small_caps
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
97 14 Dtool_z_GL68B0 0 6 112 729 0 14 Dtool_z_GL68B0 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_small_caps
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
98 14 Dtool_z_GLCZAn 0 6 113 729 0 14 Dtool_z_GLCZAn 281 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_small_caps
|
|
// Access: Published
|
|
// Description: Returns the small_caps flag. See set_small_caps().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
99 14 Dtool_z_GLuF_9 0 4 114 731 0 14 Dtool_z_GLuF_9 481 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_small_caps_scale
|
|
// Access: Published
|
|
// Description: Sets the scale factor applied to lowercase letters
|
|
// from their uppercase equivalents, when the small_caps
|
|
// flag is in effect. See set_small_caps(). Normally,
|
|
// this will be a number less than one.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 16 small_caps_scale 1 730
|
|
100 14 Dtool_z_GLVrrU 0 4 115 731 0 14 Dtool_z_GLVrrU 237 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_small_caps_scale
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
101 14 Dtool_z_GLfV3a 0 6 116 729 0 14 Dtool_z_GLfV3a 235 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_small_caps_scale
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
102 14 Dtool_z_GL3_2N 0 6 117 730 0 14 Dtool_z_GL3_2N 463 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_small_caps_scale
|
|
// Access: Published
|
|
// Description: Returns the scale factor applied to lowercase letters
|
|
// from their uppercase equivalents, when the small_caps
|
|
// flag is in effect. See set_small_caps() and
|
|
// set_small_caps_scale().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
103 14 Dtool_z_GLQ85E 0 4 118 731 0 14 Dtool_z_GLQ85E 301 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_slant
|
|
// Access: Published
|
|
// Description: Specifies the factor by which the text slants to the
|
|
// right.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 5 slant 1 730
|
|
104 14 Dtool_z_GLHlo1 0 4 119 731 0 14 Dtool_z_GLHlo1 227 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_slant
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
105 14 Dtool_z_GLiZ7r 0 6 120 729 0 14 Dtool_z_GLiZ7r 224 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_slant
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
106 14 Dtool_z_GLKL7e 0 6 121 730 0 14 Dtool_z_GLKL7e 314 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_slant
|
|
// Access: Published
|
|
// Description: Returns the factor by which the text is specified to
|
|
// slant to the right.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
107 14 Dtool_z_GL9RdK 0 4 122 731 0 14 Dtool_z_GL9RdK 433 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_underscore
|
|
// Access: Published
|
|
// Description: Sets the underscore flag. When this is set,
|
|
// the text is underscored with a one-pixel line the
|
|
// same color as the text foreground, drawn at the
|
|
// baseline.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 10 underscore 1 729
|
|
108 14 Dtool_z_GL2Us1 0 4 123 731 0 14 Dtool_z_GL2Us1 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_underscore
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
109 14 Dtool_z_GLl8v1 0 6 124 729 0 14 Dtool_z_GLl8v1 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_underscore
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
110 14 Dtool_z_GLdXuo 0 6 125 729 0 14 Dtool_z_GLdXuo 281 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_underscore
|
|
// Access: Published
|
|
// Description: Returns the underscore flag. See set_underscore().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
111 14 Dtool_z_GLRj9s 0 4 126 731 0 14 Dtool_z_GLRj9s 447 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_underscore_height
|
|
// Access: Published
|
|
// Description: Specifies the vertical height of the underscore,
|
|
// relative to the text baseline. This only has meaning
|
|
// if the underscore mode is enabled with
|
|
// set_underscore().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 17 underscore_height 1 730
|
|
112 14 Dtool_z_GLYqLu 0 4 127 731 0 14 Dtool_z_GLYqLu 239 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_underscore_height
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
113 14 Dtool_z_GLxpFO 0 6 128 729 0 14 Dtool_z_GLxpFO 236 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_underscore_height
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
114 14 Dtool_z_GLp0FB 0 6 129 730 0 14 Dtool_z_GLp0FB 329 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_underscore_height
|
|
// Access: Published
|
|
// Description: Returns the vertical height of the underscore; see
|
|
// set_underscore_height().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
115 14 Dtool_z_GL7ogz 0 4 130 731 0 14 Dtool_z_GL7ogz 297 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_align
|
|
// Access: Published
|
|
// Description: Specifies the alignment of the text within its
|
|
// margins.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 10 align_type 1 718
|
|
116 14 Dtool_z_GLWteE 0 4 131 731 0 14 Dtool_z_GLWteE 270 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_align
|
|
// Access: Published
|
|
// Description: Restores the default alignment of the text.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
117 14 Dtool_z_GLSdzH 0 6 132 729 0 14 Dtool_z_GLSdzH 224 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_align
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
118 14 Dtool_z_GLl2z6 0 6 133 718 0 14 Dtool_z_GLl2z6 224 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_align
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
119 14 Dtool_z_GLC_M9 0 4 134 731 0 14 Dtool_z_GLC_M9 395 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_indent
|
|
// Access: Published
|
|
// Description: Specifies the amount of extra space that is inserted
|
|
// before the first character of each line. This can be
|
|
// thought of as a left margin.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 6 indent 1 730
|
|
120 14 Dtool_z_GLIAtK 0 4 135 731 0 14 Dtool_z_GLIAtK 318 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_indent
|
|
// Access: Published
|
|
// Description: Removes the indent setting from the text. Text
|
|
// will be as wide as it is.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
121 14 Dtool_z_GL7oOi 0 6 136 729 0 14 Dtool_z_GL7oOi 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_indent
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
122 14 Dtool_z_GLTLOV 0 6 137 730 0 14 Dtool_z_GLTLOV 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_indent
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
123 14 Dtool_z_GLlTPz 0 4 138 731 0 14 Dtool_z_GLlTPz 400 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_wordwrap
|
|
// Access: Published
|
|
// Description: Sets the text up to automatically wordwrap when it
|
|
// exceeds the indicated width. This can be thought of
|
|
// as a right margin or margin width.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 8 wordwrap 1 730
|
|
124 14 Dtool_z_GLq0Vt 0 4 139 731 0 14 Dtool_z_GLq0Vt 322 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_wordwrap
|
|
// Access: Published
|
|
// Description: Removes the wordwrap setting from the text. Text
|
|
// will be as wide as it is.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
125 14 Dtool_z_GL2SM7 0 6 140 729 0 14 Dtool_z_GL2SM7 227 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_wordwrap
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
126 14 Dtool_z_GLO3Nu 0 6 141 730 0 14 Dtool_z_GLO3Nu 227 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_wordwrap
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
127 14 Dtool_z_GLGPH5 0 4 142 731 0 14 Dtool_z_GLGPH5 671 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_preserve_trailing_whitespace
|
|
// Access: Published
|
|
// Description: Sets the preserve_trailing_whitespace flag. When
|
|
// this is set, trailing whitespace at the end of the
|
|
// line is not stripped when the text is wordwrapped (it
|
|
// is stripped by default). Since the trailing
|
|
// whitespace is invisible, this is important primarily
|
|
// for determining the proper width of a frame or card
|
|
// behind the text.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 28 preserve_trailing_whitespace 1 729
|
|
128 14 Dtool_z_GLk_Vr 0 4 143 731 0 14 Dtool_z_GLk_Vr 249 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_preserve_trailing_whitespace
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
129 14 Dtool_z_GLgu7s 0 6 144 729 0 14 Dtool_z_GLgu7s 247 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_preserve_trailing_whitespace
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
130 14 Dtool_z_GL4J6f 0 6 145 729 0 14 Dtool_z_GL4J6f 352 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_preserve_trailing_whitespace
|
|
// Access: Published
|
|
// Description: Returns the preserve_trailing_whitespace flag. See
|
|
// set_preserve_trailing_whitespace().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
131 14 Dtool_z_GLlx5m 0 4 146 731 0 14 Dtool_z_GLlx5m 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_text_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 10 text_color 1 749
|
|
132 14 Dtool_z_GLqqgv 0 4 146 731 0 14 Dtool_z_GLqqgv 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_text_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 758 1 r 1 730 1 g 1 730 1 b 1 730 1 a 1 730
|
|
133 14 Dtool_z_GL6ttP 0 4 147 731 0 14 Dtool_z_GL6ttP 352 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_text_color
|
|
// Access: Published
|
|
// Description: Removes the text color specification; the text will
|
|
// be colored whatever it was in the source font file.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
134 14 Dtool_z_GL5OXS 0 6 148 729 0 14 Dtool_z_GL5OXS 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_text_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
135 14 Dtool_z_GLBzWF 0 7 149 761 0 14 Dtool_z_GLBzWF 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_text_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
136 14 Dtool_z_GLMYoy 0 4 150 731 0 14 Dtool_z_GLMYoy 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 12 shadow_color 1 749
|
|
137 14 Dtool_z_GLL_2W 0 4 150 731 0 14 Dtool_z_GLL_2W 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 758 1 r 1 730 1 g 1 730 1 b 1 730 1 a 1 730
|
|
138 14 Dtool_z_GLCS3R 0 4 151 731 0 14 Dtool_z_GLCS3R 273 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_shadow_color
|
|
// Access: Published
|
|
// Description: Removes the shadow color specification.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
139 14 Dtool_z_GLBnqk 0 6 152 729 0 14 Dtool_z_GLBnqk 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
140 14 Dtool_z_GLZaqX 0 7 153 761 0 14 Dtool_z_GLZaqX 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
141 14 Dtool_z_GLapcN 0 4 154 731 0 14 Dtool_z_GLapcN 397 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_shadow
|
|
// Access: Published
|
|
// Description: Specifies that the text should be drawn with a
|
|
// shadow, by creating a second copy of the text and
|
|
// offsetting it slightly behind the first.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 13 shadow_offset 1 762
|
|
142 14 Dtool_z_GL3fZ9 0 4 154 731 0 14 Dtool_z_GL3fZ9 397 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_shadow
|
|
// Access: Published
|
|
// Description: Specifies that the text should be drawn with a
|
|
// shadow, by creating a second copy of the text and
|
|
// offsetting it slightly behind the first.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 758 7 xoffset 1 730 7 yoffset 1 730
|
|
143 14 Dtool_z_GL_RkQ 0 4 155 731 0 14 Dtool_z_GL_RkQ 303 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_shadow
|
|
// Access: Published
|
|
// Description: Specifies that a shadow will not be drawn behind the
|
|
// text.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
144 14 Dtool_z_GLI1O1 0 6 156 729 0 14 Dtool_z_GLI1O1 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_shadow
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
145 14 Dtool_z_GLgrOo 0 7 157 766 0 14 Dtool_z_GLgrOo 371 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_shadow
|
|
// Access: Published
|
|
// Description: Returns the offset of the shadow as set by
|
|
// set_shadow(). It is an error to call this if
|
|
// has_shadow() is false.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
146 14 Dtool_z_GLLXjT 0 4 158 731 0 14 Dtool_z_GLLXjT 649 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_bin
|
|
// Access: Published
|
|
// Description: Names the CullBin that the text geometry should be
|
|
// assigned to. If this is set, then a CullBinAttrib
|
|
// will be created to explicitly place each component in
|
|
// the named bin.
|
|
//
|
|
// The draw_order value will also be passed to each
|
|
// CullBinAttrib as appropriate; this is particularly
|
|
// useful if this names a CullBinFixed, e.g. "fixed".
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 3 bin 1 747
|
|
147 14 Dtool_z_GLAeJK 0 4 159 731 0 14 Dtool_z_GLAeJK 420 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_bin
|
|
// Access: Published
|
|
// Description: Removes the effect of a previous call to
|
|
// set_bin(). Text will be drawn in whatever bin
|
|
// it would like to be drawn in, with no explicit
|
|
// ordering.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
148 14 Dtool_z_GLmxqz 0 6 160 729 0 14 Dtool_z_GLmxqz 324 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_bin
|
|
// Access: Published
|
|
// Description: Returns true if an explicit drawing bin has been
|
|
// set via set_bin(), false otherwise.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
149 14 Dtool_z_GLOWqm 0 6 161 747 0 14 Dtool_z_GLOWqm 323 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_bin
|
|
// Access: Published
|
|
// Description: Returns the drawing bin set with set_bin(), or empty
|
|
// string if no bin has been set.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
150 14 Dtool_z_GL0od6 0 6 162 734 0 14 Dtool_z_GL0od6 771 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_draw_order
|
|
// Access: Published
|
|
// Description: Sets the drawing order of text created by the
|
|
// TextNode. This is actually the draw order of the
|
|
// card and frame. The shadow is drawn at
|
|
// _draw_order+1, and the text at _draw_order+2.
|
|
//
|
|
// This affects the sorting order assigned to the nodes
|
|
// as they are created, and also is passed to whatever
|
|
// bin may be assigned via set_bin().
|
|
//
|
|
// The return value is the first unused draw_order
|
|
// number, e.g. _draw_order + 3.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 10 draw_order 1 734
|
|
151 14 Dtool_z_GLP1HS 0 4 163 731 0 14 Dtool_z_GLP1HS 232 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_draw_order
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
152 14 Dtool_z_GLVlQH 0 6 164 729 0 14 Dtool_z_GLVlQH 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_draw_order
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
153 14 Dtool_z_GL_LP6 0 6 165 734 0 14 Dtool_z_GL_LP6 282 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_draw_order
|
|
// Access: Published
|
|
// Description: Returns the drawing order set with set_draw_order().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
154 14 Dtool_z_GLFusw 0 4 166 731 0 14 Dtool_z_GLFusw 409 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_tab_width
|
|
// Access: Published
|
|
// Description: Sets the width of each tab stop, in screen units. A
|
|
// tab character embedded in the text will advance the
|
|
// horizontal position to the next tab stop.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 9 tab_width 1 730
|
|
155 14 Dtool_z_GLpdwn 0 4 167 731 0 14 Dtool_z_GLpdwn 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_tab_width
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
156 14 Dtool_z_GLnpZ0 0 6 168 729 0 14 Dtool_z_GLnpZ0 228 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_tab_width
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
157 14 Dtool_z_GLPKYn 0 6 169 730 0 14 Dtool_z_GLPKYn 271 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_tab_width
|
|
// Access: Published
|
|
// Description: Returns the width set via set_tab_width().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
158 14 Dtool_z_GLUBRK 0 4 170 731 0 14 Dtool_z_GLUBRK 962 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_glyph_scale
|
|
// Access: Published
|
|
// Description: Specifies the factor by which to scale each letter of
|
|
// the text as it is placed, in addition to any scales
|
|
// inherited from the node or from set_text_scale().
|
|
// This can be used (possibly in conjunction with
|
|
// set_glyph_shift()) to implement superscripting or
|
|
// subscripting.
|
|
//
|
|
// The glyph scale is cumulative when applied to nested
|
|
// TextProperties. It is intended primarily for
|
|
// implementing superscripts, not for scaling the text
|
|
// in general. See also set_text_scale(), which is
|
|
// intended primarily for scaling the text in general,
|
|
// and is not cumulative.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 11 glyph_scale 1 730
|
|
159 14 Dtool_z_GL89_H 0 4 171 731 0 14 Dtool_z_GL89_H 233 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_glyph_scale
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
160 14 Dtool_z_GLQy8B 0 6 172 729 0 14 Dtool_z_GLQy8B 230 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_glyph_scale
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
161 14 Dtool_z_GL5U70 0 6 173 730 0 14 Dtool_z_GL5U70 322 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_glyph_scale
|
|
// Access: Published
|
|
// Description: Returns the scale factor of each letter as specified
|
|
// by set_glyph_scale().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
162 14 Dtool_z_GL_nuw 0 4 174 731 0 14 Dtool_z_GL_nuw 471 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_glyph_shift
|
|
// Access: Published
|
|
// Description: Specifies a vertical amount to shift each letter of
|
|
// the text as it is placed. This can be used (possibly
|
|
// in conjunction with set_glyph_scale()) to implement
|
|
// superscripting or subscripting.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 11 glyph_shift 1 730
|
|
163 14 Dtool_z_GLTz3h 0 4 175 731 0 14 Dtool_z_GLTz3h 233 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_glyph_shift
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
164 14 Dtool_z_GLzIZo 0 6 176 729 0 14 Dtool_z_GLzIZo 230 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_glyph_shift
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
165 14 Dtool_z_GLrrYb 0 6 177 730 0 14 Dtool_z_GLrrYb 324 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_glyph_shift
|
|
// Access: Published
|
|
// Description: Returns the vertical shift of each letter as
|
|
// specified by set_glyph_shift().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
166 14 Dtool_z_GL2BFI 0 4 178 731 0 14 Dtool_z_GL2BFI 580 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::set_text_scale
|
|
// Access: Published
|
|
// Description: Specifies the factor by which to scale the text, in
|
|
// addition to any scalings imposed by the node, as well
|
|
// as in addition to the glyph scale.
|
|
//
|
|
// The text scale is not cumulative when applied to
|
|
// nested TextProperties. See also set_glyph_scale(),
|
|
// which is cumulative.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 10 text_scale 1 730
|
|
167 14 Dtool_z_GLmX6N 0 4 179 731 0 14 Dtool_z_GLmX6N 232 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::clear_text_scale
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 758
|
|
168 14 Dtool_z_GL0prD 0 6 180 729 0 14 Dtool_z_GL0prD 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::has_text_scale
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
169 14 Dtool_z_GLtEq2 0 6 181 730 0 14 Dtool_z_GLtEq2 317 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::get_text_scale
|
|
// Access: Published
|
|
// Description: Returns the scale factor of the text as specified
|
|
// by set_text_scale().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 759
|
|
170 14 Dtool_z_GLlo22 0 4 182 731 0 14 Dtool_z_GLlo22 374 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::add_properties
|
|
// Access: Published
|
|
// Description: Sets any properties that are explicitly specified in
|
|
// other on this object. Leaves other properties
|
|
// unchanged.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 758 5 other 1 759
|
|
171 14 Dtool_z_GLdHuP 0 4 183 731 0 14 Dtool_z_GLdHuP 220 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::write
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 759 3 out 1 732 12 indent_level 1 734
|
|
172 14 Dtool_z_GLdtgi 0 4 183 731 0 14 Dtool_z_GLdtgi 220 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextProperties::write
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 759 3 out 1 732
|
|
173 14 Dtool_z_GL_CJ5 0 7 184 736 0 14 Dtool_z_GL_CJ5 0 0
|
|
174 14 Dtool_z_GLN6lL 0 7 187 767 540 14 Dtool_z_GLN6lL 710 // Filename: textGraphic.I
|
|
// Created by: drose (18Aug06)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 0
|
|
175 14 Dtool_z_GLpCNu 0 7 187 767 540 14 Dtool_z_GLpCNu 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 5 model 1 768 5 frame 1 749
|
|
176 14 Dtool_z_GLHFvO 0 7 187 767 540 14 Dtool_z_GLHFvO 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 5 5 model 1 768 4 left 1 730 5 right 1 730 6 bottom 1 730 3 top 1 730
|
|
177 14 Dtool_z_GLvDG5 0 7 188 773 0 14 Dtool_z_GLvDG5 320 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::get_model
|
|
// Access: Published
|
|
// Description: Returns the NodePath associated with the graphic,
|
|
// that renders the desired image.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 771
|
|
178 14 Dtool_z_GLc221 0 4 189 731 0 14 Dtool_z_GLc221 387 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::set_model
|
|
// Access: Published
|
|
// Description: Changes the NodePath associated with the graphic.
|
|
// This NodePath should contain geometry that will
|
|
// render the desired graphic image.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 767 5 model 1 768
|
|
179 14 Dtool_z_GLE9om 0 7 190 761 0 14 Dtool_z_GLE9om 786 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::get_frame
|
|
// Access: Published
|
|
// Description: Returns the frame specified for the graphic. This is
|
|
// the amount of space that will be reserved for the
|
|
// graphic when it is embedded in a text paragraph, in
|
|
// the form (left, right, bottom, top).
|
|
//
|
|
// The actual graphic, as rendered by the NodePath
|
|
// specified via set_model(), should more or less fit
|
|
// within this rectangle. It is not required to fit
|
|
// completely within it, but if it does not, it may
|
|
// visually overlap with nearby text.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 771
|
|
180 14 Dtool_z_GLXWvI 0 4 191 731 0 14 Dtool_z_GLXWvI 329 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::set_frame
|
|
// Access: Published
|
|
// Description: Specifies the (left, right, bottom, top) bounding
|
|
// frame for the graphic. See get_frame().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 767 5 frame 1 749
|
|
181 14 Dtool_z_GLAwvx 0 4 191 731 0 14 Dtool_z_GLAwvx 329 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::set_frame
|
|
// Access: Published
|
|
// Description: Specifies the (left, right, bottom, top) bounding
|
|
// frame for the graphic. See get_frame().
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 767 4 left 1 730 5 right 1 730 6 bottom 1 730 3 top 1 730
|
|
182 14 Dtool_z_GL_b5d 0 6 192 729 0 14 Dtool_z_GL_b5d 282 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::get_instance_flag
|
|
// Access: Published
|
|
// Description: Returns the instance_flag. See set_instance_flag().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 771
|
|
183 14 Dtool_z_GLteDv 0 4 193 731 0 14 Dtool_z_GLteDv 664 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextGraphic::set_instance_flag
|
|
// Access: Published
|
|
// Description: Sets the instance_flag. When this is true, the
|
|
// graphic is directly instanced to the scene graph
|
|
// whenever it appears; when it is false, the graphic is
|
|
// copied. The default is false, which is best for most
|
|
// applications. You might need to set it true for
|
|
// special kinds of "graphics" like interactive
|
|
// elements, for instance a PGEntry.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 767 13 instance_flag 1 729
|
|
184 14 Dtool_z_GLYE4B 0 4 196 731 0 14 Dtool_z_GLYE4B 707 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::set_properties
|
|
// Access: Published
|
|
// 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.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 774 4 name 1 747 10 properties 1 759
|
|
185 14 Dtool_z_GL4Bnj 0 7 197 758 532 14 Dtool_z_GL4Bnj 668 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::get_properties
|
|
// Access: Published
|
|
// 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.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 774 4 name 1 747
|
|
186 14 Dtool_z_GLGLtg 0 6 198 729 0 14 Dtool_z_GLGLtg 687 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::has_properties
|
|
// Access: Published
|
|
// 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.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 775 4 name 1 747
|
|
187 14 Dtool_z_GLTUsF 0 4 199 731 0 14 Dtool_z_GLTUsF 316 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::clear_properties
|
|
// Access: Published
|
|
// Description: Removes the named TextProperties structure from the
|
|
// manager.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 774 4 name 1 747
|
|
188 14 Dtool_z_GLxUqK 0 4 200 731 0 14 Dtool_z_GLxUqK 570 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::set_graphic
|
|
// Access: Published
|
|
// 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.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 774 4 name 1 747 5 model 1 768
|
|
189 14 Dtool_z_GLv_WR 0 4 200 731 0 14 Dtool_z_GLv_WR 705 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::set_graphic
|
|
// Access: Published
|
|
// 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.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 774 4 name 1 747 7 graphic 1 771
|
|
190 14 Dtool_z_GLu958 0 7 201 767 540 14 Dtool_z_GLu958 653 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::get_graphic
|
|
// Access: Published
|
|
// 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.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 774 4 name 1 747
|
|
191 14 Dtool_z_GL_5_r 0 6 202 729 0 14 Dtool_z_GL_5_r 669 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::has_graphic
|
|
// Access: Published
|
|
// 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.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 775 4 name 1 747
|
|
192 14 Dtool_z_GLxHIW 0 4 203 731 0 14 Dtool_z_GLxHIW 310 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::clear_graphic
|
|
// Access: Published
|
|
// Description: Removes the named TextGraphic structure from the
|
|
// manager.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 774 4 name 1 747
|
|
193 14 Dtool_z_GLUMME 0 4 204 731 0 14 Dtool_z_GLUMME 228 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::write
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 775 3 out 1 732 12 indent_level 1 734
|
|
194 14 Dtool_z_GL7FOX 0 4 204 731 0 14 Dtool_z_GL7FOX 228 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::write
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 775 3 out 1 732
|
|
195 14 Dtool_z_GLBXYT 0 6 205 774 0 14 Dtool_z_GLBXYT 325 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextPropertiesManager::get_global_ptr
|
|
// Access: Published, Static
|
|
// Description: Returns the pointer to the global TextPropertiesManager
|
|
// object.
|
|
//////////////////////////////////////////////////////////////////// 0
|
|
196 14 Dtool_z_GLmLuN 0 7 207 779 553 14 Dtool_z_GLmLuN 231 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::Copy Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 copy 1 777
|
|
197 14 Dtool_z_GLUbOE 0 7 207 779 553 14 Dtool_z_GLUbOE 226 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 7 encoder 1 780
|
|
198 14 Dtool_z_GLD2J3 0 6 208 779 0 14 Dtool_z_GLD2J3 239 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::Copy Assignment Operator
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 779 4 copy 1 777
|
|
199 14 Dtool_z_GLnx5n 0 4 210 731 0 14 Dtool_z_GLnx5n 268 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::clear
|
|
// Access: Published
|
|
// Description: Reinitializes the contents of the TextAssembler.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 779
|
|
200 14 Dtool_z_GLuwMB 0 4 211 731 0 14 Dtool_z_GLuwMB 1061 // Filename: textAssembler.I
|
|
// Created by: drose (06Apr04)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_usage_hint
|
|
// Access: Published
|
|
// Description: Specifies the UsageHint that will be applied to
|
|
// generated geometry. The default is UH_static, which
|
|
// is probably the right setting, but if you know the
|
|
// TextNode's geometry will have a short lifespan, it
|
|
// may be better to set it to UH_stream. See
|
|
// geomEnums.h.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 779 10 usage_hint 1 781
|
|
201 14 Dtool_z_GLM1BZ 0 6 212 781 0 14 Dtool_z_GLM1BZ 334 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_usage_hint
|
|
// Access: Published
|
|
// Description: Returns the UsageHint that will be applied to
|
|
// generated geometry. See set_usage_hint().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
202 14 Dtool_z_GLUkOG 0 4 213 731 0 14 Dtool_z_GLUkOG 557 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_max_rows
|
|
// Access: Published
|
|
// Description: If max_rows is greater than zero, no more than
|
|
// max_rows will be accepted. Text beyond that will be
|
|
// truncated.
|
|
//
|
|
// Setting this will not truncate text immediately. You
|
|
// must follow this up with a call to set_wtext() to
|
|
// truncate the existing text.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 779 8 max_rows 1 734
|
|
203 14 Dtool_z_GLMIDM 0 6 214 734 0 14 Dtool_z_GLMIDM 371 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_max_rows
|
|
// Access: Published
|
|
// Description: If max_rows is greater than zero, no more than
|
|
// max_rows will be accepted. Text beyond that will be
|
|
// truncated.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
204 14 Dtool_z_GLQ2vI 0 4 215 731 0 14 Dtool_z_GLQ2vI 313 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_dynamic_merge
|
|
// Access: Published
|
|
// Description: Sets the dynamic_merge flag. See
|
|
// TextNode::set_flatten_flags().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 779 13 dynamic_merge 1 729
|
|
205 14 Dtool_z_GL47hp 0 6 216 729 0 14 Dtool_z_GL47hp 316 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_dynamic_merge
|
|
// Access: Published
|
|
// Description: Returns the dynamic_merge flag. See
|
|
// TextNode::set_flatten_flags().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
206 14 Dtool_z_GLSOKH 0 4 217 731 0 14 Dtool_z_GLSOKH 346 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_multiline_mode
|
|
// Access: Published
|
|
// Description: Sets the multiline mode flag. Set the multiline
|
|
// mode to allow text to wrap. It defaults to true.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 779 4 flag 1 729
|
|
207 14 Dtool_z_GLD0fZ 0 6 218 729 0 14 Dtool_z_GLD0fZ 318 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_multiline_mode
|
|
// Access: Published
|
|
// Description: Returns the multline_mode flag. See
|
|
// TextNode::set_multiline_mode().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
208 14 Dtool_z_GLILcD 0 4 219 731 0 14 Dtool_z_GLILcD 384 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_properties
|
|
// Access: Published
|
|
// Description: Specifies the default TextProperties that are applied
|
|
// to the text in the absence of any nested property
|
|
// change sequences.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 779 10 properties 1 759
|
|
209 14 Dtool_z_GLSkIx 0 6 220 759 0 14 Dtool_z_GLSkIx 382 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_properties
|
|
// Access: Published
|
|
// Description: Returns the default TextProperties that are applied
|
|
// to the text in the absence of any nested property
|
|
// change sequences.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
210 14 Dtool_z_GLmyxC 0 6 220 759 0 14 Dtool_z_GLmyxC 371 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_properties
|
|
// Access: Published
|
|
// Description: Returns the TextProperties in effect for the object
|
|
// at the indicated position in the pre-wordwrapped
|
|
// string.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 777 1 n 1 734
|
|
211 14 Dtool_z_GLClP5 0 6 220 759 0 14 Dtool_z_GLClP5 345 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_properties
|
|
// Access: Published
|
|
// Description: Returns the TextProperties in effect for the object
|
|
// at the indicated position in the indicated row.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 777 1 r 1 734 1 c 1 734
|
|
212 14 Dtool_z_GLQBZl 0 6 221 729 0 14 Dtool_z_GLQBZl 629 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_wtext
|
|
// Access: Published
|
|
// Description: Accepts a new text string and associated properties
|
|
// structure, and precomputes the wordwrapping layout
|
|
// appropriately. After this call,
|
|
// get_wordwrapped_wtext() and get_num_rows() can be
|
|
// called.
|
|
//
|
|
// The return value is true if all the text is accepted,
|
|
// or false if some was truncated (see set_max_rows()).
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 779 5 wtext 1 747
|
|
213 14 Dtool_z_GLIKgD 0 6 222 729 0 14 Dtool_z_GLIKgD 956 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::set_wsubstr
|
|
// Access: Published
|
|
// Description: Replaces the 'count' characters from 'start' of the
|
|
// current text with the indicated replacement text. If
|
|
// the replacement text does not have count characters,
|
|
// the length of the string will be changed accordingly.
|
|
//
|
|
// The substring may include nested formatting
|
|
// characters, but they must be self-contained and
|
|
// self-closed. The formatting characters are not
|
|
// literally saved in the internal string; they are
|
|
// parsed at the time of the set_wsubstr() call.
|
|
//
|
|
// The return value is true if all the text is accepted,
|
|
// or false if some was truncated (see set_max_rows()).
|
|
//////////////////////////////////////////////////////////////////// 4 4 this 3 779 5 wtext 1 747 5 start 1 734 5 count 1 734
|
|
214 14 Dtool_z_GLleel 0 6 223 747 0 14 Dtool_z_GLleel 702 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_plain_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text, without any embedded properties characters. If
|
|
// there is an embedded graphic object, a zero value is
|
|
// inserted in that position.
|
|
//
|
|
// This string has the same length as
|
|
// get_num_characters(), and the characters in this
|
|
// string correspond one-to-one with the characters
|
|
// returned by get_character(n).
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
215 14 Dtool_z_GLBYbI 0 6 224 747 0 14 Dtool_z_GLBYbI 837 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_wordwrapped_plain_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text, with newlines inserted according to the
|
|
// wordwrapping. The string will contain no embedded
|
|
// properties characters. If there is an embedded
|
|
// graphic object, a zero value is inserted in that
|
|
// position.
|
|
//
|
|
// This string has the same number of newline characters
|
|
// as get_num_rows(), and the characters in this string
|
|
// correspond one-to-one with the characters returned by
|
|
// get_character(r, c).
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
216 14 Dtool_z_GLgmhF 0 6 225 747 0 14 Dtool_z_GLgmhF 547 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text.
|
|
//
|
|
// The string will contain embedded properties
|
|
// characters, which may not exactly match the embedded
|
|
// properties characters of the original string, but it
|
|
// will encode the same way.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
217 14 Dtool_z_GLuhaA 0 6 226 747 0 14 Dtool_z_GLuhaA 1004 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_wordwrapped_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text, with newlines inserted according to the
|
|
// wordwrapping.
|
|
//
|
|
// The string will contain embedded properties
|
|
// characters, which may not exactly match the embedded
|
|
// properties characters of the original string, but it
|
|
// will encode the same way.
|
|
//
|
|
// Embedded properties characters will be closed before
|
|
// every newline, then reopened (if necessary) on the
|
|
// subsequent character following the newline. This
|
|
// means it will be safe to divide the text up at the
|
|
// newline characters and treat each line as an
|
|
// independent piece.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
218 14 Dtool_z_GL4jF2 0 6 228 734 0 14 Dtool_z_GL4jF2 630 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_r
|
|
// Access: Published
|
|
// Description: Computes the row index of the nth character or
|
|
// graphic object in the text and returns it.
|
|
//
|
|
// If the nth character is not a normal printable
|
|
// character with a position in the wordwrapped string,
|
|
// returns -1 (for instance, a soft-hyphen character, or
|
|
// a newline character, may not have a corresponding
|
|
// position).
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 777 1 n 1 734
|
|
219 14 Dtool_z_GLolgx 0 6 229 734 0 14 Dtool_z_GLolgx 633 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_c
|
|
// Access: Published
|
|
// Description: Computes the column index of the nth character or
|
|
// graphic object in the text and returns it.
|
|
//
|
|
// If the nth character is not a normal printable
|
|
// character with a position in the wordwrapped string,
|
|
// returns -1 (for instance, a soft-hyphen character, or
|
|
// a newline character, may not have a corresponding
|
|
// position).
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 777 1 n 1 734
|
|
220 14 Dtool_z_GLu7e7 0 6 230 734 0 14 Dtool_z_GLu7e7 586 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_index
|
|
// Access: Published
|
|
// Description: Computes the character index of the character at the
|
|
// rth row and cth column position. This is the inverse
|
|
// of calc_r_c().
|
|
//
|
|
// It is legal for c to exceed the index number of the
|
|
// last column by 1, and it is legal for r to exceed the
|
|
// index number of the last row by 1, if c is 0.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 777 1 r 1 734 1 c 1 734
|
|
221 14 Dtool_z_GL2nEz 0 6 231 734 0 14 Dtool_z_GL2nEz 312 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_num_characters
|
|
// Access: Published
|
|
// Description: Returns the number of characters of text, before
|
|
// wordwrapping.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
222 14 Dtool_z_GLzobk 0 6 232 783 0 14 Dtool_z_GLzobk 444 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_character
|
|
// Access: Published
|
|
// Description: Returns the character at the indicated position in
|
|
// the pre-wordwrapped string. If the object at this
|
|
// position is a graphic object instead of a character,
|
|
// returns 0.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 777 1 n 1 734
|
|
223 14 Dtool_z_GL7eHM 0 6 232 783 0 14 Dtool_z_GL7eHM 418 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_character
|
|
// Access: Published
|
|
// Description: Returns the character at the indicated position in
|
|
// the indicated row. If the object at this position is
|
|
// a graphic object instead of a character, returns 0.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 777 1 r 1 734 1 c 1 734
|
|
224 14 Dtool_z_GLGr5s 0 6 233 771 0 14 Dtool_z_GLGr5s 450 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_graphic
|
|
// Access: Published
|
|
// Description: Returns the graphic object at the indicated position
|
|
// in the pre-wordwrapped string. If the object at this
|
|
// position is a character instead of a graphic object,
|
|
// returns NULL.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 777 1 n 1 734
|
|
225 14 Dtool_z_GLOuRk 0 6 233 771 0 14 Dtool_z_GLOuRk 441 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_graphic
|
|
// Access: Published
|
|
// Description: Returns the graphic object at the indicated position
|
|
// in the indicated row. If the object at this position
|
|
// is a character instead of a graphic object, returns
|
|
// NULL.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 777 1 r 1 734 1 c 1 734
|
|
226 14 Dtool_z_GL2hc3 0 6 234 730 0 14 Dtool_z_GL2hc3 342 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_width
|
|
// Access: Published
|
|
// Description: Returns the width of the character or object at the
|
|
// indicated position in the pre-wordwrapped string.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 777 1 n 1 734
|
|
227 14 Dtool_z_GLogry 0 6 234 730 0 14 Dtool_z_GLogry 333 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_width
|
|
// Access: Published
|
|
// Description: Returns the width of the character or object at the
|
|
// indicated position in the indicated row.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 777 1 r 1 734 1 c 1 734
|
|
228 14 Dtool_z_GLT6xG 0 6 235 734 0 14 Dtool_z_GLT6xG 327 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_num_rows
|
|
// Access: Published
|
|
// Description: Returns the number of rows of text after it has all
|
|
// been wordwrapped and assembled.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
229 14 Dtool_z_GL_GLI 0 6 236 734 0 14 Dtool_z_GL_GLI 315 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_num_cols
|
|
// Access: Published
|
|
// Description: Returns the number of characters and/or graphic
|
|
// objects in the nth row.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 777 1 r 1 734
|
|
230 14 Dtool_z_GLjVRO 0 6 237 730 0 14 Dtool_z_GLjVRO 582 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_xpos
|
|
// Access: Published
|
|
// Description: Returns the x position of the origin of the character
|
|
// or graphic object at the indicated position in the
|
|
// indicated row.
|
|
//
|
|
// It is legal for c to exceed the index number of the
|
|
// last column by 1, and it is legal for r to exceed the
|
|
// index number of the last row by 1, if c is 0.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 777 1 r 1 734 1 c 1 734
|
|
231 14 Dtool_z_GLm8Ru 0 6 238 730 0 14 Dtool_z_GLm8Ru 484 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_ypos
|
|
// Access: Published
|
|
// Description: Returns the y position of the origin of all of the
|
|
// characters or graphic objects in the indicated row.
|
|
//
|
|
// It is legal for r to exceed the index number of the
|
|
// last row by 1. The value of c is presently ignored.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 777 1 r 1 734 1 c 1 734
|
|
232 14 Dtool_z_GLtnEV 0 7 239 755 0 14 Dtool_z_GLtnEV 523 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::assemble_text
|
|
// Access: Published
|
|
// Description: Actually assembles all of the text into a GeomNode,
|
|
// and returns the node (or possibly a parent of the
|
|
// node, to keep the shadow separate). Once this has
|
|
// been called, you may query the extents of the text
|
|
// via get_ul(), get_lr().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 779
|
|
233 14 Dtool_z_GLvG9i 0 6 240 784 0 14 Dtool_z_GLvG9i 315 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_ul
|
|
// Access: Published
|
|
// Description: Returns the upper-left corner of the assembled text,
|
|
// in 2-d text coordinates.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
234 14 Dtool_z_GLsDuE 0 6 241 784 0 14 Dtool_z_GLsDuE 316 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::get_lr
|
|
// Access: Published
|
|
// Description: Returns the lower-right corner of the assembled text,
|
|
// in 2-d text coordinates.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 777
|
|
235 14 Dtool_z_GLR7hM 0 6 242 730 0 14 Dtool_z_GLR7hM 281 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_width
|
|
// Access: Published, Static
|
|
// Description: Returns the width of a single TextGraphic image.
|
|
//////////////////////////////////////////////////////////////////// 2 7 graphic 1 771 10 properties 1 759
|
|
236 14 Dtool_z_GLJf_A 0 6 242 730 0 14 Dtool_z_GLJf_A 486 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::calc_width
|
|
// Access: Published, Static
|
|
// Description: Returns the width of a single character, according to
|
|
// its associated font. This also correctly calculates
|
|
// the width of cheesy ligatures and accented
|
|
// characters, which may not exist in the font as such.
|
|
//////////////////////////////////////////////////////////////////// 2 9 character 1 783 10 properties 1 759
|
|
237 14 Dtool_z_GLnw6l 0 6 243 729 0 14 Dtool_z_GLnw6l 1045 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::has_exact_character
|
|
// Access: Published, Static
|
|
// Description: Returns true if the named character exists in the
|
|
// font exactly as named, false otherwise. Note that
|
|
// because Panda can assemble glyphs together
|
|
// automatically using cheesy accent marks, this is not
|
|
// a reliable indicator of whether a suitable glyph can
|
|
// be rendered for the character. For that, use
|
|
// has_character() instead.
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// but returns false for characters that would render
|
|
// with the "invalid glyph". It also returns false for
|
|
// characters that would be synthesized within Panda,
|
|
// but see has_character().
|
|
//////////////////////////////////////////////////////////////////// 2 9 character 1 783 10 properties 1 759
|
|
238 14 Dtool_z_GLHADO 0 6 244 729 0 14 Dtool_z_GLHADO 733 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::has_character
|
|
// Access: Published, Static
|
|
// Description: Returns true if the named character exists in the
|
|
// font or can be synthesized by Panda, false otherwise.
|
|
// (Panda can synthesize some accented characters by
|
|
// combining similar-looking glyphs from the font.)
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// but returns false for characters that would render
|
|
// with the "invalid glyph".
|
|
//////////////////////////////////////////////////////////////////// 2 9 character 1 783 10 properties 1 759
|
|
239 14 Dtool_z_GL_UGk 0 6 245 729 0 14 Dtool_z_GL_UGk 1131 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextAssembler::is_whitespace
|
|
// Access: Published, Static
|
|
// Description: Returns true if the indicated character represents
|
|
// whitespace in the font, or false if anything visible
|
|
// will be rendered for it.
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// and returns false for any other characters, including
|
|
// characters that do not exist in the font (these would
|
|
// be rendered with the "invalid glyph", which is
|
|
// visible).
|
|
//
|
|
// Note that this function can be reliably used to
|
|
// identify Unicode whitespace characters only if the
|
|
// font has all of the whitespace characters defined.
|
|
// It will return false for any character not in the
|
|
// font, even if it is an official Unicode whitespace
|
|
// character.
|
|
//////////////////////////////////////////////////////////////////// 2 9 character 1 783 10 properties 1 759
|
|
240 14 Dtool_z_GLxTrj 0 7 255 786 597 14 Dtool_z_GLxTrj 220 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::Constructor
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 name 1 747
|
|
241 14 Dtool_z_GLNhOQ 0 7 255 786 597 14 Dtool_z_GLNhOQ 369 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::Copy Constructor
|
|
// Access: Published
|
|
// Description: It's sort of a copy constructor: it copies the
|
|
// indicated TextProperties, without copying a complete
|
|
// TextNode.
|
|
//////////////////////////////////////////////////////////////////// 2 4 name 1 747 4 copy 1 759
|
|
242 14 Dtool_z_GL64_2 0 6 258 730 0 14 Dtool_z_GL64_2 994 // Filename: textNode.I
|
|
// Created by: drose (13Mar02)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_line_height
|
|
// Access: Published
|
|
// Description: Returns the number of units high each line of text
|
|
// is. This is based on the font. Note that it is
|
|
// possible for the text to include nested font change
|
|
// commands, in which case the value of this method is
|
|
// questionable.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
243 14 Dtool_z_GLgyMC 0 4 259 731 0 14 Dtool_z_GLgyMC 439 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_max_rows
|
|
// Access: Published
|
|
// Description: Sets the maximum number of rows that may be formatted
|
|
// by the TextNode. If more text than this is
|
|
// attempted, it will be truncated and has_overflow()
|
|
// will return true.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 8 max_rows 1 734
|
|
244 14 Dtool_z_GLIv_f 0 4 260 731 0 14 Dtool_z_GLIv_f 323 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_max_rows
|
|
// Access: Published
|
|
// Description: Resets the TextNode's default behavior of not
|
|
// limiting the number of rows of text.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
245 14 Dtool_z_GLafTN 0 6 261 729 0 14 Dtool_z_GLafTN 342 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_max_rows
|
|
// Access: Published
|
|
// Description: Returns true if a limit on the height of the TextNode
|
|
// has been set via set_max_rows(), false otherwise.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
246 14 Dtool_z_GL_cGl 0 6 262 734 0 14 Dtool_z_GL_cGl 315 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_max_rows
|
|
// Access: Published
|
|
// Description: Returns the limit on the height of the TextNode
|
|
// specified by set_max_rows().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
247 14 Dtool_z_GLP7gc 0 6 263 729 0 14 Dtool_z_GLP7gc 364 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_overflow
|
|
// Access: Published
|
|
// Description: Returns true if the last text set on the text node
|
|
// exceeded the max_rows constraint, or false if it all
|
|
// fit.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
248 14 Dtool_z_GLF8Bv 0 4 264 731 0 14 Dtool_z_GLF8Bv 224 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 11 frame_color 1 749
|
|
249 14 Dtool_z_GLUbTz 0 4 264 731 0 14 Dtool_z_GLUbTz 224 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 786 1 r 1 730 1 g 1 730 1 b 1 730 1 a 1 730
|
|
250 14 Dtool_z_GLgap6 0 7 265 761 0 14 Dtool_z_GLgap6 224 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
251 14 Dtool_z_GLAoPk 0 4 266 731 0 14 Dtool_z_GLAoPk 224 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_border
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 786 4 size 1 730 10 uv_portion 1 730
|
|
252 14 Dtool_z_GL3G6F 0 4 267 731 0 14 Dtool_z_GL3G6F 226 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_card_border
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
253 14 Dtool_z_GLrI81 0 6 268 730 0 14 Dtool_z_GLrI81 229 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_border_size
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
254 14 Dtool_z_GL0YDM 0 6 269 730 0 14 Dtool_z_GL0YDM 235 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_border_uv_portion
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
255 14 Dtool_z_GL_Hvs 0 6 270 729 0 14 Dtool_z_GL_Hvs 224 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_card_border
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
256 14 Dtool_z_GLzpf9 0 4 271 731 0 14 Dtool_z_GLzpf9 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 10 card_color 1 749
|
|
257 14 Dtool_z_GL_JmF 0 4 271 731 0 14 Dtool_z_GL_JmF 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 786 1 r 1 730 1 g 1 730 1 b 1 730 1 a 1 730
|
|
258 14 Dtool_z_GLJA_Y 0 7 272 761 0 14 Dtool_z_GLJA_Y 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
259 14 Dtool_z_GLhpTx 0 4 273 731 0 14 Dtool_z_GLhpTx 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_texture
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 12 card_texture 1 789
|
|
260 14 Dtool_z_GLzHSq 0 4 274 731 0 14 Dtool_z_GLzHSq 227 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_card_texture
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
261 14 Dtool_z_GL7f88 0 6 275 729 0 14 Dtool_z_GL7f88 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_card_texture
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
262 14 Dtool_z_GLpfvU 0 7 276 789 0 14 Dtool_z_GLpfvU 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_texture
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
263 14 Dtool_z_GLfW_a 0 4 277 731 0 14 Dtool_z_GLfW_a 526 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_as_margin
|
|
// Access: Published
|
|
// Description: Specifies that a border will be drawn around the text
|
|
// when it is next created. The parameters are the
|
|
// amount of additional padding to insert between the
|
|
// frame and the text in each dimension, and all should
|
|
// generally be positive.
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 786 4 left 1 730 5 right 1 730 6 bottom 1 730 3 top 1 730
|
|
264 14 Dtool_z_GL7_wM 0 4 278 731 0 14 Dtool_z_GL7_wM 599 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_actual
|
|
// Access: Published
|
|
// Description: Similar to set_frame_as_margin, except the frame is
|
|
// specified in actual coordinate units (relative to
|
|
// the text's origin), irrespective of the size of the
|
|
// text. The left and bottom coordinates should
|
|
// generally be negative, while the right and top
|
|
// coordinates should generally be positive.
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 786 4 left 1 730 5 right 1 730 6 bottom 1 730 3 top 1 730
|
|
265 14 Dtool_z_GLutht 0 4 279 731 0 14 Dtool_z_GLutht 296 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_frame
|
|
// Access: Published
|
|
// Description: Specifies that a border will not be drawn around the
|
|
// text.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
266 14 Dtool_z_GL4KuG 0 6 280 729 0 14 Dtool_z_GL4KuG 218 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_frame
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
267 14 Dtool_z_GL8doH 0 6 281 729 0 14 Dtool_z_GL8doH 675 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::is_frame_as_margin
|
|
// Access: Published
|
|
// Description: If this is true, the frame was set via a call to
|
|
// set_frame_as_margin(), and the dimension of the frame
|
|
// as returned by get_frame_as_set() represent a margin
|
|
// all around the text. If false, then the frame was
|
|
// set via a call to set_frame_actual(), and the
|
|
// dimensions of the frame as returned by
|
|
// get_frame_as_set() are relative to the text's origin.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
268 14 Dtool_z_GLLXz1 0 7 282 761 0 14 Dtool_z_GLLXz1 529 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_as_set
|
|
// Access: Published
|
|
// Description: Returns the dimensions of the frame as set by
|
|
// set_frame_as_margin() or set_frame_actual(). Use
|
|
// is_frame_actual() to determine how to interpret the
|
|
// values returned by this function. It is an error to
|
|
// call this if has_frame() is false.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
269 14 Dtool_z_GLMa1R 0 7 283 761 0 14 Dtool_z_GLMa1R 767 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_actual
|
|
// Access: Published
|
|
// Description: Returns the actual dimensions of the frame around the
|
|
// text. If the frame was set via set_frame_as_margin(),
|
|
// the result returned by this function reflects the
|
|
// size of the current text; if the frame was set via
|
|
// set_frame_actual(), this returns the values
|
|
// actually set.
|
|
//
|
|
// If the text has no frame at all, this returns the
|
|
// dimensions of the text itself, as if the frame were
|
|
// set with a margin of 0, 0, 0, 0.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
270 14 Dtool_z_GLlIlf 0 4 284 731 0 14 Dtool_z_GLlIlf 320 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_line_width
|
|
// Access: Published
|
|
// Description: Specifies the thickness of the lines that will be
|
|
// used to draw the frame.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 10 line_width 1 730
|
|
271 14 Dtool_z_GLM20H 0 6 285 730 0 14 Dtool_z_GLM20H 318 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_line_width
|
|
// Access: Published
|
|
// Description: Returns the thickness of the lines that will be
|
|
// used to draw the frame.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
272 14 Dtool_z_GLkMsJ 0 4 286 731 0 14 Dtool_z_GLkMsJ 470 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_frame_corners
|
|
// Access: Published
|
|
// Description: Enables or disables the drawing of corners for the
|
|
// frame. These are extra points drawn at each of the
|
|
// four corners, to soften the ugly edges generated when
|
|
// the line width is greater than one.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 7 corners 1 729
|
|
273 14 Dtool_z_GLsWF6 0 6 287 729 0 14 Dtool_z_GLsWF6 226 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_frame_corners
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
274 14 Dtool_z_GLr1zs 0 4 288 731 0 14 Dtool_z_GLr1zs 587 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_as_margin
|
|
// Access: Published
|
|
// Description: Specifies that a (possibly opaque or semitransparent)
|
|
// card will be held behind the text when it is next
|
|
// created. Like set_frame_as_margin, the parameters are
|
|
// the amount of additional padding to insert around the
|
|
// text in each dimension, and all should generally be
|
|
// positive.
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 786 4 left 1 730 5 right 1 730 6 bottom 1 730 3 top 1 730
|
|
275 14 Dtool_z_GLQVW0 0 4 289 731 0 14 Dtool_z_GLQVW0 596 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_actual
|
|
// Access: Published
|
|
// Description: Similar to set_card_as_margin, except the card is
|
|
// specified in actual coordinate units (relative to
|
|
// the text's origin), irrespective of the size of the
|
|
// text. The left and bottom coordinates should
|
|
// generally be negative, while the right and top
|
|
// coordinates should generally be positive.
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 786 4 left 1 730 5 right 1 730 6 bottom 1 730 3 top 1 730
|
|
276 14 Dtool_z_GLTKeT 0 4 290 731 0 14 Dtool_z_GLTKeT 455 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_card_decal
|
|
// Access: Published
|
|
// Description: Sets the card_decal flag. When this is true, the
|
|
// text is decalled onto the card, which is necessary if
|
|
// the TextNode is to be rendered in the 3-d world
|
|
// without putting it in a bin.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 10 card_decal 1 729
|
|
277 14 Dtool_z_GL92SD 0 4 291 731 0 14 Dtool_z_GL92SD 293 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_card
|
|
// Access: Published
|
|
// Description: Specifies that a card will not be drawn behind the
|
|
// text.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
278 14 Dtool_z_GLtTVI 0 6 292 729 0 14 Dtool_z_GLtTVI 217 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_card
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
279 14 Dtool_z_GLhF8z 0 6 293 729 0 14 Dtool_z_GLhF8z 275 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_decal
|
|
// Access: Published
|
|
// Description: Returns the card_decal flag. See set_card_decal().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
280 14 Dtool_z_GL_1k2 0 6 294 729 0 14 Dtool_z_GL_1k2 666 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::is_card_as_margin
|
|
// Access: Published
|
|
// Description: If this is true, the card was set via a call to
|
|
// set_card_as_margin(), and the dimension of the card
|
|
// as returned by get_card_as_set() represent a margin
|
|
// all around the text. If false, then the card was
|
|
// set via a call to set_card_actual(), and the
|
|
// dimensions of the card as returned by
|
|
// get_card_as_set() are relative to the text's origin.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
281 14 Dtool_z_GLIo16 0 7 295 761 0 14 Dtool_z_GLIo16 523 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_as_set
|
|
// Access: Published
|
|
// Description: Returns the dimensions of the card as set by
|
|
// set_card_as_margin() or set_card_actual(). Use
|
|
// is_card_actual() to determine how to interpret the
|
|
// values returned by this function. It is an error to
|
|
// call this if has_card() is false.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
282 14 Dtool_z_GLsvt7 0 7 296 761 0 14 Dtool_z_GLsvt7 759 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_actual
|
|
// Access: Published
|
|
// Description: Returns the actual dimensions of the card around the
|
|
// text. If the card was set via set_card_as_margin(),
|
|
// the result returned by this function reflects the
|
|
// size of the current text; if the card was set via
|
|
// set_card_actual(), this returns the values
|
|
// actually set.
|
|
//
|
|
// If the text has no card at all, this returns the
|
|
// dimensions of the text itself, as if the card were
|
|
// set with a margin of 0, 0, 0, 0.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
283 14 Dtool_z_GL__32 0 7 297 761 0 14 Dtool_z_GL__32 529 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_card_transformed
|
|
// Access: Published
|
|
// Description: Returns the actual card dimensions, transformed by
|
|
// the matrix set by set_transform(). This returns the
|
|
// card dimensions in actual coordinates as seen by the
|
|
// rest of the world. Also see get_upper_left_3d() and
|
|
// get_lower_right_3d().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
284 14 Dtool_z_GLPbTJ 0 4 298 731 0 14 Dtool_z_GLPbTJ 314 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_transform
|
|
// Access: Published
|
|
// Description: Sets an additional transform that is applied to the
|
|
// entire text paragraph.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 9 transform 1 790
|
|
285 14 Dtool_z_GLot_Q 0 7 299 793 0 14 Dtool_z_GLot_Q 222 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_transform
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
286 14 Dtool_z_GLq9jN 0 4 300 731 0 14 Dtool_z_GLq9jN 316 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_coordinate_system
|
|
// Access: Published
|
|
// Description: Specifies the coordinate system in which the text
|
|
// will be generated.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 2 cs 1 756
|
|
287 14 Dtool_z_GL8bzG 0 6 301 756 0 14 Dtool_z_GL8bzG 230 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_coordinate_system
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
288 14 Dtool_z_GLKHp_ 0 4 302 731 0 14 Dtool_z_GLKHp_ 567 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_usage_hint
|
|
// Access: Published
|
|
// Description: Specifies the UsageHint that will be applied to
|
|
// generated geometry. The default is UH_static, which
|
|
// is probably the right setting, but if you know the
|
|
// TextNode's geometry will have a short lifespan, it
|
|
// may be better to set it to UH_stream. See
|
|
// geomEnums.h.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 10 usage_hint 1 781
|
|
289 14 Dtool_z_GLWHkr 0 6 303 781 0 14 Dtool_z_GLWHkr 329 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_usage_hint
|
|
// Access: Published
|
|
// Description: Returns the UsageHint that will be applied to
|
|
// generated geometry. See set_usage_hint().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
290 14 Dtool_z_GL9YIA 0 4 304 731 0 14 Dtool_z_GL9YIA 2201 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_flatten_flags
|
|
// Access: Published
|
|
// Description: Sets the flatten flags. This should be a union of
|
|
// the TextNode::FlattenFlags options. This controls
|
|
// the degree of flattening performed on the TextNode's
|
|
// internal geometry (i.e. the scene graph returned by
|
|
// generate()) each time the text is changed. In
|
|
// general, more flattening means a more optimal result,
|
|
// but it will take more time to generate.
|
|
//
|
|
// The choice may be any of these three:
|
|
//
|
|
// FF_none - No flatten operation is called. The
|
|
// letters are left as independent Geoms.
|
|
//
|
|
// FF_light - A flatten_light() operation is called.
|
|
// The attributes are applied to the vertices, but no
|
|
// nodes are removed.
|
|
//
|
|
// FF_medium - A flatten_medium() operation is called.
|
|
// The attributes are applied to the vertices, and a few
|
|
// trivial nodes are removed.
|
|
//
|
|
// FF_strong - A flatten_strong() operation is called.
|
|
// The attributes are applied to the vertices, and the
|
|
// resulting nodes are aggressively combined into as few
|
|
// nodes as possible.
|
|
//
|
|
// In addition to the above choices, you may optionally
|
|
// include the following flag:
|
|
//
|
|
// FF_dynamic_merge - Copy the geoms into a single
|
|
// GeomVertexData as we go, instead of relying on the
|
|
// flatten operation at the end. This pre-flattens the
|
|
// text considerably, and may obviate the need for
|
|
// flatten altogether; it also tends to improve
|
|
// performance considerably even if you do call flatten.
|
|
// However, it is not as fast as not calling flatten at
|
|
// all.
|
|
//
|
|
// The default is taken from the text-flatten and
|
|
// text-dynamic-merge config variables.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 13 flatten_flags 1 734
|
|
291 14 Dtool_z_GLF_2G 0 6 305 734 0 14 Dtool_z_GLF_2G 279 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_flatten_flags
|
|
// Access: Published
|
|
// Description: Returns the flatten flags. See set_flatten_flags().
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
292 14 Dtool_z_GLGF3a 0 4 306 731 0 14 Dtool_z_GLGF3a 398 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_font
|
|
// Access: Published
|
|
// Description: Sets the font that will be used when making text. If
|
|
// this is set to NULL, the default font will be used,
|
|
// which can be set via set_default_font().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 4 font 1 728
|
|
293 14 Dtool_z_GLf1JB 0 4 307 731 0 14 Dtool_z_GLf1JB 256 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_font
|
|
// Access: Published
|
|
// Description: Resets the font to the default font.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
294 14 Dtool_z_GL_Vg7 0 4 308 731 0 14 Dtool_z_GL_Vg7 1131 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_small_caps
|
|
// Access: Published
|
|
// Description: Sets the small_caps flag. When this is set,
|
|
// lowercase letters are generated as scaled-down
|
|
// versions of their uppercase equivalents. This is
|
|
// particularly useful to set for fonts that do not have
|
|
// lowercase letters.
|
|
//
|
|
// It is also a good idea to set this for a (dynamic)
|
|
// font that has already implemented lowercase letters
|
|
// as scaled-down versions of their uppercase
|
|
// equivalents, since without this flag the texture
|
|
// memory may needlessly duplicate equivalent glyphs for
|
|
// upper and lowercase letters. Setting this flag
|
|
// causes the texture memory to share the mixed-case
|
|
// letters.
|
|
//
|
|
// The amount by which the lowercase letters are scaled
|
|
// is specified by set_small_caps_scale().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 10 small_caps 1 729
|
|
295 14 Dtool_z_GLwdub 0 4 309 731 0 14 Dtool_z_GLwdub 226 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_small_caps
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
296 14 Dtool_z_GLUbUd 0 4 310 731 0 14 Dtool_z_GLUbUd 475 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_small_caps_scale
|
|
// Access: Published
|
|
// Description: Sets the scale factor applied to lowercase letters
|
|
// from their uppercase equivalents, when the small_caps
|
|
// flag is in effect. See set_small_caps(). Normally,
|
|
// this will be a number less than one.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 16 small_caps_scale 1 730
|
|
297 14 Dtool_z_GLINuw 0 4 311 731 0 14 Dtool_z_GLINuw 232 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_small_caps_scale
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
298 14 Dtool_z_GLb_en 0 4 312 731 0 14 Dtool_z_GLb_en 218 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_slant
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 5 slant 1 730
|
|
299 14 Dtool_z_GLSyQo 0 4 313 731 0 14 Dtool_z_GLSyQo 221 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_slant
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
300 14 Dtool_z_GLLgJS 0 4 314 731 0 14 Dtool_z_GLLgJS 218 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_align
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 10 align_type 1 718
|
|
301 14 Dtool_z_GL6Qem 0 4 315 731 0 14 Dtool_z_GL6Qem 221 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_align
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
302 14 Dtool_z_GLQfWK 0 4 316 731 0 14 Dtool_z_GLQfWK 389 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_indent
|
|
// Access: Published
|
|
// Description: Specifies the amount of extra space that is inserted
|
|
// before the first character of each line. This can be
|
|
// thought of as a left margin.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 6 indent 1 730
|
|
303 14 Dtool_z_GLmAkO 0 4 317 731 0 14 Dtool_z_GLmAkO 222 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_indent
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
304 14 Dtool_z_GL9HMt 0 4 318 731 0 14 Dtool_z_GL9HMt 394 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_wordwrap
|
|
// Access: Published
|
|
// Description: Sets the text up to automatically wordwrap when it
|
|
// exceeds the indicated width. This can be thought of
|
|
// as a right margin or margin width.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 8 wordwrap 1 730
|
|
305 14 Dtool_z_GLfZHt 0 4 319 731 0 14 Dtool_z_GLfZHt 320 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_wordwrap
|
|
// Access: Published
|
|
// Description: Removes the wordwrap setting from the TextNode. Text
|
|
// will be as wide as it is.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
306 14 Dtool_z_GL_L_O 0 4 320 731 0 14 Dtool_z_GL_L_O 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_text_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 10 text_color 1 749
|
|
307 14 Dtool_z_GLIuGX 0 4 320 731 0 14 Dtool_z_GLIuGX 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_text_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 786 1 r 1 730 1 g 1 730 1 b 1 730 1 a 1 730
|
|
308 14 Dtool_z_GLrIpB 0 4 321 731 0 14 Dtool_z_GLrIpB 346 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_text_color
|
|
// Access: Published
|
|
// Description: Removes the text color specification; the text will
|
|
// be colored whatever it was in the source font file.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
309 14 Dtool_z_GLMFJk 0 4 322 731 0 14 Dtool_z_GLMFJk 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 12 shadow_color 1 749
|
|
310 14 Dtool_z_GLwKru 0 4 322 731 0 14 Dtool_z_GLwKru 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 5 4 this 3 786 1 r 1 730 1 g 1 730 1 b 1 730 1 a 1 730
|
|
311 14 Dtool_z_GLy9rr 0 4 323 731 0 14 Dtool_z_GLy9rr 228 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_shadow_color
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
312 14 Dtool_z_GLmLmp 0 4 324 731 0 14 Dtool_z_GLmLmp 391 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_shadow
|
|
// Access: Published
|
|
// Description: Specifies that the text should be drawn with a
|
|
// shadow, by creating a second copy of the text and
|
|
// offsetting it slightly behind the first.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 13 shadow_offset 1 762
|
|
313 14 Dtool_z_GLGBV_ 0 4 324 731 0 14 Dtool_z_GLGBV_ 391 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_shadow
|
|
// Access: Published
|
|
// Description: Specifies that the text should be drawn with a
|
|
// shadow, by creating a second copy of the text and
|
|
// offsetting it slightly behind the first.
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 786 7 xoffset 1 730 7 yoffset 1 730
|
|
314 14 Dtool_z_GL7Hq_ 0 4 325 731 0 14 Dtool_z_GL7Hq_ 297 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_shadow
|
|
// Access: Published
|
|
// Description: Specifies that a shadow will not be drawn behind the
|
|
// text.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
315 14 Dtool_z_GLGgph 0 4 326 731 0 14 Dtool_z_GLGgph 672 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_bin
|
|
// Access: Published
|
|
// Description: Names the GeomBin that the TextNode geometry should
|
|
// be assigned to. If this is set, then a
|
|
// GeomBinTransition will be created to explicitly place
|
|
// each component in the named bin.
|
|
//
|
|
// The draw_order value will also be passed to each
|
|
// GeomBinTransition as appropriate; this is
|
|
// particularly useful if this names a GeomBinFixed,
|
|
// e.g. "fixed".
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 3 bin 1 747
|
|
316 14 Dtool_z_GLvUkz 0 4 327 731 0 14 Dtool_z_GLvUkz 414 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_bin
|
|
// Access: Published
|
|
// Description: Removes the effect of a previous call to
|
|
// set_bin(). Text will be drawn in whatever bin
|
|
// it would like to be drawn in, with no explicit
|
|
// ordering.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
317 14 Dtool_z_GLRbS_ 0 6 328 734 0 14 Dtool_z_GLRbS_ 765 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_draw_order
|
|
// Access: Published
|
|
// Description: Sets the drawing order of text created by the
|
|
// TextMaker. This is actually the draw order of the
|
|
// card and frame. The shadow is drawn at
|
|
// _draw_order+1, and the text at _draw_order+2.
|
|
//
|
|
// This affects the sorting order assigned to the arcs
|
|
// as they are created, and also is passed to whatever
|
|
// bin may be assigned via set_bin().
|
|
//
|
|
// The return value is the first unused draw_order
|
|
// number, e.g. _draw_order + 3.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 10 draw_order 1 734
|
|
318 14 Dtool_z_GLejrP 0 4 329 731 0 14 Dtool_z_GLejrP 226 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_draw_order
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
319 14 Dtool_z_GLZrKk 0 4 330 731 0 14 Dtool_z_GLZrKk 403 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_tab_width
|
|
// Access: Published
|
|
// Description: Sets the width of each tab stop, in screen units. A
|
|
// tab character embedded in the text will advance the
|
|
// horizontal position to the next tab stop.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 9 tab_width 1 730
|
|
320 14 Dtool_z_GLELAu 0 4 331 731 0 14 Dtool_z_GLELAu 225 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_tab_width
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
321 14 Dtool_z_GLgJjt 0 4 332 731 0 14 Dtool_z_GLgJjt 467 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_glyph_scale
|
|
// Access: Published
|
|
// Description: Specifies the factor by which to scale each letter of
|
|
// the text as it is placed. This can be used (possibly
|
|
// in conjunction with set_glyph_shift()) to implement
|
|
// superscripting or subscripting.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 11 glyph_scale 1 730
|
|
322 14 Dtool_z_GLQ6h8 0 4 333 731 0 14 Dtool_z_GLQ6h8 227 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_glyph_scale
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
323 14 Dtool_z_GL6XIO 0 4 334 731 0 14 Dtool_z_GL6XIO 465 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_glyph_shift
|
|
// Access: Published
|
|
// Description: Specifies a vertical amount to shift each letter of
|
|
// the text as it is placed. This can be used (possibly
|
|
// in conjunction with set_glyph_scale()) to implement
|
|
// superscripting or subscripting.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 11 glyph_shift 1 730
|
|
324 14 Dtool_z_GLa77j 0 4 335 731 0 14 Dtool_z_GLa77j 227 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_glyph_shift
|
|
// Access: Published
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
325 14 Dtool_z_GLhRrL 0 4 336 731 0 14 Dtool_z_GLhRrL 289 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_text
|
|
// Access: Published
|
|
// Description: Changes the text that is displayed under the
|
|
// TextNode.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 4 text 1 747
|
|
326 14 Dtool_z_GL0t8R 0 4 336 731 0 14 Dtool_z_GL0t8R 569 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_text
|
|
// Access: Published
|
|
// Description: The two-parameter version of set_text() accepts an
|
|
// explicit encoding; the text is immediately decoded
|
|
// and stored as a wide-character string. Subsequent
|
|
// calls to get_text() will return the same text
|
|
// re-encoded using whichever encoding is specified by
|
|
// set_encoding().
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 786 4 text 1 747 8 encoding 1 794
|
|
327 14 Dtool_z_GLExTx 0 4 337 731 0 14 Dtool_z_GLExTx 255 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::clear_text
|
|
// Access: Published
|
|
// Description: Removes the text from the TextNode.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
328 14 Dtool_z_GLp36A 0 4 338 731 0 14 Dtool_z_GLp36A 297 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::append_text
|
|
// Access: Published
|
|
// Description: Appends the indicates string to the end of the stored
|
|
// text.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 4 text 1 747
|
|
329 14 Dtool_z_GL4uPV 0 4 339 731 0 14 Dtool_z_GL4uPV 377 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::append_unicode_char
|
|
// Access: Published
|
|
// Description: Appends a single character to the end of the stored
|
|
// text. This may be a wide character, up to 16 bits in
|
|
// Unicode.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 9 character 1 783
|
|
330 14 Dtool_z_GLwRGG 0 6 340 747 0 14 Dtool_z_GLwRGG 502 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_wordwrapped_text
|
|
// Access: Public
|
|
// Description: Returns a string that represents the contents of the
|
|
// text, as it has been formatted by wordwrap rules.
|
|
//
|
|
// In earlier versions, this did not contain any
|
|
// embedded special characters like \1 or \3; now it
|
|
// does.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
331 14 Dtool_z_GL03Il 0 6 341 730 0 14 Dtool_z_GL03Il 366 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::calc_width
|
|
// Access: Published
|
|
// Description: Returns the width of a line of text of arbitrary
|
|
// characters. The line should not include the newline
|
|
// character.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 787 4 line 1 747
|
|
332 14 Dtool_z_GL7iBP 0 6 341 730 0 14 Dtool_z_GL7iBP 432 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::calc_width
|
|
// Access: Published
|
|
// Description: Returns the width of a line of text of arbitrary
|
|
// characters. The line should not include the newline
|
|
// character or any embedded control characters like \1
|
|
// or \3.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 787 4 line 1 747
|
|
333 14 Dtool_z_GLYwcF 0 6 341 730 0 14 Dtool_z_GLYwcF 394 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::calc_width
|
|
// Access: Published
|
|
// Description: Returns the width of a single character of the font,
|
|
// or 0.0 if the character is not known. This may be a
|
|
// wide character (greater than 255).
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 787 9 character 1 783
|
|
334 14 Dtool_z_GLB1x6 0 6 342 729 0 14 Dtool_z_GLB1x6 1032 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_exact_character
|
|
// Access: Published
|
|
// Description: Returns true if the named character exists in the
|
|
// font exactly as named, false otherwise. Note that
|
|
// because Panda can assemble glyphs together
|
|
// automatically using cheesy accent marks, this is not
|
|
// a reliable indicator of whether a suitable glyph can
|
|
// be rendered for the character. For that, use
|
|
// has_character() instead.
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// but returns false for characters that would render
|
|
// with the "invalid glyph". It also returns false for
|
|
// characters that would be synthesized within Panda,
|
|
// but see has_character().
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 787 9 character 1 783
|
|
335 14 Dtool_z_GLD8Op 0 6 343 729 0 14 Dtool_z_GLD8Op 720 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::has_character
|
|
// Access: Published
|
|
// Description: Returns true if the named character exists in the
|
|
// font or can be synthesized by Panda, false otherwise.
|
|
// (Panda can synthesize some accented characters by
|
|
// combining similar-looking glyphs from the font.)
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// but returns false for characters that would render
|
|
// with the "invalid glyph".
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 787 9 character 1 783
|
|
336 14 Dtool_z_GLwDRU 0 6 344 729 0 14 Dtool_z_GLwDRU 1118 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::is_whitespace
|
|
// Access: Published
|
|
// Description: Returns true if the indicated character represents
|
|
// whitespace in the font, or false if anything visible
|
|
// will be rendered for it.
|
|
//
|
|
// This returns true for whitespace and Unicode
|
|
// whitespace characters (if they exist in the font),
|
|
// and returns false for any other characters, including
|
|
// characters that do not exist in the font (these would
|
|
// be rendered with the "invalid glyph", which is
|
|
// visible).
|
|
//
|
|
// Note that this function can be reliably used to
|
|
// identify Unicode whitespace characters only if the
|
|
// font has all of the whitespace characters defined.
|
|
// It will return false for any character not in the
|
|
// font, even if it is an official Unicode whitespace
|
|
// character.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 787 9 character 1 783
|
|
337 14 Dtool_z_GL_svx 0 4 345 731 0 14 Dtool_z_GL_svx 450 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::set_wtext
|
|
// Access: Published
|
|
// Description: Changes the text that is displayed under the
|
|
// TextNode, with a wide text. This automatically sets
|
|
// the string reported by get_text() to the 8-bit
|
|
// encoded version of the same string.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 5 wtext 1 747
|
|
338 14 Dtool_z_GLHS8n 0 4 346 731 0 14 Dtool_z_GLHS8n 313 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::append_wtext
|
|
// Access: Published
|
|
// Description: Appends the indicates string to the end of the stored
|
|
// wide-character text.
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 786 4 text 1 747
|
|
339 14 Dtool_z_GLFiQ_ 0 6 347 747 0 14 Dtool_z_GLFiQ_ 507 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_wordwrapped_wtext
|
|
// Access: Published
|
|
// Description: Returns a wstring that represents the contents of the
|
|
// text, as it has been formatted by wordwrap rules.
|
|
//
|
|
// In earlier versions, this did not contain any
|
|
// embedded special characters like \1 or \3; now it
|
|
// does.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
340 14 Dtool_z_GLmp7p 0 4 348 731 0 14 Dtool_z_GLmp7p 222 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::output
|
|
// Access: Public, Virtual
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 787 3 out 1 732
|
|
341 14 Dtool_z_GLIFnr 0 4 349 731 0 14 Dtool_z_GLIFnr 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::write
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 3 4 this 3 787 3 out 1 732 12 indent_level 1 734
|
|
342 14 Dtool_z_GLem6v 0 4 349 731 0 14 Dtool_z_GLem6v 223 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::write
|
|
// Access: Published, Virtual
|
|
// Description:
|
|
//////////////////////////////////////////////////////////////////// 2 4 this 3 787 3 out 1 732
|
|
343 14 Dtool_z_GLUosZ 0 6 350 730 0 14 Dtool_z_GLUosZ 359 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_left
|
|
// Access: Published
|
|
// Description: Returns the leftmost extent of the text in local 2-d
|
|
// coordinates, unmodified by the set_transform()
|
|
// matrix.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
344 14 Dtool_z_GLAxZW 0 6 351 730 0 14 Dtool_z_GLAxZW 361 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_right
|
|
// Access: Published
|
|
// Description: Returns the rightmost extent of the text in local 2-d
|
|
// coordinates, unmodified by the set_transform()
|
|
// matrix.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
345 14 Dtool_z_GLqsLg 0 6 352 730 0 14 Dtool_z_GLqsLg 363 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_bottom
|
|
// Access: Published
|
|
// Description: Returns the bottommost extent of the text in local
|
|
// 2-d coordinates, unmodified by the set_transform()
|
|
// matrix.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
346 14 Dtool_z_GLD4yi 0 6 353 730 0 14 Dtool_z_GLD4yi 357 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_top
|
|
// Access: Published
|
|
// Description: Returns the topmost extent of the text in local 2-d
|
|
// coordinates, unmodified by the set_transform()
|
|
// matrix.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
347 14 Dtool_z_GLpjNJ 0 6 354 730 0 14 Dtool_z_GLpjNJ 297 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_height
|
|
// Access: Published
|
|
// Description: Returns the net height of the text in local 2-d
|
|
// coordinates.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
348 14 Dtool_z_GLW_Z2 0 6 355 730 0 14 Dtool_z_GLW_Z2 295 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_width
|
|
// Access: Published
|
|
// Description: Returns the net width of the text in local 2-d
|
|
// coordinates.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
349 14 Dtool_z_GLObuQ 0 7 356 796 0 14 Dtool_z_GLObuQ 395 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_upper_left_3d
|
|
// Access: Published
|
|
// Description: Returns the upper-left extent of the text object,
|
|
// after it has been transformed into 3-d space by
|
|
// applying the set_transform() matrix.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
350 14 Dtool_z_GLz0ox 0 7 357 796 0 14 Dtool_z_GLz0ox 397 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_lower_right_3d
|
|
// Access: Published
|
|
// Description: Returns the lower-right extent of the text object,
|
|
// after it has been transformed into 3-d space by
|
|
// applying the set_transform() matrix.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
351 14 Dtool_z_GL4Pci 0 6 358 734 0 14 Dtool_z_GL4Pci 394 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_num_rows
|
|
// Access: Published
|
|
// Description: Returns the number of rows of text that were
|
|
// generated. This counts word-wrapped rows as well as
|
|
// rows generated due to embedded newlines.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
352 14 Dtool_z_GLfMjA 0 7 359 755 0 14 Dtool_z_GLfMjA 403 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::generate
|
|
// Access: Published
|
|
// Description: Generates the text, according to the parameters
|
|
// indicated within the TextNode, and returns a Node
|
|
// that may be parented within the tree to represent it.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
353 14 Dtool_z_GLg9eZ 0 4 360 731 0 14 Dtool_z_GLg9eZ 442 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::update
|
|
// Access: Published
|
|
// Description: Can be called after the TextNode has been fully
|
|
// configured, to force the node to recompute its text
|
|
// immediately, rather than waiting for it to be drawn.
|
|
// This call is optional.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
354 14 Dtool_z_GLZ_1G 0 4 361 731 0 14 Dtool_z_GLZ_1G 537 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::force_update
|
|
// Access: Published
|
|
// Description: Forces the TextNode to recompute itself now, even if
|
|
// it believes nothing has changed. Normally, this
|
|
// should not need to be called, but it may be useful if
|
|
// some properties change outside of the TextNode's
|
|
// knowledge (for instance, within the font).
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 786
|
|
355 14 Dtool_z_GLoCcY 0 7 362 755 0 14 Dtool_z_GLoCcY 637 ////////////////////////////////////////////////////////////////////
|
|
// Function: TextNode::get_internal_geom
|
|
// Access: Published
|
|
// Description: Returns the actual node that is used internally to
|
|
// render the text, if the TextNode is parented within
|
|
// the scene graph.
|
|
//
|
|
// In general, you should not call this method. Call
|
|
// generate() instead if you want to get a handle to
|
|
// geometry that represents the text. This method is
|
|
// provided as a debugging aid only.
|
|
//////////////////////////////////////////////////////////////////// 1 4 this 3 787
|
|
356 14 Dtool_z_GLxuS_ 0 7 363 736 0 14 Dtool_z_GLxuS_ 0 0
|
|
357 14 Dtool_z_GLHSSc 0 7 248 755 0 14 Dtool_z_GLHSSc 0 1 4 this 3 786
|
|
358 14 Dtool_z_GL9k_x 0 7 249 786 597 14 Dtool_z_GL9k_x 0 1 4 this 3 755
|
|
359 14 Dtool_z_GL2clc 0 6 251 780 0 14 Dtool_z_GL2clc 0 1 4 this 3 786
|
|
360 14 Dtool_z_GLtPjp 0 7 252 786 597 14 Dtool_z_GLtPjp 0 1 4 this 3 780
|
|
361 14 Dtool_z_GLrYU8 0 6 253 758 0 14 Dtool_z_GLrYU8 0 1 4 this 3 786
|
|
362 14 Dtool_z_GLzq3d 0 7 254 786 597 14 Dtool_z_GLzq3d 0 1 4 this 3 758
|
|
95
|
|
704 8 TextFont 0 26625 8 TextFont 8 TextFont 0 0 0 0 367 0 8 368 369 371 372 373 374 375 376 0 1 370 2 3 705 363 364 3 706 365 366 0 2 707 708 497
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TextFont
|
|
// Description : An encapsulation of a font; i.e. a set of glyphs that
|
|
// may be assembled together by a TextNode to represent
|
|
// a string of text.
|
|
//
|
|
// This is just an abstract interface; see
|
|
// StaticTextFont or DynamicTextFont for an actual
|
|
// implementation.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
705 19 TypedReferenceCount 0 2049 19 TypedReferenceCount 19 TypedReferenceCount 0 0 0 0 0 0 0 0 0 0 0 0 710
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TypedReferenceCount
|
|
// Description : A base class for things which need to inherit from
|
|
// both TypedObject and from ReferenceCount. It's
|
|
// convenient to define this intermediate base class
|
|
// instead of multiply inheriting from the two classes
|
|
// each time they are needed, so that we can sensibly
|
|
// pass around pointers to things which are both
|
|
// TypedObjects and ReferenceCounters.
|
|
//
|
|
// See also TypedObject for detailed instructions.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
706 7 Namable 0 2049 7 Namable 7 Namable 0 0 0 0 0 0 0 0 0 0 0 0 324
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : Namable
|
|
// Description : A base class for all things which can have a name.
|
|
// The name is either empty or nonempty, but it is never
|
|
// NULL.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
707 10 RenderMode 0 794624 20 TextFont::RenderMode 20 TextFont::RenderMode 704 0 0 0 0 0 0 0 0 0 6 10 RM_texture 20 TextFont::RM_texture 0 12 RM_wireframe 22 TextFont::RM_wireframe 1 10 RM_polygon 20 TextFont::RM_polygon 2 11 RM_extruded 21 TextFont::RM_extruded 3 8 RM_solid 18 TextFont::RM_solid 4 10 RM_invalid 20 TextFont::RM_invalid 5 0 0
|
|
|
|
708 12 WindingOrder 0 794624 22 TextFont::WindingOrder 22 TextFont::WindingOrder 704 0 0 0 0 0 0 0 0 0 4 10 WO_default 20 TextFont::WO_default 0 7 WO_left 17 TextFont::WO_left 1 8 WO_right 18 TextFont::WO_right 2 10 WO_invalid 20 TextFont::WO_invalid 3 0 0
|
|
|
|
709 15 DynamicTextPage 0 141313 15 DynamicTextPage 15 DynamicTextPage 0 0 0 0 379 0 2 377 378 0 0 1 0 710 0 0 0 0 419
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : DynamicTextPage
|
|
// Description : A single "page" of a DynamicTextFont. This is a
|
|
// single texture that holds a number of glyphs for
|
|
// rendering. The font starts out with one page, and
|
|
// will add more as it needs them.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
710 7 Texture 0 2049 7 Texture 7 Texture 0 0 0 0 0 0 0 0 0 0 0 0 1051
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : Texture
|
|
// Description : Represents a texture object, which is typically a
|
|
// single 2-d image but may also represent a 1-d or 3-d
|
|
// texture image, or the six 2-d faces of a cube map
|
|
// texture.
|
|
//
|
|
// A texture's image data might be stored in system RAM
|
|
// (see get_ram_image()) or its image may be represented
|
|
// in texture memory on one or more
|
|
// GraphicsStateGuardians (see prepare()), or both. The
|
|
// typical usage pattern is that a texture is loaded
|
|
// from an image file on disk, which copies its image
|
|
// data into system RAM; then the first time the texture
|
|
// is rendered its image data is copied to texture
|
|
// memory (actually, to the graphics API), and the
|
|
// system RAM image is automatically freed.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
711 15 DynamicTextFont 0 26625 15 DynamicTextFont 15 DynamicTextFont 0 0 0 1 384 385 0 45 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 1 799 0 2 3 704 380 381 3 712 382 383 0 0 469
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : DynamicTextFont
|
|
// Description : A DynamicTextFont is a special TextFont object that
|
|
// rasterizes its glyphs from a standard font file
|
|
// (e.g. a TTF file) on the fly. It requires the
|
|
// FreeType 2.0 library (or any higher,
|
|
// backward-compatible version).
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
712 12 FreetypeFont 0 2049 12 FreetypeFont 12 FreetypeFont 0 0 0 0 0 0 0 0 0 0 0 0 481
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : FreetypeFont
|
|
// Description : This is a common base class for both DynamicTextFont
|
|
// and PNMTextMaker. Both of these are utility classes
|
|
// that use the FreeType library to generate glyphs from
|
|
// fonts; this class abstracts out that common wrapper
|
|
// around FreeType.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
713 8 FontPool 0 141313 8 FontPool 8 FontPool 0 0 0 0 440 0 9 431 432 433 434 435 436 437 438 439 0 0 0 0 0 402
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : FontPool
|
|
// Description : This is the preferred interface for loading fonts for
|
|
// the TextNode system. It is similar to ModelPool and
|
|
// TexturePool in that it unifies references to the same
|
|
// filename.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
714 13 GeomTextGlyph 0 75777 13 GeomTextGlyph 13 GeomTextGlyph 0 0 0 0 0 0 1 441 0 0 1 0 715 0 0 0 0 549
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : GeomTextGlyph
|
|
// Description : This is a specialization on Geom for containing a
|
|
// primitive intended to represent a DynamicTextGlyph.
|
|
// Its sole purpose is to maintain the geom count on the
|
|
// glyph, so we can determine the actual usage count on
|
|
// a dynamic glyph (and thus know when it is safe to
|
|
// recycle the glyph).
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
715 4 Geom 0 2049 4 Geom 4 Geom 0 0 0 0 0 0 0 1 800 0 0 0 0 687
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : Geom
|
|
// Description : A container for geometry primitives. This class
|
|
// associates one or more GeomPrimitive objects with a
|
|
// table of vertices defined by a GeomVertexData object.
|
|
// All of the primitives stored in a particular Geom are
|
|
// drawn from the same set of vertices (each primitive
|
|
// uses a subset of all of the vertices in the table),
|
|
// and all of them must be rendered at the same time, in
|
|
// the same graphics state.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
716 14 StaticTextFont 0 141313 14 StaticTextFont 14 StaticTextFont 0 0 0 1 442 444 0 1 443 0 0 1 0 704 0 0 0 0 486
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : StaticTextFont
|
|
// Description : A StaticTextFont is loaded up from a model that was
|
|
// previously generated via egg-mkfont, and contains all
|
|
// of its glyphs already generated and available for
|
|
// use. It doesn't require linking with any external
|
|
// libraries like FreeType.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
717 14 TextProperties 0 141313 14 TextProperties 14 TextProperties 0 0 0 1 445 532 0 86 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 0 0 0 0 1 718 1219
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TextProperties
|
|
// Description : This defines the set of visual properties that may be
|
|
// assigned to the individual characters of the text.
|
|
// (Properties which affect the overall block of text
|
|
// can only be specified on the TextNode directly).
|
|
//
|
|
// Typically, there is just one set of properties on a
|
|
// given block of text, which is set directly on the
|
|
// TextNode (TextNode inherits from TextProperties).
|
|
// That makes all of the text within a particular block
|
|
// have the same appearance.
|
|
//
|
|
// This separate class exists in order to implement
|
|
// multiple different kinds of text appearing within one
|
|
// block. The text string itself may reference a
|
|
// TextProperties structure by name using the \1 and \2
|
|
// tokens embedded within the string; each nested
|
|
// TextProperties structure modifies the appearance of
|
|
// subsequent text within the block.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
718 9 Alignment 0 794624 25 TextProperties::Alignment 25 TextProperties::Alignment 717 0 0 0 0 0 0 0 0 0 6 6 A_left 22 TextProperties::A_left 0 7 A_right 23 TextProperties::A_right 1 8 A_center 24 TextProperties::A_center 2 12 A_boxed_left 28 TextProperties::A_boxed_left 3 13 A_boxed_right 29 TextProperties::A_boxed_right 4 14 A_boxed_center 30 TextProperties::A_boxed_center 5 0 0
|
|
|
|
719 11 TextGraphic 0 141313 11 TextGraphic 11 TextGraphic 0 0 0 1 533 540 0 6 534 535 536 537 538 539 0 0 0 0 0 1140
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TextGraphic
|
|
// Description : This defines a special model that has been
|
|
// constructed for the purposes of embedding an
|
|
// arbitrary graphic image within a text paragraph.
|
|
//
|
|
// It can be any arbitrary model, though it should be
|
|
// built along the same scale as the text, and it should
|
|
// probably be at least mostly two-dimensional.
|
|
// Typically, this means it should be constructed in the
|
|
// X-Z plane, and it should have a maximum vertical (Z)
|
|
// height of 1.0.
|
|
//
|
|
// The frame specifies an arbitrary bounding volume in
|
|
// the form (left, right, bottom, top). This indicates
|
|
// the amount of space that will be reserved within the
|
|
// paragraph. The actual model is not actually required
|
|
// to fit within this rectangle, but if it does not, it
|
|
// may visually overlap with nearby text.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
720 21 TextPropertiesManager 0 43009 21 TextPropertiesManager 21 TextPropertiesManager 0 0 0 0 0 0 10 541 542 543 544 545 546 547 548 549 550 0 0 0 0 0 1613
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TextPropertiesManager
|
|
// Description : This defines all of the TextProperties structures
|
|
// that might be referenced by name from an embedded
|
|
// text string.
|
|
//
|
|
// A text string, as rendered by a TextNode, can contain
|
|
// embedded references to one of the TextProperties
|
|
// defined here, by enclosing the name between \1 (ASCII
|
|
// 0x01) characters; this causes a "push" to the named
|
|
// state. All text following the closing \1 character
|
|
// will then be rendered in the new state. The next \2
|
|
// (ASCII 0x02) character will then restore the previous
|
|
// state for subsequent text.
|
|
//
|
|
// For instance, "x\1up\1n\2 + y" indicates that the
|
|
// character "x" will be rendered in the normal state,
|
|
// the character "n" will be rendered in the "up" state,
|
|
// and then " + y" will be rendered in the normal state
|
|
// again.
|
|
//
|
|
// This can also be used to define arbitrary models that
|
|
// can serve as embedded graphic images in a text
|
|
// paragraph. This works similarly; the convention is
|
|
// to create a TextGraphic that describes the graphic
|
|
// image, and then associate it here via the
|
|
// set_graphic() call. Then "\5name\5" will embed the
|
|
// named graphic.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
721 13 TextAssembler 0 26625 13 TextAssembler 13 TextAssembler 0 0 0 1 551 553 0 37 552 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 0 0 0 0 0 541
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TextAssembler
|
|
// Description : This class is not normally used directly by user
|
|
// code, but is used by the TextNode to lay out a block
|
|
// of text and convert it into rows of Geoms according
|
|
// to the TextProperties. However, user code may take
|
|
// advantage of it, if desired, for very low-level text
|
|
// operations.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
722 8 TextNode 0 26625 8 TextNode 8 TextNode 0 0 0 1 596 597 0 106 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 0 0 3 3 723 590 591 3 724 592 593 3 717 594 595 0 1 725 1336
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TextNode
|
|
// Description : The primary interface to this module. This class
|
|
// does basic text assembly; given a string of text and
|
|
// a TextFont object, it creates a piece of geometry
|
|
// that may be placed in the 3-d or 2-d world to
|
|
// represent the indicated text.
|
|
//
|
|
// The TextNode may be used in one of two ways.
|
|
// Naively, it may simply be parented directly into the
|
|
// scene graph and rendered as if it were a GeomNode; in
|
|
// this mode, the actual polygon geometry that renders
|
|
// the text is not directly visible or accessible, but
|
|
// remains hidden within the TextNode.
|
|
//
|
|
// The second way TextNode may be used is as a text
|
|
// generator. To use it in this way, do not parent the
|
|
// TextNode to the scene graph; instead, set the
|
|
// properties of the text and call generate() to return
|
|
// an ordinary node, containing ordinary geometry, which
|
|
// you may use however you like. Each time you call
|
|
// generate() a new node is returned.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
723 9 PandaNode 0 2049 9 PandaNode 9 PandaNode 0 0 0 0 0 0 0 0 0 0 0 0 374
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : PandaNode
|
|
// Description : A basic node of the scene graph or data graph. This
|
|
// is the base class of all specialized nodes, and also
|
|
// serves as a generic node with no special properties.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
724 11 TextEncoder 0 2049 11 TextEncoder 11 TextEncoder 0 0 0 0 0 0 0 0 0 0 0 0 676
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TextEncoder
|
|
// Description : This class can be used to convert text between
|
|
// multiple representations, e.g. utf-8 to Unicode. You
|
|
// may use it as a static class object, passing the
|
|
// encoding each time, or you may create an instance and
|
|
// use that object, which will record the current
|
|
// encoding and retain the current string.
|
|
//
|
|
// This class is also a base class of TextNode, which
|
|
// inherits this functionality.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
725 12 FlattenFlags 0 794624 22 TextNode::FlattenFlags 22 TextNode::FlattenFlags 722 0 0 0 0 0 0 0 0 0 5 7 FF_none 17 TextNode::FF_none 0 8 FF_light 18 TextNode::FF_light 1 9 FF_medium 19 TextNode::FF_medium 2 9 FF_strong 19 TextNode::FF_strong 4 16 FF_dynamic_merge 26 TextNode::FF_dynamic_merge 8 0 0
|
|
|
|
726 16 TextFont const * 0 8576 16 TextFont const * 16 TextFont const * 0 0 727 0 0 0 0 0 0 0 0 0 0
|
|
|
|
727 14 TextFont const 0 8832 14 TextFont const 14 TextFont const 0 0 704 0 0 0 0 0 0 0 0 0 0
|
|
|
|
728 10 TextFont * 0 8576 10 TextFont * 10 TextFont * 0 0 704 0 0 0 0 0 0 0 0 0 0
|
|
|
|
729 4 bool 0 8194 4 bool 4 bool 0 4 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
730 5 float 0 8194 5 float 5 float 0 2 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
731 4 void 0 8194 4 void 4 void 0 6 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
732 9 ostream * 0 8576 9 ostream * 9 ostream * 0 0 733 0 0 0 0 0 0 0 0 0 0
|
|
|
|
733 7 ostream 0 2048 7 ostream 7 ostream 0 0 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
734 3 int 0 8194 3 int 3 int 0 1 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
735 10 TypeHandle 0 2048 10 TypeHandle 10 TypeHandle 0 0 0 0 0 0 0 0 0 0 0 0 1098
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : TypeHandle
|
|
// Description : TypeHandle is the identifier used to differentiate
|
|
// C++ class types. Any C++ classes that inherit from
|
|
// some base class, and must be differentiated at run
|
|
// time, should store a static TypeHandle object that
|
|
// can be queried through a static member function
|
|
// named get_class_type(). Most of the time, it is also
|
|
// desirable to inherit from TypedObject, which provides
|
|
// some virtual functions to return the TypeHandle for a
|
|
// particular instance.
|
|
//
|
|
// At its essence, a TypeHandle is simply a unique
|
|
// identifier that is assigned by the TypeRegistry. The
|
|
// TypeRegistry stores a tree of TypeHandles, so that
|
|
// ancestry of a particular type may be queried, and the
|
|
// type name may be retrieved for run-time display.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
736 12 TypeHandle * 0 8576 12 TypeHandle * 12 TypeHandle * 0 0 735 0 0 0 0 0 0 0 0 0 0
|
|
|
|
737 21 TypedReferenceCount * 0 8576 21 TypedReferenceCount * 21 TypedReferenceCount * 0 0 705 0 0 0 0 0 0 0 0 0 0
|
|
|
|
738 9 Namable * 0 8576 9 Namable * 9 Namable * 0 0 706 0 0 0 0 0 0 0 0 0 0
|
|
|
|
739 23 DynamicTextPage const * 0 8576 23 DynamicTextPage const * 23 DynamicTextPage const * 0 0 740 0 0 0 0 0 0 0 0 0 0
|
|
|
|
740 21 DynamicTextPage const 0 8832 21 DynamicTextPage const 21 DynamicTextPage const 0 0 709 0 0 0 0 0 0 0 0 0 0
|
|
|
|
741 23 DynamicTextFont const * 0 8576 23 DynamicTextFont const * 23 DynamicTextFont const * 0 0 742 0 0 0 0 0 0 0 0 0 0
|
|
|
|
742 21 DynamicTextFont const 0 8832 21 DynamicTextFont const 21 DynamicTextFont const 0 0 711 0 0 0 0 0 0 0 0 0 0
|
|
|
|
743 17 DynamicTextFont * 0 8576 17 DynamicTextFont * 17 DynamicTextFont * 0 0 711 0 0 0 0 0 0 0 0 0 0
|
|
|
|
744 16 Filename const * 0 8576 16 Filename const * 16 Filename const * 0 0 745 0 0 0 0 0 0 0 0 0 0
|
|
|
|
745 14 Filename const 0 8832 14 Filename const 14 Filename const 0 0 746 0 0 0 0 0 0 0 0 0 0
|
|
|
|
746 8 Filename 0 2048 8 Filename 8 Filename 0 0 0 0 0 0 0 0 0 0 0 0 869
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : Filename
|
|
// Description : The name of a file, such as a texture file or an Egg
|
|
// file. Stores the full pathname, and includes
|
|
// functions for extracting out the directory prefix
|
|
// part and the file extension and stuff.
|
|
//
|
|
// A Filename is also aware of the mapping between the
|
|
// Unix-like filename convention we use internally, and
|
|
// the local OS's specific filename convention, and it
|
|
// knows how to perform basic OS-specific I/O, like
|
|
// testing for file existence and searching a
|
|
// searchpath, as well as the best way to open an
|
|
// fstream for reading or writing.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
747 13 atomic string 0 2 13 atomic string 13 atomic string 0 7 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
748 10 FilterType 0 794624 19 Texture::FilterType 19 Texture::FilterType 710 0 0 0 0 0 0 0 0 0 9 10 FT_nearest 19 Texture::FT_nearest 0 9 FT_linear 18 Texture::FT_linear 1 25 FT_nearest_mipmap_nearest 34 Texture::FT_nearest_mipmap_nearest 2 24 FT_linear_mipmap_nearest 33 Texture::FT_linear_mipmap_nearest 3 24 FT_nearest_mipmap_linear 33 Texture::FT_nearest_mipmap_linear 4 23 FT_linear_mipmap_linear 32 Texture::FT_linear_mipmap_linear 5 9 FT_shadow 18 Texture::FT_shadow 6 10 FT_default 19 Texture::FT_default 7 10 FT_invalid 19 Texture::FT_invalid 8 0 0
|
|
|
|
749 18 LVecBase4f const * 0 8576 18 LVecBase4f const * 18 LVecBase4f const * 0 0 750 0 0 0 0 0 0 0 0 0 0
|
|
|
|
750 16 LVecBase4f const 0 8832 16 LVecBase4f const 16 LVecBase4f const 0 0 751 0 0 0 0 0 0 0 0 0 0
|
|
|
|
751 10 LVecBase4f 0 2048 10 LVecBase4f 10 LVecBase4f 0 0 0 0 0 0 0 0 0 0 0 0 265
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : LVecBase4
|
|
// Description : This is the base class for all three-component
|
|
// vectors and points.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
752 6 Format 0 794624 15 Texture::Format 15 Texture::Format 710 0 0 0 0 0 0 0 0 0 37 15 F_depth_stencil 24 Texture::F_depth_stencil 1 13 F_color_index 22 Texture::F_color_index 2 5 F_red 14 Texture::F_red 3 7 F_green 16 Texture::F_green 4 6 F_blue 15 Texture::F_blue 5 7 F_alpha 16 Texture::F_alpha 6 5 F_rgb 14 Texture::F_rgb 7 6 F_rgb5 15 Texture::F_rgb5 8 6 F_rgb8 15 Texture::F_rgb8 9 7 F_rgb12 16 Texture::F_rgb12 10 8 F_rgb332 17 Texture::F_rgb332 11 6 F_rgba 15 Texture::F_rgba 12 6 F_rgbm 15 Texture::F_rgbm 13 7 F_rgba4 16 Texture::F_rgba4 14 7 F_rgba5 16 Texture::F_rgba5 15 7 F_rgba8 16 Texture::F_rgba8 16 8 F_rgba12 17 Texture::F_rgba12 17 11 F_luminance 20 Texture::F_luminance 18 17 F_luminance_alpha 26 Texture::F_luminance_alpha 19 21 F_luminance_alphamask 30 Texture::F_luminance_alphamask 20 8 F_rgba16 17 Texture::F_rgba16 21 8 F_rgba32 17 Texture::F_rgba32 22 17 F_depth_component 26 Texture::F_depth_component 23 19 F_depth_component16 28 Texture::F_depth_component16 24 19 F_depth_component24 28 Texture::F_depth_component24 25 19 F_depth_component32 28 Texture::F_depth_component32 26 5 F_r16 14 Texture::F_r16 27 6 F_rg16 15 Texture::F_rg16 28 7 F_rgb16 16 Texture::F_rgb16 29 6 F_srgb 15 Texture::F_srgb 30 12 F_srgb_alpha 21 Texture::F_srgb_alpha 31 12 F_sluminance 21 Texture::F_sluminance 32 18 F_sluminance_alpha 27 Texture::F_sluminance_alpha 33 6 F_r32i 15 Texture::F_r32i 34 5 F_r32 14 Texture::F_r32 35 6 F_rg32 15 Texture::F_rg32 36 7 F_rgb32 16 Texture::F_rgb32 37 0 0
|
|
|
|
753 17 DynamicTextPage * 0 8576 17 DynamicTextPage * 17 DynamicTextPage * 0 0 709 0 0 0 0 0 0 0 0 0 0
|
|
|
|
754 14 FreetypeFont * 0 8576 14 FreetypeFont * 14 FreetypeFont * 0 0 712 0 0 0 0 0 0 0 0 0 0
|
|
|
|
755 11 PandaNode * 0 8576 11 PandaNode * 11 PandaNode * 0 0 723 0 0 0 0 0 0 0 0 0 0
|
|
|
|
756 16 CoordinateSystem 0 532480 16 CoordinateSystem 16 CoordinateSystem 0 0 0 0 0 0 0 0 0 0 6 10 CS_default 10 CS_default 0 12 CS_zup_right 12 CS_zup_right 1 12 CS_yup_right 12 CS_yup_right 2 11 CS_zup_left 11 CS_zup_left 3 11 CS_yup_left 11 CS_yup_left 4 10 CS_invalid 10 CS_invalid 5 0 0
|
|
|
|
757 16 StaticTextFont * 0 8576 16 StaticTextFont * 16 StaticTextFont * 0 0 716 0 0 0 0 0 0 0 0 0 0
|
|
|
|
758 16 TextProperties * 0 8576 16 TextProperties * 16 TextProperties * 0 0 717 0 0 0 0 0 0 0 0 0 0
|
|
|
|
759 22 TextProperties const * 0 8576 22 TextProperties const * 22 TextProperties const * 0 0 760 0 0 0 0 0 0 0 0 0 0
|
|
|
|
760 20 TextProperties const 0 8832 20 TextProperties const 20 TextProperties const 0 0 717 0 0 0 0 0 0 0 0 0 0
|
|
|
|
761 12 LVecBase4f * 0 8576 12 LVecBase4f * 12 LVecBase4f * 0 0 751 0 0 0 0 0 0 0 0 0 0
|
|
|
|
762 18 LVecBase2f const * 0 8576 18 LVecBase2f const * 18 LVecBase2f const * 0 0 763 0 0 0 0 0 0 0 0 0 0
|
|
|
|
763 16 LVecBase2f const 0 8832 16 LVecBase2f const 16 LVecBase2f const 0 0 764 0 0 0 0 0 0 0 0 0 0
|
|
|
|
764 10 LVecBase2f 0 2048 10 LVecBase2f 10 LVecBase2f 0 0 0 0 0 0 0 0 0 0 0 0 752
|
|
// Filename: lvecBase2_src.h
|
|
// Created by: drose (08Mar00)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : LVecBase2
|
|
// Description : This is the base class for all two-component
|
|
// vectors and points.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
765 9 LVector2f 0 2048 9 LVector2f 9 LVector2f 0 0 0 0 0 0 0 0 0 0 0 0 707
|
|
// Filename: lvector2_src.h
|
|
// Created by: drose (08Mar00)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : LVector2
|
|
// Description : This is a two-component vector offset.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
766 11 LVector2f * 0 8576 11 LVector2f * 11 LVector2f * 0 0 765 0 0 0 0 0 0 0 0 0 0
|
|
|
|
767 13 TextGraphic * 0 8576 13 TextGraphic * 13 TextGraphic * 0 0 719 0 0 0 0 0 0 0 0 0 0
|
|
|
|
768 16 NodePath const * 0 8576 16 NodePath const * 16 NodePath const * 0 0 769 0 0 0 0 0 0 0 0 0 0
|
|
|
|
769 14 NodePath const 0 8832 14 NodePath const 14 NodePath const 0 0 770 0 0 0 0 0 0 0 0 0 0
|
|
|
|
770 8 NodePath 0 2048 8 NodePath 8 NodePath 0 0 0 0 0 0 0 2 801 802 0 0 0 0 4938
|
|
//
|
|
// A NodePath is the fundamental unit of high-level interaction with
|
|
// the scene graph. It encapsulates the complete path down to a node
|
|
// from some other node, usually the root of the scene graph. This is
|
|
// used to resolve ambiguities associated with instancing.
|
|
//
|
|
// NodePath also contains a number of handy high-level methods for
|
|
// common scene-graph manipulations, such as reparenting, and common
|
|
// state changes, such as repositioning.
|
|
//
|
|
// There are also a number of NodePath methods for finding nodes deep
|
|
// within the tree by name or by type. These take a path string,
|
|
// which at its simplest consists of a series of node names separated
|
|
// by slashes, like a directory pathname.
|
|
//
|
|
// Each component of the path string may optionally consist of one of
|
|
// the following special names, instead of a node name:
|
|
//
|
|
// * -- matches exactly one node, with any name.
|
|
// ** -- matches any sequence of zero or more nodes.
|
|
// +typename -- matches any node that is or derives from the given type.
|
|
// -typename -- matches any node that is the given type exactly.
|
|
// =tag -- matches any node that has the indicated tag.
|
|
// =tag=value -- matches any node whose tag matches the indicated value.
|
|
//
|
|
// Furthermore, a node name may itself contain standard filename
|
|
// globbing characters, like *, ?, and [a-z], that will be accepted as
|
|
// a partial match. (In fact, the '*' special name may be seen as
|
|
// just a special case of this.) The globbing characters may not be
|
|
// used with the typename matches or with tag matches, but they may
|
|
// be used to match a tag's value in the =tag=value syntax.
|
|
//
|
|
// The special characters "@@", appearing at the beginning of a node
|
|
// name, indicate a stashed node. Normally, stashed nodes are not
|
|
// returned by a find (but see the special flags, below), but a
|
|
// stashed node may be found if it is explicitly named with its
|
|
// leading @@ characters. By extension, "@@*" may be used to identify
|
|
// any stashed node.
|
|
//
|
|
// Examples:
|
|
//
|
|
// "room//graph" will look for a node named "graph", which is a child
|
|
// of an unnamed node, which is a child of a node named "room", which
|
|
// is a child of the starting path.
|
|
//
|
|
// "**/red*" will look for any node anywhere in the tree (below the
|
|
// starting path) with a name that begins with "red".
|
|
//
|
|
// "**/+PartBundleNode/**/head" will look for a node named "head",
|
|
// somewhere below a PartBundleNode anywhere in the tree.
|
|
//
|
|
//
|
|
// The search is always potentially ambiguous, even if the special
|
|
// wildcard operators are not used, because there may be multiple
|
|
// nodes in the tree with the same name. In general, in the case of
|
|
// an ambiguity, the shortest path is preferred; when a method (such
|
|
// as extend_by) must choose only only one of several possible paths,
|
|
// it will choose the shortest available; on the other hand, when a
|
|
// method (such as find_all_matches) is to return all of the matching
|
|
// paths, it will sort them so that the shortest paths appear first in
|
|
// the output.
|
|
//
|
|
//
|
|
// Special flags. The entire string may optionally be followed by the
|
|
// ";" character, followed by one or more of the following special
|
|
// control flags, with no intervening spaces or punctuation:
|
|
//
|
|
// -h Do not return hidden nodes.
|
|
// +h Do return hidden nodes.
|
|
// -s Do not return stashed nodes unless explicitly referenced with @@.
|
|
// +s Return stashed nodes even without any explicit @@ characters.
|
|
// -i Node name comparisons are not case insensitive: case must match
|
|
// exactly.
|
|
// +i Node name comparisons are case insensitive: case is not important.
|
|
// This affects matches against the node name only; node type
|
|
// and tag strings are always case sensitive.
|
|
//
|
|
// The default flags are +h-s-i.
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : NodePath
|
|
// Description : NodePath is the fundamental system for disambiguating
|
|
// instances, and also provides a higher-level interface
|
|
// for manipulating the scene graph.
|
|
//
|
|
// A NodePath is a list of connected nodes from the root
|
|
// of the graph to any sub-node. Each NodePath
|
|
// therefore uniquely describes one instance of a node.
|
|
//
|
|
// NodePaths themselves are lightweight objects that may
|
|
// easily be copied and passed by value. Their data is
|
|
// stored as a series of NodePathComponents that are
|
|
// stored on the nodes. Holding a NodePath will keep a
|
|
// reference count to all the nodes in the path.
|
|
// However, if any node in the path is removed or
|
|
// reparented (perhaps through a different NodePath),
|
|
// the NodePath will automatically be updated to reflect
|
|
// the changes.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
771 19 TextGraphic const * 0 8576 19 TextGraphic const * 19 TextGraphic const * 0 0 772 0 0 0 0 0 0 0 0 0 0
|
|
|
|
772 17 TextGraphic const 0 8832 17 TextGraphic const 17 TextGraphic const 0 0 719 0 0 0 0 0 0 0 0 0 0
|
|
|
|
773 10 NodePath * 0 8576 10 NodePath * 10 NodePath * 0 0 770 0 0 0 0 0 0 0 0 0 0
|
|
|
|
774 23 TextPropertiesManager * 0 8576 23 TextPropertiesManager * 23 TextPropertiesManager * 0 0 720 0 0 0 0 0 0 0 0 0 0
|
|
|
|
775 29 TextPropertiesManager const * 0 8576 29 TextPropertiesManager const * 29 TextPropertiesManager const * 0 0 776 0 0 0 0 0 0 0 0 0 0
|
|
|
|
776 27 TextPropertiesManager const 0 8832 27 TextPropertiesManager const 27 TextPropertiesManager const 0 0 720 0 0 0 0 0 0 0 0 0 0
|
|
|
|
777 21 TextAssembler const * 0 8576 21 TextAssembler const * 21 TextAssembler const * 0 0 778 0 0 0 0 0 0 0 0 0 0
|
|
|
|
778 19 TextAssembler const 0 8832 19 TextAssembler const 19 TextAssembler const 0 0 721 0 0 0 0 0 0 0 0 0 0
|
|
|
|
779 15 TextAssembler * 0 8576 15 TextAssembler * 15 TextAssembler * 0 0 721 0 0 0 0 0 0 0 0 0 0
|
|
|
|
780 13 TextEncoder * 0 8576 13 TextEncoder * 13 TextEncoder * 0 0 724 0 0 0 0 0 0 0 0 0 0
|
|
|
|
781 9 UsageHint 0 794624 20 GeomEnums::UsageHint 20 GeomEnums::UsageHint 782 0 0 0 0 0 0 0 0 0 5 9 UH_client 20 GeomEnums::UH_client 0 9 UH_stream 20 GeomEnums::UH_stream 1 10 UH_dynamic 21 GeomEnums::UH_dynamic 2 9 UH_static 20 GeomEnums::UH_static 3 14 UH_unspecified 25 GeomEnums::UH_unspecified 4 0 382
|
|
// The usage hint describes to the rendering backend how often the
|
|
// data in question will be modified and/or rendered. It allows the
|
|
// backend to make appropriate choices about what part of memory the
|
|
// data should be stored in.
|
|
// The hint is provided as a performance optimization only, and does
|
|
// not constrain actual usage; although it may be an important
|
|
// optimization.
|
|
|
|
782 9 GeomEnums 0 2048 9 GeomEnums 9 GeomEnums 0 0 0 0 0 0 0 0 0 0 0 0 400
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : GeomEnums
|
|
// Description : This class exists just to provide scoping for the
|
|
// various enumerated types used by Geom,
|
|
// GeomVertexData, GeomVertexArrayData, GeomPrimitive,
|
|
// and other related classes.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
783 7 wchar_t 0 8194 7 wchar_t 7 wchar_t 0 1 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
784 17 LVector2f const * 0 8576 17 LVector2f const * 17 LVector2f const * 0 0 785 0 0 0 0 0 0 0 0 0 0
|
|
|
|
785 15 LVector2f const 0 8832 15 LVector2f const 15 LVector2f const 0 0 765 0 0 0 0 0 0 0 0 0 0
|
|
|
|
786 10 TextNode * 0 8576 10 TextNode * 10 TextNode * 0 0 722 0 0 0 0 0 0 0 0 0 0
|
|
|
|
787 16 TextNode const * 0 8576 16 TextNode const * 16 TextNode const * 0 0 788 0 0 0 0 0 0 0 0 0 0
|
|
|
|
788 14 TextNode const 0 8832 14 TextNode const 14 TextNode const 0 0 722 0 0 0 0 0 0 0 0 0 0
|
|
|
|
789 9 Texture * 0 8576 9 Texture * 9 Texture * 0 0 710 0 0 0 0 0 0 0 0 0 0
|
|
|
|
790 17 LMatrix4f const * 0 8576 17 LMatrix4f const * 17 LMatrix4f const * 0 0 791 0 0 0 0 0 0 0 0 0 0
|
|
|
|
791 15 LMatrix4f const 0 8832 15 LMatrix4f const 15 LMatrix4f const 0 0 792 0 0 0 0 0 0 0 0 0 0
|
|
|
|
792 9 LMatrix4f 0 2048 9 LMatrix4f 9 LMatrix4f 0 0 0 0 0 0 0 3 803 804 805 0 0 0 0 215
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : LMatrix4
|
|
// Description : This is a 4-by-4 transform matrix.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
793 11 LMatrix4f * 0 8576 11 LMatrix4f * 11 LMatrix4f * 0 0 792 0 0 0 0 0 0 0 0 0 0
|
|
|
|
794 8 Encoding 0 794624 21 TextEncoder::Encoding 21 TextEncoder::Encoding 724 0 0 0 0 0 0 0 0 0 3 9 E_iso8859 22 TextEncoder::E_iso8859 0 6 E_utf8 19 TextEncoder::E_utf8 1 9 E_unicode 22 TextEncoder::E_unicode 2 0 0
|
|
|
|
795 8 LPoint3f 0 2048 8 LPoint3f 8 LPoint3f 0 0 0 0 0 0 0 0 0 0 0 0 1083
|
|
// Filename: lpoint3_src.h
|
|
// Created by: drose (25Sep99)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
//
|
|
// PANDA 3D SOFTWARE
|
|
// Copyright (c) Carnegie Mellon University. All rights reserved.
|
|
//
|
|
// All use of this software is subject to the terms of the revised BSD
|
|
// license. You should have received a copy of this license along
|
|
// with this source code in a file named "LICENSE."
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
// Class : LPoint3
|
|
// Description : This is a three-component point in space (as opposed
|
|
// to a three-component vector, which represents a
|
|
// direction and a distance). Some of the methods are
|
|
// slightly different between LPoint3 and LVector3; in
|
|
// particular, subtraction of two points yields a
|
|
// vector, while addition of a vector and a point yields
|
|
// a point.
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
796 10 LPoint3f * 0 8576 10 LPoint3f * 10 LPoint3f * 0 0 795 0 0 0 0 0 0 0 0 0 0
|
|
|
|
797 6 string 0 2048 20 basic_string< char > 20 basic_string< char > 0 0 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
798 7 wstring 0 2048 23 basic_string< wchar_t > 23 basic_string< wchar_t > 0 0 0 0 0 0 0 0 0 0 0 0 0
|
|
|
|
0
|
|
0
|
|
7
|
|
799 0 0 25 9 get_pages 13 get_num_pages 8 get_page
|
|
800 0 0 90 14 get_primitives 18 get_num_primitives 13 get_primitive
|
|
801 0 0 585 9 get_nodes 13 get_num_nodes 8 get_node
|
|
802 0 0 585 13 get_ancestors 13 get_num_nodes 12 get_ancestor
|
|
803 0 0 716 8 get_rows 4 size 7 get_row
|
|
804 0 0 716 8 get_cols 4 size 7 get_col
|
|
805 0 0 716 9 get_row3s 4 size 8 get_row3
|