Skip to content

Feat: A Compose host entry point that draws a Python-declared root - #48

Merged
b-re-w merged 3 commits into
developfrom
work/compose-host
Oct 2, 2026
Merged

b-re-w merged 3 commits into
developfrom
work/compose-host

Conversation

@b-re-w

@b-re-w b-re-w commented Oct 2, 2026

Copy link
Copy Markdown
Member

Closes #18

New module python-multiplatform-compose (the library stays Compose-free): PythonContent(root) / PythonContent(module, attribute) reads a Python-held State in the composition and composes its value (a Python callable); a Python write replacing the root recomposes on the next frame with no host call; per-root callable arena released on replace and on dispose. withPythonComposer and PythonCallableArena promoted from the compose fixtures. No library name known to the binder.

Tests: PythonContentRenderTest (3; red with no module and with an empty stub, tamper check on the state read). Coordinator verification after merging develop: compose fixtures 105/0, new module compiles for desktop and Android.

Follow-up: Python-side mutableStateOf/.value needs generic functions and member properties in the walker -> #38.

b-re-w added 3 commits October 3, 2026 07:43
python-multiplatform-compose (new module; the library itself stays free of
Compose) adds PythonContent(root) / PythonContent(module, attribute): it reads
a Python-held State inside the composition and composes its value, a Python
callable, so a Python write that replaces the root recomposes on the next frame
with no host call. Each root has its own callable arena, released when the root
is replaced or the composition disposed. withPythonComposer and
PythonCallableArena are promoted from the compose fixtures, which now use them.
No library name is known to the binder.
# Conflicts:
#	ksp-fixtures/compose/src/desktopMain/kotlin/fixture/compose/PythonComposition.kt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant