|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface DeltaFormattedTransforming
To extend the formatting further, one might think of a class that formats
not the coordinates, but differences in the coordinates. If you start
with two primary point p1 and p2 and want to format the distance in the
secondary system, first convert you primary point to the secondary
system, ala s1 = #toSecondary(p1) and
s2 = #toSecondary(p2). Now, format the x-distance with
#deltaFormatSecondaryX}Math.abs(s1.getX()-s2.getX()).
This interface extends only the Morphing interface, as in principle
distances can be formatted even if the class does not know how to format
coordinates. In reality, though, implementing classes will also implement
the FormattingMorphing instance.
| Method Summary | |
|---|---|
String |
deltaFormatUserSpaceX(Rectangle2D dxsec)
Formats the x-coordinate difference of a secondary x-distance. |
String |
deltaFormatUserSpaceY(Rectangle2D dysec)
Formats the y-coordinate difference of a secondary y-distance. |
| Methods inherited from interface jview.DeltaTransforming |
|---|
toNormalizedDistance, toUserDistance |
| Methods inherited from interface jview.CoordinateTransforming |
|---|
toNormalizedSpace, toUserSpace |
| Method Detail |
|---|
String deltaFormatUserSpaceX(Rectangle2D dxsec)
Point2D#getX difference from
two #toSecondary calls.
String deltaFormatUserSpaceY(Rectangle2D dysec)
Point2D#getY difference from
two #toPrimary calls.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||