Unified Typesetting API M1-20040817

de.inghuimische.uta
Interface Line

All Known Implementing Classes:
AbstractLine

public interface Line

A line of text is the connection between two breakpoints. Take a look at Breakpoint.getLine(Breakpoint).

Author:
Christian Ziesemer

Method Summary
 double getDemerits()
          Returns an abstract measurement for the total quality of this line.
 Item getFirstItem()
          Returns the first item of this line.
 Item getLastItem()
          Returns the last item of this line.
 double getOpticalDensity(boolean position)
          Returns the optical density of the requested glyph.
 double getPreferredWidth()
          Returns the preferred width of this line.
 double getWidth()
          Returns the actual width of this line.
 

Method Detail

getOpticalDensity

public double getOpticalDensity(boolean position)
Returns the optical density of the requested glyph.

Parameters:
position - Either the start or the end of the line.
Returns:
The optical density of the requested character.
See Also:
Item.DENSITY_START, Item.DENSITY_END, Item.getOpticalDensity(boolean, int)

getDemerits

public double getDemerits()
Returns an abstract measurement for the total quality of this line. Simple implementations may return 0. This value is used as the length of a edge when building a brakpoint graph.

Returns:
An abstract measurement for the total quality of this line.

getWidth

public double getWidth()
Returns the actual width of this line. A typesetter may use this value (and the preferred width) to justify a line, this is not done by the linebreak algorithm.

Returns:
The actual width of this line.

getPreferredWidth

public double getPreferredWidth()
Returns the preferred width of this line. A typesetter may use this value (and the actual width) to justify a line, this is not done by the linebreak algorithm.

Returns:
The preferred width of this line.

getFirstItem

public Item getFirstItem()
Returns the first item of this line.

Returns:
The first item of this line.

getLastItem

public Item getLastItem()
Returns the last item of this line.

Returns:
The last item of this line.

Unified Typesetting API M1-20040817


An inghuimische.de project.
Copyright (C) 2004 Christian Ziesemer; See the Mozilla Public License for more details.