MCPcopy Create free account
hub / github.com/HumbleUI/JWM

github.com/HumbleUI/JWM @0.4.25

Chat with this repo
repository ↗ · DeepWiki ↗ · release 0.4.25 ↗ · + Follow
1,357 symbols 2,836 edges 168 files 145 documented · 11% updated 15d ago0.4.25 · 2026-06-16★ 63648 open issues

Browse by type

Functions 1,153 Types & classes 204
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Java Window Management library

Vision

JWM is a cross-platform Java window management and OS integration library.

JWM aims to expose an interface that abstracts over window creation, input handling and OS integration. It’s planned to support all the primary desktop platforms:

  • Windows
  • macOS
  • X11
  • Wayland

Primary goals:

  • Native JVM API
  • High-quality OS integration (indistinguishable from native apps)
  • Plays well with (but does not require) Skija

Motto: “Electron for JVM, without Chrome and JS”

Comparison to other UI/window libraries

Traditionally, Java UIs struggled with high-quality OS integration. JWM plans to bring it to modern standards by implementing those integrations from scratch in modern low-level OS-native APIs. Prior art:

AWT:

  • Bullet-proof, works everywhere
  • Event loop is two-threaded (lags in UI)
  • Dated font management, color management, dpi management
  • No vsync

JavaFX:

  • Fixed threading model
  • Performance is sometimes great, sometimes terrible
  • Even more limited fonts/color/graphics API
  • VSync is weird in multi-monitor case
  • No real extensibility

Winit:

  • Tried at JetBrains
  • Complicated event loop model (tries to unify desktop + web + mobile)
  • https://github.com/rust-windowing/winit/blob/master/FEATURES.md

GLFW via LWJGL, SDL2:

  • Game-oriented
  • Bad window management
  • No OS integration
  • Create one window and go full-screen is the main use-case

Electron:

  • Seems great, will use as inspiration
  • https://www.electronjs.org/docs

Dependency

Key Value
groupId io.github.humbleui
artifactId jwm
version version

Resources

Status

Alpha. Expect API breakages.

App

Windows macOS X11
start
makeWindow #121
getScreens
getPrimaryScreen
runOnUIThread
terminate
Show notification

Theme

Windows macOS X11
isHighContrast
isDark
isInverted #161

Window

Windows macOS X11
setEventListener
setTextInputClient
setTextInputEnabled
unmarkText
show
getWindowRect
getContentRect
setWindowPosition
setWindowSize
setContentSize
getScreen
requestFrame
close #107
minimize
maximize
restore
setTitle
setIcon #95
Set system cursor
Customize titlebar #75 #75 #75
focus
Get ZOrder
Progress Bar
Set custom cursor
openFile
openFolder
Transparency
Toggle Fullscreen
setMinimumSize
setMaximumSize
setResizable
bringToFront
isFront

Events

Windows macOS X11
EventFrame
EventKey
EventMouseButton
EventMouseMove
EventMouseScroll #115
EventTextInput #105
EventTextInputMarked
EventWindowCloseRequest
EventWindowMove #116
EventWindowResize
EventWindowMinimize #96
EventWindowMaximize #96
EventWindowRestore #96
EventWindowVisible #140 #140 #140
EventWindowScreenChange #117 #117 #117
EventWindowFocusIn
EventWindowFocusOut
EventWindowFullScreenEnter
EventWindowFullScreenExit
Drag & Drop
Touch events #249
Theme Changed

Screen

Windows macOS X11
id
isPrimary
bounds
scale
workArea #119
colorSpace #122 #122 #122

Clipboard

Windows macOS X11
set #51
get #51
getFormats #51
clear #51
registerFormat #51

Layers

Windows macOS X11
Raster #81
OpenGL
DirectX 11
DirectX 12
Metal
Vulkan

Packaging

Windows macOS X11
Run on GraalVM
App package

Building from source

Prerequisites:

  • Shared: Git, CMake(3.11+), Ninja, C++ compiler, JDK 11+, $JAVA_HOME, Python 3
  • Windows 10: Microsoft Visual C++ (MSVC), x64 Native Tools Command Prompt for VS
  • Ubuntu 20.04: libxcomposite-dev libxrandr-dev libgl1-mesa-dev libxi-dev libxcursor-dev

Run:

./script/build.py

Run examples:

./script/run.py

Run examples without building (use version from the table above):

./script/run.py --jwm-version <version>

Local JAR

Generate & install a local .jar file:

./script/install.py

This outputs target/jwm-0.0.0-SNAPSHOT.jar for use in testing (e.g. io.github.humbleui/jwm {:local/root "..."} if using deps.edn)

MacOS

Before running the build, ensure you've installed: * XCode Developer Tools (xcode-select --install) * Ninja (brew install ninja) * Python 3 (brew install python)

Debugging

Set JWM_VERBOSE in process env to see extra log output when running locally.

# Mac / Linux
export JWM_VERBOSE=true

# Windows
set JWM_VERBOSE=true

Contributing

PRs & issue reports are welcome!

Please read Conventions first.

If you are looking where to start, there’s a label: Good first issue.

Issues labeled “Design” and “Not sure” require prior discussion—leave a comment with your ideas!

Contributors

Development sponsored by:

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Shape

Method 962
Function 191
Class 177
Enum 23
Interface 4

Languages

C++54%
Java43%
Python3%

Modules by API surface

windows/cc/D3D12/d3dx12.h196 symbols
macos/java/WindowMac.java79 symbols
windows/cc/WindowWin32.cc78 symbols
windows/java/WindowWin32.java58 symbols
linux/java/WindowX11.java54 symbols
linux/cc/WindowX11.cc47 symbols
shared/java/Window.java41 symbols
windows/java/LayerD3D12.java30 symbols
script/build_utils.py26 symbols
windows/cc/LayerD3D12.cc25 symbols
windows/cc/ClipboardWin32.cc23 symbols
macos/java/LayerMetal.java23 symbols

For agents

$ claude mcp add JWM \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page