Catlike Coding
Unity Code Documentation
Public Member Functions | Public Attributes | Properties | List of all members
CatlikeCoding.TextBox.TextRenderer Class Reference

Base class for text renderers. These end up as child objects of a text box. More...

Inherits MonoBehaviour.

Inherited by CatlikeCoding.TextBox.TextMeshRenderer.

Public Member Functions

virtual void Add (CharMetaData meta, Vector2 offset)
 Add a character. More...
 
virtual void Apply ()
 Perform any work that needs to be done after character have been added. More...
 
virtual void Prepare ()
 Perform any work that needs to be done before characters will be added, like clearing old data. More...
 
virtual void SetClipBounds (Bounds2D clipBounds)
 Perform any work to support clipping. More...
 

Public Attributes

int renderedCharCount
 How many characters to render. Will be set before Prepare is called. More...
 
TextBox textBox
 Text box that uses the renderer. More...
 

Properties

virtual Bounds Bounds [get]
 Get the 3D bounds of the rendered content. More...
 

Detailed Description

Base class for text renderers. These end up as child objects of a text box.

Member Function Documentation

virtual void CatlikeCoding.TextBox.TextRenderer.Add ( CharMetaData  meta,
Vector2  offset 
)
virtual

Add a character.

Parameters
metaCharacter meta data.
offsetAdditional offset.

Reimplemented in CatlikeCoding.TextBox.TextMeshRenderer, and CatlikeCoding.TextBox.TextMeshCylinderRenderer.

virtual void CatlikeCoding.TextBox.TextRenderer.Apply ( )
virtual

Perform any work that needs to be done after character have been added.

Reimplemented in CatlikeCoding.TextBox.TextMeshRenderer, CatlikeCoding.TextBox.TextMeshTorusRenderer, and CatlikeCoding.TextBox.TextMeshCircleRenderer.

virtual void CatlikeCoding.TextBox.TextRenderer.Prepare ( )
virtual

Perform any work that needs to be done before characters will be added, like clearing old data.

Reimplemented in CatlikeCoding.TextBox.TextMeshRenderer, and CatlikeCoding.TextBox.TextMeshCylinderRenderer.

virtual void CatlikeCoding.TextBox.TextRenderer.SetClipBounds ( Bounds2D  clipBounds)
virtual

Perform any work to support clipping.

It is up to subclasses whether they support clipping.

Parameters
clipBoundsClip bounds.

Reimplemented in CatlikeCoding.TextBox.TextMeshRenderer.

Member Data Documentation

int CatlikeCoding.TextBox.TextRenderer.renderedCharCount

How many characters to render. Will be set before Prepare is called.

TextBox CatlikeCoding.TextBox.TextRenderer.textBox

Text box that uses the renderer.

Property Documentation

virtual Bounds CatlikeCoding.TextBox.TextRenderer.Bounds
get

Get the 3D bounds of the rendered content.

It is up to subclasses whether they return useful bounds of not.