반응형
TextField 내 'textAlign: TextAlign.center'를 삽입해주면 쉽게 해결된다.
Container(
width: screenWidth*(300/360),
child: TextField(
controller: textfieldController_OpenChatLink,
textInputAction: TextInputAction.done,
// textAlign: TextAlign.center,
decoration: InputDecoration(
hintText: 'https://open.kakao.com/12345679',
hintStyle: TextStyle(
fontSize: screenWidth*(16/360),
color: hexToColor('#D2D2D2'),
fontWeight: FontWeight.bold,
)
),
),
)
Container(
width: screenWidth*(300/360),
child: TextField(
controller: textfieldController_OpenChatLink,
textInputAction: TextInputAction.done,
textAlign: TextAlign.center,
decoration: InputDecoration(
hintText: 'https://open.kakao.com/12345679',
hintStyle: TextStyle(
fontSize: screenWidth*(16/360),
color: hexToColor('#D2D2D2'),
fontWeight: FontWeight.bold,
)
),
),
)
반응형
'개발 > Flutter' 카테고리의 다른 글
[ Flutter ] 앱 시작할때 나오는 로딩 화면 구현하기! (Splash Screen) (2) | 2021.08.04 |
---|---|
[ Flutter ] PageView 자동 스크롤 기능 넣기! (3) | 2021.08.03 |
[ Flutter ] Google Map 현재 위치로 이동하는 버튼 만들기 (0) | 2021.02.26 |
[ Flutter ] TextField의 prefixIcon 사이즈 내맘대로 조절하기 (0) | 2021.02.25 |
[ Flutter ] ExpansionTile로 숨김 / 드러내기 기능 구현해보기! (0) | 2021.01.12 |