Advertisement
fahad005

TextView sample

Oct 25th, 2021
847
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 1.30 KB | None | 0 0
  1. <?xml version="1.0" encoding="utf-8"?>
  2.  
  3. <layout>
  4.     <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
  5.        xmlns:app="http://schemas.android.com/apk/res-auto"
  6.        xmlns:tools="http://schemas.android.com/tools"
  7.        android:layout_width="match_parent"
  8.        android:layout_height="match_parent"
  9.        android:orientation="vertical"
  10.        tools:context=".MainActivity">
  11.  
  12.         <TextView
  13.            android:id="@+id/nameText"
  14.            android:layout_width="wrap_content"
  15.            android:layout_height="wrap_content"
  16.            app:layout_constraintBottom_toBottomOf="parent"
  17.            app:layout_constraintLeft_toLeftOf="parent"
  18.            app:layout_constraintRight_toRightOf="parent"
  19.            app:layout_constraintTop_toTopOf="parent"
  20.            android:text="Fahad"
  21.            android:fontFamily="cursive"
  22.            android:textColor="@color/white"
  23.            android:textSize="40sp"
  24.            android:textStyle="bold"
  25.            android:textAllCaps="true"
  26.            android:visibility="visible"
  27.            android:padding="10dp"
  28.            android:background="#0048FF"
  29.            android:backgroundTint="#FF0000"
  30.            />
  31.  
  32.     </androidx.constraintlayout.widget.ConstraintLayout>
  33. </layout>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement