C# Class Nez.IMGUI

Afficher le fichier Open project: prime31/Nez

Méthodes publiques

Méthode Description
beginWindow ( float x, float y, float width, float height, bool useRawMousePosition = true ) : void

begins an IMGUI window specifying where and how large it should be. If you are not using IMGUI in world space (for example, inside a Scene with a scaled resolution policy) passing false for useRawMousePosition will use the Input.scaledMousePosition.

button ( string text ) : bool
endWindow ( ) : void
header ( string text ) : void

creates a full width header with text

progressBar ( float value ) : float

value should be between 0 and 1

slider ( float value, string name = "" ) : float

value should be between 0 and 1

space ( float verticalSpace ) : void

adds some vertical space

toggle ( string text, bool isChecked ) : bool

creates a checkbox/toggle

Private Methods

Méthode Description
IMGUI ( ) : Microsoft.Xna.Framework.Graphics
drawString ( string text, Color color, TextAlign align = TextAlign.Center, float elementHeight = ELEMENT_HEIGHT ) : void
endElement ( float elementHeight = ELEMENT_HEIGHT ) : void
isMouseBetween ( float left, float right ) : bool
isMouseOverElement ( ) : bool

Method Details

beginWindow() public static méthode

begins an IMGUI window specifying where and how large it should be. If you are not using IMGUI in world space (for example, inside a Scene with a scaled resolution policy) passing false for useRawMousePosition will use the Input.scaledMousePosition.
public static beginWindow ( float x, float y, float width, float height, bool useRawMousePosition = true ) : void
x float The x coordinate.
y float The y coordinate.
width float Width.
height float Height.
useRawMousePosition bool If set to true use raw mouse position.
Résultat void

button() public static méthode

public static button ( string text ) : bool
text string
Résultat bool

endWindow() public static méthode

public static endWindow ( ) : void
Résultat void

header() public static méthode

creates a full width header with text
public static header ( string text ) : void
text string Text.
Résultat void

progressBar() public static méthode

value should be between 0 and 1
public static progressBar ( float value ) : float
value float Value.
Résultat float

slider() public static méthode

value should be between 0 and 1
public static slider ( float value, string name = "" ) : float
value float Value.
name string
Résultat float

space() public static méthode

adds some vertical space
public static space ( float verticalSpace ) : void
verticalSpace float Vertical space.
Résultat void

toggle() public static méthode

creates a checkbox/toggle
public static toggle ( string text, bool isChecked ) : bool
text string Text.
isChecked bool If set to true is checked.
Résultat bool