이것은 내 코드이며 서로 옆에 버튼을 설정하는 여러 방법을 시도했지만 작동하지 않았습니다.서로 옆에 버튼을 배치하십시오.
정말 도움이 될 것입니다.
<?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="wrap_content"
android:orientation="vertical" >
<Button
android:id="@+id/button1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:layout_alignParentLeft="true" />
<Button
android:id="@+id/button2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1" />
</LinearLayout>
제발 안드로이드 : orientation = "horizontal" –
더 정확하게 '다음'을 정의하지 않는 한 대답 할 수 없습니다. – NickT
여러분의 레이아웃에 무엇이 있습니까, 그리고 나란히 정렬해야합니까? –