Class: Axlsx::TableStyleElement
- Inherits:
-
Object
- Object
- Axlsx::TableStyleElement
- Defined in:
- lib/axlsx/stylesheet/table_style_element.rb
Overview
tables and table styles are not supported in this version. This class exists in preparation for that support.
an element of style that belongs to a table style.
Instance Attribute Summary (collapse)
-
- (Integer) dxfId
The dxfId this style element points to.
-
- (Integer) size
Number of rows or columns used in striping when the type is firstRowStripe, secondRowStripe, firstColumnStripe, or secondColumnStripe.
-
- (Symbol) type
The type of style element.
Instance Method Summary (collapse)
-
- (TableStyleElement) initialize(options = {})
constructor
creates a new TableStyleElement object.
-
- (String) to_xml(xml)
Serializes the table style element.
Constructor Details
- (TableStyleElement) initialize(options = {})
creates a new TableStyleElement object
49 50 51 52 53 |
# File 'lib/axlsx/stylesheet/table_style_element.rb', line 49 def initialize(={}) .each do |o| self.send("#{o[0]}=", o[1]) if self.respond_to? o[0] end end |
Instance Attribute Details
- (Integer) dxfId
The dxfId this style element points to
43 44 45 |
# File 'lib/axlsx/stylesheet/table_style_element.rb', line 43 def dxfId @dxfId end |
- (Integer) size
Number of rows or columns used in striping when the type is firstRowStripe, secondRowStripe, firstColumnStripe, or secondColumnStripe.
39 40 41 |
# File 'lib/axlsx/stylesheet/table_style_element.rb', line 39 def size @size end |
- (Symbol) type
The type of style element. The following type are allowed
:wholeTable :headerRow :totalRow :firstColumn :lastColumn :firstRowStripe :secondRowStripe :firstColumnStripe :secondColumnStripe :firstHeaderCell :lastHeaderCell :firstTotalCell :lastTotalCell :firstSubtotalColumn :secondSubtotalColumn :thirdSubtotalColumn :firstSubtotalRow :secondSubtotalRow :thirdSubtotalRow :blankRow :firstColumnSubheading :secondColumnSubheading :thirdColumnSubheading :firstRowSubheading :secondRowSubheading :thirdRowSubheading :pageFieldLabels :pageFieldValues
35 36 37 |
# File 'lib/axlsx/stylesheet/table_style_element.rb', line 35 def type @type end |
Instance Method Details
- (String) to_xml(xml)
Serializes the table style element
62 63 64 |
# File 'lib/axlsx/stylesheet/table_style_element.rb', line 62 def to_xml(xml) xml.tableStyleElement self.instance_values end |