I just started to migrate to Flutter web and just at the start point, encountered this strange problem.
When using Persian/Arabic Characters in code, it would be shown improperly on the UI. Other Characters are shown nice.
Flutter Default Sample App
environment:
sdk: ">=2.7.0 <3.0.0"
Code:
children: <Widget>[
Text(
'You have pressed the button this many times:',
style: Theme.of(context).textTheme.headline4,
),
Text(
'??? ??? ???? ?? ??? ????? ??? ???? ???? ???:',
style: Theme.of(context).textTheme.headline4,
),
Text(
'?ě????',
style: Theme.of(context).textTheme.headline4,
),
Text(
'$_counter',
style: Theme.of(context).textTheme.headline4,
),
],
The Project and System Encoding are set to UTF-8.
Result:
question from:
https://stackoverflow.com/questions/65856142/flutter-web-persian-arabic-strings-not-showing-properly-on-the-ui 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…