Patterns (.fpattern)

Reusable RGBA tiles with portable metadata and deduplicated pixels.

Reviewed against the application source on 5 October 2026. Focale is in active development; available commands and published packages may differ by build.

Use in the application

Import or export from a pattern selector. Edit → Define Pattern captures the document or a hard rectangular selection without feathering. Editing a stored pattern opens an independent copy; define the edited result as a new preset.

File structure

UTF-8 JSON with an explicit format tag and version. The current reader and writer use version 1. The example shows the library envelope; the full reference describes the complete value schemas.

presets stores id, name, patternId and optional groupPath. assets holds content-derived ids, width, height and Base64 rgba in row-major straight-alpha order. Several presets can share one asset. The file stores flattened tiles, not their original document layers.

File structure
FieldValue
Extension.fpattern
formatfocale-pattern-presets
version1
EncodingJSON UTF-8
{
  "format": "focale-pattern-presets",
  "version": 1,
  "presets": [
    {
      "id": "user.example",
      "name": "Blue fabric",
      "patternId": "pattern.2.1.9e2b63675440c0d9",
      "groupPath": [
        "Materials",
        "Fabric"
      ]
    }
  ],
  "assets": [
    {
      "id": "pattern.2.1.9e2b63675440c0d9",
      "width": 2,
      "height": 1,
      "rgba": "ChTI/8zq/4A="
    }
  ]
}

Validation and limits

Maximum: 256 MiB encoded, 128 MiB decoded RGBA, 4,096 presets and assets, 4,096 pixels per tile axis and 16 million pixels per tile. Identities and exact byte lengths are checked.

Photoshop interchange

PAT import converts supported colour modes to eight-bit RGBA. PAT export preserves supported tile pixels, names, order and groups. Built-in procedural patterns are omitted from native exports.

Complete format references

Download the full Markdown specifications in English, including schemas, validation rules and compatibility details.

Other documentation pages