Skip to content

CursorPosition not calculated correctly on behaviors events for iOS devices#32688

Closed
KarthikRajaKalaimani wants to merge 3 commits intodotnet:mainfrom
KarthikRajaKalaimani:fix-32483
Closed

CursorPosition not calculated correctly on behaviors events for iOS devices#32688
KarthikRajaKalaimani wants to merge 3 commits intodotnet:mainfrom
KarthikRajaKalaimani:fix-32483

Conversation

@KarthikRajaKalaimani
Copy link
Copy Markdown
Contributor

Issue Details:

The CursorPosition property value is not calculated correctly on TextChanged event of the Entry in iOS platform but it calculated correctly in Android platform.

Root Cause:

Analysed the issue how it works in android platform, then saw that when enter text on entry, the selectionchanged event is triggered from native level and we updated the VirtualView.CursorPosition by getting the cursorposition of native platformview on SelectionChanged event. So, it works fine in android platform. Then checked in iOS platform, the SelectionChanged event is not triggered from iOS when enter text on entry.

Description of Change:

I retrieved the cursor position using platformView.GetCursorPosition() and assigned it to VirtualView.CursorPosition in the OnEditingChanged event within EntryHandler.iOS.cs.

Tested the behavior in the following platforms.

  • Android
  • Windows
  • iOS
  • Mac

Reference:

N/A

Issues Fixed:

Fixes #32483

Screenshots

Before After
Screen.Recording.2025-11-18.at.1.13.54.PM.mov
Screen.Recording.2025-11-18.at.1.12.06.PM.mov

@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Nov 18, 2025
@dotnet-policy-service
Copy link
Copy Markdown
Contributor

Hey there @@KarthikRajaKalaimani! 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 Nov 18, 2025
@sheiksyedm
Copy link
Copy Markdown
Contributor

This is duplicate fix by below one
#30505

@github-actions github-actions bot locked and limited conversation to collaborators Dec 19, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

community ✨ Community Contribution partner/syncfusion Issues / PR's with Syncfusion collaboration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CursorPosition not calculated correctly on behaviors events for iOS devices

3 participants