Androidを使い始めました。シンプルなレイアウトがうまくいきません。
を使用しLinearLayoutてTextViews、1つの行に2つ配置します。1つTextViewは左側にあり、もう1つは右側にあります(CSSのfloat:left、float:rightに類似)。
それは可能ですか、それともViewGroupそれを達成するために別のまたはさらに別のレイアウトネストを使用する必要がありますか?
ここに私がこれまで持っているものがあります:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="fill_parent"
android:orientation="horizontal" android:padding="10sp">
<TextView android:id="@+id/mytextview1" android:layout_height="wrap_content" android:text="somestringontheleftSomestring" android:layout_width="wrap_content"/>
<TextView android:id="@+id/mytextview2" android:layout_height="wrap_content" android:ellipsize="end"
android:text="somestringontheright" android:layout_width="wrap_content"/>
</LinearLayout>


