Skip to content

feat(vector): read Adobe Illustrator templates (.ait) - #1774

Merged
KnifeLemon merged 11 commits into
KnifeLemon:mainfrom
YusufMntm:feat/ait-template-1726
Dec 2, 2026
Merged

KnifeLemon merged 11 commits into
KnifeLemon:mainfrom
YusufMntm:feat/ait-template-1726

Conversation

@YusufMntm

Copy link
Copy Markdown
Contributor

Fixes #1726

What and why

An Illustrator template (.ait) is stored exactly like an Illustrator file (.ai): a PDF-compatible file, or a
PostScript one from older versions. Only the name tells Illustrator to open it as a new untitled document. Filee
already converts .ai, but didn't know the .ait name, so templates were refused.

Design

  • .ait is a second extension of the existing read-only ai format in FormatRegistry (the way eps lists
    epsf/epsi), not a new format id. It therefore takes every existing AI route unchanged: PDF-compatible files go
    through PDF out of the box, PostScript-based ones through Ghostscript. VectorConverter already decides by the
    file's header, not its extension, and .ai stays the primary extension; Filee never writes .ait.
  • FormatFields needs no change: the grade and the design field belong to the format, so .ait inherits them.
  • Schema 102: upgraded libraries learn .ait on the vector donut through LearnExtensions, as earlier alias PRs did,
    so a profile that already claims .ait keeps it. If another PR takes 102 first I'll renumber.
  • README format row, docs/ENGINES.md and a CHANGELOG.md entry with its ko/en update lines.

Tests

  • FormatRegistryTests.Detects_formats: template.ait → ai.
  • AitAliasTests: detection (any case) and the vector donut, AI still read-only with .ai as primary extension,
    web sniffing keeps the .ait name for a PDF-compatible download, and the v101 → v102 migration (adds .ait once,
    leaves a custom claim alone).
  • GraphicsTests.Illustrator_templates_convert_like_illustrator_files: a PDF-compatible .ait built in the test
    converts to PDF and PNG like the existing .ai test.

Ran locally (Windows): Filee.Core.Tests all 1796 pass, GraphicsTests 57 pass (3 Ghostscript-only skips), dotnet format --verify-no-changes on the changed files.

Not tried: a real template saved by Illustrator, or a PostScript-based .ait (Ghostscript isn't installed here).
That path is the same Ghostscript step .ai already uses.

🤖 Generated with Claude Code

An Illustrator template is stored like a normal .ai file; only the name
differs. Add .ait to the read-only AI format so it takes every existing AI
route (PDF-compatible through PDF, PostScript-based through Ghostscript),
and teach upgraded libraries the extension on the vector donut (schema 102).

Fixes KnifeLemon#1726

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added the feature New features label Nov 22, 2026
@KnifeLemon KnifeLemon mentioned this pull request Nov 24, 2026
1 task done

@KnifeLemon KnifeLemon left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @YusufMntm. A second extension on the read-only ai format is the right shape:

  • every AI route applies to .ait unchanged (PDF-compatible files directly, PostScript ones through Ghostscript);
  • .ai stays the primary extension, and Filee never writes .ait;
  • the v102 step lets existing libraries learn .ait without moving a custom claim.

CI is green.

#1794 takes schema 102 too. I'll renumber whichever of the two merges second myself, so you don't need to.

@YusufMntm

Copy link
Copy Markdown
Contributor Author

Merged main in to clear the conflict: only CHANGELOG.md conflicted, and both sides are kept (upstream's entries first). The relevant tests pass locally. Nothing else changed, and the schema number is still yours to settle at merge.

…#1794's v102

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@YusufMntm

Copy link
Copy Markdown
Contributor Author

Merged main in to clear the conflict. Since #1794 took schema 102 first, the .ait step moves to v103 (CurrentSchemaVersion = 103, and its test now starts from 102); CHANGELOG.md and the other conflicts keep both sides, upstream's first. Core tests and the relevant engine tests pass locally. Renumber again at merge if another step lands first.

Main took schema 103-106 (.jsp, sequence alignments, .blp, CBR), so the
.ait step moves to v107.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@YusufMntm

Copy link
Copy Markdown
Contributor Author

Merged main in again to clear the conflict (173b4081):

  • Schema 107: main now takes 103–106 (.jsp, sequence alignments, .blp, CBR), so the .ait step is v107 and AitAliasTests starts the migration from 106. feat(image): colour-mapped previews of single-band rasters #1849 asks for 107 as well, so whichever lands second needs the next number.
  • CHANGELOG.md, README.md and docs/ENGINES.md: main's side kept, with the AI/AIT wording put back on the lines main also changed.

Filee.Core.Tests passes locally (1840 passed, 11 skipped), and dotnet format --verify-no-changes is clean on the changed files.

@YusufMntm

Copy link
Copy Markdown
Contributor Author

Merged main in to clear the CHANGELOG.md conflict after #1891, #1897 and #1903 (0d96f70e): both sides kept, main's ko/en lines first. Nothing else changed; main is still at schema 106, so .ait stays v107 (#1849 asks for 107 too). Filee.Core.Tests (1840 passed, 11 skipped) and the .ait engine tests pass locally.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@YusufMntm

Copy link
Copy Markdown
Contributor Author

Merged main in to clear the conflict (b3c3e4b6):

ko: Adobe Illustrator 템플릿(.ait)을 .ai 파일처럼 PDF, PNG 등으로 변환할 수 있어요
en: Adobe Illustrator templates (.ait) open and convert like .ai files
- **Illustrator templates** (#1726). Adobe Illustrator template files (`.ait`) are now recognized alongside `.ai` and
  convert to PDF, PNG and the other picture formats in the same way (PDF-compatible files out of the box,
  PostScript-based ones through Ghostscript). Filee reads `.ait` but never writes it.

Filee.Core.Tests passes locally.

KnifeLemon#1935 took schema step 108 for .wbk, so the .ait step moves to v109.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@YusufMntm

Copy link
Copy Markdown
Contributor Author

Merged main in to clear the conflict (f7861f95):

Filee.Core.Tests: 1882 passed, 11 skipped, 1 failed. The failure is PresetGalleryVersionTests.A_field_added_to_the_allow_list_says_which_filee_first_reads_it, which this branch doesn't touch (no preset field changes here); it comes in with main.

KnifeLemon and others added 3 commits December 2, 2026 10:28
.3ds took settings schema 109 on main, so the .ait step becomes v110
(CurrentSchemaVersion 110) and AitAliasTests migrates from 109.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
"ait" joins SharedPresetVersions.Extensions (2.6.0), as an extension
added to the existing AI format. CHANGELOG gets an Unreleased bullet and
a ko/en update line.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@KnifeLemon

Copy link
Copy Markdown
Owner

@YusufMntm we pushed a few things to your branch so this can go in:

  • Merged current main. .3ds ([Format]: .3ds #1895) took settings schema 109 in the meantime, so the .ait step is now v110: CurrentSchemaVersion = 110 and if (from < 110) after the .3ds block, and AitAliasTests migrates from 109 (Version_109_libraries_learn_ait_…).
  • Added "ait" to SharedPresetVersions.Extensions (2.6.0), since it's a new extension of the existing AI format. That's the preset gallery entry; the red check on your last run was main's gallery field count, which merging main fixes.
  • Added a CHANGELOG bullet and a ko/en update line crediting you.

Thanks!

@KnifeLemon
KnifeLemon merged commit a462ce0 into KnifeLemon:main Dec 2, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature New features

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Format]: .ait

2 participants