struct

Cairo::Rectangle

Inherits Struct / Value / Object

A data structure for holding a rectangle.

Wrapper for LibCairo::RectangleT structure.

Constructors

new(x : Float64, y : Float64, width : Float64, height : Float64)

Creates new rectangle using specified coordinates of top left corner (x, y), width and height.

Source
new(rect : LibCairo::RectangleT)

Creates new rectangle from LibCairo::RectangleT.

Source
new

Creates uninitialized rectangle.

Source

Instance methods

height

Height of the rectangle.

Source
height=(height : Float64)

Setter for height.

Source
to_cairo_rectange

Returns underlying LibCairo::RectangleT structure.

Source
to_unsafe

Pointer of underlying LibCairo::RectangleT structure.

Source
width

Width of the rectangle.

Source
width=(width : Float64)

Setter for width.

Source
x

X coordinate of the left side of the rectangle.

Source
x=(x : Float64)

Setter for X coordinate.

Source
y

Y coordinate of the the top side of the rectangle.

Source
y=(y : Float64)

Setter for Y coordinate.

Source