Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[Bug] iOS Label text alignment in RTL when mixing English/Arabic & LineHeight #12473

Closed
darrabam opened this issue Oct 13, 2020 · 1 comment · Fixed by #13197
Closed

[Bug] iOS Label text alignment in RTL when mixing English/Arabic & LineHeight #12473

darrabam opened this issue Oct 13, 2020 · 1 comment · Fixed by #13197

Comments

@darrabam
Copy link

darrabam commented Oct 13, 2020

Description

Arabic text alignment randomly becomes incorrect for some items in the collection if an item in the collection has mixture of Arabic and English alphabets AND LineHeight attribute is set for the label.

I tried to narrow it down and this is my observation:

  • If all items in the collection contain only Arabic alphabets, this issue doesn't appear.
  • If there are some items with mixture Arabic and English alphabets, but LineHeight is NOT set, also the items appear fine.

I believe this issue is related to #9795

Basic Information

  • IDE: VS Community 2019-16.7.4
  • Platform Target Frameworks
    • iOS: 14.0
  • Nuget Packages: XF: 4.8.0.1534 or 5.0.0.1558-pre3 , Essentials: 1.5.3.2
  • Affected Devices: iOS simulator

Screenshots

ezgif com-gif-maker (1)

Reproduction Link

Simple project is available in: https://github.com/darrabam/LabelAlignmentRTLBug

@darrabam darrabam added s/unverified New report that has yet to be verified t/bug 🐛 labels Oct 13, 2020
@samhouts samhouts added this to New in Triage Oct 13, 2020
@rachelkang rachelkang added a/collectionview a/label a/rtl e/3 🕒 3 and removed s/unverified New report that has yet to be verified labels Oct 13, 2020
@rachelkang rachelkang moved this from New to Ready For Work in Triage Oct 13, 2020
@darrabam
Copy link
Author

@rachelkang This is not related to collectionvew, simply placing labels in a stackedlayout and setting the LineHeight attribute will show the bug.
image

@samhouts samhouts added this to To do in Other Ready For Work Nov 3, 2020
@samhouts samhouts removed this from Ready For Work in Triage Nov 3, 2020
@rachelkang rachelkang self-assigned this Dec 18, 2020
Other Ready For Work automation moved this from To do to Done Jan 27, 2021
rmarinho pushed a commit that referenced this issue Jan 27, 2021
…3311 fixes #12473 fixes #8157

* Add Issue3311.cs

* Update Issue331.cs test file

* Fix RTL issue on FormattedText

* Add relevant RTL FormattedText test

* Update Issue3311.cs

* Add Issue12473

* Add BackgroundColor to test labels for clarit

* Add LabelTest for RTL Label with LineHeight

* Add missing closing EmbeddedResource tag

* Remove UITest template code

* Update RTL tests to be more thorough

* UpdateHorizontalTextAlignment on UpdateFormattedText

Fix RTL issue that arises when certain text properties are set on a Label w/ RTL and FormattedText (i.e. FontAttributes, FontSize, LineHeight, TextColor, TextTransform, etc)

* Remove TextType from tests

TextType on FormattedText labels causes app crash. This separate issue will be fixed in a follow-up PR
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Development

Successfully merging a pull request may close this issue.

2 participants