jinshil / blazorwebview Goto Github PK
View Code? Open in Web Editor NEWA WebKitGtk WebView for running Blazor Hybrid applications.
License: Apache License 2.0
A WebKitGtk WebView for running Blazor Hybrid applications.
License: Apache License 2.0
I hope this is not off-base, but I wonder if you'd consider adding support for Windows and/or macOS? Currently we have no single BlazorWebView solution working across all 3 platforms.
What's the project status? Do we expect to see a nuget package for it in near future?
Does the underlying WebKitGTK provide an on-screen keyboard, or would the application need to provide its own? I'd be interested in whether BlazorWebView would work for a touchscreen embedded device.
Is it possible to run this project on Windows? (Because it seems to be based on Gtk)
Is there any guidance or pattern we should follow with respect to opening and managing child windows? Is this supported?
https://github.com/tryphotino/photino.Blazor
Photino is a lightweight open-source framework for building native,
cross-platform desktop applications with Web UI technology.
Photino.Blazor builds on Photino.NET to add Blazor capabilities.
Photino uses the OSs built-in WebKit-based browser control for Windows, macOS and Linux. Photino is the lightest cross-platform framework. Compared to Electron, a Photino app is up to 110 times smaller! And it uses far less system memory too!
Hi,
I tried your project on a current fedora 38 with dotnet 6 / 7 installed. Unfortunately it did not work out. It looks like the code in GtkSharp is hard coding an old webkitgtk library.
Unhandled exception. System.TypeInitializationException: The type initializer for 'WebKit.WebView' threw an exception.
---> System.DllNotFoundException: Webkit: libwebkit2gtk-4.0.dll, libwebkit2gtk-4.0.so.37, libwebkit2gtk-4.0.dylib, libwebkit2gtk-4.0.0.dll
at GLibrary.Load(Library library)
at WebKit.WebView..cctor()
As this project looks quite interesting, I wonder what your thoughts are in regard to base it on Gir.Core? Gir.Core supports Gtk4 and current WebKitGtk versions. It follows the binaries inside the current gnome Flatpak SDK. This allows to create Flatpaks which can be distributed via Flathub.
But the project and API is not complete or guaranteed to be stable, so it is quite possible that the APIs you are relying on are not yet generated or are even not supported anymore as there was some API break on WebKitGTK side.
As I'm actively working on Gir.Core, I would be interested in making the needed API available to you.
I created a small issue on my side gircore/gir.core#931 to keep your project in my mind in case you are not interested as I think it could benefit a lot of users. If you like, the project could even be part of Gir.Core itself as it looks like that not much code is needed maintenance wise.
Exception has occurred: CLR/System.DllNotFoundException
An unhandled exception of type 'System.DllNotFoundException' occurred in Gtk-4.0.dll: 'Unable to load shared library 'libgtk-4.so.1' or one of its dependencies. In order to help diagnose loading problems, consider using a tool like strace. If you're using glibc, consider setting the LD_DEBUG environment variable:
/snap/dotnet-sdk/236/shared/Microsoft.NETCore.App/8.0.2/libgtk-4.so.1: cannot open shared object file: No such file or directory
/mnt/d/Development/Visual Studio Projects/BlazorWebView/WebKitGtk.Test/bin/Debug/net8.0/libgtk-4.so.1: cannot open shared object file: No such file or directory
/snap/core20/current/lib/x86_64-linux-gnu/libc.so.6: version GLIBC_2.33' not found (required by /lib/x86_64-linux-gnu/libgtk-4.so.1) /snap/dotnet-sdk/236/shared/Microsoft.NETCore.App/8.0.2/liblibgtk-4.so.1: cannot open shared object file: No such file or directory /mnt/d/Development/Visual Studio Projects/BlazorWebView/WebKitGtk.Test/bin/Debug/net8.0/liblibgtk-4.so.1: cannot open shared object file: No such file or directory /snap/dotnet-sdk/236/shared/Microsoft.NETCore.App/8.0.2/libgtk-4.so.1.so: cannot open shared object file: No such file or directory /mnt/d/Development/Visual Studio Projects/BlazorWebView/WebKitGtk.Test/bin/Debug/net8.0/libgtk-4.so.1.so: cannot open shared object file: No such file or directory /snap/dotnet-sdk/236/shared/Microsoft.NETCore.App/8.0.2/liblibgtk-4.so.1.so: cannot open shared object file: No such file or directory /mnt/d/Development/Visual Studio Projects/BlazorWebView/WebKitGtk.Test/bin/Debug/net8.0/liblibgtk-4.so.1.so: cannot open shared object file: No such file or directory' at System.Runtime.InteropServices.NativeLibrary.<LoadByName>g____PInvoke|2_0(UInt16* __libraryName_native, QCallAssembly __callingAssembly_native, Int32 __hasDllImportSearchPathFlag_native, UInt32 __dllImportSearchPathFlag_native, Int32 __throwOnError_native) at Gtk.Internal.ImportResolver.Resolve(String libraryName, Assembly assembly, Nullable
1 searchPath)
at System.Runtime.InteropServices.NativeLibrary.LoadLibraryCallbackStub(String libraryName, Assembly assembly, Boolean hasDllImportSearchPathFlags, UInt32 dllImportSearchPathFlags)
at Gtk.Internal.Functions.Init()
at Gtk.Module.Initialize()
at WebKit.Module.Initialize()
at Program.Main(String[] args) in /mnt/d/Development/Visual Studio Projects/BlazorWebView/WebKitGtk.Test/Program.cs:line 12
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.