0

解析した JSON を ListView に表示しようとしていますが、フォントの色を #000000 に指定しているにもかかわらず、ListView のテキストが常に薄い灰色で表示されるという小さな問題があります。

リストを呼び出すコード スニペット:

protected void onPostExecute(JSONObject json) {

    ListView myListView = (ListView)findViewById(android.R.id.list);
    myListView.setAdapter(new ArrayAdapter<String>(getApplicationContext(), android.R.layout.simple_list_item_1, items));           
}

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" >

    <ListView
        android:id="@android:id/list"
        android:layout_width="fill_parent"
        android:layout_height="wrap_content"
        android:textColor="#000000" >
    </ListView>

</LinearLayout>

問題の可能性はありますか?

4

0 に答える 0