Android开发:从Hello World到计算器应用的实现
1. 运行“Hello, World”示例
在Android开发中,我们可以先从一个简单的“Hello, World”示例开始,其布局代码如下:
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Hello World!"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
android:textSize="36sp"/>
</androidx.constraintlayout.widget.ConstraintLayout>
超级会员免费看
订阅专栏 解锁全文
29

被折叠的 条评论
为什么被折叠?



