diff --git a/chart.module b/chart.module
index 76e177b..cee0aa0 100644
--- a/chart.module
+++ b/chart.module
@@ -1223,3 +1223,20 @@ function chart_types() {
     CHART_TYPE_QR => t('QR code'),
   );
 }
+
+/**
+ * Generate a map of legend positions.
+ *
+ * @return
+ *   An associative array of legend positions.
+ */
+function chart_legend_positions() {
+  return array(
+    CHART_LEGEND_BOTTOM => t('Bottom'),
+    CHART_LEGEND_TOP => t('Top'),
+    CHART_LEGEND_BOTTOM_VERTICAL => t('Bottom Vertical'),
+    CHART_LEGEND_TOP_VERTICAL => t('Top Vertical'),
+    CHART_LEGEND_RIGHT => t('Right'),
+    CHART_LEGEND_LEFT => t('Left'),
+  );
+}
diff --git a/chart_views/views/chart_views_plugin_style_chart.inc b/chart_views/views/chart_views_plugin_style_chart.inc
index cd46714..aff7708 100644
--- a/chart_views/views/chart_views_plugin_style_chart.inc
+++ b/chart_views/views/chart_views_plugin_style_chart.inc
@@ -20,6 +20,8 @@ class chart_views_plugin_style_chart extends views_plugin_style {
     $options['height'] = array('default' => 400);
     $options['color_scheme'] = array('default' => 'default');
     $options['label_append_value'] = array('default' => FALSE);
+    $options['legend'] = array('default' => TRUE);
+    $options['legend_position'] = array('default' => 'b');
 
     return $options;
   }
@@ -65,6 +67,19 @@ class chart_views_plugin_style_chart extends views_plugin_style {
       '#description' => t('If checked, calculated values will be appended in the chart legend.'),
       '#default_value' => $this->options['label_append_value'],
     );
+    $form['legend'] = array(
+      '#type' => 'checkbox',
+      '#title' => t('Append Legend Box'),
+      '#description' => t('If checked, a legend box would be created'),
+      '#default_value' => $this->options['legend'],
+    );
+    $form['legend_position'] = array(
+      '#type' => 'radios',
+      '#title' => t('Legend Position'),
+      '#description' => t('Indicate where the Legend would be placed'),
+      '#default_value' => $this->options['legend_position'],
+      '#options' => chart_legend_positions(),
+    );
   }
 
   function render() {
@@ -88,6 +103,8 @@ class chart_views_plugin_style_chart extends views_plugin_style {
         '#data' => array(),
         '#labels' => array(),
         '#data_colors' => array(),
+	'#legends' => $this->options['legend'] ? array() : '',
+	'#legend_position' => $this->options['legend'] ? $this->options['legend_position'] : '',
       );
 
       foreach ($records as $row_index => $row) {
@@ -100,6 +117,13 @@ class chart_views_plugin_style_chart extends views_plugin_style {
         }
       }
 
+      foreach ($this->view->field as $key => $field) {
+        if (!$field->options['exclude']) {
+	  if ($this->options['legend'])
+	    $chart['#legends'][] = $field->options['label'];
+	}
+      }
+
       // Allow modules to alter the chart based on views context.
       drupal_alter('chart_views', $chart, $this->view->name, $this->display->id);
 
