android - How to get a button's height to match another element's height? -


i want put button next edittext , want heights match.

for example, built in android browser:

alt text

the go button same height edittext field. know wrap both these views in parent layout view, , set both of heights fill_parent, , make them match. however, without having give layout static size. rather have edittext take whatever height needs based on font size , have button next match whatever height might be.

is possible xml layout?

you need make edittext wrap_content on height , have button fill_parent. need have them both wrapped in layout parent. way associated same layout parent.

try , see how works, if helps let me know. if doesn't maybe can give code out.


Comments

Popular posts from this blog

android - Spacing between the stars of a rating bar? -

html - Instapaper-like algorithm -

c# - How to execute a particular part of code asynchronously in a class -