CellexalVR  1.1.0
A virtual reality platform for the exploration and analysis of single-cell gene expression data
CellexalVR.AnalysisObjects.LegendManager Class Reference

Represents a manager that handles a set of legends. More...

Inheritance diagram for CellexalVR.AnalysisObjects.LegendManager:
CellexalVR.AnalysisObjects.EnvironmentMenuWithTabs CellexalVR.Interaction.CellexalRaycastable

Public Types

enum  Legend { AttributeLegend, GeneExpressionLegend, SelectionLegend }
 

Public Member Functions

void DetachLegendFromCube ()
 Detach by clicking the detach button. Goes back to normal legend state. More...
 
void DeactivateLegend ()
 Deactivates all legends and hides the legend. More...
 
void ActivateLegend ()
 Activates the desired legend, as determined by desiredLegend. More...
 
void ActivateLegend (Legend legendToActivate)
 Activates a legend. Does not set the gameobject active. More...
 
void ClearLegends ()
 Clears all legends. More...
 
Vector3 WorldToRelativePos (Vector3 worldPos)
 Projects and converts a world space coordinate to a local position on the legend plane. More...
 
Vector3 WorldToRelativeHistogramPos (Vector3 worldPos)
 PRojects and converts a workd More...
 
- Public Member Functions inherited from CellexalVR.AnalysisObjects.EnvironmentMenuWithTabs
void SetTabButtonPositions (bool overrideShowScrollButtons=false)
 Recalculates tabButtonPositions and tabScrollPositions. Should be called if an EnvironmentTab is added or removed. More...
 
void MoveTabButtons ()
 Moves all tab button gameobjects to their correct positions. This function moves all tab buttons, visible and hidden, and sets the disables the hidden ones with GameObject.SetActive(bool). More...
 
EnvironmentTab AddTab ()
 Adds a new tab to this menu, using the tabPrefab. More...
 
void SwitchToTab (EnvironmentTab tab)
 Switches to the specified tab by disabling the content of all others, and enabling the content of the specified tab. More...
 
void ScrollTabs (int direction)
 Scrolls the tab buttons. More...
 
void TurnOffAllTabs ()
 Dsiables the content gameobject on all tabs. More...
 
- Public Member Functions inherited from CellexalVR.Interaction.CellexalRaycastable
virtual void OnRaycastHit (RaycastHit hitInfo, CellexalRaycast raycaster)
 Called by CellexalRaycast.Update every frame that a raycast hit this target. More...
 
virtual void OnRaycastEnter ()
 Called on the first frame that this CellexalRaycastable is hit by a CellexalRaycast. More...
 
virtual void OnRaycastExit ()
 Called on the first frame that this CellexalRaycastable is not hit by a CellexalRaycast anymore. More...
 

Public Attributes

GameObject backgroundPlane
 
GroupingLegend attributeLegend
 
GroupingLegend selectionLegend
 
GameObject detachArea
 
GeneExpressionHistogram geneExpressionHistogram
 
bool legendActive
 
Legend desiredLegend
 
Legend currentLegend
 
Dictionary< Legend, EnvironmentTablegends = new Dictionary<Legend, EnvironmentTab>()
 
- Public Attributes inherited from CellexalVR.AnalysisObjects.EnvironmentMenuWithTabs
List< EnvironmentTabtabs
 
EnvironmentTab tabPrefab
 
EnvironmentTabScrollButton tabScrollButton1
 
EnvironmentTabScrollButton tabScrollButton2
 
float tabScrollTime = 0.5f
 
Vector3 tabButtonSize = new Vector3(0.1f, 0f, 0f)
 
Vector3 tabButtonPositionIncrement
 
Vector3 tabButtonBoundsCenter
 
Vector3 tabButtonBoundsSize
 
Vector3[] tabButtonPositions
 
Vector3[] tabScrollPositions
 
- Public Attributes inherited from CellexalVR.Interaction.CellexalRaycastable
UnityEvent OnActivate
 
UnityEvent RaycastEnter
 
UnityEvent RaycastExit
 
bool canBePushedAndPulled = true
 
bool active = true
 

Detailed Description

Represents a manager that handles a set of legends.

Member Function Documentation

◆ ActivateLegend() [1/2]

void CellexalVR.AnalysisObjects.LegendManager.ActivateLegend ( )

Activates the desired legend, as determined by desiredLegend.

◆ ActivateLegend() [2/2]

void CellexalVR.AnalysisObjects.LegendManager.ActivateLegend ( Legend  legendToActivate)

Activates a legend. Does not set the gameobject active.

Parameters
legendToActivateThe legend to activate

◆ ClearLegends()

void CellexalVR.AnalysisObjects.LegendManager.ClearLegends ( )

Clears all legends.

◆ DeactivateLegend()

void CellexalVR.AnalysisObjects.LegendManager.DeactivateLegend ( )

Deactivates all legends and hides the legend.

◆ DetachLegendFromCube()

void CellexalVR.AnalysisObjects.LegendManager.DetachLegendFromCube ( )

Detach by clicking the detach button. Goes back to normal legend state.

◆ WorldToRelativeHistogramPos()

Vector3 CellexalVR.AnalysisObjects.LegendManager.WorldToRelativeHistogramPos ( Vector3  worldPos)

PRojects and converts a workd

Parameters
worldPos
Returns

◆ WorldToRelativePos()

Vector3 CellexalVR.AnalysisObjects.LegendManager.WorldToRelativePos ( Vector3  worldPos)

Projects and converts a world space coordinate to a local position on the legend plane.

Parameters
worldPosThe world coordinate to convert.
Returns
A Vector3 in the range [0,1]

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