AbnSrn
AbnSrn

Reputation: 596

How to prevent vaadin default styles and how to increase width and height of textfield

I am developing application using vaadin framework. I am new in vaadin framework.

I have lot of confusion in designing.

1) I am creating layout to display loginform but it will come with some default styles. That styles collapsed my desgin.

Please any one say How can I remove or prevent that vaadin default styles.

2) If I increase text-field height it automatically changed to text-area.

Please help any one How can I increase text-field height.

Upvotes: 1

Views: 2309

Answers (3)

Alireza
Alireza

Reputation: 126

for question 1, you should first setPrimaryStyleName and if you need other style, addStyleName

Upvotes: 0

Hink
Hink

Reputation: 1103

I cannot see any function setRow and setHeight doesnt allow to edit more lines. Only one line vertically i middle. Vaadin 7

Upvotes: 0

Kukuh Indrayana
Kukuh Indrayana

Reputation: 204

answer for number 2 :

Setting height for TextField also has a side-effect that puts TextField into multiline mode (aka "textarea"). Multiline mode can also be achieved by calling setRows(int). The height value overrides the number of rows set by setRows(int).

If you want to set height of single line TextField, call setRows(int) with value 0 after setting the height. Setting rows to 0 resets the side-effect.

Upvotes: 3

Related Questions