Skip to content
Discussion options

You must be logged in to vote

Got it. To do that, set up a callback where you update the required scale factor directly in onInit, like this:

ProImageEditorCallbacks(
  cropRotateEditorCallbacks: CropRotateEditorCallbacks(
    onInit: () {
      final editor = editorKey.currentState!;

      /// Use the image size to calculate the required scale factor.
      final imageSize = editor.sizesManager.decodedImageSize;

      final cropEditor = editor.cropRotateEditor.currentState!;
      cropEditor.setScale(2);
    },
  ),
);

In that example, I just set the scale factor to 2, but you'll need to calculate it based on your image size. Also, make sure to update to version 11.15.0, as I added the setScale method in that release.

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@yangheecho
Comment options

@hm21
Comment options

hm21 Dec 18, 2025
Maintainer

Answer selected by yangheecho
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants