Bumblebee
Bumblebee

Reputation: 33

Localization support in Flutter

In my Flutter application, I have added support for English, Arabic, and Chinese languages. I am showing these three text widgets inside a List View. I would like to display Arabic language text only in RTL mode(Without Directionality widget). Any suggestions on this?

Actual output:

Actual output

Expected output

enter image description here

Upvotes: 0

Views: 773

Answers (1)

Mohammed Alfateh
Mohammed Alfateh

Reputation: 3514

You can make the text widget position fixed either by wrapping it with Align widget

        Align(
          alignment: Alignment.centerRight,
          child: Text(
            'عربى',
          ),
        ),

Or change the textAlign property

        Text(
          'عربى',
          textAlign: TextAlign.right,
        ),

Upvotes: 3

Related Questions