Tanoda
Leap.Unity.GraphicalRenderer.LeapTextGraphic Class Reference
Inheritance diagram for Leap.Unity.GraphicalRenderer.LeapTextGraphic:
Leap.Unity.GraphicalRenderer.LeapGraphic Leap.Unity.Space.ISpaceComponent

Public Types

enum  HorizontalAlignment { Left , Center , Right }
 
enum  VerticalAlignment { Top , Center , Bottom }
 

Public Member Functions

bool HasRectChanged ()
 
- Public Member Functions inherited from Leap.Unity.GraphicalRenderer.LeapGraphic
void SetBlendShapeAmount (float amount)
 Helper method to set the blend shape amount for a blend shape data object attached to this graphic. This method will throw an exception if there is no blend shape data obj attached to this graphic. More...
 
float GetBlendShapeAmount ()
 Helper method to get the blend shape amount for a blend shape data object attached to this graphic. This method will throw an exception if there is no blend shape data obj attached to this graphic. More...
 
void SetCustomChannel (string channelName, Color color)
 Helper method to set the custom channel value for the given channel name. This method will throw an exception if there is no channel with the given name, if the graphic is not currently attached to a group, or if the channel does not match up with the data type. More...
 
void SetCustomChannel (string channelName, float value)
 Helper method to set the custom channel value for the given channel name. This method will throw an exception if there is no channel with the given name, if the graphic is not currently attached to a group, or if the channel does not match up with the data type. More...
 
void SetCustomChannel (string channelName, Matrix4x4 value)
 Helper method to set the custom channel value for the given channel name. This method will throw an exception if there is no channel with the given name, if the graphic is not currently attached to a group, or if the channel does not match up with the data type. More...
 
void SetCustomChannel (string channelName, Vector4 value)
 Helper method to set the custom channel value for the given channel name. This method will throw an exception if there is no channel with the given name, if the graphic is not currently attached to a group, or if the channel does not match up with the data type. More...
 
GetCustomChannel< T > (string channelName)
 Helper method to get a custom channel data object given the name of the feature it is attached to. This method can only be used if the graphic is currently attached to a group. More...
 
void SetRuntimeTint (Color color)
 Helper method to set the runtime tint color for a runtime tint data object attached to this graphic. This method will throw an exception if there is no tint data obj attached to this graphic. More...
 
void SetRuntimeTint (string htmlString)
 Overload of SetRuntimeTint that takes in a Html style string code that represents a color. Any string that can be parsed by ColorUtility.TryParseHtmlString can be used as an argument to this method. More...
 
Color GetRuntimeTint ()
 Helper method to get the runtime tint color for a runtime tint data object attached to this graphic. This method will throw an exception if there is no tint data obj attached to this graphic. More...
 
bool TryDetach ()
 This method tries to detach this graphic from whatever group it is currently attached to. It can fail if the graphic is not attached to any group, or if the group it is attached to does not support adding/removing graphics at runtime. More...
 
GetFeatureData< T > ()
 Gets a single feature data object of a given type T. This will return null if there is no feature data object attached to this graphic of type T. More...
 
virtual void NotifyWillBeAttached (LeapGraphicGroup toBeAttachedTo)
 Called by the system to notify that this graphic will be attached within the next frame. This is only called at runtime. More...
 
virtual void CancelWillBeAttached ()
 Called by the system to notify that a previous notification that this graphic would be attached has been cancelled due to a call to TryRemoveGraphic. More...
 
virtual void NotifyWillBeDetached (LeapGraphicGroup toBeDetachedFrom)
 Called by the system to notify that this graphic will be detached within the next frame. This is only called at runtime. More...
 
virtual void CancelWillBeDetached ()
 Called by the system to notify that a previous notification that this graphic would be detached has been cancelled due to a call to TryAddGraphic. More...
 
virtual void OnAttachedToGroup (LeapGraphicGroup group, LeapSpaceAnchor anchor)
 Called by the system when this graphic is attached to a group. This method is invoked both at runtime and at edit time. More...
 
void OnUpdateAnchor (LeapSpaceAnchor anchor)
 Called by graphic groups when a renderer's attached space changes. More...
 
virtual void OnDetachedFromGroup ()
 Called by the system when this graphic is detached from a group. This method is invoked both at runtime and at edit time. More...
 
virtual void OnAssignFeatureData (List< LeapFeatureData > data)
 Called by the system whenever feature data is re-assigned to this graphic. This is only called at edit time. More...
 
virtual void OnBeforeSerialize ()
 
virtual void OnAfterDeserialize ()
 

Protected Member Functions

override void OnValidate ()
 
- Protected Member Functions inherited from Leap.Unity.GraphicalRenderer.LeapGraphic
virtual void Reset ()
 
virtual void OnValidate ()
 
virtual void Awake ()
 
virtual void OnEnable ()
 
virtual void OnDestroy ()
 
virtual void OnDrawGizmos ()
 

Properties

List< TextWrapper.Tokentokens [get]
 
string text [get, set]
 
FontStyle fontStyle [get, set]
 
int fontSize [get, set]
 
float lineSpacing [get, set]
 
HorizontalAlignment horizontalAlignment [get, set]
 
VerticalAlignment verticalAlignment [get, set]
 
Color color [get, set]
 
- Properties inherited from Leap.Unity.GraphicalRenderer.LeapGraphic
bool isRepresentationDirty [get, set]
 An internal flag that returns true if the visual representation of this graphic needs to be updated. You can set this to true to request a regeneration of the graphic during the next update cycle of the renderer. Note however, that not all renderers support updating the representation at runtime. More...
 
bool isRepresentationDirtyOrEditTime [get]
 A simple utility getter that returns true if isRepresentationDirty is true, OR it is currently edit time. More...
 
string favoriteGroupName [get, set]
 Gets or sets the name of the group that this graphic likes to be attached to. Whenever a graphic is enabled, it will try to attach to its favorite group. Whenever a graphic gets attached to a group, that group becomes its new favorite. More...
 
LeapSpaceAnchor anchor [get]
 Returns the space anchor for this graphic. This will be null if the graphic is not currently part of a space. The anchor cannot be changed dynamically at runtime. More...
 
ITransformer transformer [get]
 A utility getter that returns a transformer for this graphic. Even if the space anchor for this graphic is null, this will still return a valid transformer. In the null case, the transformer is always the identity transformer. More...
 
IList< LeapFeatureDatafeatureData [get]
 Returns a list of feature data attached to this graphic. If this graphic is attached to a group, this feature data matches 1-to-1 with the features attached to this group. More...
 
LeapGraphicGroup attachedGroup [get]
 Returns the group this graphic is attached to. More...
 
bool isAttachedToGroup [get]
 Returns whether or not this graphic is attached to any group. Can still return false at runtime even if TryAddGraphic has just completed successfully due to the runtime delay for addition/removal of graphics. More...
 
bool willbeAttached [get]
 Returns whether or not this graphic will be attached to a group within the next frame. Can only be true at runtime, since runtime is the only time when delayed attachment occurs. More...
 
bool willbeDetached [get]
 Returns whether or not this graphic will be detached from a group within the next frame. Can only be true at runtime, since runtime is the only time when delayed detaching occurs. More...
 
Type preferredRendererType [get]
 Returns the type this graphic prefers to be attached to. When calling LeapGraphicRenderer.TryAddGraphic it will prioritize being attached to groups with this renderer type if possible. More...
 
- Properties inherited from Leap.Unity.Space.ISpaceComponent
LeapSpaceAnchor anchor [get]
 

Additional Inherited Members

- Public Attributes inherited from Leap.Unity.GraphicalRenderer.LeapGraphic
Action< LeapGraphicGroupOnAttachedToGroupEvent
 
Action OnDetachedFromGroupEvent
 
- Protected Attributes inherited from Leap.Unity.GraphicalRenderer.LeapGraphic
LeapSpaceAnchor _anchor
 
FeatureDataList _featureData = new FeatureDataList()
 
LeapGraphicRenderer _attachedRenderer
 
int _attachedGroupIndex = -1
 
string _favoriteGroupName
 
SerializableType _preferredRendererType
 

Detailed Description

Definition at line 15 of file LeapTextGraphic.cs.

Member Enumeration Documentation

◆ HorizontalAlignment

Enumerator
Left 
Center 
Right 

Definition at line 166 of file LeapTextGraphic.cs.

◆ VerticalAlignment

Enumerator
Top 
Center 
Bottom 

Definition at line 172 of file LeapTextGraphic.cs.

Member Function Documentation

◆ HasRectChanged()

bool Leap.Unity.GraphicalRenderer.LeapTextGraphic.HasRectChanged ( )

Definition at line 151 of file LeapTextGraphic.cs.

◆ OnValidate()

override void Leap.Unity.GraphicalRenderer.LeapTextGraphic.OnValidate ( )
protectedvirtual

Reimplemented from Leap.Unity.GraphicalRenderer.LeapGraphic.

Definition at line 144 of file LeapTextGraphic.cs.

Property Documentation

◆ color

Color Leap.Unity.GraphicalRenderer.LeapTextGraphic.color
getset

Definition at line 132 of file LeapTextGraphic.cs.

◆ fontSize

int Leap.Unity.GraphicalRenderer.LeapTextGraphic.fontSize
getset

Definition at line 84 of file LeapTextGraphic.cs.

◆ fontStyle

FontStyle Leap.Unity.GraphicalRenderer.LeapTextGraphic.fontStyle
getset

Definition at line 72 of file LeapTextGraphic.cs.

◆ horizontalAlignment

HorizontalAlignment Leap.Unity.GraphicalRenderer.LeapTextGraphic.horizontalAlignment
getset

Definition at line 108 of file LeapTextGraphic.cs.

◆ lineSpacing

float Leap.Unity.GraphicalRenderer.LeapTextGraphic.lineSpacing
getset

Definition at line 96 of file LeapTextGraphic.cs.

◆ text

string Leap.Unity.GraphicalRenderer.LeapTextGraphic.text
getset

Definition at line 55 of file LeapTextGraphic.cs.

◆ tokens

List<TextWrapper.Token> Leap.Unity.GraphicalRenderer.LeapTextGraphic.tokens
get

Definition at line 44 of file LeapTextGraphic.cs.

◆ verticalAlignment

VerticalAlignment Leap.Unity.GraphicalRenderer.LeapTextGraphic.verticalAlignment
getset

Definition at line 120 of file LeapTextGraphic.cs.


The documentation for this class was generated from the following file: