Class: Writexlsx::Chart::Caption
- Inherits:
-
Object
- Object
- Writexlsx::Chart::Caption
- Defined in:
- lib/write_xlsx/chart/caption.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#data_id ⇒ Object
Returns the value of attribute data_id.
-
#formula ⇒ Object
Returns the value of attribute formula.
-
#layout ⇒ Object
readonly
Returns the value of attribute layout.
-
#name ⇒ Object
Returns the value of attribute name.
-
#name_font ⇒ Object
Returns the value of attribute name_font.
-
#none ⇒ Object
readonly
Returns the value of attribute none.
-
#overlay ⇒ Object
readonly
Returns the value of attribute overlay.
Instance Method Summary collapse
-
#initialize(chart) ⇒ Caption
constructor
A new instance of Caption.
-
#merge_with_hash(params) ⇒ Object
:nodoc:.
Constructor Details
#initialize(chart) ⇒ Caption
Returns a new instance of Caption.
9 10 11 |
# File 'lib/write_xlsx/chart/caption.rb', line 9 def initialize(chart) @chart = chart end |
Instance Attribute Details
#data_id ⇒ Object
Returns the value of attribute data_id.
6 7 8 |
# File 'lib/write_xlsx/chart/caption.rb', line 6 def data_id @data_id end |
#formula ⇒ Object
Returns the value of attribute formula.
6 7 8 |
# File 'lib/write_xlsx/chart/caption.rb', line 6 def formula @formula end |
#layout ⇒ Object (readonly)
Returns the value of attribute layout.
7 8 9 |
# File 'lib/write_xlsx/chart/caption.rb', line 7 def layout @layout end |
#name ⇒ Object
Returns the value of attribute name.
6 7 8 |
# File 'lib/write_xlsx/chart/caption.rb', line 6 def name @name end |
#name_font ⇒ Object
Returns the value of attribute name_font.
6 7 8 |
# File 'lib/write_xlsx/chart/caption.rb', line 6 def name_font @name_font end |
#none ⇒ Object (readonly)
Returns the value of attribute none.
7 8 9 |
# File 'lib/write_xlsx/chart/caption.rb', line 7 def none @none end |
#overlay ⇒ Object (readonly)
Returns the value of attribute overlay.
7 8 9 |
# File 'lib/write_xlsx/chart/caption.rb', line 7 def @overlay end |
Instance Method Details
#merge_with_hash(params) ⇒ Object
:nodoc:
13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/write_xlsx/chart/caption.rb', line 13 def merge_with_hash(params) # :nodoc: @name, @formula = @chart.process_names(params[:name], params[:name_formula]) @data_id = @chart.data_id(@formula, params[:data]) @name_font = @chart.convert_font_args(params[:name_font]) @layout = @chart.layout_properties(params[:layout], 1) # Set the title overlay option. @overlay = params[:overlay] # Set the no automatic title option. @none = params[:none] end |