EditorGUIUtility Manual     Reference     Scripting  
Scripting > Editor Classes > EditorGUIUtility
EditorGUIUtility Inherits from GUIUtility

Misc helper stuff for EditorGUI.

Note: This is an editor class. To use it you have to place your script in Assets/Editor inside your project folder. Editor classes are in the UnityEditor namespace so for C# scripts you need to add "using UnityEditor;" at the beginning of the script.

Class Variables
isProSkin

Is the user currently using the pro skin? (Read Only)

whiteTexture

Get a white texture.

systemCopyBuffer

The system copy buffer.

Class Functions
ObjectContent

Return a GUIContent object with the name and icon of an Object.

HasObjectThumbnail

Does a given class have per-object thumbnails?

SetIconSize

Set icons rendered as part of GUIContent to be rendered at a specific size.

GetIconSize

Get the size that has been set using SetIconSize.

FindTexture

Get a texture from its source filename.

GetBuiltinSkin

Get one of the built-in GUI skins, which can be the game view, inspector or scene view skin as chosen by the parameter.

LoadRequired

Load a built-in resource that has to be there.

Load

Load a built-in resource

PingObject

Ping an object in a window like clicking it in an inspector

RenderGameViewCameras

Render all ingame cameras.

QueueGameViewInputEvent

Send an input event into the game.

LookLikeControls

Make all ref::EditorGUI look like regular controls.

LookLikeInspector

Make all EditorGUI look like simplified outline view controls.

CommandEvent

Creates an event

DrawColorSwatch

Draw a color swatch.

DrawCurveSwatch

Draw a curve swatch.

DrawRegionSwatch

Draw swatch with a filled region between two SerializedProperty curves.

RGBToHSV

Convert a color from RGB to HSV color space.

HSVToRGB

Convert a set of HSV values to an RGB Color.

AddCursorRect

Add a custom mouse pointer to a control

Inherited members
Inherited Class Variables
hotControl

The controlID of the current hot control.

keyboardControl

The controlID of the control that has keyboard focus.

Inherited Class Functions
GetControlID

Get a unique ID for a control.

GetStateObject

Get a state object from a controlID.

QueryStateObject

Get an existing state object from a controlID.

GUIToScreenPoint

Convert a point from GUI position to screen space.

ScreenToGUIPoint

Convert a point from screen space to GUI position.

RotateAroundPivot

Helper function to rotate the GUI around a point.

ScaleAroundPivot

Helper function to scale the GUI around a point.