Class: Ambling::Pie::Settings
- Inherits:
-
Object
- Object
- Ambling::Pie::Settings
- Includes:
- Base
- Defined in:
- lib/ambling/pie.rb
Overview
“!” before x or y position (for example: <x>!20</x>) means that the coordinate will be calculated from the right side or the bottom
Defined Under Namespace
Classes: Animation, Background, Balloon, ContextMenu, DataLabels, ErrorMessages, ExportAsImage, Group, Labels, Legend, Pie, Strings
Constant Summary collapse
- VALUES =
[:data_type,:csv_separator,:skip_rows,:font,:text_size,:text_color,:decimals_separator,:thousands_separator,:digits_after_decimal,:reload_data_interval,:preloader_on_reload,:redraw,:add_time_stamp,:precision,:exclude_invisible,:pie,:animation,:data_labels,:group,:background,:balloon,:legend,:export_as_image,:error_messages,:strings,:context_menu,:labels]
Instance Attribute Summary collapse
-
#add_time_stamp ⇒ Object
- false
-
(true / false) if true, a unique number will be added every time flash loads data.
-
#animation ⇒ Object
Returns the value of attribute animation.
-
#background ⇒ Object
BACKGROUND.
-
#balloon ⇒ Object
BALLOON.
-
#context_menu ⇒ Object
<menu function_name=“printChart” title=“Print chart”></menu>.
-
#csv_separator ⇒ Object
- ;
-
(string) csv file data separator (you need it only if you are using csv file for your data).
-
#data_labels ⇒ Object
Returns the value of attribute data_labels.
-
#data_type ⇒ Object
- xml
-
(xml / csv).
-
#decimals_separator ⇒ Object
- ,
-
(string) decimal separator.
-
#digits_after_decimal ⇒ Object
-
(Number) if your value has less digits after decimal then is set here, zeroes will be added.
-
#error_messages ⇒ Object
“error_messages” settings will be applied for all error messages except the one which is showed if settings file wasn’t found.
-
#exclude_invisible ⇒ Object
- false
-
(true / false) whether to exclude invisible slices (where alpha=0) then calculating percent values or not.
-
#export_as_image ⇒ Object
export_as_image feature works only on a web server.
-
#font ⇒ Object
- Arial
-
(font name) use device fonts, such as Arial, Times New Roman, Tahoma, Verdana…
-
#group ⇒ Object
Returns the value of attribute group.
-
#labels ⇒ Object
labels can also be added in data xml file, using exactly the same structure like it is here.
-
#legend ⇒ Object
LEGEND.
-
#pie ⇒ Object
Returns the value of attribute pie.
-
#precision ⇒ Object
- 2
-
(Number) shows how many numbers should be shown after comma for calculated values (percents).
-
#preloader_on_reload ⇒ Object
- false
-
(true / false) Whether to show preloaded when data or settings are reloaded.
-
#redraw ⇒ Object
- false
-
(true / false) if your chart’s width or height is set in percents, and redraw is set to true, the chart will be redrawn then screen size changes.
-
#reload_data_interval ⇒ Object
- 0
-
(Number) how often data should be reloaded (time in seconds).
-
#skip_rows ⇒ Object
- 0
-
(Number) if you are using csv data type, you can set the number of rows which should be skipped here.
-
#strings ⇒ Object
Returns the value of attribute strings.
-
#text_color ⇒ Object
- #000000
-
(hex color code) main text color.
-
#text_size ⇒ Object
- 11
-
(Number) text size of all texts.
-
#thousands_separator ⇒ Object
-
(string) thousand separator.
Method Summary
Methods included from Base
#build_xml, #initialize, #populate, #to_xml
Instance Attribute Details
#add_time_stamp ⇒ Object
- false
-
(true / false) if true, a unique number will be added every time flash loads data. Mainly this feature is useful if you set reload _data_interval
76 77 78 |
# File 'lib/ambling/pie.rb', line 76 def add_time_stamp @add_time_stamp end |
#animation ⇒ Object
Returns the value of attribute animation.
96 97 98 |
# File 'lib/ambling/pie.rb', line 96 def animation @animation end |
#background ⇒ Object
BACKGROUND
111 112 113 |
# File 'lib/ambling/pie.rb', line 111 def background @background end |
#balloon ⇒ Object
BALLOON
116 117 118 |
# File 'lib/ambling/pie.rb', line 116 def balloon @balloon end |
#context_menu ⇒ Object
<menu function_name=“printChart” title=“Print chart”></menu>
141 142 143 |
# File 'lib/ambling/pie.rb', line 141 def @context_menu end |
#csv_separator ⇒ Object
- ;
-
(string) csv file data separator (you need it only if you are using csv file for your data)
21 22 23 |
# File 'lib/ambling/pie.rb', line 21 def csv_separator @csv_separator end |
#data_labels ⇒ Object
Returns the value of attribute data_labels.
101 102 103 |
# File 'lib/ambling/pie.rb', line 101 def data_labels @data_labels end |
#data_type ⇒ Object
- xml
-
(xml / csv)
16 17 18 |
# File 'lib/ambling/pie.rb', line 16 def data_type @data_type end |
#decimals_separator ⇒ Object
- ,
-
(string) decimal separator. Note, that this is for displaying data only. Decimals in data xml file must be separated with a dot
46 47 48 |
# File 'lib/ambling/pie.rb', line 46 def decimals_separator @decimals_separator end |
#digits_after_decimal ⇒ Object
-
(Number) if your value has less digits after decimal then is set here, zeroes will be added
56 57 58 |
# File 'lib/ambling/pie.rb', line 56 def digits_after_decimal @digits_after_decimal end |
#error_messages ⇒ Object
“error_messages” settings will be applied for all error messages except the one which is showed if settings file wasn’t found
131 132 133 |
# File 'lib/ambling/pie.rb', line 131 def @error_messages end |
#exclude_invisible ⇒ Object
- false
-
(true / false) whether to exclude invisible slices (where alpha=0) then calculating percent values or not
86 87 88 |
# File 'lib/ambling/pie.rb', line 86 def exclude_invisible @exclude_invisible end |
#export_as_image ⇒ Object
export_as_image feature works only on a web server
126 127 128 |
# File 'lib/ambling/pie.rb', line 126 def export_as_image @export_as_image end |
#font ⇒ Object
- Arial
-
(font name) use device fonts, such as Arial, Times New Roman, Tahoma, Verdana…
31 32 33 |
# File 'lib/ambling/pie.rb', line 31 def font @font end |
#group ⇒ Object
Returns the value of attribute group.
106 107 108 |
# File 'lib/ambling/pie.rb', line 106 def group @group end |
#labels ⇒ Object
labels can also be added in data xml file, using exactly the same structure like it is here
146 147 148 |
# File 'lib/ambling/pie.rb', line 146 def labels @labels end |
#legend ⇒ Object
LEGEND
121 122 123 |
# File 'lib/ambling/pie.rb', line 121 def legend @legend end |
#pie ⇒ Object
Returns the value of attribute pie.
91 92 93 |
# File 'lib/ambling/pie.rb', line 91 def pie @pie end |
#precision ⇒ Object
- 2
-
(Number) shows how many numbers should be shown after comma for calculated values (percents)
81 82 83 |
# File 'lib/ambling/pie.rb', line 81 def precision @precision end |
#preloader_on_reload ⇒ Object
- false
-
(true / false) Whether to show preloaded when data or settings are reloaded
66 67 68 |
# File 'lib/ambling/pie.rb', line 66 def preloader_on_reload @preloader_on_reload end |
#redraw ⇒ Object
- false
-
(true / false) if your chart’s width or height is set in percents, and redraw is set to true, the chart will be redrawn then screen size changes
71 72 73 |
# File 'lib/ambling/pie.rb', line 71 def redraw @redraw end |
#reload_data_interval ⇒ Object
- 0
-
(Number) how often data should be reloaded (time in seconds)
61 62 63 |
# File 'lib/ambling/pie.rb', line 61 def reload_data_interval @reload_data_interval end |
#skip_rows ⇒ Object
- 0
-
(Number) if you are using csv data type, you can set the number of rows which should be skipped here
26 27 28 |
# File 'lib/ambling/pie.rb', line 26 def skip_rows @skip_rows end |
#strings ⇒ Object
Returns the value of attribute strings.
136 137 138 |
# File 'lib/ambling/pie.rb', line 136 def strings @strings end |
#text_color ⇒ Object
- #000000
-
(hex color code) main text color. Every text color can be set individually in the settings below
41 42 43 |
# File 'lib/ambling/pie.rb', line 41 def text_color @text_color end |
#text_size ⇒ Object
- 11
-
(Number) text size of all texts. Every text size can be set individually in the settings below
36 37 38 |
# File 'lib/ambling/pie.rb', line 36 def text_size @text_size end |
#thousands_separator ⇒ Object
-
(string) thousand separator. use “none” if you don’t want to separate
51 52 53 |
# File 'lib/ambling/pie.rb', line 51 def thousands_separator @thousands_separator end |