lib/axlsx/stylesheet/table_style.rb in axlsx-1.0.8 vs lib/axlsx/stylesheet/table_style.rb in axlsx-1.0.9

- old
+ new

@@ -3,19 +3,19 @@ # @note Table are not supported in this version and only the defaults required for a valid workbook are created. class TableStyle < SimpleTypedList # The name of this table style # @return [string] - attr_accessor :name + attr_reader :name # indicates if this style should be applied to pivot tables # @return [Boolean] - attr_accessor :pivot + attr_reader :pivot # indicates if this style should be applied to tables # @return [Boolean] - attr_accessor :table + attr_reader :table # creates a new TableStyle object # @raise [ArgumentError] if name option is not provided. # @param [String] name # @option options [Boolean] pivot @@ -26,11 +26,14 @@ self.send("#{o[0]}=", o[1]) if self.respond_to? o[0] end super TableStyleElement end + # @see name def name=(v) Axlsx::validate_string v; @name=v end + # @see pivot def pivot=(v) Axlsx::validate_boolean v; @pivot=v end + # @see table def table=(v) Axlsx::validate_boolean v; @table=v end # Serializes the table style # @param [Nokogiri::XML::Builder] xml The document builder instance this objects xml will be added to. # @return [String]