Class: Ambling::Line::Settings::Values::YLeft
- Inherits:
-
Object
- Object
- Ambling::Line::Settings::Values::YLeft
- Includes:
- Base
- Defined in:
- lib/ambling/line.rb
Overview
y left axis
Constant Summary collapse
- VALUES =
[:enabled,:reverse,:rotate,:min,:max,:strict_min_max,:frequency,:skip_first,:skip_last,:color,:text_size,:unit,:unit_position,:integers_only,:inside,:duration]
Instance Attribute Summary collapse
-
#color ⇒ Object
- text_color
-
(hex color code).
-
#duration ⇒ Object
-
(ss/mm/hh/DD) In case you want your axis to display formatted durations instead of numbers, you have to set the unit of the duration in your data file.
-
#enabled ⇒ Object
- true
-
(true / false).
-
#frequency ⇒ Object
- 1
-
(Number) how often values should be placed, 1 - near every gridline, 2 - near every second gridline…
-
#inside ⇒ Object
- false
-
(true / false) if set to true, axis values will be displayed inside plot area.
-
#integers_only ⇒ Object
- false
-
(true / false) if set to true, values with decimals will be omitted.
-
#max ⇒ Object
-
(Number) maximum value of this axis.
-
#min ⇒ Object
-
(Number) minimum value of this axis.
-
#reverse ⇒ Object
- false
-
(true / false) whether to reverse this axis values or not.
-
#rotate ⇒ Object
- 0
-
(0 - 90) angle of rotation.
-
#skip_first ⇒ Object
- true
-
(true / false) to skip or not first value.
-
#skip_last ⇒ Object
- false
-
(true / false) to skip or not last value.
-
#strict_min_max ⇒ Object
- false
-
(true / false) by default, if your values are bigger then defined max (or smaller then defined min), max and min is changed so that all the chart would fit to chart area.
-
#text_size ⇒ Object
- text_size
-
(Number).
-
#unit ⇒ Object
-
(text) unit which will be added to values on y axis.
-
#unit_position ⇒ Object
- right
-
(left / right).
Method Summary
Methods included from Base
#build_xml, #initialize, #populate, #to_xml
Instance Attribute Details
#color ⇒ Object
- text_color
-
(hex color code)
639 640 641 |
# File 'lib/ambling/line.rb', line 639 def color @color end |
#duration ⇒ Object
-
(ss/mm/hh/DD) In case you want your axis to display formatted durations instead of numbers, you have to set the unit of the duration in your data file. For example, if your values in data file represents seconds, set “ss” here.
669 670 671 |
# File 'lib/ambling/line.rb', line 669 def duration @duration end |
#enabled ⇒ Object
- true
-
(true / false)
594 595 596 |
# File 'lib/ambling/line.rb', line 594 def enabled @enabled end |
#frequency ⇒ Object
- 1
-
(Number) how often values should be placed, 1 - near every gridline, 2 - near every second gridline…
624 625 626 |
# File 'lib/ambling/line.rb', line 624 def frequency @frequency end |
#inside ⇒ Object
- false
-
(true / false) if set to true, axis values will be displayed inside plot area. This setting will not work for values rotated by 1-89 degrees (0 and 90 only)
664 665 666 |
# File 'lib/ambling/line.rb', line 664 def inside @inside end |
#integers_only ⇒ Object
- false
-
(true / false) if set to true, values with decimals will be omitted
659 660 661 |
# File 'lib/ambling/line.rb', line 659 def integers_only @integers_only end |
#max ⇒ Object
-
(Number) maximum value of this axis. If empty, this value will be calculated automatically
614 615 616 |
# File 'lib/ambling/line.rb', line 614 def max @max end |
#min ⇒ Object
-
(Number) minimum value of this axis. If empty, this value will be calculated automatically.
609 610 611 |
# File 'lib/ambling/line.rb', line 609 def min @min end |
#reverse ⇒ Object
- false
-
(true / false) whether to reverse this axis values or not. If set to true, values will start from biggest number and will end with a smallest number
599 600 601 |
# File 'lib/ambling/line.rb', line 599 def reverse @reverse end |
#rotate ⇒ Object
- 0
-
(0 - 90) angle of rotation. If you want to rotate by degree from 1 to 89, you must have font.swf file in fonts folder
604 605 606 |
# File 'lib/ambling/line.rb', line 604 def rotate @rotate end |
#skip_first ⇒ Object
- true
-
(true / false) to skip or not first value
629 630 631 |
# File 'lib/ambling/line.rb', line 629 def skip_first @skip_first end |
#skip_last ⇒ Object
- false
-
(true / false) to skip or not last value
634 635 636 |
# File 'lib/ambling/line.rb', line 634 def skip_last @skip_last end |
#strict_min_max ⇒ Object
- false
-
(true / false) by default, if your values are bigger then defined max (or smaller then defined min), max and min is changed so that all the chart would fit to chart area. If you don’t want this, set this option to true.
619 620 621 |
# File 'lib/ambling/line.rb', line 619 def strict_min_max @strict_min_max end |
#text_size ⇒ Object
- text_size
-
(Number)
644 645 646 |
# File 'lib/ambling/line.rb', line 644 def text_size @text_size end |
#unit ⇒ Object
-
(text) unit which will be added to values on y axis
649 650 651 |
# File 'lib/ambling/line.rb', line 649 def unit @unit end |
#unit_position ⇒ Object
- right
-
(left / right)
654 655 656 |
# File 'lib/ambling/line.rb', line 654 def unit_position @unit_position end |