Last active
February 9, 2024 07:47
-
-
Save sunmeat/b622c51855e8f357d49f0076761b8f9f to your computer and use it in GitHub Desktop.
listview android example 2
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
layout\my_item.xml: | |
<TextView xmlns:android="http://schemas.android.com/apk/res/android" | |
android:layout_width="match_parent" | |
android:layout_height="wrap_content" | |
android:fontFamily="casual" | |
android:padding="10dp" | |
android:textColor="@color/pink" | |
android:textSize="30sp" | |
android:textStyle="bold" /> | |
================================================================================== | |
MainActivity.java: | |
... | |
adapter = new ArrayAdapter<>(this, R.layout.my_item, data); | |
... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment