editView


15
down vote accepted

I know you don't want to use an EditText but it's really easy to make it look like a TextView.

<EditText android:id="@+id/Id" android:layout_width="fill_parent" android:layout_height="wrap_content" android:background="@android:color/transparent" > </EditText>

You can also use android:background="@null".

Edit:

The TextView's editable param does make it editable (with some restrictions).

If you set android:editable="true" you can access the TextView via the D-pad, or you could add android:focusableInTouchMode="true" to be able to gain focus on touch.

The problem is you cannot modify the existing text, and you cannot move the cursor. The text you write just gets added before the existing text.

你可能感兴趣的:(android)