Class: AlGraph::ContainerBar
- Inherits:
-
DataContainer
- Object
- DataContainer
- AlGraph::ContainerBar
- Defined in:
- lib/al_graph.rb
Overview
バーグラフ用データコンテナ
Instance Attribute Summary collapse
-
#at_bar ⇒ Hash
バーの描画アトリビュート.
-
#at_bar_several ⇒ Hash<Hash>
個別のバー描画アトリビュート.
-
#base_container ⇒ Containerbar
readonly
積み重ねグラフの時、下になるコンテナオブジェクト.
Attributes inherited from DataContainer
#at_data_labels, #id, #labels, #legend, #plot, #x_axis, #y_axis, #y_data
Instance Method Summary collapse
-
#initialize(ydata, legend = nil) ⇒ ContainerBar
constructor
(ContainerBar) constructor.
-
#set_color(color) ⇒ Object
(also: #color=)
(ContainerBar) 色の指定.
-
#set_stack(base) ⇒ Object
(ContainerBar) 積み重ね設定.
Methods inherited from DataContainer
#add_data_labels, #each, #size
Constructor Details
#initialize(ydata, legend = nil) ⇒ ContainerBar
(ContainerBar) constructor
1933 1934 1935 1936 1937 1938 1939 |
# File 'lib/al_graph.rb', line 1933 def initialize(ydata, legend = nil) super @at_bar = {:stroke_width=>1, :stroke=>:black} @at_bar_several = {} @base_container = nil end |
Instance Attribute Details
#at_bar ⇒ Hash
Returns バーの描画アトリビュート.
1917 1918 1919 |
# File 'lib/al_graph.rb', line 1917 def @at_bar end |
#at_bar_several ⇒ Hash<Hash>
Returns 個別のバー描画アトリビュート.
1920 1921 1922 |
# File 'lib/al_graph.rb', line 1920 def @at_bar_several end |
#base_container ⇒ Containerbar (readonly)
Returns 積み重ねグラフの時、下になるコンテナオブジェクト.
1923 1924 1925 |
# File 'lib/al_graph.rb', line 1923 def base_container @base_container end |
Instance Method Details
#set_color(color) ⇒ Object Also known as: color=
(ContainerBar) 色の指定
1959 1960 1961 |
# File 'lib/al_graph.rb', line 1959 def set_color(color) @at_bar[:fill] = color end |
#set_stack(base) ⇒ Object
(ContainerBar) 積み重ね設定
1947 1948 1949 |
# File 'lib/al_graph.rb', line 1947 def set_stack(base) @base_container = base end |