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

[SuperEditor][Android] Fix magnified area (Resolves #1957) #1990

Merged
merged 1 commit into from
May 13, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1750,11 +1750,7 @@ class SuperEditorAndroidControlsOverlayManagerState extends State<SuperEditorAnd
child: AndroidMagnifyingGlass(
key: magnifierKey,
magnificationScale: 1.5,
// In theory, the offsetFromFocalPoint should either be `-150` to match the actual
// offset, or it should be `-150 / magnificationLevel`. Neither of those align the
// focal point correctly. The following offset was found empirically to give the
// desired results, no matter how high the magnification.
offsetFromFocalPoint: const Offset(0, -58),
offsetFromFocalPoint: Offset(0, -150 / MediaQuery.devicePixelRatioOf(context)),
),
),
);
Expand Down
Loading