2012-03-04 3 views
0

다음은 로그인 버튼의 코드입니다 : 이제폰갭은 로그인 버튼 UI 수정

<button type="submit" data-theme="a" id="loginButton">Login</button> 

, 내가 페이지의 중앙에 로그인 버튼의 크기와 표시를 증가해야합니다. 아이디어가 있으면 공유하십시오.

답변

1

당신이 ecplise를 사용하는 경우, 다음 버튼 의 속성 섹션에서 Layout weight를 사용하거나 빠른 방법은

<button 
    type="submit" 
    data-theme="a" 
    android:layout_width="40dp" //set size depending on your requirements 
    android:layout_width="wrap_content" 
    android:layout_centerInParent="true" 
    id="loginButton"> 

     Login 

    </button> 

EDIT를 설정하는 것은 : 미안 해요, 난 당신이 증가하고 싶은 생각 버튼의 크기. 그것을 중심은 방법 페이지의 버튼 센터를 만들기 위해

+1

화면에 대하여 그것을 중심 것 RelativeLayout

<RelativeLayout android:id="@+id/RelativeLayout01" android:layout_width="fill_parent" android:layout_height="fill_parent" xmlns:android="http://schemas.android.com/apk/res/android"> <button type="submit" data-theme="a" android:layout_width="40dp" //set size depending on your requirements android:layout_width="wrap_content" android:layout_centerInParent="true" id="loginButton"> Login </button> </RelativeLayout> 

속성 android:layout_centerInParent="true"를 사용할 수 있습니까? –

+1

phonegap과 HTML을 사용하여 버튼을 표시합니다. 전화 걸기 버튼을 중앙 집중화하도록 도와주세요. –