Skip to content

class Rectangle < Commands::Base internal

Command to render a rectangle

#padding=(value) public

Sets padding for the rectangle

Arguments

Returns

Returns self

#outline=(value) public

Set outline for rect

Arguments

#outline_color=(value) public

Set outline color

Arguments

#color=(value) public

Set fill color

Arguments

Returns

Returns self

#round=(amount) public

sets rounding

Arguments

  • amount - a float value between 0 and 1

Returns

Returns self

#padding? public

returns true if the rectangle has any padding

#background_boundary public

get the rect dimensions after padding and outline applied

Returns

Returns Array(Float)

#outline? public

Does this rect have any outlines?

#outline_uniform? public

Is the rect outline uniform?