Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed the Label not sized correctly on Android #28215

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

Ahamed-Ali
Copy link
Contributor

Root Cause of the issue

  • The label size measurement is incorrect in Android due to inaccurate width calculations from the native TextView. This can cause the TextView to occupy more width than necessary.

Description of Change

  • Calculate widthMeasureSpec using the maximum line width from the Layout to improve text measurement accuracy and prevent unnecessary space usage.

Issues Fixed

Fixes #27614

Tested the behaviour in the following platforms

  • Android
  • Windows
  • iOS
  • Mac

Screenshot

Before Issue Fix After Issue Fix
LabelIssue.mov
LabelFix.mov

@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Mar 6, 2025
Copy link
Contributor

Hey there @Ahamed-Ali! Thank you so much for your PR! Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@dotnet-policy-service dotnet-policy-service bot added the partner/syncfusion Issues / PR's with Syncfusion collaboration label Mar 6, 2025
@jsuarezruiz
Copy link
Contributor

/azp run

Copy link

Azure Pipelines successfully started running 3 pipeline(s).

{
App.WaitForElement("EndButton");
App.Tap("EndButton");
VerifyScreenshot();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pending snapshots on Mac and Windows. Running a build.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Snapshots were added for Windows, but the Mac image was not generated due to the build being canceled. @jsuarezruiz

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-controls-label Label, Span community ✨ Community Contribution partner/syncfusion Issues / PR's with Syncfusion collaboration platform/android 🤖
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Label not sized correctly on Android
2 participants