3rd Eye Scene C#
3rd Eye Scene C# documentation
Tes::Shapes::Text2D Class Reference

Defines 2D text to render. More...

Inheritance diagram for Tes::Shapes::Text2D:
Tes::Shapes::Shape

List of all members.

Public Member Functions

 Text2D (string text, Vector3 pos)
 Create a 2D text shape.
 Text2D (string text, uint id, Vector3 pos)
 Create a 2D text shape.
 Text2D (string text, uint id, ushort category, Vector3 pos)
 Create a 2D text shape.
 Text2D (string text)
 Create a 2D text shape.
 Text2D (string text, uint id)
 Create a 2D text shape.
 Text2D (string text, uint id, ushort category)
 Create a 2D text shape.
override bool WriteCreate (PacketBuffer packet)
 Overridden create message.
override object Clone ()
 Clone this shape.

Protected Member Functions

void OnClone (Text2D copy)
 Additional data copy on Clone().

Properties

string Text [get, set]
 The text string to render.
bool InWorldSpace [get, set]
 Position in world coordinates (true) or screen coordinates (false).

Detailed Description

Defines 2D text to render.

Can represent 2D screen located text, or 3D located text projected in to screen space. Use InWorldSpace true for 3D located text.

2D located text ignores the position Z coordinate. X and Y range [0, 1], with (0, 0) being the top left corner and (1, 1) the bottom right.


Constructor & Destructor Documentation

Tes::Shapes::Text2D::Text2D ( string  text,
Vector3  pos 
) [inline]

Create a 2D text shape.

Parameters:
textThe text string to display.
posThe text position.
Tes::Shapes::Text2D::Text2D ( string  text,
uint  id,
Vector3  pos 
) [inline]

Create a 2D text shape.

Parameters:
textThe text string to display.
idThe shape ID. Zero for transient shapes.
posThe text position.
Tes::Shapes::Text2D::Text2D ( string  text,
uint  id,
ushort  category,
Vector3  pos 
) [inline]

Create a 2D text shape.

Parameters:
textThe text string to display.
idThe shape ID. Zero for transient shapes.
categoryCategory to which the shape belongs.
posThe text position.
Tes::Shapes::Text2D::Text2D ( string  text) [inline]

Create a 2D text shape.

Parameters:
textThe text string to display.
Tes::Shapes::Text2D::Text2D ( string  text,
uint  id 
) [inline]

Create a 2D text shape.

Parameters:
textThe text string to display.
idThe shape ID. Zero for transient shapes.
Tes::Shapes::Text2D::Text2D ( string  text,
uint  id,
ushort  category 
) [inline]

Create a 2D text shape.

Parameters:
textThe text string to display.
idThe shape ID. Zero for transient shapes.
categoryCategory to which the shape belongs.

Member Function Documentation

override object Tes::Shapes::Text2D::Clone ( ) [inline, virtual]

Clone this shape.

Returns:
A deep copy of this object.

Reimplemented from Tes::Shapes::Shape.

void Tes::Shapes::Text2D::OnClone ( Text2D  copy) [inline, protected]

Additional data copy on Clone().

Parameters:
copyThe cloned object.
override bool Tes::Shapes::Text2D::WriteCreate ( PacketBuffer  packet) [inline, virtual]

Overridden create message.

Includes the text written as a byte count, followed by a series of UTF-8 bytes. No null terminator is included.

Parameters:
packetPacket to write to.
Returns:
True on success.

Reimplemented from Tes::Shapes::Shape.


The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Enumerations Properties Events