1<?xml version="1.0" encoding="utf-8"?> 2<ScrollView 3 xmlns:android="http://schemas.android.com/apk/res/android" 4 xmlns:tools="http://schemas.android.com/tools" 5 android:id="@+id/scrollView" 6 tools:context="org.libwebsockets.client.MainActivity" 7 android:theme="@android:style/Theme.Holo.Light" 8 android:layout_width="match_parent" 9 android:layout_height="match_parent" 10 android:fillViewport="true"> 11 12 <RelativeLayout 13 android:layout_width="fill_parent" 14 android:layout_height="fill_parent" 15 android:paddingBottom="@dimen/activity_vertical_margin" 16 android:paddingLeft="@dimen/activity_horizontal_margin" 17 android:paddingRight="@dimen/activity_horizontal_margin" 18 android:paddingTop="@dimen/activity_vertical_margin"> 19 20 <ImageView 21 android:layout_width="wrap_content" 22 android:layout_height="wrap_content" 23 android:id="@+id/imageView" 24 android:layout_alignParentTop="true" 25 android:layout_centerHorizontal="true" 26 android:src="@drawable/warmcat" /> 27 28 <EditText 29 android:layout_width="match_parent" 30 android:layout_height="wrap_content" 31 android:id="@+id/editText_serverLocation" 32 android:hint="Hostname or IP address" 33 android:background="@android:drawable/editbox_background" 34 android:textAppearance="@style/Base.TextAppearance.AppCompat" 35 android:singleLine="true" 36 android:layout_marginTop="@dimen/activity_vertical_margin" 37 android:layout_below="@+id/imageView" 38 android:layout_alignParentStart="true" /> 39 40 <EditText 41 android:layout_width="match_parent" 42 android:layout_height="wrap_content" 43 android:inputType="number" 44 android:ems="10" 45 android:id="@+id/editText_portNumber" 46 android:background="@android:drawable/editbox_background" 47 android:hint="Port number" 48 android:text="7681" 49 android:textAppearance="@style/Base.TextAppearance.AppCompat" 50 android:singleLine="true" 51 android:layout_below="@+id/editText_serverLocation" 52 android:layout_alignParentStart="true" 53 android:layout_marginTop="@dimen/activity_vertical_margin" 54 android:layout_marginBottom="@dimen/activity_vertical_margin" /> 55 56 <Button 57 android:layout_width="wrap_content" 58 android:layout_height="wrap_content" 59 android:text="(dis)connect" 60 android:id="@+id/button" 61 android:textAppearance="@style/Base.TextAppearance.AppCompat" 62 android:onClick="clickStart" 63 android:layout_below="@+id/editText_portNumber" 64 android:layout_centerHorizontal="true" 65 android:layout_marginBottom="@dimen/activity_vertical_margin" /> 66 67 <TextView 68 android:layout_width="fill_parent" 69 android:layout_height="fill_parent" 70 android:textAppearance="?android:attr/textAppearanceLarge" 71 android:text="dumb-increment-protocol" 72 android:id="@+id/textView_counter" 73 android:layout_centerHorizontal="true" 74 android:gravity="center_vertical|center_horizontal" 75 android:layout_alignParentBottom="true" 76 android:background="@android:drawable/alert_light_frame" 77 android:singleLine="false" 78 android:layout_below="@+id/button" /> 79 80 </RelativeLayout> 81</ScrollView> 82