Skip to main content

Shape

Namespace:FairyGUI
Source:Assets/Scripts/Core/Shape.cs (line 9)

public class Shape : DisplayObject

Inheritance:EventDispatcher → DisplayObject → Shape

Inherited members​

DisplayObject

onPaint, _contentRect, _flags, _paintingInfo, _paintingMode, _vertexMatrix, gOwner, id, name, AddToBatch, CreateGameObject, DestroyGameObject, Dispose, EnsureSizeCorrect, EnterPaintingMode, GetBounds, GetScreenShot, GlobalToLocal, InvalidateBatchingState, LeavePaintingMode, LocalToGlobal, LocalToWorld, OnSizeChanged, RemoveFromParent, SetGameObject, SetLayer, SetPosition, SetRenderingOrder, SetScale, SetSize, SetXY, TransformPoint, TransformRect, TransformRectPoint, Update, WorldToLocal, alpha, blendMode, cacheAsBitmap, cachedTransform, cursor, filter, focalLength, focusable, focused, gameObject, graphics, grayed, height, home, isDisposed, layer, location, material, onAddedToStage, onClickLink, onClick, onFocusIn, onFocusOut, onKeyDown, onMouseWheel, onRemovedFromStage, onRightClick, onRollOut, onRollOver, onTouchBegin, onTouchEnd, onTouchMove, paintingGraphics, paintingMode, parent, perspective, pivot, pixelPerfect, position, renderingOrder, rotationX, rotationY, rotation, scaleX, scaleY, scale, shader, size, skew, stage, tabStop, topmost, touchDisabled, touchable, visible, width, worldSpaceContainer, xy, x, y, z

EventDispatcher

AddCapture, AddEventListener, BroadcastEvent, BubbleEvent, DispatchEvent, RemoveCapture, RemoveEventListener, RemoveEventListeners, hasEventListeners, isDispatching

Constructors​

Shape()​

public Shape();

Source:Core/Shape.cs (line 14)

Methods​

Clear()​

public void Clear();

Source:Core/Shape.cs (line 221)

DrawEllipse(Color)​

public void DrawEllipse(Color fillColor);
ParameterTypeDescription
fillColorColor

Source:Core/Shape.cs (line 100)

DrawEllipse(float, Color, Color, Color, float, float)​

public void DrawEllipse(float lineSize, Color centerColor, Color lineColor, Color fillColor, float startDegree, float endDegree);
ParameterTypeDescription
lineSizefloat
centerColorColor
lineColorColor
fillColorColor
startDegreefloat
endDegreefloat

Source:Core/Shape.cs (line 122)

DrawPolygon(IList<Vector2>, Color)​

public void DrawPolygon(IList<Vector2> points, Color fillColor);
ParameterTypeDescription
pointsIList<Vector2>
fillColorColor

Source:Core/Shape.cs (line 144)

DrawPolygon(IList<Vector2>, Color, float, Color)​

public void DrawPolygon(IList<Vector2> points, Color fillColor, float lineSize, Color lineColor);
ParameterTypeDescription
pointsIList<Vector2>
fillColorColor
lineSizefloat
lineColorColor

Source:Core/Shape.cs (line 179)

DrawPolygon(IList<Vector2>, Color32[])​

public void DrawPolygon(IList<Vector2> points, Color32[] colors);
ParameterTypeDescription
pointsIList<Vector2>
colorsColor32[]

Source:Core/Shape.cs (line 161)

DrawRect(float, Color, Color)​

public void DrawRect(float lineSize, Color lineColor, Color fillColor);
ParameterTypeDescription
lineSizefloat
lineColorColor
fillColorColor

Source:Core/Shape.cs (line 44)

DrawRect(float, Color32[])​

public void DrawRect(float lineSize, Color32[] colors);
ParameterTypeDescription
lineSizefloat
colorsColor32[]

Source:Core/Shape.cs (line 61)

DrawRegularPolygon(int, float, Color?, Color, Color, float, float[])​

public void DrawRegularPolygon(int sides, float lineSize, Color? centerColor, Color lineColor, Color fillColor, float rotation, float[] distances);
ParameterTypeDescription
sidesint
lineSizefloat
centerColorColor?
lineColorColor
fillColorColor
rotationfloat
distancesfloat[]

Source:Core/Shape.cs (line 203)

DrawRoundRect(float, Color, Color, float, float, float, float)​

public void DrawRoundRect(float lineSize, Color lineColor, Color fillColor, float topLeftRadius, float topRightRadius, float bottomLeftRadius, float bottomRightRadius);
ParameterTypeDescription
lineSizefloat
lineColorColor
fillColorColor
topLeftRadiusfloat
topRightRadiusfloat
bottomLeftRadiusfloat
bottomRightRadiusfloat

Source:Core/Shape.cs (line 80)

HitTest()​

protected override DisplayObject HitTest();

Source:Core/Shape.cs (line 234)

Properties​

color​

public Color color { get; set; }

Source:Core/Shape.cs (line 25)

isEmpty​

public bool isEmpty { get; }

Source:Core/Shape.cs (line 229)