Class: PDF::SimpleTable::Column

Inherits:
Object
  • Object
show all
Defined in:
lib/gems/pdf-writer-1.1.8/lib/pdf/simpletable.rb

Overview

Defines formatting options for a column.

Defined Under Namespace

Classes: Heading

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name) {|_self| ... } ⇒ Column

Returns a new instance of Column.

Yields:

  • (_self)

Yield Parameters:



22
23
24
25
26
# File 'lib/gems/pdf-writer-1.1.8/lib/pdf/simpletable.rb', line 22

def initialize(name)
  @name = name

  yield self if block_given?
end

Instance Attribute Details

#headingObject

The heading of the column. This should be an instance of PDF::SimpleTable::Column::Heading. If it is not, it will be converted into one.



31
32
33
# File 'lib/gems/pdf-writer-1.1.8/lib/pdf/simpletable.rb', line 31

def heading
  @heading
end

#justificationObject

The justification of the column. May be :left, :right, :center, or :full.



48
49
50
# File 'lib/gems/pdf-writer-1.1.8/lib/pdf/simpletable.rb', line 48

def justification
  @justification
end

The data name that will be used to provide a hyperlink for values in this column.



45
46
47
# File 'lib/gems/pdf-writer-1.1.8/lib/pdf/simpletable.rb', line 45

def link_name
  @link_name
end

#nameObject (readonly)

The name of the column.



39
40
41
# File 'lib/gems/pdf-writer-1.1.8/lib/pdf/simpletable.rb', line 39

def name
  @name
end

#widthObject

The width of the column. If this value is set, the column will be exactly this number of units wide.



42
43
44
# File 'lib/gems/pdf-writer-1.1.8/lib/pdf/simpletable.rb', line 42

def width
  @width
end