Class: Laser::Cutter::Renderer::LineRenderer
- Defined in:
- lib/laser-cutter/renderer/line_renderer.rb
Constant Summary
Constants inherited from Base
Instance Attribute Summary
Attributes inherited from Base
#config, #page_manager, #subject
Instance Method Summary collapse
Methods inherited from Base
Constructor Details
This class inherits a constructor from Laser::Cutter::Renderer::Base
Instance Method Details
#enclosure ⇒ Object
11 12 13 |
# File 'lib/laser-cutter/renderer/line_renderer.rb', line 11 def enclosure self.line end |
#render(pdf = nil) ⇒ Object
6 7 8 9 |
# File 'lib/laser-cutter/renderer/line_renderer.rb', line 6 def render pdf = nil pdf.stroke { pdf.line [line.p1.x, line.p1.y].map{ |p| p.send(units) }, [line.p2.x, line.p2.y].map{ |p| p.send(units) }} end |