Anchor

object Anchor

This companion object of class Anchor contains a number of standard anchors (TopLeft, Center, etc.) and a class for creating anchors in a custom location.

The object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

See also:
Companion:
class
class Object
trait Matchable
class Any
Anchor.type

Type members

Classlikes

final case class Absolute(deltaFromTopLeft: Pos) extends Anchor

An anchor at a custom Pos.

An anchor at a custom Pos.

Value parameters:
deltaFromTopLeft

the Pos of the anchor within the anchored object, relative to the object’s top left-hand corner

case object BottomCenter extends Anchor

An anchor at the middle of the bottom edge. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the middle of the bottom edge. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

case object BottomLeft extends Anchor

An anchor at the bottom left-hand corner. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the bottom left-hand corner. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

case object BottomRight extends Anchor

An anchor at the bottom right-hand corner. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the bottom right-hand corner. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

case object Center extends Anchor

An anchor at the middle. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the middle. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

case object CenterLeft extends Anchor

An anchor at the middle of the left edge. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the middle of the left edge. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

case object CenterRight extends Anchor

An anchor at the middle of the right edge. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the middle of the right edge. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

case object TopCenter extends Anchor

An anchor at the middle of the top edge. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the middle of the top edge. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

case object TopLeft extends Anchor

An anchor at the top left-hand corner. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the top left-hand corner. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

case object TopRight extends Anchor

An anchor at the top right-hand corner. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

An anchor at the top right-hand corner. This object has an alias in the top-level package o1, so it’s accessible to students simply via import o1.*.

Givens