How to take screenshot of widget beyond the screen in flutter?

后端 未结 3 1230
無奈伤痛
無奈伤痛 2020-12-18 06:17

I am using RepaintBoundary to take the screenshot of the current widget which is a listView. But it only captures the content which is visi

3条回答
  •  萌比男神i
    2020-12-18 06:37

    I achieve the solution of this problem using this package: Screenshot, that takes a screenshot of the entire widget. It's easy and simple, follow the steps on the PubDev or GitHub and you can make it work.

    OBS: To take a full screenshot of the widget make sure that your widget is fully scrollable, and not just a part of it.

    (In my case, i had a ListView inside a Container, and the package doesn't take the screenshot of all ListView because i have many itens on it, SO i have wrap my Container inside a SingleChildScrollView and it works! :D). Screenshot of my screen

    More details in this issue

提交回复
热议问题