# feat: read ink drawings and handwriting as strokes in page coordinates · clo/snowbound

[View on GitCafe](https://git.cafe/clo/snowbound/commit/7f30bf34648c9ac7a69e74956b04546b9894a380)

Repository: [clo/snowbound](https://git.cafe/clo/snowbound)

Visibility: public

Requested revision: 7f30bf34648c9ac7a69e74956b04546b9894a380

Requested commit: 7f30bf34648c9ac7a69e74956b04546b9894a380

Commit: 7f30bf34648c9ac7a69e74956b04546b9894a380

Tree: 08a8c4f0e49181205989fdbdd0b98c72f9e8715e

Author: clover caruso

Committer: clover caruso

## Message

```
feat: read ink drawings and handwriting as strokes in page coordinates

The public MS-ONE text has no ink object; the layout matches what the
onenote_parser crate (MPL-2.0, reimplemented here rather than copied) and
Joplin's converter read: a container (jcid 0x60014) whose data node (0x2003b)
lists strokes (0x20047), each packing its coordinates as ISF multi-byte
first differences in HIMETRIC, one block per dimension of the style object's
(0x120048) GUID table, with pen width, height, colour, transparency and tip
on the style. The reader interprets those four kinds, and page::Ink decodes
every stroke into a polyline of absolute page points, keeping nested
containers as groups; ink is a page object or paragraph content, and the
writer treats it as fixed.

corpus/native-ink/cold-ui-ink is the oracle: two mouse-drawn drawings whose
native positions and sizes the decoded extents reproduce (OneNote reports a
size one HIMETRIC unit larger than the point extent). tests/page_ink.rs
checks the Rust decoding and tools/test_ink_read.py an independent Python
decoding of the same packets; verify-document.py now compares every ink
drawing's extent, projected through the page origin on left-to-right pages,
and reports differences as geometry entries. The canvas places its read-only
ink placeholder at the stroke extent.

Assisted-by: claude-fable-5.1

```

## Parents

- [bcb13ba046299393ccadffa70cc2c57963ffc3ce](https://git.cafe/clo/snowbound/commit/bcb13ba046299393ccadffa70cc2c57963ffc3ce?format=markdown)

[Source at this commit](https://git.cafe/clo/snowbound/tree/7f30bf34648c9ac7a69e74956b04546b9894a380?format=markdown)
