---
url: /en-us/standard/conformance.md
---
This page explains the meaning of the normative words in the specification, how to verify on your own that you meet a level, and lists the public samples used for verification.

## Normative words

| Word | Meaning |
| --- | --- |
| **must** | Not meeting it means not conforming to the level the rule belongs to |
| **must not** | A prohibited behavior, as binding as "must" |
| **should** | Recommended practice; if not followed, make sure this causes no misplaced content, silent loss of content or security risk |
| **may** | Optional; does not affect interoperability |

The "Requirement" column in field tables:

| Value | Meaning |
| --- | --- |
| **Required** | Must be written and pass the field checks |
| **Optional** | May be omitted; when written, must still pass the field checks |
| **Conditional** | Whether it is required is determined by the field's description |

The "Level" column in field tables states from which level a **reader** must understand the field. Required fields must always be written, whatever level a writer declares.

## Rule IDs

Every normative rule has a stable ID, for example `INK-11`. ID prefixes correspond to pages:

| Prefix | Page | Prefix | Page |
| --- | --- | --- | --- |
| VER | [Versions and Changes](version) | CANVAS | [Canvas Block](blocks/canvas) |
| TYPE | [Block Types and Encoding](type) | INK | [Ink Block](blocks/ink) |
| COMPAT | [Compatibility and Fallback](compatibility) | SHAPE | [Shape Block](blocks/shape) |
| FILE | [Main Ink File](file/main) | MEDIA | [Media Block](blocks/media) |
| SAVE | [Saving, Appending and Recovery](incremental) | CLEAR | [Clear Block](blocks/clear) |
| EXTRA | [Resource Package](file/extra) | COLOR | [Color Map](common/color) |
| HDR | [Header Block](blocks/header) | NIB | [Nibs and Caps](common/nib) |
| HEXT | [Header Extension Block](blocks/headerextension) | PRESET | [Shape Preset Registry](appendix/shape-presets) |
| DEV | [Device Structure](blocks/device) | | |

Once published, an ID never changes its meaning and is never reused; deleted rules are recorded in [Versions and Changes](version).

## Self-certifying a level

UInk has no certification body and provides no automated test tool. An app verifies itself with the following steps and then declares its level:

1. Choose the target levels, deciding the read level and the write level separately.
2. Check every item on the checklists of that level and all levels below it in [Levels and Certification](levels#checklist).
3. Verify with the public samples below: a reader opens each sample and compares the result with the expected result for that level in `fixtures.json`; files produced by a writer are opened and checked with another reader known to be correct.
4. Declare it in the app's documentation, for example: `UInk 1.1 read: Standard + Inkeys extension; write: Basic`.

## Reading process

1. Validate the first block, the Header (VER-3, HDR-2); refuse to parse if it does not conform.
2. Read the optional Header Extension and create implicit singletons for missing registries (HEXT-3).
3. Decode the remaining objects in order: a Canvas starts a new scope; content blocks belong to the preceding Canvas (FILE-3); for the same Canvas unique key, the last one wins (FILE-8); unknown Type IDs are skipped (TYPE-9).
4. When the end is incomplete, discard the last object; when the middle is corrupt, stop reading without resynchronizing (FILE-16, FILE-17).
5. Recalculate the page count and other state from the objects actually read, without relying on the statistics in the Header (HDR-5).
6. Display according to your own level, and handle content beyond your level as described in [Compatibility and Fallback](compatibility).

## Public samples

The 1.1 samples are produced by the generator script in the repository and are all published in [`/dist-standard/uink-v11/`](/dist-standard/uink-v11/fixtures.json). [`fixtures.json`](/dist-standard/uink-v11/fixtures.json) records each sample's purpose, the rule IDs it covers, its objects in readable form, and the expected result at each level; [`SHA256SUMS.txt`](/dist-standard/uink-v11/SHA256SUMS.txt) is for verifying the downloads.

::: tip
If you find that a sample's expected result disagrees with the specification text, the specification text wins; please report it.
:::

| Sample | Primary level | What it verifies |
| --- | --- | --- |
| `core-pages.uink` | Core | Multiple pages, varying Pen width, the seven basic Shapes, implicit singletons |
| `core-page-append.uink` | Core | A new version of the same page is appended and the last one to appear wins; `pageIndex` temporarily duplicated |
| `basic-appearance.uink` | Basic | Opacity, highlighter rectangle nib, caps, dashed lines, arrows, rounded corners, dot background |
| `standard-ppt.uink` | Standard | PowerPoint Workspace, `slideId` binding, binding by `pageIndex`, retained pages, end page |
| `standard-media.uink` + `.extra` | Standard | Image `fit` and `crop`, Media mapped by `viewport` |
| `standard-shape-object.uink` | Standard | Shape object layer: first part and subsequent parts, shared `undoId` |
| `full-layers-devices.uink` | Full | Multiple layers, multiple Devices, nested Workspaces |
| `full-hdr-advanced.uink` | Full | HDR colors, Advanced Highlighter, `renderOnlyWhenLatest` |
| `full-shape-preset.uink` | Full | `construction` of registered presets; unknown presets fall back to the object layer |
| `inkeys-erase-clear.uink` | Inkeys | Erase Ink, eraser nibs, Clear intervals |
| `compat-v10.uink` | Core | A 1.1 reader reads a version 10 file on a best-effort basis |
| `fallback-unknown.uink` | Core | Fallback for unknown blocks, keys and enum values |
| `truncated-tail.uink` | Core | Recovery when the last object is incomplete |
| `corrupt-middle.uink` | Core | When an object in the middle is corrupt, keep the content before it and stop reading |
| `future-minor.uink` | Core | A file with `version = 12`: skip unknown blocks and keys, read on a best-effort basis |
| `core-shape-curves.uink` | Core | Curves and free-form shapes: the two branches of a hyperbola written as two Polylines grouped into an object, a heart written as a Polygon |

The 1.0 samples are kept in [`/dist-standard/uink-v10/`](/dist-standard/uink-v10/fixtures.json) and are no longer updated.
