function QuantChartChartAPI::adminSettings in Quant 7
Implements parent:adminSettings().
Overrides QuantChart::adminSettings
File
- plugins/
QuantChartChartAPI.inc, line 26
Class
- QuantChartChartAPI
- QuantChart plugin class to generate charts using chart.module (Chart API)
Code
function adminSettings() {
$form = array();
$palette = $this
->palette();
// Color settings
$form['chartapi_color'] = array(
'#type' => 'fieldset',
'#title' => t('Color settings'),
'#collapsible' => TRUE,
'#collapsed' => TRUE,
'#description' => t('Specify the colors that the charts will be rendered in.'),
);
for ($i = 0; $i < QUANT_PALETTE_AMOUNT; $i++) {
$form['chartapi_color']['quant_chartapi_palette_color_' . $i] = array(
'#type' => 'textfield',
'#title' => t('Color') . ' #' . ($i + 1),
'#default_value' => $palette[$i],
'#field_prefix' => '#',
'#size' => 10,
'#maxlength' => 6,
);
}
return $form;
}