Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- Retrofit2
- NumberPIcker
- 기기고유값
- Navigation
- Room
- json
- 생명주기
- layout_constrainedWidth
- Load failed
- SSAID
- Lifecycle
- http
- DialogFragment
- WorkManager
- todo
- gradle plugin
- 화면 회전
- Popup menu background color
- studywithme
- RecyclerView
- ThreeTen Backport
- Android
- log
- Collections Function
- DataBinding
- kotlin
- multipart
- BottomSheetDialogFragment
- findNavController
- layout_constrainedHeight
Archives
- Today
- Total
목록layout_constrainedWidth (1)
chacha's

ConstraintLayout을 사용할 때 layout_height = "wrap_content"로 지정하면 제약 조건에 맞게 알아서 설정될 줄 알았다. 하지만 아이템의 개수가 많아지면 버튼 아래 쪽으로 뷰가 넘어가는 문제가 발생하였습니다. 이 경우, layout_constrainedHeight="true" 속성을 사용하면 제약조건에 맞게 뷰가 넘어가지 않는 것을 확인할 수 있습니다. 📌 RecyclerView 외에도 TextView와 같이 길이가 변하는 뷰를 설정할 때, app:layout_constrainedWidth=”true”, app:layout_constrainedHeight=”true” 속성을 사용하여 제약조건에 맞게 뷰를 설정할 수 있습니다. END
Android/TIL
2021. 12. 24. 13:35