Open-source Android PDF and document toolkit with PDF tools, Office viewing, XLSX editing, scanning, and image editing. Built with Kotlin and Jetpack Compose.
Rust androiddocument-scannerdocximage-editorjetpack-composekotlinliquid-glassofflineopen-sourcepdfpdf-compressorpdf-editorpdf-mergerpdf-readerpdf-splitterpdf-toolspdf-viewerpptxspreadsheet-editorxlsx
artefact-mobile
The engine on phones: the document engine (engine/crates/engine and everything below it) as a
native library, libartefact.so, with Kotlin bindings generated by UniFFI. The Android app in
../../android loads it and drives the engine through its automation tools (page_rotate,
comment_add, form_fill…) and render requests.
| Path | What |
|---|---|
src/lib.rs |
MobileSession: the engine's automation tools and page renders for UniFFI |
src/tests.rs |
Host tests of that API (cargo test -p artefact-mobile) |
uniffi.toml |
Bindings config: Kotlin package com.chethan616.clearpdf.core, library artefact |
bindgen/ |
uniffi-bindgen, pinned to the crate's UniFFI release; the Android build runs it |
fetch-models.sh |
Downloads the OCR models into ../assets/models again (they are committed) |
The Android build (android/app/build.gradle.kts) runs cargo ndk … -p artefact-mobile for each
ABI and then the bindgen, so building the app is all it takes. Host tests:
cd engine
cargo test -p artefact-mobile