Class: Ambling::Column::Settings

Inherits:
Object
  • Object
show all
Includes:
Base
Defined in:
lib/ambling/column.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: Axes, Background, Balloon, Column, ContextMenu, ErrorMessages, ExportAsImage, Graphs, Grid, Guides, Labels, Legend, Line, PlotArea, Strings, Values

Constant Summary collapse

VALUES =
[:type,:data_type,:csv_separator,:skip_rows,:font,:text_size,:text_color,:decimals_separator,:thousands_separator,:digits_after_decimal,:redraw,:reload_data_interval,:preloader_on_reload,:add_time_stamp,:precision,:depth,:angle,:colors,:column,:line,:background,:plot_area,:grid,:values,:axes,:balloon,:legend,:export_as_image,:error_messages,:strings,:context_menu,:labels,:graphs,:guides]

Instance Attribute Summary collapse

Method Summary

Methods included from Base

#build_xml, #initialize, #populate, #to_xml

Instance Attribute Details

#add_time_stampObject

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



81
82
83
# File 'lib/ambling/column.rb', line 81

def add_time_stamp
  @add_time_stamp
end

#angleObject

30

(0 - 90) angle of chart area and columns (for 3D effect)



96
97
98
# File 'lib/ambling/column.rb', line 96

def angle
  @angle
end

#axesObject

axes



136
137
138
# File 'lib/ambling/column.rb', line 136

def axes
  @axes
end

#backgroundObject

BACKGROUND



116
117
118
# File 'lib/ambling/column.rb', line 116

def background
  @background
end

#balloonObject

BALLOON



141
142
143
# File 'lib/ambling/column.rb', line 141

def balloon
  @balloon
end

#colorsObject

#FF6600,#FCD202,#B0DE09,#0D8ECF,#2A0CD0,#CD0D74,#CC0000,#00CC00,#0000CC,#DDDDDD,#999999,#333333,#990000

Colors of graphs. if the graph color is not set, color from this array will be used



101
102
103
# File 'lib/ambling/column.rb', line 101

def colors
  @colors
end

#columnObject

Returns the value of attribute column.



106
107
108
# File 'lib/ambling/column.rb', line 106

def column
  @column
end

#context_menuObject

<menu function_name=“printChart” title=“Print chart”></menu>



166
167
168
# File 'lib/ambling/column.rb', line 166

def context_menu
  @context_menu
end

#csv_separatorObject

;

(string) csv file data separator (you need it only if you are using csv file for your data)



26
27
28
# File 'lib/ambling/column.rb', line 26

def csv_separator
  @csv_separator
end

#data_typeObject

xml

(xml / csv)



21
22
23
# File 'lib/ambling/column.rb', line 21

def data_type
  @data_type
end

#decimals_separatorObject

,

(string) decimal separator. Note, that this is for displaying data only. Decimals in data xml file must be separated with a dot



51
52
53
# File 'lib/ambling/column.rb', line 51

def decimals_separator
  @decimals_separator
end

#depthObject

0

(Number) the depth of chart and columns (for 3D effect)



91
92
93
# File 'lib/ambling/column.rb', line 91

def depth
  @depth
end

#digits_after_decimalObject

(Number) if your value has less digits after decimal then is set here, zeroes will be added



61
62
63
# File 'lib/ambling/column.rb', line 61

def digits_after_decimal
  @digits_after_decimal
end

#error_messagesObject

“error_messages” settings will be applied for all error messages except the one which is showed if settings file wasn’t found



156
157
158
# File 'lib/ambling/column.rb', line 156

def error_messages
  @error_messages
end

#export_as_imageObject

export_as_image feature works only on a web server



151
152
153
# File 'lib/ambling/column.rb', line 151

def export_as_image
  @export_as_image
end

#fontObject

Arial

(font name) use device fonts, such as Arial, Times New Roman, Tahoma, Verdana…



36
37
38
# File 'lib/ambling/column.rb', line 36

def font
  @font
end

#graphsObject

if graph settings are defined both here and in data file, the ones from data file are used



176
177
178
# File 'lib/ambling/column.rb', line 176

def graphs
  @graphs
end

#gridObject

GRID



126
127
128
# File 'lib/ambling/column.rb', line 126

def grid
  @grid
end

#guidesObject

guides are straight lines drawn through all plot area at a give value. Can also be filled with color



181
182
183
# File 'lib/ambling/column.rb', line 181

def guides
  @guides
end

#labelsObject

labels can also be added in data xml file, using exactly the same structure like it is here



171
172
173
# File 'lib/ambling/column.rb', line 171

def labels
  @labels
end

#legendObject

LEGEND



146
147
148
# File 'lib/ambling/column.rb', line 146

def legend
  @legend
end

#lineObject

Here are general settings for “line” graph type. You can set most of these settings for individual lines in graph settings below



111
112
113
# File 'lib/ambling/column.rb', line 111

def line
  @line
end

#plot_areaObject

PLOT AREA (the area between axes)



121
122
123
# File 'lib/ambling/column.rb', line 121

def plot_area
  @plot_area
end

#precisionObject

2

(Number) shows how many numbers should be shown after comma for calculated values (percents)



86
87
88
# File 'lib/ambling/column.rb', line 86

def precision
  @precision
end

#preloader_on_reloadObject

false

(true / false) Whether to show preloaded when data or settings are reloaded



76
77
78
# File 'lib/ambling/column.rb', line 76

def preloader_on_reload
  @preloader_on_reload
end

#redrawObject

this function is beta, be careful. Legend, buttons labels will not be repositioned if you set your x and y values for these objects



66
67
68
# File 'lib/ambling/column.rb', line 66

def redraw
  @redraw
end

#reload_data_intervalObject

0

(Number) how often data should be reloaded (time in seconds)



71
72
73
# File 'lib/ambling/column.rb', line 71

def reload_data_interval
  @reload_data_interval
end

#skip_rowsObject

0

(Number) if you are using csv data type, you can set the number of rows which should be skipped here



31
32
33
# File 'lib/ambling/column.rb', line 31

def skip_rows
  @skip_rows
end

#stringsObject

Returns the value of attribute strings.



161
162
163
# File 'lib/ambling/column.rb', line 161

def strings
  @strings
end

#text_colorObject

#000000

(hex color code) main text color. Every text color can be set individually in the settings below



46
47
48
# File 'lib/ambling/column.rb', line 46

def text_color
  @text_color
end

#text_sizeObject

11

(Number) text size of all texts. Every text size can be set individually in the settings below



41
42
43
# File 'lib/ambling/column.rb', line 41

def text_size
  @text_size
end

#thousands_separatorObject

(string) thousand separator. use “none” if you don’t want to separate



56
57
58
# File 'lib/ambling/column.rb', line 56

def thousands_separator
  @thousands_separator
end

#typeObject

column

(column / bar)



16
17
18
# File 'lib/ambling/column.rb', line 16

def type
  @type
end

#valuesObject

VALUES



131
132
133
# File 'lib/ambling/column.rb', line 131

def values
  @values
end