如何在my xml的图形布局中以粗体显示我的文本?我希望我的标题以粗体显示,而结果则采用正常格式。谢谢。我希望你能帮助我处理这件事。以大胆显示文本
<?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="fill_parent"
android:orientation="vertical" >
<TextView
android:id="@+id/coordinates"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/instruction" />
<TextView
android:id="@+id/result"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/result" />
<Button
android:id="@+id/btn_process"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/btn_text" />
<ScrollView
android:layout_width="fill_parent"
android:layout_height="wrap_content" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="300dp"
android:orientation="vertical" >
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="Original" />
<ImageView
android:id="@+id/imageSource"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/test_ideal_graph" />
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="Result" />
<FrameLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content" >
<ImageView
android:id="@+id/imageAfter"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<ProgressBar
android:id="@+id/progressBar"
style="?android:attr/progressBarStyleLarge"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</FrameLayout>
</LinearLayout>
</ScrollView>
</LinearLayout>
在每个文本视图中添加android:textStyle =“bold” – 2013-02-25 07:56:48
http://stackoverflow.com/a/5169604/1434631 – Nermeen 2013-02-25 07:57:51