O1Library Docs
Fall 2026
Docs API

# Absolute

o1.world.objects.Anchor.Absolute
final case class Absolute(deltaFromTopLeft: Pos) extends Anchor

An anchor at a custom Pos.

## Parameters

deltaFromTopLeft

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

## Attributes

Graph
Supertypes
  trait Serializable
  trait Product
  trait Equals
  trait Anchor
  class Object
  trait Matchable
  class Any
  Show all

## Members list

### Value members

#### Constructors

def this(fromLeft: Double, fromTop: Double)

Given x and y offsets, produces an anchor that is that far from the top left-hand corner.

Given x and y offsets, produces an anchor that is that far from the top left-hand corner.

## Parameters

fromLeft

  the anchor’s x coordinate within the anchored object, relative to the object’s left edge

fromTop

  the anchor’s y coordinate within the anchored object, relative to the object’s top edge

## Attributes

#### Concrete methods

def internalXWithin(anchored: HasAnchor): Double

Returns the x coordinate of the anchoring point within the given `Pic` or other anchorable object, relative to the object’s left edge.

Returns the x coordinate of the anchoring point within the given `Pic` or other anchorable object, relative to the object’s left edge.

## Attributes

def internalYWithin(anchored: HasAnchor): Double

Returns the y coordinate of the anchoring point within the given `Pic` or other anchorable object, relative to the object’s top edge.

Returns the y coordinate of the anchoring point within the given `Pic` or other anchorable object, relative to the object’s top edge.

## Attributes

override def toString: String

Returns a `String` description of the absolute anchor.

Returns a `String` description of the absolute anchor.

## Attributes

Definition Classes
  Any

#### Inherited methods

def internalPosWithin(anchored: HasAnchor): Pos

Returns the Pos of the anchoring point within the given `Pic` or other anchorable object, relative to the object’s top left-hand corner.

Returns the Pos of the anchoring point within the given `Pic` or other anchorable object, relative to the object’s top left-hand corner.

## Attributes

Inherited from:
  Anchor

def productElementNames: Iterator[String]

An iterator over the names of all the elements of this product.

An iterator over the names of all the elements of this product.

## Attributes

Inherited from:
  Product

def productIterator: Iterator[Any]

An iterator over all the elements of this product.

An iterator over all the elements of this product.

## Attributes

Returns

  in the default implementation, an `Iterator[Any]`

Inherited from:
  Product

def toAbsoluteWithin(anchored: HasAnchor): Absolute

Returns an absolute anchor the Pos of the anchoring point within the given `Pic` or other anchorable object, relative to the object’s top left-hand corner.

Returns an absolute anchor the Pos of the anchoring point within the given `Pic` or other anchorable object, relative to the object’s top left-hand corner.

## Attributes

Inherited from:
  Anchor