/**
  * {@inheritdoc}
  */
 public function getAttributes()
 {
     $attributes = array('type' => 'password');
     $autocomplete = $this->config()->get('autocomplete');
     if ($autocomplete) {
         $attributes['autocomplete'] = 'on';
     } else {
         $attributes['autocomplete'] = 'off';
     }
     return array_merge(parent::getAttributes(), $attributes);
 }