Class: Ambling::Column::Settings::Legend
- Inherits:
-
Object
- Object
- Ambling::Column::Settings::Legend
- Includes:
- Base
- Defined in:
- lib/ambling/column.rb
Overview
LEGEND
Defined Under Namespace
Classes: Key
Constant Summary collapse
- VALUES =
[:enabled,:x,:y,:width,:max_columns,:color,:alpha,:border_color,:border_alpha,:text_color,:text_size,:spacing,:margins,:reverse_order,:align,:key]
Instance Attribute Summary collapse
-
#align ⇒ Object
- left
-
(left / center / right) alignment of legend entries.
-
#alpha ⇒ Object
- 0
-
(0 - 100) background alpha.
-
#border_alpha ⇒ Object
- 0
-
(0 - 100) border alpha.
-
#border_color ⇒ Object
- #000000
-
(hex color code) border color.
-
#color ⇒ Object
- #FFFFFF
-
(hex color code) background color.
-
#enabled ⇒ Object
- true
-
(true / false).
-
#key ⇒ Object
KEY (the color box near every legend entry).
-
#margins ⇒ Object
- 0
-
(Number) legend margins (space between legend border and legend entries, recommended to use only if legend border is visible or background color is different from chart area background color).
-
#max_columns ⇒ Object
-
(Number) the maximum number of columns in the legend.
-
#reverse_order ⇒ Object
- false
-
(true / false) whether to sort legend entries in a reverse order.
-
#spacing ⇒ Object
- 10
-
(Number) vertical and horizontal gap between legend entries.
-
#text_color ⇒ Object
- text_color
-
(hex color code).
-
#text_size ⇒ Object
- text_size
-
(Number).
-
#width ⇒ Object
-
(Number / Number%) if empty, will be equal to plot area width.
-
#x ⇒ Object
-
(Number / Number% / !Number) if empty, will be equal to left margin.
-
#y ⇒ Object
-
(Number / Number% / !Number) if empty, will be below plot area.
Method Summary
Methods included from Base
#build_xml, #initialize, #populate, #to_xml
Instance Attribute Details
#align ⇒ Object
- left
-
(left / center / right) alignment of legend entries
882 883 884 |
# File 'lib/ambling/column.rb', line 882 def align @align end |
#alpha ⇒ Object
- 0
-
(0 - 100) background alpha
842 843 844 |
# File 'lib/ambling/column.rb', line 842 def alpha @alpha end |
#border_alpha ⇒ Object
- 0
-
(0 - 100) border alpha
852 853 854 |
# File 'lib/ambling/column.rb', line 852 def border_alpha @border_alpha end |
#border_color ⇒ Object
- #000000
-
(hex color code) border color
847 848 849 |
# File 'lib/ambling/column.rb', line 847 def border_color @border_color end |
#color ⇒ Object
- #FFFFFF
-
(hex color code) background color. Separate color codes with comas for gradient
837 838 839 |
# File 'lib/ambling/column.rb', line 837 def color @color end |
#enabled ⇒ Object
- true
-
(true / false)
812 813 814 |
# File 'lib/ambling/column.rb', line 812 def enabled @enabled end |
#key ⇒ Object
KEY (the color box near every legend entry)
887 888 889 |
# File 'lib/ambling/column.rb', line 887 def key @key end |
#margins ⇒ Object
- 0
-
(Number) legend margins (space between legend border and legend entries, recommended to use only if legend border is visible or background color is different from chart area background color)
872 873 874 |
# File 'lib/ambling/column.rb', line 872 def margins @margins end |
#max_columns ⇒ Object
-
(Number) the maximum number of columns in the legend
832 833 834 |
# File 'lib/ambling/column.rb', line 832 def max_columns @max_columns end |
#reverse_order ⇒ Object
- false
-
(true / false) whether to sort legend entries in a reverse order
877 878 879 |
# File 'lib/ambling/column.rb', line 877 def reverse_order @reverse_order end |
#spacing ⇒ Object
- 10
-
(Number) vertical and horizontal gap between legend entries
867 868 869 |
# File 'lib/ambling/column.rb', line 867 def spacing @spacing end |
#text_color ⇒ Object
- text_color
-
(hex color code)
857 858 859 |
# File 'lib/ambling/column.rb', line 857 def text_color @text_color end |
#text_size ⇒ Object
- text_size
-
(Number)
862 863 864 |
# File 'lib/ambling/column.rb', line 862 def text_size @text_size end |
#width ⇒ Object
-
(Number / Number%) if empty, will be equal to plot area width
827 828 829 |
# File 'lib/ambling/column.rb', line 827 def width @width end |
#x ⇒ Object
-
(Number / Number% / !Number) if empty, will be equal to left margin
817 818 819 |
# File 'lib/ambling/column.rb', line 817 def x @x end |
#y ⇒ Object
-
(Number / Number% / !Number) if empty, will be below plot area
822 823 824 |
# File 'lib/ambling/column.rb', line 822 def y @y end |