Search code examples
wpfmozilla

Embedded mozilla in WPF application


We are trying to find out , if there is a such possibility (subj). We've found few open source projects , but seems people abandon them.

We need somehow to use Mozilla in our wpf application , why Mozilla , because we have ready plugin for Mozilla , that we need to integrate with application.

Any link to not abandoned open source , is highly appreciated. I am not a developer , i am only translator for our development team that know 0 English , so If I wrote something not readable , please forgive me...


Solution

  • Hi Tatyana and welcome to SO!

    The web rendering engine that powers Mozilla Firefox is currently Gecko.

    If you look for the WPF keywords together with Gecko, you can find some solutions to your problem. The most promising one seems to be GeckoFX, which seems sufficiently easy to use by looking at their documentation. Here's a snippet from their wiki:

    [STAThread]
    static void Main(string[] args)
    {
        Xpcom.Initialize("Firefox");
        var geckoWebBrowser = new GeckoWebBrowser {Dock = DockStyle.Fill};
        Form f = new Form();
        f.Controls.Add(geckoWebBrowser);
        geckoWebBrowser.Navigate("www.google.com");
        Application.Run(f);
    }