4Q-s-r-o / signature

Flutter plugin that creates a canvas for writing down a signature
MIT License
252 stars 83 forks source link

Black area in horizontal screenmode #102

Closed ea-jobvalley closed 4 months ago

ea-jobvalley commented 7 months ago

Hello, I'm implementing a signing feature in Flutter using this nice plugin. Unfortunately I have an issue with a mysterious black area on the screen which only appears in horizontal screen mode. I attached a screenshot of it.

Screenshot 2024-02-06 at 11 51 29

The code of the widgets build method:

Widget build(BuildContext context) {
    final SignatureController signatureController = SignatureController(
      penStrokeWidth: 5,
      penColor: Colors.black,
      exportBackgroundColor: Colors.white,
    );
    final signatureCanvas = Signature(
      controller: signatureController,
      backgroundColor: Colors.debugRed,
    );

    return Scaffold(
      backgroundColor: Colors.white,
      body: Expanded(
        child: signatureCanvas,
      ),
    );
  }

The issue appears on both Android and iOS (devices and simulators).

EDIT: I just replaced "signatureCanvas" with a Container() and the problem still occurs. So I guess it has nothing to do with the plugin.

MartinHlavna commented 4 months ago

I have been unable to reproduce this, so it indeed looks like related to something else rather than plugin.