[flutter] Offstage : 위젯을 사라지게 한다

Edward Hyun·2021년 11월 17일
0

app&web-dev

목록 보기
9/178
post-custom-banner

Visibility는 물리적 공간을 차지하면서 show/hide만 하지만
Offstage는 물리적 공간까지도 show/hide 해준다 (강추)

참고::https://stackoverflow.com/questions/44489804/show-hide-widgets-in-flutter-programmatically

Try the Offstage widget
if attribute offstage:true the not occupy the physical space and invisible,
if attribute offstage:false it will occupy the physical space and visible

Offstage(
   offstage: true,
   child: Text("Visible"),
),

Opacity, which can stop its child from being painted.
Offstage, which can stop its child from being laid out or painted.
TickerMode, which can stop its child from being animated.
ExcludeSemantics, which can hide the child from accessibility tools.
IgnorePointer, which can disable touch interactions with the child.

Visibility 참고 자료
https://api.flutter.dev/flutter/widgets/Visibility-class.html

Offstage 참고 자료
https://api.flutter.dev/flutter/widgets/Offstage-class.html

profile
앱&웹개발(flutter, vuejs, typescript, react), 인공지능(nlp, asr, rl), 백엔드(nodejs, flask, golang, grpc, webrtc, aws, msa, nft, spring cloud, nest.js), 함수형 프로그래밍(scala, erlang)을 공부하며 정리합니다.
post-custom-banner

0개의 댓글