CodePudding user response:
Try using RichText widget instead of the regular Text widget
CodePudding user response:
Use RichText widget as:
RichText(
text: TextSpan(
children: <TextSpan>[
TextSpan(
text: 'Hello', // non-emoji characters
),
TextSpan(
text: '? ?️u200d?', // emoji characters
style: TextStyle(
fontFamily: 'EmojiOne',
),
),
],
),
);
[OR]
Widget build(BuildContext context) {
return Center(
child: Container(
alignment: Alignment.center,
color: Colors.deepPurple,
//width: 200.0,
//height: 100.0,
child: Text("Emoji ? ",
style: TextStyle(
fontFamily: 'Raleway',
fontSize: 40,
decoration: TextDecoration.none,
color: Colors.white
))));
}

