The command line's files open before the first frame, which is what
applies the interface language, so their status line and notices came
out in English in every language. open_paths now applies it first.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The second questionnaire answer (Algeria). The earlier تدرج اللون read
as "colour gradient" beside Gradient تدرج. Hue, Hue/Saturation, Hue
Jitter and Hue Cube follow.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The preset file import status (`preset_files_ui::open`) asks for
"Imported {n} brush/pattern/gradient from {file}" plurals; the Arabic
catalog only had the style one, so these results showed in English.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Served script fallbacks were appended to every UI font family in the
order they arrived. A Japanese and a Simplified Chinese face both cover
Han, and egui draws a character with the first face in the stack that has
it, so a Chinese interface drew Han with the Japanese face when that one
had arrived first (fetched for a Japanese text layer, say). ui_faces now
puts the interface language's own served face first, so the stack a
language change rebuilds follows the language; and when that face arrives
after another served face, add_ui_face rebuilds the stack the same way
instead of appending. served::fallback_for_language gives the face.
This orders the served faces only; with an interface language that has
no served face (English), they stay in arrival order.
Review finding on #10006.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A served script fallback joins every egui font family, and egui panics on
a configured font it cannot parse: a host answering a font's path with an
error page, or serving a truncated file, stopped the web UI on its next
layout or font rebuild. add_ui_face now checks the face with
cjk::font_face_is_readable first, as the system-font fallbacks are
checked, and leaves an unreadable one out with a warning. The regression
test panicked in epaint's family.rs before the check.
Review finding on #10006.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
serve_fonts asks for the interface language's served script font once per
language, but the font manifest loads asynchronously: when the first frame
ran before it arrived, no fallback was registered yet, the request found
nothing, and an Arabic interface on an English browser stayed without its
font until the language changed. The manifest load now asks for the
interface language's font along with the browser languages'.
Review finding on #10006.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The web build has no system fonts and embeds no craft fonts, so an Arabic
(or Japanese, Chinese, Korean, Hindi) interface had no font for its labels:
served fonts were registered only in the document text engine. A served
script fallback now also joins the end of every egui font family, and the
font stack theme::install_fonts rebuilds on a language change includes it
again. The web shell asks for the interface language's script font, not
only the browser languages'.
Review finding on #10006.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Conflicts in perf/budgets.toml and docs/scorecard.md: both sides added perf rows (P80 here, P81 and P82 from #9942). Kept all three; scorecard regenerated with cargo xtask scorecard.
egui 0.37 lays text out with the Unicode Bidirectional Algorithm, so the
display-order rewrite #5385 added for egui 0.36 now reverses Arabic and
Hebrew layer names and the in-app title a second time. Names go to egui
as typed; the title line asks for a left-to-right paragraph so
"— PhotoCraft" stays at the right; bidi_text::elide cuts a right-to-left
name at its logical end and egui puts the "…" at the left.
Tests lay the text out with egui and compare glyph positions.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Honor CARGO_BUILD_TARGET in FreeBSD packaging for aarch64 release builds
package.sh took the arch from uname -m. The release VM is an x86_64 guest that
cross-compiles aarch64 with CARGO_BUILD_TARGET set, so an aarch64 build was
named freebsd-x86_64 and read binaries from the host target dir.
Read the arch from CARGO_BUILD_TARGET when it is set, and read binaries from
target/<triple>/release. Skip the man-page example and the --version run when
cross-building, since the aarch64 binaries cannot run on the x86_64 guest.
Unset CARGO_BUILD_TARGET keeps the old behavior.
* Reject unsupported CARGO_BUILD_TARGET and resolve host-tuple in FreeBSD packaging
Accept only x86_64-unknown-freebsd and aarch64-unknown-freebsd. Any other
target exits 2 before any build, so a non-FreeBSD target cannot be packaged
as an x86_64 FreeBSD archive.
Resolve cargo's host-tuple alias to the real host triple before choosing the
binary dir, so the path matches cargo's output.
* Skip the photocraft-cli --version run when CARGO_BUILD_TARGET is set
A target build's binary may not run on the host (aarch64 on the x86_64 VM),
and under set -e the smoke run would fail the release after the archive is
written. The native path (CARGO_BUILD_TARGET unset) still runs it.
step_damage narrows a layer whose only change is in its surfaces (pixels, mask, type,
smart-object and fill caches) to the bounding box of the tiles that differ: a merge walk of
the two tile maps, pointer compares only. A mask's tiles grow by its feather, all of them by
the layer's effects and the effects of the groups around it, never past the layer's whole
extents. A frame-spanning effect whose frame moved keeps the whole extents (#4053). Undo,
redo and History jumps get it for free: undoing a 60 px dab on a full-canvas layer redraws
its tiles, not the canvas, and so does a fill or filter on a small selection.
The painting commands' own damage rects go through one door, Session::hint_damage, which
intersects them with the edit's damage. Debug and test builds count a hint that misses a
changed tile in Session::damage_misses and log it; nothing panics. refresh_type_layers reports
step_damage instead of None.
Deleted: note_damage and layers_damage (identical to step_damage after layer.setProps and
layer.translate), note_inert_insert (step_damage already steps over inert layers, #1771),
and the engine's siblings_of they used.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Track-only rows that check they hit the whole-document-redraw path and
print the refreshed pixel count: undo of a brush dab on a 16-bit
15000x10000 full-canvas layer (reps capped at 5) and a fill of a 2 %
selection on a 24 MP full-canvas layer.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Only the outermost run_command writes the frame's command stage, so a nested
run (file.save -> layer.smartObjects.saveContents, actions.play -> its view
steps) isn't counted twice. ui_frame's UI moves into ui_body and finish_frame
runs after it on every path, including the screen picker's wait modal; the
pass before fonts are ready closes it too.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Track-only row, the slow-frame recorder's worst case. A 24 MP photo plus
three full-canvas blended copies (Multiply, Screen, Overlay); each sample
toggles the top copy and times one harness.step(), so every frame
recomposites all 24 MP on the CPU (the photo's tiles are never uniform,
which keeps the reduced render's one-colour shortcut out of the way).
The row errors unless each frame recorded a CPU refresh covering at least
95 % of the canvas, so it can't silently take a fast path. 10 samples.
crop_ui.rs moved to tools/; the PR's builders replace main's Clippy extractions of the same code; #6723's Color Lookup save carried into the moved encoder.