-
Notifications
You must be signed in to change notification settings - Fork 176
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
Attach to a parent window? #283
Comments
I'm reopening this because we don't have a ticket for this yet.. |
Just to add on usecases. I have an "old" application in Qt with two QtWebViews managed by that application – its basically just a convenience for managing two browser windows for the user for managing multiple accounts etc. But maintaining and deploying this application for Linux/macOS/Win is quite labor intense(Qt by itself and the Webview with openssl dependencies etc.) and i would love to replace it with something like fltk-rs and two embedded web-views. Would love if this could work like the embedded VLC example as an additional inspiration. |
Also adding @mikesoylu to the thread who may be able to provide comment (he forked @vanderlokken's code to work with MacOS). |
If i am not fully mistaken the underlying c-lib should already support that, no? https://raw.githubusercontent.com/zserge/webview/master/webview.h // Creates a new webview instance. If debug is non-zero - developer tools will
// be enabled (if the platform supports them). Window parameter can be a
// pointer to the native window handle. If it's non-null - then child WebView
// is embedded into the given parent window. Otherwise a new window is created.
// Depending on the platform, a GtkWindow, NSWindow or HWND pointer can be
// passed here.
WEBVIEW_API webview_t webview_create(int debug, void *window); i tried digging through the code a little bit with EDIT: EDIT2: and this https://github.com/webview/webview/blob/0.1.0/webview.h looks quite similar to the current implementation of |
Hi was able to do it with cocoa(just for some apple specific stuff) and webview-sys. Relevant code can be found here in the fork: mikesoylu/rust-vst-gui@3b56730#diff-7ea3d8f419ddb71f86b7e524c1c7025cf92f1b46ad6457e505795209408f67f1 |
I've done this but for a C++ plugins framework here. I don't know Rust but it should be possible to extract the webview classes and write a wrapper. The classes were written from scratch with all the plugin specifics in mind: no statics, no link to GUI toolkits, etc. This reverb plugin has a webview based UI. |
Hi! Any updates on this? It would be extremely helpful for writing UI in games :) |
In the audio production world, developers can build VST plugins. These plugins can have GUI's but need to attach the GUI to an externally managed window.
Is it possible to add a feature to this library to allow such functionality?
For example, here's a rust crate for vst gui's that opens a web view and attaches it to a parent window:
https://github.com/vanderlokken/rust-vst-gui/blob/c71ca8df17bbfb2b109aa72ffc05bbf56e3aeadd/src/lib.rs#L56
Here's the maintaners thoughts on using this library for cross-browser support:
vanderlokken/rust-vst-gui#8 (comment)
EDIT
ACK! This has already been mentioned in the Readme! So Sorry!
The text was updated successfully, but these errors were encountered: