-
-
Notifications
You must be signed in to change notification settings - Fork 203
Open
Labels
Description
Package Version
12.0.2
Flutter Version
3.41
Platforms
Android
How to reproduce?
In the cCropRotateEditor, when the image is at the bottom, the top edge of the image is not covered by crop OverlayOpacity
As shown in the picture below, please note that there is a green line at the top, which is the topmost part of the image:

my code:
Widget build(BuildContext context) {
final l10n = context.l10n;
return Theme(
data: AppConfig.darkTheme,
child: Builder(
builder: (context) {
final colorScheme = ColorScheme.of(context);
final backgroundColor = colorScheme.surfaceContainerLowest;
return Scaffold(
backgroundColor: backgroundColor,
body: CropRotateEditor.memory(
key: _cropEditorKey,
widget.imageBytes,
initConfigs: CropRotateEditorInitConfigs(
theme: AppConfig.darkTheme,
configs: ProImageEditorConfigs(
heroTag: 'avatar',
designMode: platformDesignMode,
imageGeneration: const ImageGenerationConfigs(
outputFormat: .png,
pngFilter: .average,
),
cropRotateEditor: CropRotateEditorConfigs(
tools: const [
CropRotateTool.rotate,
CropRotateTool.flip,
CropRotateTool.reset,
],
initialCropMode: CropMode.oval,
initAspectRatio: 1,
desktopCornerDragArea: 0.00000001,
mobileCornerDragArea: 0.00000001,
style: CropRotateEditorStyle(
appBarBackground: Colors.transparent,
appBarColor: colorScheme.onSurface,
helperLineColor: colorScheme.onSurface,
background: backgroundColor,
cropCornerColor: colorScheme.onSurface,
cropOverlayColor: colorScheme.scrim,
bottomBarBackground: Colors.transparent,
bottomBarColor: colorScheme.onSurface,
cropCornerLength: 0,
cropCornerThickness: 0,
cropOverlayOpacity: 1,
cropOverlayInteractionOpacity: 0.45,
),
widgets: CropRotateEditorWidgets(
appBar: (cropRotateEditor, rebuildStream) => null,
bottomBar: (cropRotateEditor, rebuildStream) =>
ReactiveWidget(
stream: rebuildStream,
builder: (_) => Padding(
padding: 4.paddingX,
child: Row(
mainAxisAlignment: .spaceBetween,
children: [
TextButton(
onPressed: () {
context.router.pop();
},
child: Text(l10n.cancel),
),
FilledButton(
onPressed: () {},
style: FilledButton.styleFrom(
visualDensity: .compact,
padding: .zero,
),
child: Text(l10n.save),
),
],
),
),
),
),
),
),
),
),
);
},
),
);
}
Logs (optional)
Example code (optional)
Device Model (optional)
No response
Reactions are currently unavailable