You are here

function _google_charts in Charts 6

Same name and namespace in other branches
  1. 7 google_charts/google_charts.inc \_google_charts()

@author Bruno Massa http://drupal.org/user/67164 @file Use Google Charts on your site.

2 calls to _google_charts()
_google_charts_chart in google_charts/google_charts.inc
Convert all Chart-level data.
_google_charts_series in google_charts/google_charts.inc
Convert all Series-level data.

File

google_charts/google_charts.inc, line 8
@author Bruno Massa http://drupal.org/user/67164

Code

function _google_charts($type) {
  $types = array(
    'line2D' => array(
      'typecode' => 'lc',
      'attributes_per_value' => FALSE,
    ),
    'hbar2D' => array(
      'typecode' => 'bhg',
      'attributes_per_value' => FALSE,
    ),
    'vbar2D' => array(
      'typecode' => 'bvg',
      'attributes_per_value' => FALSE,
    ),
    'hbar2Ds' => array(
      'typecode' => 'bhs',
      'attributes_per_value' => FALSE,
    ),
    'vbar2Ds' => array(
      'typecode' => 'bvs',
      'attributes_per_value' => FALSE,
    ),
    'pie2D' => array(
      'typecode' => 'p',
      'attributes_per_value' => TRUE,
    ),
    'pie3D' => array(
      'typecode' => 'p3',
      'attributes_per_value' => TRUE,
    ),
    'venn' => array(
      'typecode' => 'v',
      'attributes_per_value' => FALSE,
    ),
    'scatter' => array(
      'typecode' => 's',
      'attributes_per_value' => FALSE,
    ),
  );
  return $types[$type];
}