TriangleF

References
public readonly struct TriangleF
Represents a triangular slab with a thickness.

Constructors

TriangleF

#
public TriangleF(PointF base, float size, float thickness, float corners)
Create a new triangle.
base (PointF)Base point of triangle.
size (float)Size or edge length of triangle.
thickness (float)Slab thickness.
corners (float)Radii of triangle corners.

Properties

ApexPath

#
public GraphicsPath ApexPath { get; }
Gets the graphics path for the apex face.

Base

#
public PointF Base { get; }
Gets the base point for the triangle (the middle of the bottom edge).

Bounds

#
public RectangleF Bounds { get; }
Gets the bounds for the entire triangle.

Corners

#
public float Corners { get; }
Gets the corner radii of the triangle.

EdgePath

#
public GraphicsPath EdgePath { get; }
Gets the graphics path for the triangle edge.

FormPath

#
public GraphicsPath FormPath { get; }
Gets the graphics path for the entire shape.

Size

#
public float Size { get; }
Gets the size of the triangle (also the length of the edges).

Thickness

#
public float Thickness { get; }
Gets the thickness of the disc.

Methods

Contains

#
public bool Contains(PointF point)
Test whether this triangle contains a given point. For this test, the corner radii are ignored.
point (PointF)

Move

#
public TriangleF Move(float dx, float dy)
dx (float)
dy (float)

MoveTo

#
public TriangleF MoveTo(PointF newBase)
newBase (PointF)

VertexAt

#
public PointF VertexAt(TriangleVertex vertex)
Gets the vertex location.
vertex (TriangleVertex)