# Preset Image Sizing

Preset images should be scaled to:

```text
714 x 1220 px
```

This size was chosen for a Samsung Galaxy A32 5G display. The physical screen is
`720 x 1600`, but the usable area is smaller because Android system UI takes up
vertical space and the rendered image was clipped by about `3px` on each side.

Measured from screenshots of the phone, the preview screen should be treated as:

```text
64 px    top system/status area
1220 px  preset image area
9 px     red status line
217 px   white bottom app/system area
90 px    black One UI navigation bar
```

The total bottom area below the red status line is `307px` (`217px + 90px`).

Use `714px` wide instead of `720px` so the image does not clip horizontally.
Use `1220px` tall so it fits between the top system/status area and the bottom
area measured above.

Resize future preset images directly to this exact size. Do not add blur
backgrounds, padding, borders, or generated fill. A plain scale is what fits.

Example:

```bash
python3 - <<'PY'
from pathlib import Path
from PIL import Image

target = (714, 1220)
for path in Path("src/presets/img").iterdir():
    if not path.is_file():
        continue

    with Image.open(path) as src:
        image = src.convert("RGB").resize(target, Image.Resampling.LANCZOS)

        if path.suffix.lower() == ".png":
            image.save(path, format="PNG", optimize=True)
        elif path.suffix.lower() in {".jpg", ".jpeg"}:
            image.save(path, format="JPEG", quality=92, optimize=True, progressive=True)
        else:
            image.save(path)
PY
```
