function ctools_stylizer_padding_selector_form
padding selector form
File
-
includes/
stylizer.inc, line 1504
Code
function ctools_stylizer_padding_selector_form(&$form, &$form_state, $label, $settings) {
// Family
$form['#prefix'] = '<div class="ctools-stylizer-spacing-form clearfix">';
$form['#type'] = 'fieldset';
$form['#title'] = $label;
$form['#suffix'] = '</div>';
$form['#tree'] = TRUE;
$options = array(
'' => '',
"0.05em" => '0.05em',
"0.1em" => '0.1em',
"0.15em" => '0.15em',
"0.2em" => '0.2em',
"0.25em" => '0.25em',
"0.3em" => '0.3em',
"0.35em" => '0.35em',
"0.4em" => '0.4em',
"0.45em" => '0.45em',
"0.5em" => '0.5em',
"0.55em" => '0.55em',
"0.6em" => '0.6em',
"0.65em" => '0.65em',
"0.7em" => '0.7em',
"0.75em" => '0.75em',
"0.8em" => '0.8em',
"0.85em" => '0.85em',
"0.9em" => '0.9em',
"0.95em" => '0.95em',
"1.0em" => '1.0em',
"1.05em" => '1.05em',
"1.1em" => '1.1em',
"1.15em" => '1.15em',
"1.2em" => '1.2em',
"1.25em" => '1.25em',
"1.3em" => '1.3em',
"1.35em" => '1.35em',
"1.4em" => '1.4em',
"1.45em" => '1.45em',
"1.5em" => '1.5em',
"1.55em" => '1.55em',
"1.6em" => '1.6em',
"1.65em" => '1.65em',
"1.7em" => '1.7em',
"1.75em" => '1.75em',
"1.8em" => '1.8em',
"1.85em" => '1.85em',
"1.9em" => '1.9em',
"1.95em" => '1.95em',
"2.0em" => '2.0em',
"2.05em" => '2.05em',
"2.1em" => '2.1em',
"2.15em" => '2.15em',
"2.2em" => '2.2em',
"2.25em" => '2.25em',
"2.3em" => '2.3em',
"2.35em" => '2.35em',
"2.4em" => '2.4em',
"2.45em" => '2.45em',
"2.5em" => '2.5em',
"2.55em" => '2.55em',
"2.6em" => '2.6em',
"2.65em" => '2.65em',
"2.7em" => '2.7em',
"2.75em" => '2.75em',
"2.8em" => '2.8em',
"2.85em" => '2.85em',
"2.9em" => '2.9em',
"2.95em" => '2.95em',
"3.0em" => '3.0em',
"3.05em" => '3.05em',
"3.1em" => '3.1em',
"3.15em" => '3.15em',
"3.2em" => '3.2em',
"3.25em" => '3.25em',
"3.3em" => '3.3em',
"3.35em" => '3.35em',
"3.4em" => '3.4em',
"3.45em" => '3.45em',
"3.5em" => '3.5em',
"3.55em" => '3.55em',
"3.6em" => '3.6em',
"3.65em" => '3.65em',
"3.7em" => '3.7em',
"3.75em" => '3.75em',
"3.8em" => '3.8em',
"3.85em" => '3.85em',
"3.9em" => '3.9em',
"3.95em" => '3.95em',
);
$form['top'] = array(
'#title' => t('Top'),
'#type' => 'select',
'#default_value' => isset($settings['top']) ? $settings['top'] : '',
'#options' => $options,
);
$form['right'] = array(
'#title' => t('Right'),
'#type' => 'select',
'#default_value' => isset($settings['right']) ? $settings['right'] : '',
'#options' => $options,
);
$form['bottom'] = array(
'#title' => t('Bottom'),
'#type' => 'select',
'#default_value' => isset($settings['bottom']) ? $settings['bottom'] : '',
'#options' => $options,
);
$form['left'] = array(
'#title' => t('Left'),
'#type' => 'select',
'#default_value' => isset($settings['left']) ? $settings['left'] : '',
'#options' => $options,
);
}