Pentagon

smile.pictures.Pentagon
object Pentagon

Regular pentagons with a vertex straight up.

import smile.colors.PresetColor.*
import smile.modeling.*

val pentagon = Pentagon(40, Pos.Origin, fillWith(Teal), None)

A teal pentagon

Attributes

Source
Shapes.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Pentagon.type

Members list

Value members

Concrete methods

def apply(width: Double, height: Double, fill: Option[FillStyle], line: Option[StrokeStyle]): Shape

The largest regular pentagon that fits in a box width wide and height high, centered at the origin.

The largest regular pentagon that fits in a box width wide and height high, centered at the origin.

Attributes

Throws
IllegalArgumentException

if a size is negative or not a number

Source
Shapes.scala
def apply(width: Double, height: Double, center: Pos, fill: Option[FillStyle], line: Option[StrokeStyle]): Shape

The largest regular pentagon that fits in a box width wide and height high, its box centered at center.

The largest regular pentagon that fits in a box width wide and height high, its box centered at center.

Attributes

Throws
IllegalArgumentException

if a size is negative or not a number

Source
Shapes.scala
def apply(circumradius: Double, center: Pos, fill: Option[FillStyle], line: Option[StrokeStyle]): Shape

A regular pentagon with its vertices circumradius from its center of symmetry, its box centered at center.

A regular pentagon with its vertices circumradius from its center of symmetry, its box centered at center.

Attributes

Throws
IllegalArgumentException

if the circumradius is negative or not a number

Source
Shapes.scala