function canvasactions_canvas2file_form in ImageCache Actions 5.3
Same name and namespace in other branches
- 8 canvasactions/canvasactions.inc \canvasactions_canvas2file_form()
- 5.2 canvasactions.inc \canvasactions_canvas2file_form()
- 6.2 canvasactions/canvasactions.inc \canvasactions_canvas2file_form()
- 6 canvasactions.inc \canvasactions_canvas2file_form()
- 7 canvasactions/canvasactions.inc \canvasactions_canvas2file_form()
Place a given image under the current canvas
Implementation of imagecache_hook_form()
Parameters
$action array of settings for this action:
Return value
a form definition
File
- ./
canvasactions.inc, line 208
Code
function canvasactions_canvas2file_form($action) {
$form = array(
'xpos' => array(
'#type' => 'textfield',
'#title' => t('X offset'),
'#default_value' => $action['xpos'],
'#size' => 6,
'#description' => t('Enter an offset in pixels or use a keyword: <em>left</em>, <em>center</em>, or <em>right</em>.'),
),
'ypos' => array(
'#type' => 'textfield',
'#title' => t('Y offset'),
'#default_value' => $action['ypos'],
'#size' => 6,
'#description' => t('Enter an offset in pixels or use a keyword: <em>top</em>, <em>center</em>, or <em>bottom</em>.'),
),
'alpha' => array(
'#type' => 'textfield',
'#title' => t('opacity'),
'#default_value' => isset($action['alpha']) ? $action['alpha'] : 100,
'#size' => 6,
'#description' => t('Opacity: 0-100.'),
),
'path' => array(
'#type' => 'textfield',
'#title' => t('file name'),
'#default_value' => $action['path'],
'#description' => t('File may be in the "files/" folder, or relative to the Drupal siteroot.'),
),
);
return $form;
}