Skip to content

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
@dotnet-policy-service
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

@azure-pipelines
Copy link

Azure Pipelines successfully started running 3 pipeline(s).

@jsuarezruiz
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 3 pipeline(s).

@Ahamed-Ali Ahamed-Ali marked this pull request as ready for review March 10, 2025 09:26
@Ahamed-Ali Ahamed-Ali requested a review from a team as a code owner March 10, 2025 09:26
@Ahamed-Ali Ahamed-Ali requested review from PureWeen and rmarinho March 10, 2025 09:26
@dotnet dotnet deleted a comment from azure-pipelines bot Mar 14, 2025
@jsuarezruiz
Copy link
Contributor

/rebase

@jsuarezruiz
Copy link
Contributor

/azp run

@jsuarezruiz jsuarezruiz self-assigned this Mar 14, 2025
@azure-pipelines
Copy link

Azure Pipelines successfully started running 3 pipeline(s).

@jsuarezruiz
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 3 pipeline(s).

@jsuarezruiz
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 3 pipeline(s).

@rmarinho rmarinho added this to the .NET 9 SR6 milestone Mar 28, 2025
@rmarinho rmarinho merged commit 7935165 into dotnet:main Mar 28, 2025
128 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Apr 28, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

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

3 participants