Skip to content

Automatic Flow Direction Change for Arabic Strings in When Drawing the String in MAUI on Android and Opposite Behavior in Windows. #17323

@ghost

Description

Description

In .NET MAUI, when drawing a string, Arabic strings undergo an automatic flow direction alteration. However, the Windows platform demonstrates different behavior when using the DrawString method from the canvas. This inconsistency interferes with the desired rendering of Arabic text when we manage the custom control coordinates for RTL and LTR internally, and it adversely affects the user experience.

Note: My device language is in LTR.

ArabicIssue.mp4

Is there any way to detect the language as RTL or LTR from string type property?

Steps to Reproduce

Step 1: Create a sample in .NET MAUI
Step 2: Develop a custom control that utilizes the DrawString method from the canvas.
Step 3: Pass an Arabic string as the text to be drawn.
Step 4: Execute the application on Android and Windows devices.

Link to public reproduction project repository

https://github.com/anandhan-rajagopal/RTLLanguageSample/tree/main

Version with bug

7.0.92

Is this a regression from previous behavior?

Not sure, did not test other versions

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

Android 5.0 and above

Did you find any workaround?

NA

Relevant log output

NA

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-localizationLocalization and globalization issuespartner/syncfusionIssues / PR's with Syncfusion collaborationplatform/androids/triagedIssue has been revieweds/verifiedVerified / Reproducible Issue ready for Engineering Triaget/bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions