一.所花时间

0.5h

二.代码量

50行

三.博客量

1篇

四.了解到的知识点

安卓文本显示  设置文本内容

<TextView
 android:id="@+id/tv_hello"
 android:layout_width="wrap_content"
 android:layout_height="wrap_content"
 android:text="你好,世界" />

// 获取名为tv_hello的文本视图
TextView tv_hello = findViewById(R.id.tv_hello);
 tv_hello.setText("你好,世界");  // 设置tv_hello的文字内容

 

posted on 2024-10-06 13:50  leapss  阅读(8)  评论(0)    收藏  举报