Giter VIP home page Giter VIP logo

Comments (4)

imgurbot12 avatar imgurbot12 commented on July 4, 2024 1

I'm going to close this issue since i ended up going with an alternative solution.

Considering how far downstream the issue ultimately is, as its specific to gtk, i don't think its likely this will change for potentially years even so there seems little value in hoping for an eventual implementation via exposing some method with wry.

It would theoretically be possible via an integration with wgpu using blitz but blitz seems like it would need a ton of enhancements to fully support what I'm hoping to achieve as well.
Thanks for the support :)

lockscreen is complete if anyone's interested!
https://github.com/imgurbot12/dynlock

from dioxus.

ealmloff avatar ealmloff commented on July 4, 2024

I'm not familiar with wayland lock screens, but wry does expose methods to render a webview inside other windows which may be helpful. Dioxus could probably expose an API that allows you to do something similar

from dioxus.

imgurbot12 avatar imgurbot12 commented on July 4, 2024

Thanks for the response. I did actually try using wry directly, unfortunately wry does not yet have support for spawning from an existing window as a child for wayland as of yet.

Wry uses tao, which uses gtk as the backend for their windows on wayland and according to their documentation and examples it doesn't seem possible. quoted from those docs:
If you want to support X11 and Wayland at the same time, we recommend using WebViewExtUnix::new_gtk or WebViewBuilderExtUnix::new_gtk with gtk::Fixed.
their examples integrating with other renderers seems to confirm this as well
https://github.com/tauri-apps/wry/blob/dev/examples/wgpu.rs#L205
https://github.com/tauri-apps/wry/blob/dev/examples/winit.rs#L25

i assume gtk doesn't have the support for using a foreign surface anymore in gtk4 since it appears the exact sort of call i needed has been removed since the transition from gtk3: https://gitlab.gnome.org/GNOME/gtk/-/issues/2132

from dioxus.

imgurbot12 avatar imgurbot12 commented on July 4, 2024

I've unfortunately given up on the idea for the moment and have opted to use iced instead since I can integrate it directly with wgpu which thankfully can use a foreign surface.
https://github.com/Smithay/client-toolkit/blob/master/examples/wgpu.rs#L64

though this means I have to implement my own rendering backend for iced since im not using it through winit which comes with a lot of the extras needed for doing it easily.

I'd be happy to come back to it if there was some other way which is why I've reached out and asked as an issue lol.

from dioxus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.