Class: Zebra::Zpl::Box
- Inherits:
-
Object
- Object
- Zebra::Zpl::Box
- Includes:
- Printable
- Defined in:
- lib/zebra/zpl/box.rb
Defined Under Namespace
Classes: InvalidLineThickness
Instance Attribute Summary collapse
-
#box_height ⇒ Object
Returns the value of attribute box_height.
-
#box_width ⇒ Object
Returns the value of attribute box_width.
-
#line_thickness ⇒ Object
Returns the value of attribute line_thickness.
-
#width ⇒ Object
Returns the value of attribute width.
Attributes included from Printable
#data, #margin, #position, #x, #y
Instance Method Summary collapse
Methods included from Printable
#initialize, #justification, #justification=, #rotation, #rotation=
Instance Attribute Details
#box_height ⇒ Object
Returns the value of attribute box_height.
10 11 12 |
# File 'lib/zebra/zpl/box.rb', line 10 def box_height @box_height end |
#box_width ⇒ Object
Returns the value of attribute box_width.
10 11 12 |
# File 'lib/zebra/zpl/box.rb', line 10 def box_width @box_width end |
#line_thickness ⇒ Object
Returns the value of attribute line_thickness.
10 11 12 |
# File 'lib/zebra/zpl/box.rb', line 10 def line_thickness @line_thickness end |
#width ⇒ Object
Returns the value of attribute width.
10 11 12 |
# File 'lib/zebra/zpl/box.rb', line 10 def width @width end |
Instance Method Details
#to_zpl ⇒ Object
30 31 32 33 34 |
# File 'lib/zebra/zpl/box.rb', line 30 def to_zpl check_attributes # "^FO#{x},#{y}^GB#{box_width},#{box_height},#{line_thickness}^FS" "^FO#{x},#{y}^GB#{box_width},#{box_height},#{line_thickness}^FS" end |