android:layout

"wrap_content" : size that can show the content

"match_parent" : parent view's size - padding

"fill_parent" : same as "match_parent", not recommended

 

android:gravity : Set position of view in layout

 

android:text

"text"

"@string/android" : string should be saved at "res/values/strings/xml

 

android:textSize

px : pixel, no matter with resolution

dip / dp : same size in different resolution

sp : similar to dp, adapt changes of user's text size

pts : points

in : inches

mm : millimeters

 

android:padding

inside the view, blank with content

Left, Top, Right, Bottom

 

android:margin

outside the view, blank with other view

Left, Top, Right, Bottom

 

app:layout

app:layout_constraint(from this direction)_to(this direction)Of : Relationship between other views

ex)

app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"

Set view's left side to parent's left side

Set view's right side to parent's right side

Set view's topside to parent's topside

 

app:layout_constraintVertical_bias : how much will this view bias? 0~1 value

'Android' 카테고리의 다른 글

SharedPreferences  (0) 2022.01.31
ListView  (0) 2022.01.31
Package  (0) 2022.01.30
Intent  (0) 2022.01.29
EditText&Button  (0) 2022.01.29

+ Recent posts