# Companion

object Companion

## Functions

isOrthogonal
Link copied to clipboard
fun isOrthogonal(at: AffineTransform): Boolean

Return true if the given transform maps a rectangle to a rectangle. If this method returns true, then the transformRectangle and transformRectangularShape methods will operate correctly.

transformBounds
Link copied to clipboard
fun transformBounds(rect: Rectangle2D, at: AffineTransform): Rectangle2D

Given a bounding-box rectangle, return a new rectangle by transforming the argument rectangle and taking the bounding box of the result. This method optimizes the calculation if the transform is orthogonal. Note that the argument rectangle is not modified, and the transform does not need to be orthogonal.