Commit Graph
3 Commits
Author SHA1 Message Date
Jake WriterandClaude Opus 5.5 55fb795ba4 Always render at the identity's devicePixelRatio
Replace the display_scale option with the one behaviour: the browser renders
at the final config's window.devicePixelRatio (layout.css.devPixelsPerPx), so
(resolution) and the CSS geometry agree with it, whether the identity was
drawn, a preset or supplied. A pref the caller passes still wins. The fpgen
draw's ratio is no longer read, which gave a supplied 2.5 identity no scale
or a scale of 2.

Headful on a real monitor, the display clamp divides by the scale, and a
window that still needs more pixels than the monitor has raises a ValueError
saying so. The monitor is only known in pixels at scale 1 on Linux, so the
scale is applied to the bound there.

New guard: display-scale-resolution (spoofing), which fails on main.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 19:46:48 -06:00
Jake WriterandClaude Opus 5.5 1aafe467ed Warn when display_scale renders at 1
After MAX_SCALE_FIT_DRAWS fresh draws that did not fit the monitor at
their display scale, or for a supplied identity that did not, the
launchers rendered at 1 without a word, which is the contradiction
display_scale exists to remove. A preset was ignored the same way.

Both now emit a LeakWarning (display_scale_unfit, display_scale_preset
in warnings.yml). It is not silenced by i_know_what_im_doing, which a
supplied fingerprint requires anyway.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-23 14:49:13 -06:00
coffeegrind123andClaude Opus 5.5 e212071839 Render at the identity's display scale with display_scale=True
fpgen draws a screen at a display scale (1536x864 is a 1920x1080 panel
at 125%) and the browser reports that devicePixelRatio, but renders at
1: (resolution: 1dppx) and the CSS geometry then contradict the screen,
a pair no real machine reports (36% of Windows draws, 74% of macOS
ones; lang315/camoufox#41).

The new launch option display_scale renders at the drawn scale through
layout.css.devPixelsPerPx, snapped to a scaling step the OS offers.
Headful on a real monitor, the identity must fit the panel physically
at that scale: fresh draws are redrawn until one does, a supplied one
that cannot stays at 1, and the display clamp bounds the physical size.
It is off by default, since it changes how every page is rendered and
how large screenshots are. Both launchers take it.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-23 14:49:13 -06:00