Allow flutter to save widget to image even if widget is offscreen
<!-- Thank you for using Flutter! If you are looking for support, please check out our documentation or consider asking a question on Stack Overflow: * https://flutter.dev/ * https://api.flutter.dev/ * https://stackoverflow.com/questions/tagged/flutter?sort=frequent If you have found a bug or if our documentation doesn't have an answer to what you're looking for, then fill our the template below. Please read our guide to filing a bug first: https://flutter.dev/docs/resources/bug-reports --> When you have an application, sometimes it's important to save widgets as images even if they're not on screen. An example of how this would be necessary: having a customized widget displayed in a thumbnail in the app but you wish to save as an image a full size/full screen version of that same widget. ## Steps to Reproduce <!-- Please tell us exactly how to reproduce the problem you are running into. --> 1. ... Following documentation, use RepaintBoundary with a global key in the widget to save as image. 2. ... Wrap the previous widget in an OffStage widget. 3. ... Try to call RenderRepaintBoundary boundary = _exportLayoutKey.currentContext.findRenderObject(); ui.Image image = await boundary.toImage(); ## Logs <!-- Include the full logs of the commands you are running between the lines with the backticks below. If you are running any "flutter" commands, please include the output of running them with "
Posted by tapizquent on Sep 8, 2019, 8:53 PM
Tags
Related issues
- Some good points here, and I definitely hate the "unalive" movement but like someone else said, it has gone beyond self-censorship to in-...
- It’s hard to take the article seriously when there’s no real discussion about how consciousness is defined and it takes Anthropic’s views...
- you know what i hate?
- > I honestly do not understand why any average person would buy anything else than a macbook today.
- Codex App frequently freezes/stutters on Windows 11 Pro despite sufficient system resources
- Add "Basic" and "Standard" plans
Raise real-world problems, find people facing the same issue, and discuss solutions.3,500 issues0 comments
ux (SaaS)
Some good points here, and I definitely hate the "unalive" movement but like someone else said, it has gone beyond self-censorship to in-...
It’s hard to take the article seriously when there’s no real discussion about how consciousness is defined and it takes Anthropic’s views...
you know what i hate?
> I honestly do not understand why any average person would buy anything else than a macbook today.
Codex App frequently freezes/stutters on Windows 11 Pro despite sufficient system resources
Add "Basic" and "Standard" plans
FEATURE: Multi-window support in Claude Code Desktop
Hi HN I built CookPal to solve a small but annoying problem for myself: I kept saving recipes from websites, TikTok, YouTube, and Instag...
Allow flutter to save widget to image even if widget is offscreen
<!-- Thank you for using Flutter! If you are looking for support, please check out our documentation or consider asking a question on Stack Overflow: * https://flutter.dev/ * https://api.flutter.dev/ * https://stackoverflow.com/questions/tagged/flutter?sort=frequent If you have found a bug or if our documentation doesn't have an answer to what you're looking for, then fill our the template below. Please read our guide to filing a bug first: https://flutter.dev/docs/resources/bug-reports --> When you have an application, sometimes it's important to save widgets as images even if they're not on screen. An example of how this would be necessary: having a customized widget displayed in a thumbnail in the app but you wish to save as an image a full size/full screen version of that same widget. ## Steps to Reproduce <!-- Please tell us exactly how to reproduce the problem you are running into. --> 1. ... Following documentation, use RepaintBoundary with a global key in the widget to save as image. 2. ... Wrap the previous widget in an OffStage widget. 3. ... Try to call RenderRepaintBoundary boundary = _exportLayoutKey.currentContext.findRenderObject(); ui.Image image = await boundary.toImage(); ## Logs <!-- Include the full logs of the commands you are running between the lines with the backticks below. If you are running any "flutter" commands, please include the output of running them with "
Comments (0)
No comments yet. Start the discussion.