전화했는데 쓸 때 사용되는 코드를 다시 크기 UI 구성 요소 소프트 키보드 나타납니다. When I use , 장저스테판 예약 크기 장저스트리시즈 it ui 구성 요소, 동시에 같은 날 제공했음 출력입니다. 그들 사이에 각 구성 요소를 사용하는 경우 그런이야길 차이? 어느쪽이야 (또는 장저스트리시즈 장저스테판) 는 좋은 크기조정 ᅴ?
이것은 내 xml:
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fillViewport="true" >
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:orientation="vertical" >
<EditText
android:id="@+id/editText5"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="45dp"
android:ems="10"
android:inputType="textPersonName" />
<Button
android:id="@+id/button1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="40dp"
android:text="My Button" />
</LinearLayout>
</RelativeLayout>
</ScrollView>
그리고 메니페스트 파일:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.adjustscroll"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="17" />
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name="com.example.adjustscroll.MainActivity"
android:label="@string/app_name"
android:windowSoftInputMode="adjustPan|adjustResize" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
>. adjustResize" "; >. >. # 39 의 기본 창 항상 크기조정 공간을 마련하기 위해 이 activity& 소프트 >. 화면에 키보드.
>. adjustPan" "; >. >. # 39 의 기본 창 크기조정 없는 공간을 마련하기 위해 이 activity& 소프트 >. 키보드. 오히려 컨텐트에서 창이 자동적으로 패닝 >. 현재 주로 키보드 및 사용자에 의해 가려진 배반자들의 도왔으매 >. 어떤 이들은 항상 볼 수 있게 됩니다. 이는 일반적으로 더 바람직합니다 >. 때문에 소프트 키보드를 닫으십시오 크기조정 비해 사용자 할 수 있습니다. >. 창의 가려진 부분을 프레젠테이션이든 dell. 및 상호 작용.
다음과 같은 설명을 따르면, 사용할 수 있는 분명한 활동
<activity android:windowSoftInputMode="adjustResize"> </activity>
또한 이를 [doc] [1] 정확한 값 조합으로의 유념해야 할 것이라고 말했습니다.
>. 이 설정은 다음 표에 나열된 값 중 하나여야 합니다. >. 또는 조합 한 " state."; 값 플러스 원 " adjust."; 값. >. 이 두 그룹 - 여러 값을 설정, 여러 " state.". 값뿐만 >. 예를 들어, - 가 정의되지 않은 결과를 얻을 수 있습니다. 개별 값은 분판된 >. 수직선 () 에 의해. 예를 들면 다음과 같습니다.
<activity android:windowSoftInputMode="stateVisible|adjustResize" . . . >
[1]: http://developer.android.com/guide/topics/manifest/activity-element.html # 바소프트