Sha256: 336fce0a298c9cf275d6176bac819a8acba15d3c99d74db9d6c23930f86d7d3c
Contents?: true
Size: 451 Bytes
Versions: 8
Compression:
Stored size: 451 Bytes
Contents
# frozen_string_literal: true module Gruff # @private class Renderer::Rectangle def initialize(color: nil) @color = color end def render(upper_left_x, upper_left_y, lower_right_x, lower_right_y) draw = Renderer.instance.draw draw.push draw.stroke('transparent') draw.fill(@color) if @color draw.rectangle(upper_left_x, upper_left_y, lower_right_x, lower_right_y) draw.pop end end end
Version data entries
8 entries across 8 versions & 1 rubygems