Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
255 commits
Select commit Hold shift + click to select a range
49f244e
screen docs
ppmpreetham Nov 14, 2026
d4fd43d
html radius
ppmpreetham Nov 15, 2026
a22ec99
theming docs
ppmpreetham Nov 15, 2026
9a8feb5
gpu targets
ppmpreetham Nov 15, 2026
cce9d0d
radius changelog
ppmpreetham Nov 15, 2026
8cfb7fb
readme badge
ppmpreetham Nov 15, 2026
149f03c
readme targets
ppmpreetham Nov 15, 2026
e35c892
anim test
ppmpreetham Nov 15, 2026
7879c90
android shell
ppmpreetham Nov 15, 2026
979a451
android docs
ppmpreetham Nov 15, 2026
2ff4950
android lua
ppmpreetham Nov 15, 2026
b7e843d
android window
ppmpreetham Nov 15, 2026
064d4cc
android rust
ppmpreetham Nov 15, 2026
ac3bd2a
android keyboard
ppmpreetham Nov 16, 2026
72121c2
control height
ppmpreetham Nov 16, 2026
d82a941
android fling
ppmpreetham Nov 16, 2026
73c9855
touch scroll
ppmpreetham Nov 16, 2026
657ac63
android javascript
ppmpreetham Nov 16, 2026
5f4acbc
android imgui
ppmpreetham Nov 16, 2026
0bac8b8
bui command
ppmpreetham Nov 16, 2026
68a7bac
bui command
ppmpreetham Nov 16, 2026
cc3870a
bui polish
ppmpreetham Nov 16, 2026
d26e2b2
bui fix
ppmpreetham Nov 16, 2026
8cd591c
bui test
ppmpreetham Nov 16, 2026
612e168
svelte bun
ppmpreetham Nov 16, 2026
1ef5bcb
wasm host
ppmpreetham Nov 16, 2026
cf429bb
rust: first child reserves one slot
concprog Nov 16, 2026
0940bd6
wasm generator
ppmpreetham Nov 16, 2026
6c0ac83
rust: cheaper style probe hash
concprog Nov 16, 2026
9055b96
rust: interaction state uses the fast hasher
concprog Nov 16, 2026
44aab17
rust: random-history layout oracle test
concprog Nov 16, 2026
6476439
rust: smaller boxes and layout nodes
concprog Nov 16, 2026
5bfdacd
rust: style table by index, one allocation for declarations
concprog Nov 16, 2026
d8270ad
rust: skip paint for boxes outside the view, reuse paint order buffer
concprog Nov 17, 2026
e609a4f
rust: split the view check into spill and offscreen
concprog Nov 17, 2026
007f7af
rust: reuse declaration and child buffers between frames
concprog Nov 17, 2026
701ab1e
kit: mark stale nodes instead of one global layout generation
concprog Nov 17, 2026
64197b5
wasm speed
ppmpreetham Nov 17, 2026
1ed9a75
wasm docs
ppmpreetham Nov 17, 2026
96910fe
Revert "bui command"
ppmpreetham Nov 17, 2026
20cd552
merge main
ppmpreetham Nov 17, 2026
3506918
rust: PanGui layout scenes as tests, with timings
concprog Nov 17, 2026
638aa70
screen identity
ppmpreetham Nov 17, 2026
3ee7540
android fixes
ppmpreetham Nov 17, 2026
31e7485
bui workflow
ppmpreetham Nov 17, 2026
127fba7
bui installers
ppmpreetham Nov 17, 2026
a2f566e
bui locks
ppmpreetham Nov 17, 2026
023a34e
bui review
ppmpreetham Nov 17, 2026
1f4e76a
close safety
ppmpreetham Nov 17, 2026
a9a3c9a
python fixes
ppmpreetham Nov 17, 2026
1922395
docs fixes
ppmpreetham Nov 17, 2026
b33c930
docs examples
ppmpreetham Nov 17, 2026
1d63c7e
changelog entries
ppmpreetham Nov 17, 2026
d65bccd
kit core
ppmpreetham Nov 17, 2026
9334089
screen fixes
ppmpreetham Nov 17, 2026
7c031a1
cmake quote
ppmpreetham Nov 17, 2026
d6ca65c
rust screens
ppmpreetham Nov 17, 2026
02fa644
area ids
ppmpreetham Nov 17, 2026
2cac6fe
node ids
ppmpreetham Nov 17, 2026
24628bf
wasm build
ppmpreetham Nov 17, 2026
130f874
wasm kit
ppmpreetham Nov 17, 2026
de6a8fa
wasm host
ppmpreetham Nov 17, 2026
8a4708f
wasm notes
ppmpreetham Nov 17, 2026
a7a77ca
remove guard
ppmpreetham Nov 17, 2026
e65d963
bui review2
ppmpreetham Nov 17, 2026
00ab7a4
rust stale
ppmpreetham Nov 17, 2026
f939664
scroll consume
ppmpreetham Nov 17, 2026
c000e82
screen restore
ppmpreetham Nov 17, 2026
c635255
line endings
ppmpreetham Nov 17, 2026
743d5bf
wasm logs
ppmpreetham Nov 17, 2026
6559a72
wasm clang
ppmpreetham Nov 17, 2026
13df915
wasm yaml
ppmpreetham Nov 17, 2026
cf932f6
bui review3
ppmpreetham Nov 17, 2026
7fe7343
wasm input
ppmpreetham Nov 17, 2026
e0bba35
wasm notes
ppmpreetham Nov 17, 2026
ce11dc4
focus hide
ppmpreetham Nov 17, 2026
cd349eb
list hover
ppmpreetham Nov 17, 2026
8e0b357
rust: keep text runs borrowed instead of copying them every frame
concprog Nov 18, 2026
49f9677
core: BLI_task_parallel_range on a persistent pool; canvas draws in p…
concprog Nov 18, 2026
0973771
Merge remote-tracking branch 'upstream/main' into rust-layout
concprog Nov 18, 2026
9330e98
rust: measure one-word text when built and compare it by size; skip t…
concprog Nov 18, 2026
07b65c4
rust: indent the taffy call under its skip check
concprog Nov 18, 2026
6338e49
core: keep Blender's parallel range settings; the canvas sets its own…
concprog Nov 18, 2026
e17c882
kit: damage only the widgets a layout moved
concprog Nov 18, 2026
2dbe343
changelog: layout damage
concprog Nov 18, 2026
e65256e
kit: damage covers what a class draws outside its rect (color ramp st…
concprog Nov 18, 2026
db01a4f
kit: arrange only the nodes a layout changed
concprog Nov 18, 2026
6a3d4c7
sound playback
ppmpreetham Nov 19, 2026
255b26a
font fallback
ppmpreetham Nov 19, 2026
c3a9f4b
image caching
ppmpreetham Nov 19, 2026
88c792b
fast effects
ppmpreetham Nov 19, 2026
cf21c52
ignore ref
ppmpreetham Nov 19, 2026
1db30fe
docs update
ppmpreetham Nov 19, 2026
0630ea2
d canvasitem
ppmpreetham Nov 19, 2026
0dd2583
Update Cargo.lock
ppmpreetham Nov 19, 2026
ef988ba
custom titlebar
ppmpreetham Nov 19, 2026
0c72d20
kit: column arrange counts and sums in one walk
concprog Nov 19, 2026
524d741
kit: name the layout's old values; drop a redundant arrange mark
concprog Nov 19, 2026
e00fabb
rust: collapse a let chain; note why the style enum stays unboxed
concprog Nov 19, 2026
09c82f2
rust: drop the lint allow on the style enum
concprog Nov 19, 2026
ae0404d
kit: mark a node stale before its change callback runs
concprog Nov 19, 2026
067d5e0
go bindings
ppmpreetham Nov 19, 2026
c663937
core: start the range pool through the platform once primitive
concprog Nov 20, 2026
9e5c43d
kit: cull with the class margin; invalidate an animating node
concprog Nov 20, 2026
437b1cd
rust: skip layout on a repeat frame; no culling bound for placeholders
concprog Nov 20, 2026
9d3423f
titlebar review
ppmpreetham Nov 20, 2026
c87d915
go review
ppmpreetham Nov 20, 2026
a1d6b62
frame size
ppmpreetham Nov 20, 2026
5f17ecc
font review
ppmpreetham Nov 20, 2026
c2f073c
image review
ppmpreetham Nov 20, 2026
adcf1f3
sound review
ppmpreetham Nov 20, 2026
2727b17
effects review
ppmpreetham Nov 20, 2026
9a0cdc7
animation review
ppmpreetham Nov 20, 2026
197af77
rust review
ppmpreetham Nov 20, 2026
ff82648
docs review
ppmpreetham Nov 20, 2026
ead1c56
compiler once
ppmpreetham Nov 20, 2026
3ce7592
go fixes
ppmpreetham Nov 20, 2026
705a54e
titlebar fixes
ppmpreetham Nov 20, 2026
032490c
paint fixes
ppmpreetham Nov 20, 2026
202d589
font fixes
ppmpreetham Nov 20, 2026
4665d31
ruby bindings
ppmpreetham Nov 22, 2026
fe785d6
asan fixes
ppmpreetham Nov 22, 2026
8fa35ee
ruby raster
ppmpreetham Nov 22, 2026
7f40c51
table leak
ppmpreetham Nov 22, 2026
7c5371c
review fixes
ppmpreetham Nov 22, 2026
d19f278
render frame
ppmpreetham Nov 22, 2026
7ee9320
review round
ppmpreetham Nov 22, 2026
48f7aef
teardown fix
ppmpreetham Nov 22, 2026
f6896c1
review fixes
ppmpreetham Nov 22, 2026
e8e436a
cmake tokens
ppmpreetham Nov 22, 2026
040010b
review fixes
ppmpreetham Nov 22, 2026
f6e1cb0
review fixes
ppmpreetham Nov 22, 2026
dae3b30
deferred frees
ppmpreetham Nov 22, 2026
887817f
close guard
ppmpreetham Nov 22, 2026
51dc403
screen leaks
ppmpreetham Nov 22, 2026
ab25acd
pointer cancel
ppmpreetham Nov 22, 2026
5e8822a
review round
ppmpreetham Nov 22, 2026
6512b23
review round
ppmpreetham Nov 22, 2026
a4d8859
review round
ppmpreetham Nov 22, 2026
6416e2e
review round
ppmpreetham Nov 22, 2026
c6af63b
review round
ppmpreetham Nov 22, 2026
96d2b23
review round
ppmpreetham Nov 22, 2026
43e81c3
review round
ppmpreetham Nov 22, 2026
c4cc7c9
Merge remote-tracking branch 'origin/wasm' into integrate/all
ppmpreetham Nov 22, 2026
393b794
Merge remote-tracking branch 'origin/feat/custom-titlebar' into integ…
ppmpreetham Nov 22, 2026
1b48de8
ramp drag
ppmpreetham Nov 22, 2026
6709c8f
Merge remote-tracking branch 'origin/perf/effects-sound-fonts' into i…
ppmpreetham Nov 22, 2026
0cc257f
Merge remote-tracking branch 'origin/fix/rust-layout-review' into int…
ppmpreetham Nov 22, 2026
9f0b5e7
Merge remote-tracking branch 'origin/feat/go-bindings' into integrate…
ppmpreetham Nov 22, 2026
58d468d
Merge remote-tracking branch 'origin/cli' into integrate/all
ppmpreetham Nov 22, 2026
856765f
Merge remote-tracking branch 'origin/fix/svelte-bun' into integrate/all
ppmpreetham Nov 22, 2026
a1c69c6
Merge remote-tracking branch 'origin/feat/ruby-gem' into integrate/all
ppmpreetham Nov 22, 2026
bfacb3b
Merge remote-tracking branch 'origin/android' into integrate/all
ppmpreetham Nov 22, 2026
5f15921
android cancel
ppmpreetham Nov 22, 2026
3ab9983
wasm getpid
ppmpreetham Nov 22, 2026
8a58c2b
retained culling
ppmpreetham Nov 22, 2026
4f5f73c
layer release
ppmpreetham Nov 22, 2026
d9f4e22
https installers
ppmpreetham Nov 22, 2026
4675bbf
screen events
ppmpreetham Nov 22, 2026
baa13a3
screen types
ppmpreetham Nov 22, 2026
1d34ac8
bundle overwrite
ppmpreetham Nov 22, 2026
462b8be
c buildtype
ppmpreetham Nov 22, 2026
0801b1b
lua rocks
ppmpreetham Nov 22, 2026
a3d67b6
doctor adds
ppmpreetham Nov 22, 2026
f0c8fdf
area handlers
ppmpreetham Nov 22, 2026
c27caf2
qjs timers
ppmpreetham Nov 22, 2026
27ca83f
text measure
ppmpreetham Nov 22, 2026
97e7edd
pnpm separator
ppmpreetham Nov 22, 2026
e16440a
zorder damage
ppmpreetham Nov 22, 2026
a75a615
value relayout
ppmpreetham Nov 22, 2026
4c5689f
go lifetimes
ppmpreetham Nov 22, 2026
871129a
toggle label
ppmpreetham Nov 22, 2026
ea76dbc
kitgen cache
ppmpreetham Nov 22, 2026
dd1147c
ci vet
ppmpreetham Nov 22, 2026
37a5ccc
child path
ppmpreetham Nov 22, 2026
05c04c4
toml errors
ppmpreetham Nov 22, 2026
25d5801
screen docs
ppmpreetham Nov 22, 2026
bc6430e
move pins
ppmpreetham Nov 22, 2026
657790a
android lifecycle
ppmpreetham Nov 22, 2026
90c048f
shell profiles
ppmpreetham Nov 22, 2026
0431351
wasm fixes
ppmpreetham Nov 22, 2026
4507d5e
cxx check
ppmpreetham Nov 22, 2026
5417c78
docs wording
ppmpreetham Nov 22, 2026
eb42370
lazy tag
ppmpreetham Nov 22, 2026
28fcbdf
screen restore
ppmpreetham Nov 22, 2026
bcd1d7c
restore test
ppmpreetham Nov 22, 2026
09b2930
Merge branch 'fix60/screens' into integrate/all
ppmpreetham Nov 22, 2026
2536b63
Merge branch 'fix60/cli' into integrate/all
ppmpreetham Nov 22, 2026
e6906e1
window show
ppmpreetham Nov 22, 2026
413a92f
app order
ppmpreetham Nov 22, 2026
cba85b4
bare pack
ppmpreetham Nov 22, 2026
aece143
window tests
ppmpreetham Nov 22, 2026
28159e1
Merge branch 'fix60/go-ruby' into integrate/all
ppmpreetham Nov 22, 2026
2c5a4a8
context free
ppmpreetham Nov 22, 2026
89c5d98
Merge branch 'fix60/go-ruby' into integrate/all
ppmpreetham Nov 22, 2026
57cc7f4
moved clips
ppmpreetham Nov 22, 2026
cb198f7
reveal order
ppmpreetham Nov 22, 2026
22a15ce
closed events
ppmpreetham Nov 22, 2026
54e6a0f
touch snap
ppmpreetham Nov 22, 2026
7a91c1c
context free
ppmpreetham Nov 22, 2026
38d2310
deferred shutdown
ppmpreetham Nov 22, 2026
0cb100d
layout prefix
ppmpreetham Nov 22, 2026
6173cf2
scaled effects
ppmpreetham Nov 22, 2026
923e5d2
copy propagation
ppmpreetham Nov 22, 2026
c063aaf
list height
ppmpreetham Nov 22, 2026
425a7d1
gpu lock
ppmpreetham Nov 22, 2026
684351d
decode wait
ppmpreetham Nov 22, 2026
3675246
cell seen
ppmpreetham Nov 22, 2026
5d560d0
changelog fixes
ppmpreetham Nov 22, 2026
3904130
Merge branch 'fix60/rust' into integrate/all
ppmpreetham Nov 22, 2026
8c06c5e
panel dragmode
ppmpreetham Nov 22, 2026
8bc354c
pinned define
ppmpreetham Nov 22, 2026
b136f06
sound error
ppmpreetham Nov 22, 2026
48fa901
image probe
ppmpreetham Nov 22, 2026
21ad833
sideways scroll
ppmpreetham Nov 22, 2026
1a2ddfa
region sizes
ppmpreetham Nov 22, 2026
3a2b00a
pending regions
ppmpreetham Nov 22, 2026
86c4aab
layout oom
ppmpreetham Nov 22, 2026
54f10dc
size nan
ppmpreetham Nov 22, 2026
4a1f3d4
resize order
ppmpreetham Nov 22, 2026
666823f
area notices
ppmpreetham Nov 22, 2026
3b04a59
maximized close
ppmpreetham Nov 22, 2026
97460f2
test leak
ppmpreetham Nov 22, 2026
0aa0fd1
Merge branch 'fix60/kit' into integrate/all
ppmpreetham Nov 22, 2026
c9c9d37
request scope
ppmpreetham Nov 22, 2026
642dcff
present backoff
ppmpreetham Nov 22, 2026
918d0e9
unset shell
ppmpreetham Nov 22, 2026
0b0c8e6
wasm paths
ppmpreetham Nov 22, 2026
8fa8768
detach notices
ppmpreetham Nov 22, 2026
af5f2a2
pending kept
ppmpreetham Nov 22, 2026
e021ba5
tooling check
ppmpreetham Nov 22, 2026
ca0b69e
dependency match
ppmpreetham Nov 22, 2026
d2bcc36
closing flag
ppmpreetham Nov 22, 2026
98d97b5
split id
ppmpreetham Nov 22, 2026
6707c84
resize notice
ppmpreetham Nov 22, 2026
cd16f55
test dangling
ppmpreetham Nov 22, 2026
a2593b6
preflight comment
ppmpreetham Nov 22, 2026
7abce21
partition reuse
ppmpreetham Nov 22, 2026
93df8c2
area rehome
ppmpreetham Nov 22, 2026
392da68
docs update
ppmpreetham Nov 22, 2026
7f8605c
flush bounds
ppmpreetham Nov 22, 2026
754f4ea
screen free
ppmpreetham Nov 22, 2026
b536905
inview reclip
ppmpreetham Nov 22, 2026
bd8c256
screen target
ppmpreetham Nov 22, 2026
9e9b80f
Merge branch 'fix60/r2a' into integrate/all
ppmpreetham Nov 22, 2026
21b247a
close cleanup
ppmpreetham Nov 22, 2026
1dd8437
remove ref
ppmpreetham Nov 22, 2026
ae49d2a
css reclip
ppmpreetham Nov 22, 2026
e0ec5b7
request count
ppmpreetham Nov 22, 2026
720c8a2
reclip placed
ppmpreetham Nov 22, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# shell scripts must keep LF line endings, whatever the checkout: a CRLF install.sh breaks `sh`
*.sh text eol=lf
90 changes: 89 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Build and test on every platform: the C/C++ project with ctest (C kit, GPU parity,
# window smoke, Dear ImGui, the Python bindings' suites), the Rust crates, the D
# binding, and a packaging check of the published Rust crates. macOS runs on Apple
# binding, the Ruby gem, and a packaging check of the published Rust crates. macOS runs on Apple
# Silicon (macos-15) and Intel (macos-15-intel; GitHub retired the macos-13 images).
#
# Wheels are built by wheels.yml.
Expand Down Expand Up @@ -180,6 +180,94 @@ jobs:
- name: Build and run the D test suite
run: dub run --config=test --compiler=ldc2

# bindings/go builds the C kit with cgo's compiler (gcc; MinGW on Windows) through
# `go generate`, then runs the tests of both packages and the examples'. They are
# headless (ui.Tester), so no display server is needed.
go:
name: go test (${{ matrix.os }})
runs-on: ${{ matrix.os }}
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
defaults:
run:
working-directory: bindings/go
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: stable
- name: X11 headers (Linux)
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y libx11-dev
- name: Build the C kit
run: go generate ./bui
# one command per step: pwsh (Windows' default shell) goes on after a failed
# native command, so a multi-line run would only report the last one
- name: go vet
run: go vet ./...
- name: go test
run: go test ./...

# bindings/ruby: the gem's extension builds the kit with CMake and Ruby's own compiler
# (RubyInstaller's MSYS2 gcc on Windows). On Linux the window tests run on Xvfb; the
# asan leg builds with AddressSanitizer (Ruby is not instrumented: the runtime is
# preloaded) and the package leg installs the packed gem, which builds from its
# vendored C sources alone.
ruby:
name: ruby (${{ matrix.os }}, ${{ matrix.leg }})
runs-on: ${{ matrix.os }}
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
include:
- { os: ubuntu-latest, leg: test }
- { os: windows-latest, leg: test }
- { os: macos-15, leg: test }
- { os: ubuntu-latest, leg: asan }
- { os: ubuntu-latest, leg: package }
defaults:
run:
working-directory: bindings/ruby
steps:
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
ruby-version: "3.3"
bundler-cache: true
working-directory: bindings/ruby
- name: X11 headers and Xvfb (Linux)
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y libx11-dev xvfb
- name: rake test (with native windows on Xvfb)
if: matrix.leg == 'test' && runner.os == 'Linux'
run: BUI_TEST_WINDOWS=1 xvfb-run -a bundle exec rake test
- name: rake test (headless)
if: matrix.leg == 'test' && runner.os != 'Linux'
run: bundle exec rake test
- name: rake test under AddressSanitizer
if: matrix.leg == 'asan'
run: |
BUI_SANITIZE=address bundle exec rake compile
# Ruby and ASan both want the alternate signal stack; Ruby's own exit leaks are not ours
BUI_TEST_WINDOWS=1 xvfb-run -a env LD_PRELOAD="$(gcc -print-file-name=libasan.so)" \
ASAN_OPTIONS=use_sigaltstack=0:detect_leaks=0:halt_on_error=1 \
ruby -Ilib -Itest -e 'Dir["test/test_*.rb"].each { |f| require_relative f }'
- uses: actions/setup-python@v5
if: matrix.leg == 'package'
with:
python-version: "3.12"
- name: Pack the gem, install it, require it
if: matrix.leg == 'package'
run: |
bundle exec rake gem
gem install --local ./blenderui-*.gem
cd "$RUNNER_TEMP"
ruby -e 'require "bui"; root = BUI::Node.new("column"); root << BUI::Node.new("button").set(text: "OK"); BUI::Context.open(root) { |c| c.render(BUI::Raster.new(64, 32), full: true) }; root.free; puts "blenderui #{BUI::VERSION}, kit #{BUI::KIT_VERSION}"'

# The crates.io package of blenderui-sys builds from its vendored sources alone.
package:
name: cargo package (blenderui-sys, vendored C sources)
Expand Down
157 changes: 157 additions & 0 deletions .github/workflows/cli.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
# The `bui` command (tools/bui): tested on the three systems for every change to it, and built for
# six targets and attached to the GitHub Release when a release tag is pushed. The installers
# (website/public/install.sh and install.ps1) and `bui update` download these archives.
#
# bui-<target>.tar.gz (Linux, macOS; holds `bui`)
# bui-<target>.zip (Windows; holds `bui.exe`)
# <archive>.sha256
#
# A release is made by tools/release.py (it tags vX.Y.Z); this runs beside release.yml and adds the
# files to the release that one creates (whichever workflow gets there first creates it).

name: bui command

on:
push:
tags: ["v*"]
pull_request:
paths: ["tools/bui/**", "website/public/install.*", ".github/workflows/cli.yml"]
workflow_dispatch:
inputs:
tag:
description: "Release tag to attach the archives to (e.g. v0.5.1)"
required: true
publish:
description: "Really upload (otherwise only build)"
type: boolean
default: false

permissions:
contents: read

env:
CARGO_TERM_COLOR: always

jobs:
test:
name: test (${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-15]
defaults:
run:
working-directory: tools/bui
steps:
- uses: actions/checkout@v4
with:
# a manual run builds the tag it was given, not the branch it was started from
ref: ${{ github.event.inputs.tag || github.ref }}
persist-credentials: false
- uses: dtolnay/rust-toolchain@stable
with:
components: clippy
- uses: Swatinem/rust-cache@v2
with:
workspaces: tools/bui
- run: cargo clippy --locked --all-targets -- -D warnings
- run: cargo test --locked

installers:
name: installers (syntax)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- name: install.sh is POSIX sh and passes shellcheck
run: |
sudo apt-get install -y shellcheck dash
dash -n website/public/install.sh
shellcheck -s sh -S warning website/public/install.sh
- name: install.ps1 is plain ASCII (Windows PowerShell 5.1 decodes a download as it likes) and parses
shell: pwsh
run: |
$bytes = [IO.File]::ReadAllBytes('website/public/install.ps1')
if ($bytes | Where-Object { $_ -gt 127 }) { throw 'install.ps1 has non-ASCII characters' }
$errors = $null
[void][System.Management.Automation.Language.Parser]::ParseFile((Resolve-Path 'website/public/install.ps1'), [ref]$null, [ref]$errors)
if ($errors) { $errors | ForEach-Object { Write-Error $_.Message }; exit 1 }

build:
name: build (${{ matrix.target }})
needs: [test, installers]
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- { target: x86_64-unknown-linux-gnu, os: ubuntu-22.04 }
- { target: aarch64-unknown-linux-gnu, os: ubuntu-22.04-arm }
- { target: x86_64-apple-darwin, os: macos-15-intel }
- { target: aarch64-apple-darwin, os: macos-15 }
- { target: x86_64-pc-windows-msvc, os: windows-latest }
- { target: aarch64-pc-windows-msvc, os: windows-11-arm }
steps:
- uses: actions/checkout@v4
with:
# a manual run builds the tag it was given, not the branch it was started from
ref: ${{ github.event.inputs.tag || github.ref }}
persist-credentials: false
- uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- uses: Swatinem/rust-cache@v2
with:
workspaces: tools/bui
key: ${{ matrix.target }}
- name: Build
working-directory: tools/bui
run: cargo build --release --locked --target ${{ matrix.target }}
- name: Package (Unix)
if: runner.os != 'Windows'
shell: bash
run: |
set -eu
mkdir -p dist
name="bui-${{ matrix.target }}.tar.gz"
tar -czf "dist/$name" -C "tools/bui/target/${{ matrix.target }}/release" bui
(cd dist && { sha256sum "$name" 2>/dev/null || shasum -a 256 "$name"; } > "$name.sha256")
- name: Package (Windows)
if: runner.os == 'Windows'
shell: pwsh
run: |
New-Item -ItemType Directory dist | Out-Null
$name = "bui-${{ matrix.target }}.zip"
Compress-Archive -Path "tools/bui/target/${{ matrix.target }}/release/bui.exe" -DestinationPath "dist/$name"
$hash = (Get-FileHash "dist/$name" -Algorithm SHA256).Hash.ToLower()
"$hash $name" | Set-Content "dist/$name.sha256" -NoNewline
- uses: actions/upload-artifact@v4
with:
name: bui-${{ matrix.target }}
path: dist/*

upload:
name: attach to the GitHub Release
needs: build
if: github.event_name == 'push' || github.event.inputs.publish == 'true'
runs-on: ubuntu-latest
permissions:
contents: write
env:
TAG: ${{ github.event.inputs.tag || github.ref_name }}
GH_TOKEN: ${{ github.token }}
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: actions/download-artifact@v4
with:
path: dist
merge-multiple: true
- name: Create the release if release.yml has not yet, then attach the files
run: |
ls -l dist
gh release view "$TAG" >/dev/null 2>&1 || gh release create "$TAG" --title "BUI ${TAG#v}" --generate-notes --verify-tag || gh release view "$TAG" >/dev/null
gh release upload "$TAG" dist/* --clobber
82 changes: 82 additions & 0 deletions .github/workflows/wasm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
# A blenderui app in a web page (docs/wasm.md): the kit and blenderui build for wasm32-wasip1 and the
# counter example renders under Node.js. Runs on changes to what the module is built from (the kit's C
# sources, blenderui and the crates it depends on, the workspace manifest they inherit from, the
# WebAssembly parts) and by hand.

name: wasm

on:
push:
branches: [main]
paths: ["platform/wasm/**", "bindings/rust/blenderui-web/**", "bindings/rust/blenderui/**", "bindings/rust/blenderui-sys/**", "bindings/rust/blenderui-vlist/**", "bindings/rust/blenderui-table/**", "bindings/rust/blenderui-paint/**", "bindings/rust/blenderui-macros/**", "bindings/rust/blenderui-tailwind/**", "bindings/rust/Cargo.toml", "examples/wasm/**", "kit/**", "gpu/**", "core/**", "types/**", "compat/**", "ui/**", "api/**", "CMakeLists.txt", "features.cmake", "features.json", ".github/workflows/wasm.yml"]
pull_request:
paths: ["platform/wasm/**", "bindings/rust/blenderui-web/**", "bindings/rust/blenderui/**", "bindings/rust/blenderui-sys/**", "bindings/rust/blenderui-vlist/**", "bindings/rust/blenderui-table/**", "bindings/rust/blenderui-paint/**", "bindings/rust/blenderui-macros/**", "bindings/rust/blenderui-tailwind/**", "bindings/rust/Cargo.toml", "examples/wasm/**", "kit/**", "gpu/**", "core/**", "types/**", "compat/**", "ui/**", "api/**", "CMakeLists.txt", "features.cmake", "features.json", ".github/workflows/wasm.yml"]
workflow_dispatch:

permissions:
contents: read

jobs:
counter:
name: the counter builds and renders
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
targets: wasm32-wasip1
- uses: actions/setup-node@v4
with:
node-version: "22"
- uses: actions/setup-python@v5
with:
python-version: "3.12"
# wasi-sdk 34's libc++ needs a recent clang (19 fails on its `#pragma clang attribute` headers); the
# runner's own is older, so LLVM 21 comes from apt.llvm.org
- name: LLVM 21 (clang with the wasm32 backend, llvm-ar), CMake and Ninja
run: |
set -o pipefail
wget -qO- https://apt.llvm.org/llvm-snapshot.gpg.key | sudo tee /etc/apt/trusted.gpg.d/apt.llvm.org.asc >/dev/null
echo "deb https://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-21 main" | sudo tee /etc/apt/sources.list.d/llvm-21.list
sudo apt-get update
sudo apt-get install -y clang-21 llvm-21 lld-21 cmake ninja-build
echo "WASI_CLANG=/usr/lib/llvm-21/bin" >> "$GITHUB_ENV"
/usr/lib/llvm-21/bin/clang --version
- name: The WASI sysroot (cached)
uses: actions/cache@v4
with:
path: ~/.bui/wasi-sysroot
key: wasi-sysroot-34-v2
# each step keeps its log and, when it fails, puts the lines that matter in an annotation (readable
# through the check-run API) and uploads the whole log
- name: Fetch the WASI sysroot
run: |
set -o pipefail
python platform/wasm/build.py --fetch-sysroot 2>&1 | tee fetch.log
- name: Build the counter
run: |
set -o pipefail
python platform/wasm/build.py examples/wasm/counter 2>&1 | tee build.log
- name: It renders, takes a click and resizes
run: |
set -o pipefail
node examples/wasm/smoke.mjs examples/wasm/counter/dist/app.wasm 2>&1 | tee smoke.log
- name: What failed
if: failure()
run: |
for f in fetch.log build.log smoke.log; do
[ -f "$f" ] || continue
errs=$(grep -n -i -m 8 -E 'error|fatal|FAILED' "$f" | cut -c1-300 | tr '\n' '|')
tail=$(tail -n 25 "$f" | cut -c1-250 | tr '\n' '|')
echo "::error title=wasm $f::first errors: ${errs} -- last lines: ${tail}" | cut -c1-3900
done
- uses: actions/upload-artifact@v4
if: always()
with:
name: wasm-logs
path: "*.log"
if-no-files-found: ignore
- uses: actions/upload-artifact@v4
with:
name: counter-web
path: examples/wasm/counter/dist/
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
ref/
addons/bui-panels
addons/bui-components
build*/
Expand Down
2 changes: 1 addition & 1 deletion ARCHITECTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ include `ui/`.)
| `gpu/` | The draw surface used by the toolkit (`GPU_*`, `imm*`) behind seam headers + a null backend that *records and forwards*: with a sink installed it emits screen-space primitives (`GPU_backend_sink.h`); without one it discards them. Theme colors reach the GPU layer through function-pointer hooks. | **Builds + tested** |
| `compat/` | Seam headers carrying upstream API names (`RNA_access.hh`, `BLF_api.hh`, …) with BUI-owned opaque types and stub implementations (`intern/bui_stubs.cc`). | **Builds** |
| `ui/` | The toolkit sources from `editors/interface`: interface.cc family, widgets, handlers, regions, view2d, views, textbox. Kept for reference and porting work; **not compiled by default** (`-DBUI_BUILD_UI=ON` builds it as `bui_ui`). `kit/` re-ports what it needs in C. | **Compiles + links** (opt-in) |
| `kit/` | Blender's UI as a retained-mode C runtime: node tree, uiLayout-style layout, `interface_handlers.cc` interaction rules, widget drawing ported from `interface_widgets.cc` (widget-base shader parameters rendered by `gpu/` raster), menus, color picker, views, editors; Tk-style pack/grid/place geometry managers, canvas display list, multi-line text area; UI undo/redo, Tab field traversal, vertical multi-drag, panel animation; Blender's file browser; images (`kit/intern/image`: Blender's imbuf design, one format table over Wuffs, libjpeg-turbo, libwebp and BUI's HDR/PNM/SVG readers in `kit/extern`, decode at the drawn size, a worker pool and a memory-budgeted cache; see [the Images page](https://bui.preetham.top/docs/concepts/images/)); damage-driven rendering; Blender's Dark and Light themes (`kit_theme_presets.c`, generated by `tools/gen_theme.py` from Blender's `Blender_Dark.xml` / `Blender_Light.xml` presets over `userdef_default_theme.c`; `BK_set_theme`); native window hosts for Win32, X11 and Cocoa (`kit_window_win32.c`, `kit_window_x11.c`, `kit_window_cocoa.m`; `kit_window_null.c` elsewhere). The Win32 host is BUI's own; the X11 host follows Blender's GHOST input mapping, and the Cocoa host (experimental: checked by CI and tried by hand on two Apple Silicon Macs) is ported from GHOST's Cocoa backend. `kit/intern/blender/` holds Blender files copied in and edited for the kit (each edit marked `BUI:`): `interface_string_search.cc` (menu search with recent searches), `interface_undo.cc` (text-edit undo), `interface_utils.cc` (float display precision). C API: `kit/include/BUI_kit.h`. | **Builds + tested** |
| `kit/` | Blender's UI as a retained-mode C runtime: node tree, uiLayout-style layout, `interface_handlers.cc` interaction rules, widget drawing ported from `interface_widgets.cc` (widget-base shader parameters rendered by `gpu/` raster), menus, color picker, views, editors; Blender's screen layout (`kit/intern/screen`, ported from `editors/screen`: areas on a graph of shared edges that split, join, dock and resize, regions that resize, hide and flip, saved as JSON); Tk-style pack/grid/place geometry managers, canvas display list, multi-line text area; UI undo/redo, Tab field traversal, vertical multi-drag, panel animation; Blender's file browser; images (`kit/intern/image`: Blender's imbuf design, one format table over Wuffs, libjpeg-turbo, libwebp and BUI's HDR/PNM/SVG readers in `kit/extern`, decode at the drawn size, a worker pool and a memory-budgeted cache; see [the Images page](https://bui.preetham.top/docs/concepts/images/)); damage-driven rendering; Blender's Dark and Light themes (`kit_theme_presets.c`, generated by `tools/gen_theme.py` from Blender's `Blender_Dark.xml` / `Blender_Light.xml` presets over `userdef_default_theme.c`; `BK_set_theme`); native window hosts for Win32, X11 and Cocoa (`kit_window_win32.c`, `kit_window_x11.c`, `kit_window_cocoa.m`; `kit_window_null.c` elsewhere). The Win32 host is BUI's own; the X11 host follows Blender's GHOST input mapping, and the Cocoa host (experimental: checked by CI and tried by hand on two Apple Silicon Macs) is ported from GHOST's Cocoa backend. `kit/intern/blender/` holds Blender files copied in and edited for the kit (each edit marked `BUI:`): `interface_string_search.cc` (menu search with recent searches), `interface_undo.cc` (text-edit undo), `interface_utils.cc` (float display precision). C API: `kit/include/BUI_kit.h`. | **Builds + tested** |
| `api/` | `bui_c_api.h` — small stable C ABI: version info + sink/viewport plumbing for hosts and bindings. | **Builds + tested** |
| `bindings/python/` | `buipy` CPython extension (no third-party deps; Dear ImGui is compiled into it, `blenderui.imgui`, so a process holds one kit) + `bui` package: `bui.components` (Blender component library), `bui.qtsyntax` / `bui.tksyntax` (Qt / tkinter APIs as thin facades over the kit), `bui.host` (native or Tk windows), `SvgSink` headless renderer, `bui.qt.BuiCanvas` PySide6/PyQt6 widget. | **Builds + tested** |
| `bindings/imgui/` | Dear ImGui (vendored, 1.93.1 WIP) on BUI: `imgui_impl_bui` platform + renderer backend hosted in a kit `custom` node (input, cursors, clipboard, DPI, damage-driven frames) drawing through `BUI_raster_mesh` and BUI textures; Blender style and Inter font; the C API (`cimgui.h`) and the generator behind the Python and Rust bindings; the Blender-widgets build (`blender/`, `-DBUI_IMGUI_BLENDER_WIDGETS=ON`). Gate: `-DBUI_BUILD_IMGUI` (ON with C++). | **Builds + tested** |
Expand Down
Loading
Loading