EditorGUIUtility

class in UnityEditor

/

Inherits from:GUIUtility

Switch to Manual

Description

Miscellaneous helper stuff for EditorGUI.

Static Variables

currentViewWidthThe width of the GUI area for the current EditorWindow or other view.
editingTextFieldIs a text field currently editing text?
fieldWidthThe minimum width in pixels reserved for the fields of Editor GUI controls.
hierarchyModeIs the Editor GUI is hierarchy mode?
isProSkinIs the user currently using the pro skin? (Read Only)
labelWidthThe width in pixels reserved for labels of Editor GUI controls.
pixelsPerPointThe scale of GUI points relative to screen pixels for the current viewThis value is the number of screen pixels per point of interface space. For instance, 2.0 on retina displays. Note that the value may differ from one view to the next if the views are on monitors with different UI scales.
singleLineHeightGet the height used for a single Editor control such as a one-line EditorGUI.TextField or EditorGUI.Popup.
standardVerticalSpacingGet the height used by default for vertical spacing between controls.
systemCopyBufferThe system copy buffer.
whiteTextureGet a white texture.
wideModeIs the Editor GUI currently in wide mode?

Static Functions

AddCursorRectAdd a custom mouse pointer to a control.
CommandEventCreates an event that can be sent to another window.
DrawColorSwatchDraw a color swatch.
DrawCurveSwatchDraw a curve swatch.
DrawRegionSwatchDraw swatch with a filled region between two SerializedProperty curves.
FindTextureGet a texture from its source filename.
GetBuiltinSkinGet one of the built-in GUI skins, which can be the game view, inspector or scene view skin as chosen by the parameter.
GetFlowLayoutedRectsLayout list of string items left to right, top to bottom in the given area.
GetIconSizeGet the size that has been set using SetIconSize.
GetObjectPickerControlIDThe controlID of the currently showing object picker.
GetObjectPickerObjectThe object currently selected in the object picker.
HasObjectThumbnailDoes a given class have per-object thumbnails?
IconContentFetch the GUIContent from the Unity builtin resources with the given name.
IsDisplayReferencedByCamerasCheck if any enabled camera can render to a particular display.
LoadLoad a built-in resource.
LoadRequiredLoad a required built-in resource.
ObjectContentReturn a GUIContent object with the name and icon of an Object.
PingObjectPing an object in the Scene like clicking it in an inspector.
PixelsToPointsConvert from pixel space to point space.
PointsToPixelsConvert from point space to pixel space.
QueueGameViewInputEventSend an input event into the game.
SetIconSizeSet icons rendered as part of GUIContent to be rendered at a specific size.
ShowObjectPickerShow the object picker from code.

Inherited members

Static Variables

hasModalWindowГлобальное свойство. Если true, то модальное окно отображается, в противном случае false.
hotControlcontrolID текущего элемента управления.
keyboardControlcontrolID элемента управления с фокусом на клавиатуру.
systemCopyBufferПолучает доступ к "визитной карточке" системы (system-wide pasteboard).

Static Functions

GetControlIDПолучает уникальный ID для элемента управления.
GetStateObjectПолучает состояние объекта из controlID.
GUIToScreenPointКонвертирует точку из GUI позиции в пространство на экране.
QueryStateObjectПолучает существующее состояние объекта из controlID.
RotateAroundPivotОбработчик функции для вращения GUI вокруг точки.
ScaleAroundPivotОбработчик функции для масштабирования GUI вокруг точки.
ScreenToGUIPointКонвертирует точку из точки в пространстве к позиции GUI.