Skip to content

Instantly share code, notes, and snippets.

@agiletalk
Created April 11, 2011 09:00
Show Gist options
  • Save agiletalk/913255 to your computer and use it in GitHub Desktop.
Save agiletalk/913255 to your computer and use it in GitHub Desktop.
[예제] TextView
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/insa"
android:textColor="#ff0000"
android:textSize="20pt"
android:textStyle="italic"
/>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/anyoung"
android:textSize="20sp"
android:background="#0000ff"
/>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="Good Morning"
android:textColor="#8000ff00"
android:textSize="5mm"
android:typeface="serif"
/>
</LinearLayout>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="hello">Hello World, TextViewTest!</string>
<string name="app_name">TextViewTest</string>
<string name="insa">Hello</string>
<string name="anyoung">안녕하세요</string>
</resources>
package org.catchabug.TextViewTest;
import android.app.Activity;
import android.os.Bundle;
public class TextViewTest extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment