PageMaker
PageMaker

Reputation: 395

How do I align textview.text with edittext.text

I tried a lot of different attribute values, but no result yet. No pictures allowed. But the text in the edittext.text remains about 3 mm to high.

One Solution is to "compensate" the "error" in ?android:attr/editTextBackgroud. This last one seems to sneek in witout clear warning or expectation.

textView: paddingbottom=14
editText layout_marginTop=10
editText background=?android:attr/editTextBackground

Upvotes: 0

Views: 129

Answers (1)

Hoan Nguyen
Hoan Nguyen

Reputation: 18151

Use layout_alignBaseline in your edit text

android:layout_alignBaseline="@id/your_textview_id"

Upvotes: 1

Related Questions