prawn-utils/lib/fourmi/prawn/utils/callbacks/border_callback.rb

15 lines
357 B
Ruby
Raw Permalink Normal View History

2022-10-14 09:05:37 +00:00
module Fourmi::Prawn::Utils
module Callbacks
class BorderCallback
def initialize(document)
@document = document
end
def render_in_front(fragment)
@document.stroke_polygon(fragment.top_left, fragment.top_right,
fragment.bottom_right, fragment.bottom_left)
end
end
end
end