def get_line_pattern(value)   # :nodoc:
    value = value.downcase if value.respond_to?(:to_str)
    default = 0

    patterns = {
      0              => 5,
      1              => 0,
      2              => 1,
      3              => 2,
      4              => 3,
      5              => 4,
      6              => 7,
      7              => 6,
      8              => 8,
      'solid'        => 0,
      'dash'         => 1,
      'dot'          => 2,
      'dash-dot'     => 3,
      'dash-dot-dot' => 4,
      'none'         => 5,
      'dark-gray'    => 6,
      'medium-gray'  => 7,
      'light-gray'   => 8,
    }

    if patterns.has_key?(value)
      patterns[value]
    else
      default
    end
  end
def get_line_pattern(value)   # :nodoc:
    value = value.downcase if value.respond_to?(:to_str)
    default = 0

    patterns = {
      0              => 5,
      1              => 0,
      2              => 1,
      3              => 2,
      4              => 3,
      5              => 4,
      6              => 7,
      7              => 6,
      8              => 8,
      'solid'        => 0,
      'dash'         => 1,
      'dot'          => 2,
      'dash-dot'     => 3,
      'dash-dot-dot' => 4,
      'none'         => 5,
      'dark-gray'    => 6,
      'medium-gray'  => 7,
      'light-gray'   => 8,
    }

    if patterns.has_key?(value)
      patterns[value]
    else
      default
    end
  end
Get the Excel chart index for line pattern that corresponds to the user
 defined value.