Skip to content

Conversation

@Samo8
Copy link
Contributor

@Samo8 Samo8 commented Jan 14, 2026

Adding support for Projection

Fixes #330

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I signed the CLA.
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation
  • I added new tests to check the change I am making
  • All existing and new tests are passing.

@Samo8
Copy link
Contributor Author

Samo8 commented Jan 14, 2026

@jokerttu There is small issue with android.graphics.Point (docs). Unfortunately coordinates are integers not decimal. This can cause small deviations because there is some rounding done.
I didn't find some solution that will make this work with 100% accuracy.

On iOS it's fine because iOS API has decimals.
Thanks.

@jokerttu jokerttu changed the title feat: projection feat: support map projection between screen and geographic coordinates Jan 15, 2026
@jokerttu jokerttu changed the title feat: support map projection between screen and geographic coordinates feat: support map projection between view and geographic coordinates Jan 15, 2026

_lastScreenCoordinate = screenCoord;

_coordinateInfo = '''
Copy link
Contributor

@illuminati1911 illuminati1911 Jan 26, 2026

Choose a reason for hiding this comment

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

I would personally maybe prefer to have small labels on top of the map that show both coordinates constantly instead of this kind of a popup that opens/closes and changes it's text content. Easier to test and takes up less screen space.

That being said this is just personal preference and I don't think change here is really necessary. It's example app at the end of they day and it works well. Just something to think about.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updated

Copy link
Contributor

@illuminati1911 illuminati1911 left a comment

Choose a reason for hiding this comment

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

Looks pretty good to me all around. Please add some integration tests and then it should be good to go. 👍

@Samo8
Copy link
Contributor Author

Samo8 commented Feb 2, 2026

Looks pretty good to me all around. Please add some integration tests and then it should be good to go. 👍

Added integration tests, updated example. Thanks.

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.

[Feature request]: ScreenCoordinate getScreenCoordinate(LatLng)

3 participants