function ResizeImageEffect::buildConfigurationForm
Same name in other branches
- 8.9.x core/modules/image/src/Plugin/ImageEffect/ResizeImageEffect.php \Drupal\image\Plugin\ImageEffect\ResizeImageEffect::buildConfigurationForm()
- 10 core/modules/image/src/Plugin/ImageEffect/ResizeImageEffect.php \Drupal\image\Plugin\ImageEffect\ResizeImageEffect::buildConfigurationForm()
- 11.x core/modules/image/src/Plugin/ImageEffect/ResizeImageEffect.php \Drupal\image\Plugin\ImageEffect\ResizeImageEffect::buildConfigurationForm()
2 calls to ResizeImageEffect::buildConfigurationForm()
- CropImageEffect::buildConfigurationForm in core/
modules/ image/ src/ Plugin/ ImageEffect/ CropImageEffect.php - ScaleImageEffect::buildConfigurationForm in core/
modules/ image/ src/ Plugin/ ImageEffect/ ScaleImageEffect.php
2 methods override ResizeImageEffect::buildConfigurationForm()
- CropImageEffect::buildConfigurationForm in core/
modules/ image/ src/ Plugin/ ImageEffect/ CropImageEffect.php - ScaleImageEffect::buildConfigurationForm in core/
modules/ image/ src/ Plugin/ ImageEffect/ ScaleImageEffect.php
File
-
core/
modules/ image/ src/ Plugin/ ImageEffect/ ResizeImageEffect.php, line 66
Class
- ResizeImageEffect
- Resizes an image resource.
Namespace
Drupal\image\Plugin\ImageEffectCode
public function buildConfigurationForm(array $form, FormStateInterface $form_state) {
$form['width'] = [
'#type' => 'number',
'#title' => $this->t('Width'),
'#default_value' => $this->configuration['width'],
'#field_suffix' => ' ' . $this->t('pixels'),
'#required' => TRUE,
'#min' => 1,
];
$form['height'] = [
'#type' => 'number',
'#title' => $this->t('Height'),
'#default_value' => $this->configuration['height'],
'#field_suffix' => ' ' . $this->t('pixels'),
'#required' => TRUE,
'#min' => 1,
];
return $form;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.