Skip to content

Conversation

@SriRadheshNagS
Copy link
Collaborator

@SriRadheshNagS SriRadheshNagS commented Jul 1, 2025

Root Cause of the Issue

When StrokeThickness is zero, the totalwidth is equal to maxWidth. So the keyFocusedViewPadding is not reduced from the maxWidth. This causes the segmented control to get cut.

This behavior causes:
Value is added with the keypadding causing the control to get cropped.

Description of Change

Added the keypadding to the totalwidth before comparing with the max width.

Issues Fixed

Fix : 189
Prevents the extra padding and renders within the given width

Output screenshots:

Before changes:

Windows

Windowsissue

Android
androidissue

Mac
macissue

iOS
iosissue

After changes:

Windows
windowsfix

Android
androidfix

Mac
macfix

iOS
iosfix

Copy link
Collaborator

@saiganesh-sakthivel saiganesh-sakthivel left a comment

Choose a reason for hiding this comment

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

fine

@PaulAndersonS
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@PaulAndersonS PaulAndersonS merged commit c88b814 into main Jul 4, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Segmented Control wrong size

5 participants