How to set the size attribute of a select field? When you use a "select" field with multiple values Drupal generates this HTML:

&lt;select multiple="multiple" name="..." id="..." class="..."&gt;


How can I inject the size="..." attribute? This will cause the box to show more values.
You might be able to do it with the #size property of the Form API. I am not sure, but you might need to also set the #multiple property to TRUE in order for the #size to be honored.

It it also not clear from the question if you are creating your own form using the Form API, modifying an existing Form API form using a hook_form_alter(), or writing your own form HTML (which I imagine - and hope - you are not doing).