C# Class UIWidgetInspector, DsynBio

Inheritance: UIRectEditor
Mostra file Open project: CyberCRI/DsynBio Class Usage Examples

Protected Properties

Property Type Description
mUseShader bool
mWidget UIWidget,

Public Methods

Method Description
OnInspectorGUI ( ) : void

Draw the inspector widget.

OnSceneGUI ( ) : void

Draw the on-screen selection, knobs, and handle all interaction logic.

Protected Methods

Method Description
DrawCommonProperties ( ) : void

All widgets have depth, color and make pixel-perfect options

DrawExtraProperties ( ) : void
DrawProperties ( ) : bool
OnInit ( ) : void

Any and all derived functionality.

Private Methods

Method Description
AdjustPosAndScale ( UIWidget, w, Vector3 startLocalPos, Vector3 startLocalScale, Vector3 worldDelta, UIWidget, dragPivot ) : void

Adjust the transform's position and scale.

AdjustWidget ( UIWidget, w, Vector3 pos, Vector3 scale, float left, float top, float right, float bottom, bool makeSquare ) : void

Adjust the widget's rectangle based on the specified modifier values.

Combine ( UIWidget, horizontal, UIWidget, vertical ) : UIWidget.Pivot
DrawKnob ( Vector3 point, bool selected, int id ) : void

Draw a control dot at the specified world position.

GetHorizontal ( UIWidget, pivot ) : UIWidget.Pivot
GetScreenDistance ( Vector3 worldPos, Vector2 mousePos ) : float

Screen-space distance from the mouse position to the specified world position.

GetScreenDistance ( Vector3 worldPoints, Vector2 mousePos, int &index ) : float

Closest screen-space distance from the mouse position to one of the specified world points.

GetVertical ( UIWidget, pivot ) : UIWidget.Pivot
IsBottom ( UIWidget, pivot ) : bool
IsLeft ( UIWidget, pivot ) : bool
IsMouseOverRect ( Vector2 mouse, List rects ) : bool

Whether the mouse position is within one of the specified rectangles.

IsRight ( UIWidget, pivot ) : bool
IsTop ( UIWidget, pivot ) : bool
Raycast ( UIWidget, widget, Vector2 mousePos ) : UIWidget[],

Raycast into the screen, returning an array of widgets.

Raycast ( Vector3 corners, Vector3 &hit ) : bool

Raycast into the screen.

RegisterUndo ( ) : void

Register an Undo command with the Unity editor.

SetCursorRect ( Rect rect, MouseCursor, cursor ) : void

Set the mouse cursor rectangle, refreshing the screen when it gets changed.

SetPivot ( UIWidget, pivot, bool isHorizontal ) : void
Toggle ( string text, string style, UIWidget, pivot, bool isHorizontal ) : void

Draw a toggle button for the pivot point.

Method Details

DrawCommonProperties() protected method

All widgets have depth, color and make pixel-perfect options
protected DrawCommonProperties ( ) : void
return void

DrawExtraProperties() protected method

protected DrawExtraProperties ( ) : void
return void

DrawProperties() protected method

protected DrawProperties ( ) : bool
return bool

OnInit() protected method

Any and all derived functionality.
protected OnInit ( ) : void
return void

OnInspectorGUI() public method

Draw the inspector widget.
public OnInspectorGUI ( ) : void
return void

OnSceneGUI() public method

Draw the on-screen selection, knobs, and handle all interaction logic.
public OnSceneGUI ( ) : void
return void

Property Details

mUseShader protected_oe static_oe property

protected static bool mUseShader
return bool

mWidget protected_oe property

protected UIWidget, mWidget
return UIWidget,