Limits · 4 November 2026
What themes can't reach yet, and the work to do
Most of what a PDF holds can carry a theme. This page lists what can't, what the tool doesn't do yet, and what each gap needs. If you can help with one, say so on the issue tracker.
The measure is the objects test in the repository (tests/objects), which holds every kind of object
a PDF 2.0 file can contain and a viewer can show. Its coverage list has 271 entries. A theme changes 193 of them.
48 keep their colours on purpose in every theme: photos, every image format, print-production marks and colour
scales that work on both papers. The other 30 are drawn by the PDF app from entries in the file, so the app has to
follow the theme. The gaps below are what that leaves. For developers,
the roadmap sets out what each part
supports and every piece of work still to do.
01
Out of a theme's reach
A theme can swap palettes, gradients, graphics states, images and colour values. It can't change a font, a script or what's inside a 3D model, so colours held there stay as they are.
- Colour fonts. A font can carry its own colours, as colour emoji do. A theme can't replace a font (rule R5.3-3 of the specification), so these keep their light-page colours. Work: decide whether a theme may swap a font's colour palette, or whether writers should draw such glyphs another way (open question 15).
- Colours set by scripts. A form can run JavaScript that colours a field when it changes, for example red for a negative number. The colour is in the script, not where a theme can swap it, so it is pure red on dark paper. Work: a way for a script to ask for a colour of the theme shown (open question 16).
- Inside 3D models and media. A theme changes the PDF's own colours round a 3D model (its background, render mode and cross-sections) but not the model's materials and lighting, and not video or sound. A white part stays bright white on a dark page. Work: say whether a 3D view per theme is wanted, or whether these stay as photos do (open question 17).
- Line widths and dashes. Draft 0.4 of the specification lets a theme draw thin grid lines and chart lines bolder, up to twice the width (rules R5.3-11 and section 6.4). The tool can't make such files yet, and nobody has measured how much bolder helps: see the evidence page on lines, dashes and grids. Marker size, font weight and layout stay the same in every theme.
- Attached files. A PDF attached to a themed PDF, or held in a portfolio, needs themes of its own. The portfolio's own colours are themed. Work: say whether a reader should match an attached file's theme to the one shown (open question 18).
02
Not done by the tool yet
These are possible with the specification as it stands, but pdf-themes doesn't do them,
or does them at a cost.
- Photos, screenshots and figure images. The only way to theme one is a whole image per theme, which makes the file bigger. Left alone, a screenshot with a white background stays a bright box on dark paper. From a single build, the tool recolours an image only when it looks like a drawing on white or a grey scan. Work: measure how often this matters in the test set, and what a second image costs.
- Black and white scans. Grey scans are themed, but a 1-bit scan (JBIG2 or fax-coded) isn't: in the test set, 15 of the 30 scans kept only Light. Work: theme 1-bit scans the way grey ones are, and check whether all 15 are 1-bit.
- Colour scans. A colour scan keeps its colours. Dark turns a grey scan light on dark, so a photo on a scanned page becomes a negative.
- Images whose soft mask has a Matte. The tool leaves these alone, because palette indices can't carry the arithmetic a reader uses to undo the matte. Work: swap in a whole image per theme, blended with the same matte, and add the rule to section 5.3 of the specification (open question 20).
- Colour scales that change. A heatmap whose scale changes between themes needs a copy of the image per theme, because its palette and its values both change.
- Wide-gamut colours in worked-out themes. Themes the tool works out read every three-channel colour profile as sRGB, so they lose the most saturated Display P3 colours. Themes built from source keep them (open question 9).
- Large files. Worked-out themes are fragile on a large file: on the 31-page objects test all six fail their check and are left out. Themes built from source don't have this problem.
- No released package. You need a copy of the repository to run the tool. Work: release it on
PyPI as
pdf-themes.
04
Left to the PDF app
30 entries in the objects test are drawn by the PDF app itself. A theme can give the colours, but the app has to use them.
Among them are pop-up notes, how a link is highlighted when clicked, link borders, page box colours, article threads and the steps of a presentation. Only the viewer on this site switches themes so far, and every other PDF app shows a themed file in its default colours. Work: support in PDF apps, starting with pdf.js, and in the library hayro that the PdfCraft app draws with.
05
The contrast check
The check measures text in every theme. Some text it can't see as text or can't measure, and some things it doesn't check at all.
- Text across two backgrounds is measured against the one it contrasts with best. It needs a fix, tests and a fresh run over the test set (also listed on the evidence page).
- Text drawn as outlines, as matplotlib writes it, isn't seen as text, so its contrast isn't checked.
- Text filled with a gradient can't be measured. It is counted in the report but doesn't stop the mark (open question 14).
- Lines and shapes under 3:1 are listed for the author but don't decide the mark, because the tool can't tell which carry meaning (open question 13).
- Colour alone, and colour vision deficiency. Nothing checks whether a chart tells its series apart only by colour (WCAG 1.4.1), or how a theme looks to someone with colour vision deficiency (open question 13).
- The mark says the automated check passed, not that a theme conforms to WCAG, which takes a person as well.
06
Signed and protected files
Showing a theme changes no bytes, so it never breaks a signature. Adding or changing themes does.
- Signed files. The tool writes a new file, so a signature made before themes were added no longer verifies, and it doesn't warn about that yet. Work: warn before writing, and say whether themes could be added in an incremental update that a signature's permissions allow (open question 19).
- Protected files. The tool doesn't check whether a file's permissions allow changes before it rewrites it. Work: check, and ask for the owner password where it's needed.
07
The name in the file
The themes sit under the private key /XXThemes, which is meant for testing, not for
files shared between apps.
Work: agree the name with the PDF Association's working group, so files shared beyond testing carry the name that
will stay, and as few names as possible. Until then the prototypes keep /XXThemes, and apps read the
key from a list, so the agreed name is a one-line addition and files that already exist keep working.
?
Found a gap that isn't here?
Say so on the issue tracker, with a file if you can share one. The tracker is public: reading it needs no account, and posting needs a free GitHub account.
03
Comments and form fields
A comment has two parts. The mark on the page is stored in the file and is themed. The note's window and the comments list are drawn by the PDF app, so they follow the app.
The mark on the page (a highlight, a note icon, a drawn box) is stored in the PDF, usually with its own appearance: a small drawing made by the app that added the comment. That is what a theme recolours. The note's text, its pop-up window, the list of comments and their replies are not drawn from the file: the PDF app shows them from the comment's text in its own interface, so they follow the app's own light or dark setting, not the document's theme.
The tool works through a comment's appearance the same way as the page, and moves its colour entries (
C,IC, and the text colours inDA,DSandRC) into objects a theme can replace. The objects test has all 28 kinds of comment, and every form field's appearance is drawn in each theme's colours.