C# Class Flood.GUI.Util

Misc utility functions.
Afficher le fichier Open project: FloodProject/flood

Méthodes publiques

Méthode Description
Add ( this color, System.Color other ) : System.Color
Add ( this r, Rectangle other ) : Rectangle
Ceil ( float x ) : int
Clamp ( float x, float min, float max ) : float
Clamp ( int x, int min, int max ) : int
ClampRectToRect ( Rectangle inside, Rectangle outside, bool clampSize = false ) : Rectangle
FloatRect ( float x, float y, float w, float h ) : Rectangle
HSVToColor ( float h, float s, float v ) : System.Color
Multiply ( this color, float amount ) : System.Color
Round ( float x ) : int
SplitAndKeep ( String text, String separators ) : String[]

Splits a string but keeps the separators intact (at the end of split parts).

Subtract ( this color, System.Color other ) : System.Color
ToHSV ( this color ) : HSV

Method Details

Add() public static méthode

public static Add ( this color, System.Color other ) : System.Color
color this
other System.Color
Résultat System.Color

Add() public static méthode

public static Add ( this r, Rectangle other ) : Rectangle
r this
other Rectangle
Résultat Rectangle

Ceil() public static méthode

public static Ceil ( float x ) : int
x float
Résultat int

Clamp() public static méthode

public static Clamp ( float x, float min, float max ) : float
x float
min float
max float
Résultat float

Clamp() public static méthode

public static Clamp ( int x, int min, int max ) : int
x int
min int
max int
Résultat int

ClampRectToRect() public static méthode

public static ClampRectToRect ( Rectangle inside, Rectangle outside, bool clampSize = false ) : Rectangle
inside Rectangle
outside Rectangle
clampSize bool
Résultat Rectangle

FloatRect() public static méthode

public static FloatRect ( float x, float y, float w, float h ) : Rectangle
x float
y float
w float
h float
Résultat Rectangle

HSVToColor() public static méthode

public static HSVToColor ( float h, float s, float v ) : System.Color
h float
s float
v float
Résultat System.Color

Multiply() public static méthode

public static Multiply ( this color, float amount ) : System.Color
color this
amount float
Résultat System.Color

Round() public static méthode

public static Round ( float x ) : int
x float
Résultat int

SplitAndKeep() public static méthode

Splits a string but keeps the separators intact (at the end of split parts).
public static SplitAndKeep ( String text, String separators ) : String[]
text String String to split.
separators String Separator characters.
Résultat String[]

Subtract() public static méthode

public static Subtract ( this color, System.Color other ) : System.Color
color this
other System.Color
Résultat System.Color

ToHSV() public static méthode

public static ToHSV ( this color ) : HSV
color this
Résultat HSV