.NET bindings for the Chromium Embedded Framework.
- Managed wrapper for the complete CEF API
- Remote wrapper to access DOM and V8 in the render process from the browser process
- Windows Forms control based on ChromiumFX
- Project Setup and Description
- Getting started with the Browser Control
- Getting started with the Remoting Framework
- API Reference
- Binary releases
The API of this project is not frozen and is subject to change. The overall structure will be kept though.
ChromiumFX version numbers have the format X.Y.Z where X is the CEF version (currently 3), Y is the CEF branch and Z is the ChromiumFX release number for a specific CEF version and branch.
A list of CEF versions known to work with each ChromiumFX version will be maintained in CefVersion.txt.
CEF binary packages are available for download at:
At startup, API compatibility is verified by checking the API hash of the loaded libcef.dll, making sure ChromiumFX fails early when loading incompatible CEF binaries.
ChromiumFX exposes the following methods for querying version information:
Licensing and Credits
ChromiumFX is BSD licensed. The CEF project is BSD licensed. Please visit
"about:credits" in a CEF-based application for complete Chromium and third-party
licensing information. See also cef/LICENSE.txt and cef/README.txt.
This is a summary of the most important changes and those relevant to embedders (API changes etc.).
- Fix Issue
#196(CfrTime.ToUniversalTime must be static).
- Update to CEF 3.3578.1860 with API changes.
- Fixed issue
- Update to CEF 3.3440.1806 with API changes.
- Improvements to the generator tool, including fix for issue
- Update to CEF 3.3239.1723 with API changes.
- Native library libcfx was retargeted to the default platform/toolset for Visual Studio 2017. Since libcfx is statically linked, this has no effect for distribution of ChromiumFX. If you can't install the required toolset, you can backout commit «Retarget libcfx».
- Fixed issue
- Update to CEF 3.3202.1678 with API changes.
- Update to CEF 3.3163.1670 with API changes.
- Update to CEF 3.3071.1644 with minor API changes.
- Removed an erroneous line of code introduced when trying to reproduce an issue. Sorry for that.
- Update to CEF 3.3071.1634 with API changes.
- Implemented a new method to retrieve the ChromiumWebBrowser object for a given CfxBrowser object.
- Update to CEF 3.3029.1619 with API changes.
- Implemented plausibility checks in the remote layer
- Implemented faster pipe stream handling for remote layer.
- Miscellaneous fixes and improvements.
- Update to CEF 3.2987.1601 without API changes.
- Fixed exception handling in remote connection.
- Fixed typo.
- CfxTask and CfrTask lifetime management is now based on CEF reference counting instead of bookkeeping with hash sets.
- Fixed some issues (see pull request #3 and
- Cleanups and improvements.
- Starting from this release, CfxTask and CfrTask objects are kept alive internally from the moment they are submitted to (Cfx|Cfr)TaskRunner.PostTask or PostDelayedTast until the Execute callback event is called, so it's not necessary anymore to keep a explicit reference in the client application.
- Update to CEF 3.2987.1596 with API changes.
- CEF introduced a new basetype cef_base_scoped_t. ChromiumFX was updated to reflect this change and implement the intended funcionality. For now, CfxSchemeRegistrar is the only class to inherit from CfxBaseScoped.
- There is an issue with the 64-bit version, see issue
- Update to CEF 3.2924.1569 with API changes.
- The parser in the generator tool had a rewrite. The new version detected some boolean parameters and 2 functions the previous version missed.
- Update to CEF 3.2883.1552 with API changes.
- Update to CEF 3.2883.1540 with API changes.
- Refactored the remote client callback interface to call directly into the pinvoke api in the render process, removing another layer of bookkeeping.
- Miscellaneous fixes and improvements.
- Fixed a case-folding collision in generated files.
- Update to CEF 3.2840.1515 with API changes.
- CEF now implements V8 Interceptors.
- The signatures of CfxV8Context.Eval and CfxV8Value.CreateObject have changed and must be updated in client applications.
- Update to CEF 3.2785.1485 with API changes.
- Added some methods and validations.
- Update to CEF 3.2785.1481 without API changes.
- CfxWindowInfo can now be created as disabled child window (see CfxWindowInfo.SetAsDisabledChild). This helps preventing CEF from taking the focus for a webpage when a browser is created offscreen.
- A cache was preventing ChromiumWebBrowser objects from being collected. This has been fixed with a weak reference cache. Embedders can now let browser objects go out of scope and the associated cef resources and render process will be released automatically.
- The remote layer now calls directly into the pinvoke api in the render process, removing one layer of bookkeeping. This applies to library calls, client callback still relay on the managed layer in the render process.
- Parameters of type size_t are now correctly marshaled as UIntPtr in the pinvoke layer and then translated into ulong in the public layer.
- Update to CEF 3.2743.1442 with API changes.
- Some fixes and updates in sample code.
- Update to CEF 3.2704.1434 with API changes.
- CEF has a new "Views" API. ChromiumFX does not yet implement that new API.
- Fix a bug which prevented the usage of the exception parameter in the V8 handler callback (see issue
- Do not throw an exception in the render process if the RPC connection gets lost. Allows the render process to exit gracefully when the browser process gets killed.
- This is a backport of ChromiumFX 3.2623.1 for the 3.2526 branch. 3.2623 is broken (see issue
- Updated to CEF 3.2623.1395, with CEF API changes.
- The WebResource facility has a new constructor with image format information.
- ChromiumWebBrowser has new CreateBrowser overloads with initial url parameters.
- Some issues were fixed, specially for the built-in find toolbar.
- As of this version, no more binaries in the download section. ChromiumFX builds out of the box with VS 2015 Community.
- The CEF client callback events with automatic UI thread invocation were deprecated. In some callbacks, CEF expects the callback arguments to be accessed exclusively from the thread performing the callback so the automatic Control.Invoke caused some problems. See also issue
#48. Embedding applications have to manually invoke in order to access UI elements from within a CEF client callback.
- Expose the remote OnV8ContextCreated event handler in the ChromiumWebBrowser control.
- Update to cef version 3.2526.1366 with API changes. Older CEF binaries won't work with this version.
- In the course of update, the CfxDragOperationsMask enumeration was changed and a bug was fixed which caused a wrong conversion of CfxDragOperationsMask.Every.
- Use images for the buttons in the find toolbar because the previously used unicode characters may not be available everywhere.
- Clear previous find results when the find textbox is emptied.
- Fix v8 handler: return true (1) when the exception string is set.
- Update to cef version 3.2526.1359 with API changes.
- Expose the FindHandler through ChromiumWebBrowser.
- Implement a Find Toolbar for the ChromiumWebBrowser Control.
- Use BeginInvoke and Wait instead of Invoke for marshalled render process invokes.
- Update to cef version 3.2454.1344. The CEF API has changed since the last supported version, need updated cef binaries for this release.
- Resolved issue
- Fixed some smaller issues.
- Upgrade to CEF release branch 3.2454. This brings in some CEF API changes.
- All obsolete/deprecated functions have been deleted.
- This is a backport of ChromiumFX 3.2357.5 for the 3.2171 branch.
- This is a bugfix release which addresses issues
#27and #29. The remote proxies of objects living in the render process did not release those objects due to a bug introduced in version 3.2357.3, causing a memory leak.
- This is a backport of ChromiumFX 3.2357.4 for the 3.2171 branch.
- The platform toolset has been changed to v140, development is now done in VS 2015 Community. So in order to build libcef.dll, VS 2015 is required or change the toolset back to v120. The precompiled binaries should continue to work with previous versions of Visual Studio.
- CfxDragHandler.OnDraggableRegionsChanged was fixed.
- The deprecated functions in the remote layer now throw NotSupportedException because they were not reliable any more.
- Internal improvements without API changes and some bug fixes.
- This is a backport of ChromiumFX 3.2357.3 for the 3.2171 branch.
- A 64-bit build is now available at cefbuilds.com for CEF 3.2357.1283 and it's compatible with this version. CEF 3.2357.1281 32-bit is still compatible as well.
- Instead of passing around a CfrRuntime object, the remote layer now uses remote process and thread contexts with thread-local and mostly transparent enter/exit semantics to keep track of remote callbacks. This implied a few changes in the public API of ChromiumFX and a lot of methods are deprecated now and will be deleted in a future release.
- Thanks to the new remote process and thread contexts, Cfr* static methods and constructors now work without passing in a remote runtime object. This allows for some useful features, e.g. implicit conversion from int, double, string and other primitive types to CfrV8Value.
- This is a back port of the current ChromiumFX version. It contains all ChromiumFX features from version 3.2357.2 but targets the CEF 3.2171 API. Besides new features, it contains a lot of important bug fixes so all users of the 3.2171 branch should upgrade.
- Windows 64-bit builds on cefbuilds.com are still hanging so if you want to use this version in 64-bit mode, you have to build your own CEF binaries.
- JSObject now implements IDictionary.
- ChromiumWebBrowser: the global objects for the main frame and other named frames are now exposed through
public JSObject GlobalObjectand
public JSObject GlobalObjectForFrame(string frameName). The previous methods AddGlobalJSProperty, AddGlobalJSFunction and AddGlobalJSObject are deprecated.
- Some camelCase fixes for C# symbols, namely CfxSslCertPrincipal and CfxSslInfo.
- CfxGenerator was converted from VB to C# with some regular expressions, manual rewriting and the SharpDevelop 4.4 code converter.
- Implemented callback event ChromiumWebBrowser.OnRegisterCustomSchemes.
- Some bug fixes.
Version 3.2357.1 Win32
- This is an update based on CEF 3.2357.1280. There was an API change between the previous 3.2357.1 release (based on CEF 3.2357.1274) and this one, and there is no 64-bit build available at cefbuilds.com - 64-bit applications have to stick with the previous version.
- Fixed a race in the ipc layer introduced in 3.2171.15. Just as many concurrency bugs, this one becomes more visible under heavy usage. So basically 3.2171.15 and
3.2357.0 are broken, with a bug causing the render process to freeze under some circumstances.
- Updated to CEF release branch 2357, the newest release branch considered production ready. If you update to this revision, you have to replace all CEF binary and resource files to the latest binary package found at https://cefbuilds.com. And you should test it with your use case to verify that there are no issues.
- As usual, the new release branch brings in a few API changes, see commit 393ad75 for an overview.
- The API reference has been updated to branch 2357 as well.
- Fixed a deadlock in the IPC code which caused the UI freeze after a renderer crash under some circumstances.
- Fixed a null reference bug unwrapping arrays of cef structs.
- Fixed a ref counting bug for arrays of cef structs.
#16resolved; added test code for the use case described in that issue.
WindowStylesenum was renamed to
CfxWindowInfo.Styleproperty type was changed to
CfxRuntime.LoadLibraries()was removed, the native libraries are now loaded transparently. To change locations for native libraries, use the
CfxRuntime.LibCfxDirPathproperties before calling anything else in the Chromium namespaces.
CfxRuntime.ExecuteProcess()now checks transparently if a remote connection is required in the render process.
- The ChromiumWebBrowser control now exposes all client handlers as properties.
- ChromiumFX and ChromiumWebBrowser now support 64-bit CEF binaries. As a consequence, both assemblies are now compiled for platform AnyCPU. See wiki for details about application layouts.
- A small test application for windowless browsing was added here.
CfxRemoting.Initializewas removed, applications now pass their render process startup callback directly through
CfxRuntime.Initialize(CfxSettings, CfxApp, CfxRenderProcessStartupDelegate).
- Some work has been done for linux support, but it's still broken. Issue 9 is tracking this.
Fixed a bug introduced in 3.2171.10: for not refcounted cef types, the pinvoke layer would use the wrong native function as a dtor function, causing memory leaks and possibly corruption. Sorry for that :)
- libcfx.dll now loads libcef.dll function pointers explicitly instead of linking to libcef.lib, removing the link time dependency. This means that ChromiumFX is now compatible with any set of CEF binaries within the same branch.
- As a consequence, ChromiumFX version numbers now have the format X.Y.Z where X is the CEF version (currently 3), Y is the CEF branch and Z is the ChromiumFX release number for a specific CEF version and branch.
- At startup, API compatibility is verified by checking the API hash of the loaded libcef.dll, making sure ChromiumFX fails early when loading incompatible CEF binaries.
- The generator tool now extracts additional information about the public CEF C++ API to help translation of the C API:
- The translation from C int (0/1) to C# bool (false/true) is now based on the signatures found in the C++ header files. This should have fixed the remaining issues with the int to bool translation.
- Some CEF C functions have different names in the CEF C++ API. The C# translation now prefers the C++ names, including overloads like
- ChromiumFX and ChromiumWebBrowser assemblies are now built for platform x86 instead of AnyCPU, so the compiler will complain if you reference them from AnyCPU projects.
- Fixed int to bool conversion for
SetOsModalLoopwas removed from remote layer.
- Moved API delegate instantiation into static initializers of the types they belong to. This reduces work load at startup and avoids the allocation of unnecessary delegates for types never used by an application or secondary processes.
- CEF getter functions for string collections (
cef_string_multimap) are now translated as functions with return value instead of functions with out paramenter. Example:
List<string> CfxBrowser.GetFrameNames(). This affects the public API of several classes.
- Some of the framework callback container classes were not recognized as such by the code generator. This has been fixed.
CfxSchemeHandlerFactoryare now correctly wrapped as framework callbacks.
- Removed browser-only
CfxEndTracingCallbackfrom remote layer.
- Fixed int to bool conversion for
SetBoolfunctions in several classes.
- Removed the
CfxRuntime.ExecuteProcess()functions with sandbox parameter from the public API. Currently there is no way to start this within a sandbox.
- Internally, the callback delegates and native function pointers are now created on demand, reducing the work load at startup. Most applications won't use all callbacks anyway.
- Version information functions added to CfxRuntime.
- The event handler and event arg classes for the framework callback events moved into their own namespaces. If you get errors, add
- A Sandcastle Help File Builder project was added and the xml documentation comments were improved for the new API reference.