
CefSharp – Embedded Chromium for .NET - tilt
https://github.com/cefsharp/CefSharp
======
andzt
Awesomium is also an excellent product I've used before to embed the chromium
engine in WinForms and WPF apps...

[http://www.awesomium.com/](http://www.awesomium.com/)

~~~
bradgessler
I can only recommend _against_ Awesomium. Their library has a lot of bugs
which I can see past, but the way they support their product is repulsive. On
average it took them 3-5 days to get back to us on a email ticket with a half-
baked response that then took another 3-5 days to clarify. The founder didn't
seem phased that this was a problem and had zero empathy that we had deadlines
to meet and software to ship.

We ended up ripping out Awesomium from our product and replaced it with
CefSharp. Now we don't get held up by Awesomiums crappy support because we can
just fix our problems ourselves. We couldn't be happier. That said, it would
be nice if there was commercial support for CefSharp. We have a team of full
time native developers who have to deal with CEF issues that would be nice to
put on somebody else's plate. Anybody know if there is such a thing?

~~~
teh_klev
They make no promises about support even with their Pro edition [0]:

 _We currently do not offer premium, priority support plans for our commercial
licensees. We will announce such plans if they become available in the
future._

So _Caveat emptor_.

[0]: [http://wiki.awesomium.com/licensing/licensing-
overview.html](http://wiki.awesomium.com/licensing/licensing-overview.html)

~~~
jvyduna
I'm bradgessler's cofounder. We were promised support in an email. That
statement about lack of support for paid customers was added after we paid
them and experienced the 3-5 day turnaround times. As I recall, the tickets
were mostly us reporting defects.

~~~
teh_klev
Ah, ok...not so good.

------
zamalek
> C++/CLI

Pity that: means it won't even compile on other platforms. It's always better
to make a pure extern "C" wrapper around the C++ library that you are using
and P/Invoke that from the CLR.

Furthermore, I work on a roughly 1MLOC C++/CLI codebase daily. Their one is
"small" and, trust me, they had better hope it stays that way. C++ is a great
language, CLI is great runtime, mix the two and you're going to have something
that approaches damn near zero maintainability.

------
Stratoscope
I've done a fair amount of work with CEF (the native version, not CefSharp),
Awesomium, Coherent UI, and the native WinForms WebBrowser control.

If you are targeting Windows and don't need features that are specific to
Chromium, I recommend the WebBrowser control above the others, because it will
save you quite a bit of file size in your application, along with less memory
usage.

Unfortunately, the WebBrowser control defaults to an IE7 compatibility mode,
which is where it's gotten much of its bad reputation. However, you _can_
force it into IE11 mode, assuming that the user's machine does have IE11
installed. (And if you are producing a Windows app, customers who have refused
to update their systems to IE11 are probably customers not worth supporting.)

Oddly enough, there is no API to do this. You have to write a value to the
registry listing your .exe filename and the IE version you want to use. But
this value is in HKEY_CURRENT_USER, so you don't need administrator privileges
or a UAC prompt to do this.

WebBrowser also sends an IE7 UserAgent string by default, but you can easily
override that.

I posted the code for both of these tweaks in the MarkdownPad forum, where I
was encouraging the author to use the WebBrowser control instead of Awesomium
which the product currently uses:

[http://forums.apricitysoftware.com/t/why-is-markdownpad-
spaw...](http://forums.apricitysoftware.com/t/why-is-markdownpad-
spawning-3-instances-of-awesomiumprocess-exe/172)

(Friends at Awesomium, don't take offense! I just think WebBrowser is a better
match for MarkdownPad, since it doesn't need Chromium features and IE11
compatibility would be plenty good for their needs. They actually used the
WebBrowser originally but switched to Awesomium because the author didn't know
how to force WebBrowser into IE11 mode!)

The problem I have with both Awesomium and Coherent UI, besides the large file
size, is that they are both stuck on old versions of Chromium: IIRC Coherent
is somewhere around Chromium 31 and Awesomium is in the upper 20's. (Sounds
like there is a new version coming out though.) CEF keeps much more up to date
on the Chromium versions; not sure about CefSharp.

Coherent has nice integrations for Unity and Unreal Engine, including hardware
acceleration, which was a real problem when I tried to integrate CEF into
Unity a year ago. (This has no doubt been resolved by now, but at the time
Chromium was going through a restructuring of the hardware rendering pipeline
and CEF just bailed out on it for a while.)

I did a fun little project with Awesomium (originally for the late great
OnLive) that composited multiple WebViews transparently on top of each other
so each one ran in its own thread. Kind of like stacking transparent iframes
but without the single-thread limitation:

[https://github.com/geary/awestack](https://github.com/geary/awestack)

~~~
stoyannk
We're releasing a major upgrade to Coherent UI that is already in Beta and
that version is based on chromium 40+. All the new features are available -
[http://coherent-labs.com/news/a-major-update-of-coherent-
ui-...](http://coherent-labs.com/news/a-major-update-of-coherent-ui-is-now-in-
open-beta-featuring-newer-version-of-chromium/). We try roll new versions
every 2 weeks and update the chromium core when there are new significant
features that we feel will benefit our users.

------
mnkypete
Alternative, which works pretty well:
[http://xilium.bitbucket.org/cefglue/](http://xilium.bitbucket.org/cefglue/)

------
stoyannk
Hi, Stoyan from Coherent Labs here. My impressions of CEF are very good. They
manage to keep it very close to the chromium HEAD, which is great. The only
technical downside of CEF is the imperfect GPU acceleration. In many cases
however the architecture of chromium itself is a hindrance. Their processes
hog memory like crazy and introduce perceivable lag. We had to write a
complete new product to solve the issue for games.

------
pdaddyo
I've been using this for about a year on the Windows version of my social
Spotify client, Soundbounce (www.soundbounce.org). I've been nothing but
impressed with how easy it was to integrate and how well it runs (once you get
over Chrome's memory use), so kudos to the dev team here.

~~~
softawre
Funnily enough, the actual Spotify client uses CEF too. As does Battle.net and
tons of other companies (including my own).

------
jimmcslim
Also worth considering for some folks,
[http://www.openfin.co](http://www.openfin.co) ; although it is commercial and
target at applications in the financial space (trading platforms, charting
apps, risk management, etc) and priced accordingly.

~~~
Hansi
OpenFin doesn't quite solve the same use case but it can if your only UI is
via browser components and the back end is C#. We use OpenFin in that way and
it's a decent product.

~~~
jimmcslim
I'd be interested to hear more about your experience with OpenFin.

------
RachelF
Thanks, this is very useful and a great alternative to embedding IE.

~~~
seanmcdirmid
It is quite nice. I did this demo 6 years ago using chromium and wpf:
[http://blogs.msdn.com/b/sean_mcdirmid/archive/2009/07/27/a-w...](http://blogs.msdn.com/b/sean_mcdirmid/archive/2009/07/27/a-web-
browser-suitable-for-harry-potter-in-wpf.aspx)

It wasn't possible to do with IE.

