class HexaPDF::Layout::TextLayouter::Box

Used for layouting. Describes an item with a fixed width, like an InlineBox or TextFragment.

Attributes

item[R]

The wrapped item.

Public Class Methods

new(item) click to toggle source

Creates a new Box for the item.

# File lib/hexapdf/layout/text_layouter.rb, line 83
def initialize(item)
  @item = item
end

Public Instance Methods

height() click to toggle source

The height of the item.

# File lib/hexapdf/layout/text_layouter.rb, line 93
def height
  @item.height
end
type() click to toggle source

Returns :box.

# File lib/hexapdf/layout/text_layouter.rb, line 98
def type
  :box
end
width() click to toggle source

The width of the item.

# File lib/hexapdf/layout/text_layouter.rb, line 88
def width
  @item.width
end