Class: Axlsx::SerAxis
Overview
A SerAxis object defines a series axis
Instance Attribute Summary collapse
-
#tick_lbl_skip ⇒ Integer
(also: #tickLblSkip)
The number of tick lables to skip between labels.
-
#tick_mark_skip ⇒ Boolean
(also: #tickMarkSkip)
The number of tickmarks to be skipped before the next one is rendered.
Attributes inherited from Axis
#ax_pos, #color, #cross_axis, #crosses, #delete, #format_code, #gridlines, #id, #label_rotation, #scaling, #tick_lbl_pos, #title
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ SerAxis
constructor
Creates a new SerAxis object.
-
#to_xml_string(str = +'')) ⇒ String
Serializes the object.
Methods included from OptionsParser
Constructor Details
#initialize(options = {}) ⇒ SerAxis
Creates a new SerAxis object
19 20 21 22 |
# File 'lib/axlsx/drawing/ser_axis.rb', line 19 def initialize( = {}) @tick_lbl_skip, @tick_mark_skip = 1, 1 super() end |
Instance Attribute Details
#tick_lbl_skip ⇒ Integer Also known as: tickLblSkip
The number of tick lables to skip between labels
8 9 10 |
# File 'lib/axlsx/drawing/ser_axis.rb', line 8 def tick_lbl_skip @tick_lbl_skip end |
#tick_mark_skip ⇒ Boolean Also known as: tickMarkSkip
The number of tickmarks to be skipped before the next one is rendered.
13 14 15 |
# File 'lib/axlsx/drawing/ser_axis.rb', line 13 def tick_mark_skip @tick_mark_skip end |
Instance Method Details
#to_xml_string(str = +'')) ⇒ String
Serializes the object
41 42 43 44 45 46 47 |
# File 'lib/axlsx/drawing/ser_axis.rb', line 41 def to_xml_string(str = +'') str << '<c:serAx>' super(str) str << '<c:tickLblSkip val="' << @tick_lbl_skip.to_s << '"/>' unless @tick_lbl_skip.nil? str << '<c:tickMarkSkip val="' << @tick_mark_skip.to_s << '"/>' unless @tick_mark_skip.nil? str << '</c:serAx>' end |