class Axlsx::Line3DChart

The Line3DChart is a three dimentional line chart (who would have guessed?) that you can add to your worksheet. @example Creating a chart

# This example creates a line in a single sheet.
require "rubygems" # if that is your preferred way to manage gems!
require "axlsx"

p = Axlsx::Package.new
ws = p.workbook.add_worksheet
ws.add_row ["This is a chart with no data in the sheet"]

chart = ws.add_chart(Axlsx::Line3DChart, :start_at=> [0,1], :end_at=>[0,6], :t#itle=>"Most Popular Pets")
chart.add_series :data => [1, 9, 10], :labels => ["Slimy Reptiles", "Fuzzy Bunnies", "Rottweiler"]

@see Worksheet#add_chart @see Worksheet#add_row @see Chart#add_series @see Series @see Package#serialize

Constants

GAP_AMOUNT_PERCENT

validation regex for gap amount percent

Attributes

gapDepth[R]

space between bar or column clusters, as a percentage of the bar or column width. @return [String]

gap_depth[R]

space between bar or column clusters, as a percentage of the bar or column width. @return [String]

Public Class Methods

new(frame, options={}) click to toggle source

Creates a new line chart object @option options [String] gap_depth @see Chart @see lineChart @see View3D

Calls superclass method Axlsx::LineChart::new
# File lib/axlsx/drawing/line_3D_chart.rb, line 44
def initialize(frame, options={})
  @gap_depth = nil
  @view_3D = View3D.new({:r_ang_ax=>1}.merge(options))
  super(frame, options)
  axes.add_axis :ser_axis, SerAxis
end

Public Instance Methods

gapDepth=(v)
Alias for: gap_depth=
gap_depth=(v) click to toggle source

@see gapDepth

# File lib/axlsx/drawing/line_3D_chart.rb, line 53
def gap_depth=(v)
  RegexValidator.validate "Line3DChart.gapWidth", GAP_AMOUNT_PERCENT, v
  @gap_depth=(v)
end
Also aliased as: gapDepth=
serAxis()
Alias for: ser_axis
ser_axis() click to toggle source

the category axis @return [Axis]

# File lib/axlsx/drawing/line_3D_chart.rb, line 34
def ser_axis
  axes[:ser_axis]
end
Also aliased as: serAxis
to_xml_string(str = '') click to toggle source

Serializes the object @param [String] str @return [String]

Calls superclass method Axlsx::LineChart#to_xml_string
# File lib/axlsx/drawing/line_3D_chart.rb, line 62
def to_xml_string(str = '')
  super(str) do |str_inner|
    str_inner << '<c:gapDepth val="' << @gap_depth.to_s << '"/>' unless @gap_depth.nil?
  end
end