Search this API

y.layout
Class LabelLayoutImpl

java.lang.Object
  extended by y.layout.LabelLayoutImpl
All Implemented Interfaces:
LabelLayout
Direct Known Subclasses:
EdgeLabelLayoutImpl, NodeLabelLayoutImpl

public class LabelLayoutImpl
extends java.lang.Object
implements LabelLayout

LabelLayoutImpl is the default implementation of the LabelLayout interface.

 

Constructor Summary
LabelLayoutImpl()
          Creates a new LabelLayoutImpl instance.
 
Method Summary
 YRectangle getBox()
          Returns the bounding box of the label.
 java.lang.Object getModelParameter()
          Returns the label model parameter that describes the position of this label.
 OrientedRectangle getOrientedBox()
          Returns the box of the label.
 void setBox(YRectangle b)
          Specifies the bounding box of the label.
 void setModelParameter(java.lang.Object parameter)
          Specifies the label model parameter that describes the position of this label.
 void setOrientedBox(OrientedRectangle orientedBox)
          Specifies the box of the label.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LabelLayoutImpl

public LabelLayoutImpl()
Creates a new LabelLayoutImpl instance.

Method Detail

getOrientedBox

public OrientedRectangle getOrientedBox()
Description copied from interface: LabelLayout
Returns the box of the label. This box matches the area that is covered by the label. The up vector of the rectangle encodes the orientation of the label.

Specified by:
getOrientedBox in interface LabelLayout
Returns:
the oriented box of the label

setOrientedBox

public void setOrientedBox(OrientedRectangle orientedBox)
Specifies the box of the label. This box matches the area that is covered by the label. The up vector of the rectangle encodes the orientation of the label.

Parameters:
orientedBox - the oriented box of the label

getBox

public YRectangle getBox()
Description copied from interface: LabelLayout
Returns the bounding box of the label. The bounding box is the smallest, paraxial rectangle that contains the whole label.

Specified by:
getBox in interface LabelLayout
Returns:
the bounding box of the label

setBox

public void setBox(YRectangle b)
Specifies the bounding box of the label. The bounding box is the smallest, paraxial rectangle that contains the whole label.

Parameters:
b - the bounding box of the label

getModelParameter

public java.lang.Object getModelParameter()
Description copied from interface: LabelLayout
Returns the label model parameter that describes the position of this label. The model parameter must fit the according label model.

Specified by:
getModelParameter in interface LabelLayout
Returns:
the label model parameter
See Also:
LabelLayout.setModelParameter(Object)

setModelParameter

public void setModelParameter(java.lang.Object parameter)
Description copied from interface: LabelLayout
Specifies the label model parameter that describes the position of this label. The model parameter must fit the according label model.

Specified by:
setModelParameter in interface LabelLayout
Parameters:
parameter - the label model parameter

© Copyright 2000-2022,
yWorks GmbH.
All rights reserved.