{"id":50436603,"url":"https://github.com/techsenger/ceffx","last_synced_at":"2026-05-31T17:02:30.803Z","repository":{"id":353717659,"uuid":"1220325255","full_name":"techsenger/ceffx","owner":"techsenger","description":"Techsenger CEFFX – A library for integrating the Chromium Embedded Framework into JavaFX.","archived":false,"fork":false,"pushed_at":"2026-05-12T11:27:18.000Z","size":434,"stargazers_count":15,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-05-12T13:28:09.413Z","etag":null,"topics":["browser","cef","chromium","java","javafx","javafx-component","javafx-library"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/techsenger.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS.txt","dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":"techsenger"}},"created_at":"2026-04-24T19:30:07.000Z","updated_at":"2026-05-12T11:27:22.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/techsenger/ceffx","commit_stats":null,"previous_names":["techsenger/ceffx"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/techsenger/ceffx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/techsenger%2Fceffx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/techsenger%2Fceffx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/techsenger%2Fceffx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/techsenger%2Fceffx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/techsenger","download_url":"https://codeload.github.com/techsenger/ceffx/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/techsenger%2Fceffx/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33739861,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-31T02:00:06.040Z","response_time":95,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["browser","cef","chromium","java","javafx","javafx-component","javafx-library"],"created_at":"2026-05-31T17:02:25.959Z","updated_at":"2026-05-31T17:02:30.791Z","avatar_url":"https://github.com/techsenger.png","language":"C++","funding_links":["https://github.com/sponsors/techsenger"],"categories":[],"sub_categories":[],"readme":"# Techsenger CEFFX\n\nTechsenger CEFFX is a library for integrating the Chromium Embedded Framework into JavaFX applications. It is a port\nof [JCEF](https://github.com/chromiumembedded/java-cef) (commit d3de827), migrated from Swing to JavaFX. Designed\nspecifically for JavaFX, CEFFX provides an optimized and efficient solution for working with Chromium on the platform.\n\nCEFFX provides prebuilt native libraries, making it easy to integrate CEF into any JavaFX application without the need\nto compile native code from source.\n\n## Table of Contents\n* [Demo](#demo)\n* [Features](#features)\n* [Related Projects](#projects)\n    * [Chromium](#projects-chromium)\n    * [CEF](#projects-cef)\n    * [JCEF](#projects-jcef)\n* [Dependencies](#dependencies)\n* [Usage](#usage)\n    * [Settings](#usage-settings)\n    * [Threads](#usage-threads)\n    * [Prebuilt Natives](#usage-prebuit-natives)\n* [Code building](#code-building)\n* [Running Demo](#running-demo)\n* [License](#license)\n* [Contributing](#contributing)\n* [Support Us](#support-us)\n\n## Demo \u003ca name=\"demo\"\u003e\u003c/a\u003e\n\n\u003cimg width=\"1200\" height=\"872\" alt=\"Techsenger CEFFX\" src=\"https://github.com/user-attachments/assets/b6b3ee9e-2bb2-4e42-9dd2-d8d3e1294d6a\" /\u003e\n\n## Features \u003ca name=\"features\"\u003e\u003c/a\u003e\n\nKey features include:\n\n* The library uses only JavaFX classes for UI development.\n* Dual-thread architecture — JavaFX thread and a dedicated CEF thread.\n* Supports almost all features of Java CEF.\n* Custom rendering capabilities.\n* A demo application showcasing library features.\n* Comprehensive documentation.\n\n## Related Projects \u003ca name=\"projects\"\u003e\u003c/a\u003e\n\n### Chromium \u003ca name=\"projects-chromium\"\u003e\u003c/a\u003e\n\n[Chromium](https://github.com/chromium/chromium) is an open-source web browser project that serves as the foundation\nfor many modern browsers, including Google Chrome. It provides a full technology stack for rendering web pages,\nincluding the Blink rendering engine, the V8 JavaScript engine, as well as subsystems for networking, graphics, and\nmultimedia. Chromium is developed as a high-performance and secure platform, offering support for modern web standards\nand a rapid release cycle.\n\nAt the same time, Chromium is not a library or an embeddable engine in the traditional sense — it is a full-featured\nbrowser project with a large codebase and a complex architecture. It can be used as a basis for other solutions, but\nit is not typically distributed as a standalone component for direct embedding into applications. For such use cases,\nhigher-level wrappers are commonly used, which adapt its capabilities for integration into third-party applications.\n\n### CEF \u003ca name=\"projects-cef\"\u003e\u003c/a\u003e\n\nThe Chromium Embedded Framework ([CEF](https://github.com/chromiumembedded/cef)) is a simple framework for embedding\nChromium-based browsers in other applications. CEF insulates the user from the underlying Chromium and Blink code\ncomplexity by offering production-quality stable APIs, release branches tracking specific Chromium releases,\nand binary distributions. Most features in CEF have default implementations that provide rich functionality while\nrequiring little or no integration work from the user. There are currently over 100 million installed instances of CEF\naround the world embedded in products from a wide range of companies and industries. Some use cases for CEF include:\n\n* Embedding an HTML5-compliant Web browser control in an existing native application.\n* Creating a light-weight native “shell” application that hosts a user interface developed primarily using Web technologies.\n* Rendering Web content “off-screen” in applications that have their own custom drawing frameworks.\n* Acting as a host for automated testing of existing Web properties and applications.\n\nCEF supports a wide range of programming languages and operating systems and can be easily integrated into both new\nand existing applications. It was designed from the ground up with both performance and ease of use in mind. The base\nframework includes C and C++ programming interfaces exposed via native libraries that insulate the host application\nfrom Chromium and Blink implementation details. It provides close integration between the browser and the host\napplication including support for custom plugins, protocols, JavaScript objects and JavaScript extensions.\nThe host application can optionally control resource loading, navigation, context menus, printing and more, while\ntaking advantage of the same performance and HTML5 technologies available in the Google Chrome Web browser.\n\n### JCEF \u003ca name=\"projects-jcef\"\u003e\u003c/a\u003e\n\nThe Java Chromium Embedded Framework ([JCEF](https://github.com/chromiumembedded/java-cef)) is a simple framework for\nembedding Chromium-based browsers in other applications using the Java programming language. It provides a robust and\nmature API that enables seamless integration of modern web technologies into Java applications, supporting features\nsuch as JavaScript execution, DOM interaction, custom rendering, and fine-grained control over browser behavior.\nBuilt as a Java wrapper around the Chromium Embedded Framework, JCEF allows developers to leverage the power of the\nChromium engine within Java applications.\n\nAt the same time, JCEF is designed around the Swing UI toolkit, which introduces limitations when used in modern\nJava applications that rely on JavaFX. This architectural choice can make integration less efficient and more complex\nin JavaFX-based environments, particularly when aiming for consistent rendering, threading, and UI behavior across\nthe application.\n\n## Dependencies \u003ca name=\"dependencies\"\u003e\u003c/a\u003e\n\nThis project will soon be available on Maven Central:\n\n```\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.techsenger.ceffx\u003c/groupId\u003e\n    \u003cartifactId\u003eceffx-natives\u003c/artifactId\u003e\n    \u003cversion\u003e${ceffx.version}\u003c/version\u003e\n    \u003cclassifier\u003e${ceffx.classifier}\u003c/classifier\u003e\n\u003c/dependency\u003e\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.techsenger.ceffx\u003c/groupId\u003e\n    \u003cartifactId\u003eceffx-core\u003c/artifactId\u003e\n    \u003cversion\u003e${ceffx.version}\u003c/version\u003e\n\u003c/dependency\u003e\n```\nThe `ceffx.classifier` uses the same values as the OpenJFX classifiers:\n\n* linux (built using the `ubuntu-22.04` runner)\n* win (built using the `windows-2022` runner)\n* mac (built using the `macos-15-intel` runner)\n* mac-aarch64 (built using the `macos-15-arm64` runner)\n\nNote that Maven can set the `classifier` using a `profile`. See an example in the demo [pom.xml](java/ceffx-demo/pom.xml).\n\nTo use snapshot versions, add our repository:\n\n```\n\u003crepository\u003e\n    \u003cid\u003erepsy-snapshots\u003c/id\u003e\n    \u003curl\u003ehttps://repo.repsy.io/mvn/techsenger/snapshots\u003c/url\u003e\n\u003c/repository\u003e\n```\n\n## Usage \u003ca name=\"usage\"\u003e\u003c/a\u003e\n\n### Settings \u003ca name=\"usage-settings\"\u003e\u003c/a\u003e\n\nCurrently `Cef` is used with the following key settings:\n\n```java\nCefSettings settings = new CefSettings();\nsettings.windowless_rendering_enabled = true;\nsettings.multi_threaded_message_loop = true;\n...\n```\n**windowless_rendering_enabled**. In native (non-OSR) mode, CEF needs a real OS-level window handle — an `HWND` on Windows,\n`NSView` on macOS, or `XID` on Linux — to embed its browser window into. In Swing/AWT this is possible because components\nlike Canvas are heavyweight: each one has its own native peer, meaning the OS actually knows about them as separate\nwindows and can return a valid handle. CEF attaches itself to that handle and renders directly into it as a child window.\n\nJavaFX, however, is built entirely on lightweight rendering — the whole `Stage` owns a single native window, and every\n`Node` inside it is just painted onto that one surface by the JavaFX engine (Prism). There are no individual native\npeers for `Node` objects, so there is no handle to give CEF. Without a valid OS window handle, CEF has nothing to attach\nto, making windowless_rendering_enabled = false simply impossible in a JavaFX context. OSR must be used instead, where\nCEF renders frames into a pixel buffer that JavaFX can then draw onto a Canvas or WritableImage.\n\n**multi_threaded_message_loop**. When this setting is `true`, CEF spawns its own dedicated thread and runs a native\nOS message loop there. This means CEF manages its own event processing independently, without requiring the host\napplication to do anything extra.\n\nWhen set to `false`, CEF gives up control of the message loop and expects the host application to periodically call\n`CefApp.doMessageLoopWork()` to drive CEF's event processing manually. This gives the host application full control\nover when and how CEF processes its events, which is essential when integrating with frameworks that have their own\nstrict threading or event loop models.\n\nTheoretically, both modes are supported in JavaFX. However, in practice when this flag is `false` does not work\ncorrectly — OS events stop being delivered to the JavaFX platform entirely. The JavaFX Application Thread itself\nremains alive and can be observed running, but no input or system events reach it. This issue is also\n[acknowledged](https://github.com/chromiumembedded/java-cef/blob/d3de8278626c160d4631db3fda2df7b77cc1e5c4/native/context.cpp#L203)\nby the JCEF developers, though in the context of windowed mode specifically. If anyone knows what the root cause of\nthis issue is, please let us know.\n\n### Threads \u003ca name=\"usage-threads\"\u003e\u003c/a\u003e\n\nCEFFX introduces a dual-thread architecture. The first thread is the JavaFX Application Thread, on which all\ninteractions with the JavaFX platform must be performed (using `Platform.runLater(...)`). The second thread is the\nCEF thread, on which all interactions with CEF must be executed (using `CefApp.runLater(...)`).\n\nPerforming CEF operations outside the CEF thread may lead to inconsistent behavior: some operations may work (always\nor intermittently), while others may fail. In addition, this can result in CEF-related exceptions being thrown.\n\nAs a rule of thumb, if something does not work as expected, it is recommended to first check which thread is being used.\n\n### Prebuilt Natives \u003ca name=\"usage-prebuit-natives\"\u003e\u003c/a\u003e\n\nCEFFX provides prebuilt native libraries, making it easy to integrate CEF into any JavaFX application without the need\nto compile it from source. This section describes all the steps required to set it up.\n\n1. Download the minimal CEF distribution from [CEF](https://cef-builds.spotifycdn.com/index.html) version\n`146.0.10+g8219561+chromium-146.0.7680.179`. Use the `Version Filter` to locate the correct version. Please note that\nother versions will not work, as CEFFX includes a built-in version check.\n2. Create a directory on your system, for example: `/foo/cef`.\n3. Copy the `contents` of the `Release` folder from the archive into `/foo/cef`.\n4. Copy the `contents` of the `Resources` folder from the archive into `/foo/cef`.\n\nAfter that, the `/foo/cef` directory should contain the following files (Linux):\n\n```\nchrome_100_percent.pak\nchrome_200_percent.pak\nchrome-sandbox\nicudtl.dat\nlibcef.so\nlibEGL.so\nlibGLESv2.so\nlibvk_swiftshader.so\nlibvulkan.so.1\nlocales\nresources.pak\nv8_context_snapshot.bin\nvk_swiftshader_icd.json\n```\n5. Add the dependencies to your JavaFX project as described in the [dependencies](#dependencies) section.\n6. On the first run, you need to extract the native binaries from the `ceffx-natives` module into `/foo/cef`.\n   Use `NativeExtractor` provided by the `ceffx-natives` module.\n7. Set the system property: `-Djava.library.path=/foo/cef`\n\n## Code Building \u003ca name=\"code-building\"\u003e\u003c/a\u003e\n\nTo build the library use the following commands.\n\n1. Clone the repository\n\n```\ngit clone https://github.com/techsenger/ceffx\n# Enter the project root directory\ncd ceffx\n```\n\n2. Build native code\n\n```\n# Create and enter the `build` directory (it is required by other tooling and should not be changed)\ncd native \u0026\u0026 mkdir build \u0026\u0026 cd build\n\n# Linux: Generate 64-bit Unix Makefiles\ncmake -G \"Unix Makefiles\" -DCMAKE_BUILD_TYPE=Release ..\n# Build using Make\nmake -j4\n\n# MacOS: Generate 64-bit Xcode project files\ncmake -G \"Xcode\" -DPROJECT_ARCH=\"x86_64\" ..\n# Open ceffx.xcodeproj in Xcode\n# - Select Scheme \u003e Edit Scheme and change the \"Build Configuration\" to \"Release\"\n# - Select Product \u003e Build\n\n# MacOS: Generate ARM64 Xcode project files\ncmake -G \"Xcode\" -DPROJECT_ARCH=\"arm64\" ..\n# Open ceffx.xcodeproj in Xcode\n# - Select Scheme \u003e Edit Scheme and change the \"Build Configuration\" to \"Release\"\n# - Select Product \u003e Build\n\n# Windows: Generate 64-bit VS2022 project files\ncmake -G \"Visual Studio 17\" -A x64 ..\n# Open ceffx.sln in Visual Studio\n# - Select Build \u003e Configuration Manager and change the \"Active solution configuration\" to \"Release\"\n# - Select Build \u003e Build Solution\n```\n3. Build Java code\n\n```\n# Enter the java directory from the project root\ncd java\n# Compile Maven project\nmvn install\n```\n\n## Running Demo \u003ca name=\"running-demo\"\u003e\u003c/a\u003e\n\nTo run the demo execute the following commands in the root of the project:\n\n    cd java \u0026\u0026 cd ceffx-demo\n    mvn javafx:run\n\nPlease note, that debugger settings are in `ceffx-demo/pom.xml` file.\n\n## License \u003ca name=\"license\"\u003e\u003c/a\u003e\n\nTechsenger CEFFX is licensed under the BSD 3-Clause License. See LICENSE file for details.\n\n## Contributing \u003ca name=\"contributing\"\u003e\u003c/a\u003e\n\nWe welcome all contributions. You can help by reporting bugs, suggesting improvements, or submitting pull requests\nwith fixes and new features. If you have any questions, feel free to reach out — we’ll be happy to assist you.\n\n## Support Us \u003ca name=\"support-us\"\u003e\u003c/a\u003e\n\nYou can support our open-source work through [GitHub Sponsors](https://github.com/sponsors/techsenger).\nYour contribution helps us maintain projects, develop new features, and provide ongoing improvements.\nMultiple sponsorship tiers are available, each offering different levels of recognition and benefits.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftechsenger%2Fceffx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftechsenger%2Fceffx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftechsenger%2Fceffx/lists"}