Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add screenshot capability #1358

Open
zakhenry opened this issue Sep 9, 2024 · 0 comments
Open

Add screenshot capability #1358

zakhenry opened this issue Sep 9, 2024 · 0 comments

Comments

@zakhenry
Copy link

zakhenry commented Sep 9, 2024

Is your feature request related to a problem? Please describe.
I want to be able to capture screenshots of the webview, specifically from the rust side both for integration testing and as a part of error reporting when the webview is in an untrusted state.

Describe the solution you'd like
On the WebviewWindow, I'd like a method async capture_screenshot() -> Bytes or similar.

Describe alternatives you've considered
It might be possible to have the capture performed by the javascript, though this might be untrustworthy if the webapp is in a broken state.

Additional context
webkit ref: https://developer.apple.com/documentation/webkit/wkwebview/2873260-takesnapshot
chromiumoxide ref: https://docs.rs/chromiumoxide/latest/chromiumoxide/page/struct.Page.html#method.screenshot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants