Is there an embeddable Webkit component for Windows / C# development?

前端 未结 11 1138
南方客
南方客 2020-12-02 04:34

I\'ve seen a few COM controls which wrap the Gecko rendering engine (GeckoFX, as well as the control shipped by Mozilla - mozctlx.dll). Is there a wrapper for Webkit that ca

相关标签:
11条回答
  • 2020-12-02 04:46

    Haven't tried yet but found WebKit.NET on SourceForge. It was moved to GitHub.

    Warning: Not maintained anymore, last commits are from early 2013

    0 讨论(0)
  • 2020-12-02 04:46

    The Windows version of Qt 4 includes both WebKit and classes to create ActiveX components. It probably isn't an ideal solution if you aren't already using Qt though.

    0 讨论(0)
  • 2020-12-02 04:47

    I don't think there is a current one out there, but there is a [barely documented] project on Google Code with an older version...

    0 讨论(0)
  • 2020-12-02 04:49

    There's a WebKit-Sharp component on Mono's GitHub Repository. I can't find any web-viewable documentation on it, and I'm not even sure if it's WinForms or GTK# (can't grab the source from here to check at the moment), but it's probably your best bet, either way.

    0 讨论(0)
  • 2020-12-02 04:50

    There's a WebKit-Sharp component on Mono's Subversion Server. I can't find any web-viewable documentation on it, and I'm not even sure if it's WinForms or GTK# (can't grab the source from here to check at the moment), but it's probably your best bet, either way.

    I think this component is CLI wrapper around webkit for Ubuntu. So this wrapper most likely could be not working on win32

    Try check another variant - project awesomium - wrapper around google project "Chromium" that use webkit. Also awesomium has features like to should interavtive web pages on 3D objects under WPF

    0 讨论(0)
  • 2020-12-02 04:51

    Take a look at the DotNetBrowser library. It provides Chromium-based WPF and WinForms browser controls, which are quite easy to embed into .NET application. It supports all the modern web standards including HTML5, CSS3 and JavaScript. The rendered page looks exactly like in Google Chrome.

    The library inherits Chromium's multi-process architecture – each web page is rendered in a separate Chromium process, and the application will continue working even after plugin crash or any other unexpected error occurs on the web page.

    Here are some other useful features, provided by DotNetBrowser: it is possible to listen to load events, handle network activity, configure proxy, simulate user actions, work with cookies, access and modify DOM, listen to DOM events, call JavaScript from .NET and vice versa, use web camera and microphone on the web page, set up WebRTC-based communication, and more.

    Check out the API Reference for more details.

    The code snippet below demonstrates how to create a BrowserView, embed it into a Form, and load a URL:

    using System.Windows.Forms;
    using DotNetBrowser;
    using DotNetBrowser.WinForms;
    
    namespace WinForms.DotNetBrowser
    {
        public partial class Form1 : Form
        {
            public Form1()
            {
                InitializeComponent();
                BrowserView browserView = new WinFormsBrowserView();
                Controls.Add((Control) browserView);
                browserView.Browser.LoadURL("http://www.youtube.com");
            }
        }
    }
    

    Once you run the example above you will get the following output:

    The library is commercial. Commercial licenses include support packages for different team sizes. It is also possible to purchase the library’s source code.

    Besides its own page the component is available as NuGet package and as VSIX package in the Visual Studio Marketplace.

    0 讨论(0)
提交回复
热议问题