저는 최근에 안드로이드 응용 프로그램에서 작업 해 왔으며, 마지막 날 또는 그 전에는 Eclipse 레이아웃 편집기를 사용하여 GUI 작업을하고있었습니다. 불행히도 x- 차원이 아닌 다른 방법으로 선형 레이아웃의 크기를 조정할 수 없습니다. 또한 TextView의 크기를 조정하여 크기를 조정할 수 있습니다. 수 실이 언급했듯이, 나는 직선형 레이아웃의 높이를 제어 할 수 없다. 내 코드 :안드로이드는 LinearLayout의 크기를 조정할 수 없습니다
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<ScrollView
android:id="@+id/scrollView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1" >
<LinearLayout
android:id="@+id/helpLinearLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="top"
android:orientation="horizontal" >
<TextView
android:id="@+id/InfoTitle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Info:"
android:textSize="35sp" />
</LinearLayout>
</ScrollView>
</LinearLayout>
그 트릭을 한 것으로 나타납니다. 고맙습니다! 편집 : 아니, 이제는 내 textview 전혀 이동할 수 없습니다. –
당신은'fill_parent' 대신에'match_parent'를 계속 사용해야합니다 – Androiderson
@ dylanisawesome1 당신이 그것을 옮길 수 없다는 것은 무엇을 의미합니까? – nedaRM