topRightRect function
Returns a new Rectangle at the top-right of area with width and height.
Upstream: TopRightRect in third_party/ultraviolet/layout.go.
Implementation
Rectangle topRightRect(Rectangle area, int width, int height) {
return rect(area.maxX - width, area.minY, width, height).intersect(area);
}