Repository navigation
A patch release (the 0.6.x line continues) with three breaks, listed under Breaking: Router::go
and RouteNavigator::go now make the stack exactly the matched chain, frust-shell-common's
non-default gpu feature replaces install_gpu_handle and gpu_handle with GpuPublisher,
with_gpu_handle and gpu_handle_generation, and the frust-shell-ios ffi_glue functions that
dereference a caller's pointers are now pub unsafe fn, with init also taking a pre_init
closure. Narrow source breaks are marked in Changed with their migrations: new MainAxisAlignment
and PathStyle variants, PageParity::SpillPool with MAX_LIVE_PAGES raised to 5,
#[non_exhaustive] TextStyle, the new InspectNode::detail field, the pre_init parameter on
Android's native_init, and added variants or fields on Capability, Method, RenderCommand,
RenderEvent and CompiledFrame. Behaviour changes to published APIs are marked there too:
AnimationController::reverse() at 0.0, PaintCtx::frame_time(), frust::gpu::with_context, the
facade's default complex-scripts feature (about 3 MB per app), the OS text scale on default-size
Text, frust_paths::atomic_write and data_dir, and frust-i18n locale negotiation. The release
adds four plugin crates (frust-background-task, frust-device-info, frust-permissions and
frust-photo-library), file and photo access on Android and iOS, frust::time, the
frust::testing::Tester driver, frust::motion::presence and snap-point detents, glass_surface,
stroke caps and joins, rich text spans, and font features and decorations. Apple's hvgl-only system
fonts (PingFang) now draw from the glyph atlas.
Breaking
Router::goandRouteNavigator::gonow make the stack exactly the matched chain, as their docs
said and as go_router definesgo. They used to replace only the top page, so pages below it
survived. Migration: to keep a page below a shell or another page, make it a parent in the route
table (Route::new("/", ..).child(shell_route(..))); a hand-written pop to the root beforego
can go. What follows from it:- A page whose matched path is unchanged keeps its state and takes the new params, and a shell
page survives anygowhose chain crosses it. A parent page in a matched chain publishes its
own path inroute_stack, and apushplacing a shell from its parent page stacks only the
shell. - A warm deep link replaces the stack (
handle_locationis ago), and one matching no route
makes it a single error page. An app receiving links no route is for, such as an OAuth callback,
declares a route for them or handles them beforetrack(). gocloses route-less overlays, including a non-dismissable one over a page it keeps; a
security gate must be a route redirect. A removed page'son_resultfires once with an empty
result, on thego's own frame.- Only the top page animates, with its route's transition or the navigator's default. Removed
pages stay alive until it settles, though depth and back already report the new stack. Ago
applied in a navigator's first build starts no transition, and when severalgocalls land in
one frame the last wins and the earlier pages are not built.
- A page whose matched path is unchanged keeps its state and takes the new params, and a shell
frust-shell-common's non-defaultgpufeature:install_gpu_handleandgpu_handleare
removed. A shell now publishes through an RAIIGpuPublisherinto a replaceable,
generation-tagged slot. Migration: hold aGpuPublisherfor the device owner's lifetime and call
publish(generation, make); read withwith_gpu_handle::<T, _>(f)(the handle is current only
for the call) and watchgpu_handle_generation()to detect a replacement.frust-shell-ios: 29 of the 32ffi_gluefunctions, and the matchingios_app!exports, are now
pub unsafe fnwith a Safety contract each, because they dereference a pointer the caller passes;
system_ui_state,set_surface_modeandset_present_syncstay safe.ffi_glue::initalso
gains a requiredpre_init: impl FnOnce()parameter beforemake_app; it runs first, inside the
function's panic guard and before the GPU device exists, and a panic in it makesinitreturn
null. C symbols and signatures are unchanged, so Swift callers are unaffected, and so are apps
usingios_app!, which passes the closure. Migration: a Rust caller of those functions wraps the
call inunsafeand honours the contract on each, and passes|| {}toinitor a closure that
runs early setup such asfrust::gpu::request_optional_features(..).
Added
frust-background-task(new plugin crate): add it from thefrustTUI's Add Plugin dialog, then
callfrust_background_task::install()in the app's setup. It backsfrust::BackgroundTaskwith
an iOS background-task assertion or an AndroidshortServiceforeground service
(FOREGROUND_SERVICE, a low-priority notification, noPOST_NOTIFICATIONSrequest). A refused
start is the no-op guard withis_granted()false; a watchdog of about 150 s bounds the service
andexpired()signals the app to cut work short. Apps targeting Android 14+ must make a Play
Console declaration, or opt out withtools:node="remove". Checked on a Pixel 5 (Android 14) and
an iPhone SE.frust::BackgroundTask(begin,expired,is_granted,end; dropping it ends the task
exactly once, from any thread): a no-op on every platform until the plugin provides a backend,
which it does only on iOS and Android, and abeginwith no backend logs one warning on those
two. The plugin installs only when no backend is set. The sanctioned pattern: a
Timer::flush_on_backgroundcallback callsbeginon the UI thread, then
spawn_blocking(write + drop(task))(not on web, wherespawn_blockingpanics).frust::time::{sleep, Timer, Duration}:sleep(duration)is an awaitable wall-clock delay (a
real browsersetTimeouton web, cleared when dropped or cancelled; durations abovei32::MAXms
clamp and a background tab may throttle it).Timer::new(duration, callback)runs a callback
once, withcancel,is_active,fire_nowanddetach; it is cancelled when dropped and with
its owner, and the callback runs under the owner that armed it. A timer fires on the next desktop
loop turn or mobile display tick while resumed; nothing ticks regularly while backgrounded, so a
due timer may fire on the first tick after resume or in a shell's background pump.
frust::spawn_local_scopedisspawn_localbound to the calling owner.Timer::flush_on_background()runs a timer's callback synchronously at the first of the app going
inactive or hidden (also on focus loss, once). Only synchronous work in it is guaranteed to
complete before suspension; work it spawns is not, and no background-task assertion is provided.
Native debug builds log a warning when a callback runs over 8 ms or a drain over 16 ms, because
the OS lifecycle callback is blocked meanwhile; release and web builds do not measure.MemoryPressure(Moderate,Critical):AppLifecycleListener::on_memory_pressure, the
shell-facingpush_memory_pressureand the diagnosticlast_memory_pressure(), independent of
AppLifecycleState. iOS reports its memory warning asCritical; Android mapsonTrimMemory
levels (RUNNING_MODERATE,RUNNING_LOW,BACKGROUND,MODERATEtoModerate,
RUNNING_CRITICALandCOMPLETEtoCritical); macOS reports a libdispatch source; Windows,
Linux and web report none.- On
Criticalpressure iOS and Android trim the render caches (SurfaceRenderer::trim_memory/
EngineRenderer::trim_memoryhold retained pages to the plain 32 MiB budget and clamp atlas
growth, one-way until the renderer is rebuilt); macOS only reports. iOS reaches this through the
additive C exportfrust_memory_warning(frust_ffi.h, called byFrustViewController).
frust_render::set_reported_device_memoryreports device memory where there is no
/proc/meminfo, and underperf-traceiOS logs
frust-perf ios-mem phys_footprint_kib=<n>|unknownabout once a second.
frust build ios --define FRUST_FORCE_MOBILE_TIER=1forces the plain tier. frust::paths::{data_dir, cache_dir, atomic_write}: the platform data and cache directories and
the write-to-temp-and-rename helper, re-exported fromfrust-pathsso an app depending on the
facade alone can place caches, sidecars and export staging; the module docs say what each platform
backs up.frust-photo-library(new plugin crate):PhotoLibrary::pick(&PickOptions)opens the system
photo picker on Android and iOS (no permission or Info.plist string needed) and a native file
dialog on desktop, with a media filter, a limit, throttledon_progressreports (PickProgress)
and aCancelToken. Mobile picks are copies in an app cache, reclaimed withclear_pick_cache
(PickedItem::is_copy);pickblocks, refuses the UI thread on mobile and allows one pick at a
time (PhotoError::Busy), and cancelling removes partial copies (PhotoError::Cancelled). The
photo-libraryregistry entry adds the Gradle module and thePhotosUIlink.frust-photo-libraryoptionallibraryfeature (Android media read permissions,
NSPhotoLibraryUsageDescription, thePhotoslink): browse withPhotoLibrary::albums,assets
(newest-first pages with anAssetQuery) andthumbnail(straight-alpha RGBA8,FillorFit,
a byte-budgeted cache withset_thumbnail_cache_budgetandclear_thumbnail_cache), plus
manage_limited_selection. Browsing is read-only and never takes the pick guard; iOS picks carry
asset_idunder the feature.PhotoLibrary::export_original(&AssetId, &ExportOptions)(library) writes an asset's untouched
original or edited bytes to a file, withallow_network, progress and aCancelToken; the
default destination is left alone byclear_pick_cache.PhotoLibrary::save(&SaveRequest)(the
savefeature) files an image or video into Photos orMediaStore, optionally into an album.
PhotoLibrary::scan_folder(&FolderGrant, &FolderScan)pages a granted folder's images and videos,
newest first. NewPhotoErrorvariants:NetworkRequired,MissingUsageDescription,
InvalidRequest. Stored location is kept by Android browse and export with Media location granted
and by the iOS picker, and zeroed by the Android Photo Picker
(photo-library-android-location-redacted).frust-permissions(new plugin crate): onestatus/request/open_settingsAPI over
Android runtime permissions and Apple authorization for photos (read/write or add-only), camera,
microphone and media location (the location stored inside photos, never device position). Each
permission is an opt-in cargo feature, and the registry entry (photos,photos-add,camera,
microphone,media-location) adds the matching manifest permissions, Info.plist strings,
framework links and macOS entitlements. Linux, Windows and web answerUnsupported.frust-device-info(new plugin crate):DeviceMemory::query()reports total RAM, the Android
low-RAM flag, system-available memory (Android, Linux, Windows) and the iOS per-process headroom,
so an app can size caches on Android 14+, where no foreground trim-memory level is delivered any
more.frust-file-dialogson Android (Storage Access Framework) and iOS
(UIDocumentPickerViewController):open_fileandopen_filesnow work, returning app-private
copies;save_filestill answersUnsupportedthere, so use the newFileDialog::export_file
(ExportOutcome). Also new:pick_folderwith persistableFolderGrants (token,restore,
local_path,list,release;FolderEntry;ListOptions) andFileDialog::cancel/
on_progresswithCancelTokenandFileProgress. UI-thread calls are refused withUiThread;
web is unchanged.FileDialogErrorgainsUiThread,NoPresenter,PlatformNotInitialized,
AccessLost,Io,PlatformandCancelled.Share::filesandShare::files_anchoredshare one to 64 files: the Android chooser (through a
FileProviderin the plugin's new Gradle module), the iOS activity sheet and a macOS sharing
picker; Linux and Windows answerShareError::Unsupported. On AndroidOkmeans the share is
enqueued, with files copied on a background thread and any failure logged under tagFrustShare.
An existing app re-runs Add Plugin forshareto include the module; text and URL sharing are
unchanged.frust-database:Database::schema_version,Database::execute_batch(many statements in one
transaction) andDatabase::migrate(&[Migration]), one transaction per step with
PRAGMA user_versionbumped inside it, identical on both engines. A stored schema newer than the
last migration the app knows is an error,DatabaseError::Migration(the new variant, also
returned for an invalid list), so a downgraded binary cannot read a schema it does not know.SharedPreferences::in_memory(): a public, infallible, process-local store that is never
persisted; clones share the map.frust::testing::Tester(facadetest-supportfeature): a state-generic headless driver under
its own child reactive owner.pump/pump_and_settle/pump_until;tap/press/
long_press/drag/timed_drag;start_gesture/start_touchwithmove_by/move_to/
up/up_at/cancel;find::{text, label, role, by_type},get_semantics/bounds/
perform_action;scene/semantics/inspect/send;set_metrics/resize. Built with
new,with_options(TesterOptions) ornew_with, with no process-wide lock, so Tester tests
run in parallel.Tester::pump(Duration)drives a per-thread virtual clock:frust::timesleeps andTimers fire
deterministically, stepping through each deadline in order (a chain or re-armed timer inside one
pump fires at its own virtual time).pump_untilremains the real-time wait, and any future
polled off the Tester's thread stays on wall time, includingfrust::spawnanduse_taskfetch
futures. The hook isfrust-reactive'stest-supportfeature (forwarded by the facade's):
time::test_support::{install_virtual_clock, advance, now}.Tester::{text_runs, text_overflows, assert_no_text_overflow}andTextRun: list every text run
with its geometry and flags, and fail a test when one is cut or sticks out. Containment stops at a
clipping ancestor: content a scroll, list or page viewport hides isTextRun::hiddenor
clipped, never an overflow.frust::testingre-exportsInspectDetailandTextInspectnext
toInspectNode, andfrust::authoringre-exportsTextWidget.frust::testing::{semantics_of, scene_of, scene_of_with}(SceneOptions): one-shot helpers for
an out-of-tree design system, enabled by thefrust-uitest-supportfeature from
[dev-dependencies], which also makesPaintCtx::for_testavailable.test-supporton
frust-textandfrust-widgetsexposes the sharedLocaleSlotGuardover the default-locale
slot.GestureDetectortap callbacks:on_tap_down,on_tap_up(beforeon_tap) andon_tap_cancel,
with#[non_exhaustive]CopyTapDownDetails/TapUpDetails(local_position) from
frust-ui. Down fires at once; a slop or bounds exit, a stolen or system cancel, or a second Down
cancels, and exactly one up or cancel follows each down (leaving the bounds cancels but a later
on_tapfires).GestureDetector::on_double_tapandDoubleTapDetails { local_position }: two taps within 300 ms
and 100 px of each other (each within the 18 px slop), timed on the raw input clock. With it wired
the singleon_tapwaits out the window and is delivered afterwards, and a second press that
fails drops the first tap; detectors without it are unchanged.GestureDetectordrag callbacks
on_{vertical_drag,horizontal_drag,pan}_{start,update,end,cancel}with#[non_exhaustive],
local-onlyDragStartDetails/DragUpdateDetails/DragEndDetails. Axis recognizers start
after 18 px along their axis, pan after 36 px; the first to cross wins and a same-axis scroll view
takes the drag first. Release velocity is on the raw input clock, andcancelarrives on the next
state-bearing pass, not inside theCancelevent.
drag_start_behavior(DragStartBehavior::{Start, Down})reports the start where the slop was
crossed (the default) or at the press point.- A second pointer contact landing while a
GestureDetectorpress is pending fireson_tap_cancel
with no long press, tap or double tap, whenever a contact-capturing widget (pinch_detector,
pan_zoom) sits below the detector. A bare detector never hears the second finger
(gesture-second-contact-needs-a-contact-captor). - Rich text spans:
frust-textTextSpanandTextContext::layout_rich/layout_rich_bounded
lay out differently styled pieces as one paragraph, andfrust-widgetsrich_text(spans)and
span(text)add per-span size, colour, weight, family, italic, letter spacing, locale, font
features, decorations and themed roles, resolving theme and the OS text scale likeTextView. A
truncated line paints its ellipsis within the width unless the ellipsis alone is wider. TextStylewith_<field>builders for every field, chained fromTextStyle::new(size, color)or
Default.OverflowWrap(Normal,Anywhere;frust::authoring::text),TextStyle::with_overflow_wrap
andTextView::overflow_wrapset per-paragraph wrapping and join the shape-cache key;
TextView::locale(..)tags a paragraph without marking color or family explicit, so it keeps
theme defaults and the OS text-scale rule.- OpenType font features:
TextStyle::with_feature(tag, value)/with_features(..)(a later
setting of a tag wins) andTextView::font_feature(s)/tabular_figures(). Text decorations:
TextDecorationonTextStyle::with_decoration,TextView::underline()/line_through()/
decoration(..)andTextLayout::decoration_rects, painted as plain fills.TextInputdraws
none (see LIMITATIONS). MonospaceFamilytheme extension (Theme::monospace_family(), attached by the shadcn, beUI and
Glyph themes) withTextView::themed_mono_family(), andTextInputView::themed_family(role)/
themed_mono_family()so a theme swap re-faces typed text; the catalog text fields use them.TextLayout::{line_count, max_width, did_exceed_max_lines, is_ellipsized, overflows_width}report
how a laid-out block fit its limits, andTextLayoutis nowSync.
TextContext::notdef_glyph_count()counts.notdefglyphs per context across retained layouts,
the shape cache and the editor.TextContext::font_cache_stats()
(FontCacheStats { write_failures, written_generation, dirty, attached, persistent }) and
BackgroundFlush::went_to_background_outcome()(BackgroundFlushOutcome, per-context results;
went_to_backgroundstill returns the flushed count), re-exported throughfrust_text,
frust_shell_commonandfrust::authoring::text. A report whose every flush failed leaves the
once-per-transition latch unarmed so the next hide retries.frust::authoring::text::LocaleStamp(frust_text::LocaleStamp):for_style/is_current
stamp a cached layout with the default-locale generation; read it before shaping and store it with
the layout.frust-widgetsText/TextInputand the glyph, material, beUI, shadcn and
native-widgets layout caches follow that rule.frust-themeOS text scale:TextScale,TypeScale::scaled,Theme::with_text_scale,
Theme::text_scale,Theme::authored_type_scale,TextScale::clampedandscale_style. The
additive iOS C exportfrust_set_text_scale(frust_ffi.h) lets a Swift embedder that hosts
frust outsideFrustViewControllerpush Dynamic Type, which the shipped controller does itself.glass_surface(child)(GlassSurfaceView, flat fromfrust) paints one tier of the theme's
glass scale behind its child: an outside shadow, rounded clip, backdrop blur and washes, specular
hairline..tier(GlassTier)picksControl,Bar(default) orChromefromGlassScale::tier;
.corner_radius(f64)clamps to a capsule, and.material(..)wins over the theme's tier. Without
either it paints opaque#EFEFEF. A material's blur is a Gaussian sigma in logical px (CSS
blur(Npx)is sigma N), clamped by the engine.set_max_backdrops_per_frame(n) -> usizeandmax_backdrops_per_frame()(flat fromfrustand
frust-render): the per-frame backdrop-blur cap is app-configurable, process-wide and clamped to
1..=16(defaultMAX_BACKDROPS_PER_FRAME4, ceilingBACKDROP_CAP_CEILING). A frame over the
cap is still refused whole (EngineError::TooManyBackdrops), and
SceneCompiler::compile_with_backdrop_capcompiles against an explicit cap.- Stroke caps, joins and miter limit, and the even-odd fill rule, in
frust-sceneand
frust::authoring::scene:StrokeCap,StrokeJoin,StrokeStyle { cap, join, miter_limit },
FillRule, andfill_path_with_rule/stroke_path_styledonSceneBuilderandPaintScene
(defaults fall back tofill_path/stroke_path). A non-finite or below-1 miter limit is
refused asInvalidGeometry. A dashed closed subpath with a skipped stretch joins its seam under
non-round styles, and the culling reach of a mitred stroke caps the miter factor so a huge limit
stays finite. The newPathStylevariants are a narrow break, below. - Stroked icons:
IconShape(Path/Circle/Rect),IconPaint(Strokedefault,Fill),
IconElement(stroke/fill,with_opacity,with_dash,with_stroke_width) and
StrokedIconSource, converted toIconDatabyFrom<StrokedIconSource>or
IconData::from_elements(from_styled_elementswithIconElementStylefor runtime-built
icons).IconData::resolve()returns one fillable outline for fill-only slots andis_stroked()
reports one;IconView::stroke_width(f64)overrides the width. - Framework haptics in
frust-core(flat fromfrustandfrust::authoring):#[non_exhaustive]
HapticFeedback(Selection,Light,Medium,Heavy,Success,Warning,Error),
HapticSink, the last-winsset_haptic_sink,haptic_sink_installed()andperform_haptic()(a
no-op without a sink); thefrust-hapticsREADME shows the wiring.MaterialHapticsforwards to
the sink when no Material hook is set (SliderTickmaps toSelection,Noneto nothing). - Animation time scale:
set_animation_time_scale(f64) -> bool(MIN_ANIMATION_TIME_SCALE0.01 ..=
MAX_ANIMATION_TIME_SCALE100.0),animation_time_scale()and the raw clock
PaintCtx::input_time(), read by gesture timers, caret blink, velocity timestamps, drag hold,
auto-scroll, the catalog tooltips and the material and shadcn press latches. Devtools adds the
authenticatedset_animation_time_scalemethod, theanimation_time_scalecapability and
DevtoolsClient::set_animation_time_scale; the protocol stays v1, and a scale a client set resets
to 1.0 when it disconnects. frust::motion::detent(flat infrust::motion):Detents, pure NaN-safe snap-point math
(open_progress,drag_to,release_target,settlereturningDetentReleaseunder a
DismissPolicy), and the headlessDetentController, whose release hands the fling velocity to
spring_to_with_velocity(with_fling_velocity, defaultDEFAULT_FLING_VELOCITY).SpringBack
snaps back to open; onDismissthe controller stops and holds progress and the caller owns the
exit animation.frust::motion::presence:Presenceandpresence(open, child)with.timing(enter, exit)and
.on_exited. The child stays mounted: always built and laid out, painted only while visible,
input only while open, semantics only while visible. Reversing a duration ramp is value-continuous
and a spring value- and velocity-continuous;on_exitedis delivered on the next frame's
Housekeeping event, once and only after an exit has painted, so it is a cleanup cue rather than a
correctness gate. Underreduce_motionit runs a linear reduced fade. A settled child paints
without an alpha layer.AnimationController::velocity()and the velocity-carrying retarget
spring_to(target, SpringDesc)/spring_to_with_velocity(target, velocity, SpringDesc)in
frust-core, so a fling or release velocity carries into the spring.frust-theme
MotionExtras { extended: 800.0, reduced_fade: 120.0 }(ms; read withMotionExtras::of(theme)/
reduced_fade_duration(); flat asfrust::MotionExtras) and
resolve_spec_with(spec, scheme, reduced_fade).column()/row().gap(f64): a fixed space between consecutive children (negative or NaN is
0).Route::transition(TransitionSpec)andRouter::push_with(location, PushOptions): precedence
push options, then route, then navigator default, all collapsing under reduce motion.
PushOptions::barrier(Color)andbarrier_dismissible(bool)add a route-owned modal scrim
following the route's eased progress; a press the page leaves unhandled dismisses through its
BackPolicyunless it lands on content.Widget::hit_test_self(provided, defaulttrue):falsemakes a widget transparent to pointer
hits beside its children; layout wrappers such asPadding,SafeAreaandAlign, and a
Containerthat paints nothing, returnfalse.Widget::inspect_detail, the#[non_exhaustive]InspectDetailenum andTextInspectlet a
widget attach typed detail to its inspect node. The text and rich-text widgets report their last
layout through it,EitherWidget,EitherOf3Widget…EitherOf8WidgetandShortcutsWidget
forward it, andInspectDetail::Clipmarks the scroll, list, page, viewport, pan-zoom, navigator
and clipping sliver widgets.frust::Layer(withLayer::IDENTITY) andfrust::resolve_layers, besideTransitionDriver,
make_driverandresolve_spec, soPageTransition::Customis authorable out of tree.SceneTextureHintsfor externally bound textures (filter:
SceneTextureFilter::{Linear, Nearest, NearestWhenMagnified}, and a caller-assertedopaque):
EngineRenderer::bind_texture_withandExternalFrame::bind_texture_with, re-exported from
frust-engine,frust-renderandfrust::gpu. Anopaquetexture joins the depth-writing
opaque pass; unhinted textures behave as before.- Texture bus:
SourceFormat::Bgra8(premultiplied) and sub-rect updates through
SourceFrame::with_update_region/UpdateRegion(re-exported as
frust::texture::UpdateRegion), refused with a one-time warning when no same-size, same-format
texture is shown. The bus detects a GPU device change by generation and recovers region producers
on the new device. - GPU device identity:
DeviceHandle::generation()(process-wide, monotonic, non-zero, shared by
clones),DeviceHandle::is_lost()(latched by the device-lost callback) and
frust::gpu::device_generation(). Android and iOS publish their live device to
frust::gpu::with_context, as desktop does. frust::gpu::request_optional_features/requested_optional_features(and
frust_render::missing_requested_features): a process-wide, adapter-conditioned union of optional
wgpu features honoured by the shells and the headless renderer; a missing feature is left out.
app!(Root, gpu_features = { .. }, ..)(facadegpufeature;@pre_initonandroid_app!/
ios_app!) requests them before the device is built, and on Android a pre-init device lacking one
is rebuilt.- External passes:
ExternalFrame::drain_id()anddevice_generation()identify the surface drain
and device a pass records for.HeadlessRenderer::render_with_passesand
render_draining_registryrender passes offscreen (EngineOraclehas the same two), with
ExternalFrame::frame_indexcounting that renderer's own renders from 0 on the explicit path.
frust::gpu::headlessre-exports the headless types and golden env-var names so an app can
golden-test its own pass.frust_render::ExternalPassDrain(doc-hidden, shell-facing) is the
per-engine drain state a custom shell passes torun_external_passes. - Refused frames:
EngineRenderer::prepare(every plan-stage refusal) andencode_prepared/
encode_prepared_traced,RegionCopyMode::of_usage,SurfaceRenderer::engine_refusals()
(EngineRefusalReport { count, first_reason }) andfrust_gpu::lifecycle::MAX_TRANSIENT_SKIPS
(3). TheFRUST_RENDER_INJECT_REFUSALknob (plan:N/record:N) refuses every Nth frame, in
release builds too. EngineRenderer::set_synthetic_oblique/synthetic_obliqueandset_glyph_run_cache/
glyph_run_cacheforward those switches on the renderer, matchingSceneCompiler.
SceneCompiler::glyph_resident_texels()andglyph_texel_budget()report what the glyph atlas
charges against its budget.- Bitmap-strike colour emoji render on the engine: bitmap-first faces (sbix without outlines, CBDT)
take an engine-side route, drawn by CoreText on iOS and decoded from PNG/dupe/flip records
elsewhere, each strike charged and refunded its exact atlas slot. Strikes over 512 px are refused;
faces with outlines draw outlines; BGRA and mask strikes still do not draw. - Apple's hvgl-only system faces (PingFang) draw from the glyph atlas instead of as outlines, by
default (SceneCompiler::set_hvgl_atlas/EngineRenderer::set_hvgl_atlasswitch the route,
OutlineReason::Hvglis the fallback), checked on an iPhone 13 mini (iOS 27.2).CompiledFrame
gainshvgl_atlas_drawsandhvgl_outline_fallbacks, and thefrust-perf encline appends the
route's counts. Faux bold and faux oblique are not applied on this route
(text-hvgl-synthesis-not-applied), and two macOS system faces have no hinting instance, so a
hinted faux-bold request on them is nearly invisible (text-hinted-faux-bold-unhintable-face). - hvgl faces are verified against CoreText: each variation copy is read back and each requested axis
classified as applied, contradicted (refusing the instance,hvgl_variation_mismatches) or
unreported (drawing CoreText's copy,hvgl_variation_unverified()), and opening a face compares a
cmapsample (hvgl_bytes_mismatches).SceneCompiler::hvgl_outline_hits/
hvgl_outline_misses, the per-frameCompiledFrame::hvgl_unavailable_glyphsand the cumulative
counter round out the diagnostics. Each kind warns once per open face; off Apple every
hvgl-classified glyph counts as unavailable. - Material
zh-Hansstrings andfrust_i18n::Locale::likely_script. - The playground gains Timers and guarded write buttons on its Network page, Picker, Browse,
Originals and Folders panels, Export file, Pick folder and Cancel on its Desktop page, a Photos
section and a "GPU pass" section.
Changed
- Breaking (narrow):
MainAxisAlignmentgainsCenter,End,SpaceBetween,SpaceAround
andSpaceEvenly, distributing leftover space only on a bounded main axis with no flexible child.
Migration: an exhaustivematchover it adds the arms or a wildcard. - Breaking (narrow):
PathStylegainsFillEvenOddandStrokeStyled { width, dash, style }
(rendered by the engine and the CPU oracle). Migration: an exhaustivematchoverPathStyle
outside frust adds the two arms, or reads throughPathStyle::fill_rule()/stroke()instead of
matching. - Breaking (narrow):
frust_engine::schedule::PageParitygainsSpillPool(SpillSlot)and
MAX_LIVE_PAGESgoes from 3 to 5: threeMAX_SPILL_PAGESslots serve a fan nested inside a fan
under a held ancestor and every tree whose isolated layers hold at most two isolated children,
costing up to +128 MiB of intermediates only on frames that use them. Migration: an exhaustive
matchneeds a wildcard arm or the newPageParity::is_spill()/spill_slot()
(PageParity::spill(n)builds one,Nonepast the limit). - Breaking (narrow):
TextStyleis now#[non_exhaustive]and gains the public fields
overflow_wrap,featuresanddecoration. Migration: build it with
TextStyle::new(size, color)orDefaultplus thewith_*builders; struct literals and
exhaustive destructures no longer compile outsidefrust-text. - Breaking (narrow):
InspectNodegains the public fielddetail. Migration: a hand-written
struct literal addsdetail: None. - Breaking (narrow): tooling and shell-facing types gained members:
frust_devtools_protocol::CapabilityandMethod(AnimationTimeScale,
SetAnimationTimeScale),frust_shell_common::RenderCommandandRenderEvent(TrimMemory),
andfrust_engine::CompiledFrame(fivehvgl_*fields). Migration: an exhaustivematchadds
the arms or a wildcard; aCompiledFramestruct literal or pattern adds the fields or... - Breaking (narrow):
frust_shell_android::jni_glue::native_initgains a required
pre_init: impl FnOnce()parameter betweencache_dirandmake_app; it stays a safe function.
It runs first, inside the panic guard and before the shell adopts the GPU device built at library
load, and a panic in it makesnativeInitreturn 0.android_app!users are unaffected, since
the macro passes the closure. Migration: a hand-written embedder passes|| {}, or a closure that
runs early setup such asfrust::gpu::request_optional_features(..); if the pre-built device
lacks a requested feature its adapter offers, the shell rebuilds it, a synchronous device build
at that launch. - Behaviour change:
AnimationController::reverse()at exactly 0.0 settlesDismissedwhere it
settledCompleted.forward()always settlesCompletedandreverse()alwaysDismissed,
whatever the start value (it can lie outside 0..=1 afterspring_to);animate_tosettles by
direction of travel. - Behaviour change:
PaintCtx::frame_time()returns the scaled animation clock (the shell clock
underset_animation_time_scale). Identical at the default scale of 1.0; code timing input should
readinput_time(). - Behaviour change:
frust::gpu::with_contextkeeps its signature but answers the current
device, which may change between calls. Do not keep device or queue clones across frames, and
rebuild device-owned resources whendevice_generation()changes. - Behaviour change: the facade's default features go from none to
complex-scripts(also on
frust-text), which carries dictionary line and word segmentation at about 3 MB per app
(docs/PERFORMANCE_BASELINES.md). Unspaced Thai, Lao, Khmer and Myanmar text wraps at dictionary
word boundaries and a Chinese/Japanese dictionary drives CJ word motion. Opt out by adding
default-features = falseto the facade dependency, which a scaffolded app declares as
frust = { package = "frust-ui", ... }(or tofrust-textlikewise): unspaced text then
overflows and CJ word motion falls back to per-character stops. Cargo unifies features, so every
library in the graph must also leave these defaults off; frust's own plugins do. - Behaviour change: default-sized
TextandTextInputfollow the OS text scale on Android and
iOS; explicit sizes do not. Scaffolded Android manifests gainfontScalein
android:configChanges, and an existing app should add it to keep state across a font-size
change. - Behaviour change:
frust_paths::atomic_write(alsofrust::paths::atomic_write) uses a
per-call temp file opened withcreate_new, so concurrent writers and same-stem files no longer
collide and a pre-placed symlink is never followed, and it returnsUnsupportedon the web
instead of panicking.data_dirandcache_dirreturnNonefor an empty or relativeHOME,
APPDATAorLOCALAPPDATA. - Behaviour change:
frust-i18nnegotiation is script-aware, sozh-TW,zh-HKandzh-MOno
longer resolve to azh-Hansbundle, and a language-only switch keeps its script. - Untagged text shapes (
locl) and line-breaks in the app default locale. ja/zh spans (style
locale, else the default) use Normal line-break strictness, so small kana and the prolonged sound
mark may start a line while kinsoku still keeps。,、and,off line starts; an explicit
TextStylelocale always wins. - The font-cache flush runs at the lifecycle
Hiddenedge instead of on pause or focus loss: iOS in
frust_did_enter_background(no longer atwillResignActive), Android innative_on_stop(no
longer atonPause), and desktop when every window is minimized, occluded or suspended (no longer
on focus loss), with a flush at exit, once per exit, including menu Quit. Web flushes nothing,
having no persistent cache. SurfaceRenderer::encodenow does the engine's planning, so a frame the engine refuses is skipped
before the swapchain is acquired, andencode_uscarries the plan CPU timesubmit_usused to.- Glyph admission is sticky: a run whose every glyph is already resident is served over the texel
budget, only a run that would insert is refused, and LRU eviction drains the excess. On iOS the
mobile_largetier starts at 3 GiB ofhw.memsize(4 GiB elsewhere), so 4 GB iPhones reach it,
raising the glyph atlas from 16 to 64 MiB and the retained-page budget from 32 to 64 MiB. - Faux-bold embolden is computed per side from the size-quantized basis at the route key, the
lowering and the resident plan, so the amount keyed and the amount drawn agree;
FontHandle::with_synthesisclamps skew to ±30 degrees and embolden to at most 0.5 em. - The per-frame backdrop cap counts only backdrops whose blur region reaches the frame target, so
one scrolled or translated clear of the frame (aScrollView's warm paint margin) no longer
counts; the up-front count can still over-count inside clipped or retained regions. - The
.notdefwarning names only the face, the script and the cluster count, never user text, and
fires once per (face, script). - The Material and shadcn overlay modals compute snap progress through
Detents, unchanged for
finite snap points; their fling-velocity constants now equalDEFAULT_FLING_VELOCITY. - Every reduce-motion collapse (navigator including the interactive edge-swipe settle, switcher,
AnimatedOpacity,card_switcher) runs forMotionExtras::reduced_fade(120 ms by default; 0
snaps with no frame request) instead of a fixed 120 ms, and thenetwork_imagefade-in collapses
to it under reduce-motion. - An
ExternalPassregistration'srecordis never run concurrently, even with two live surfaces. - The Android logger's level follows the
debug.frust.logsystem property
(adb shell setprop debug.frust.log debug; theFRUST_LOGvocabulary, cleared on reboot) instead
of being fixed atInfo; unset it staysInfoin every build.
Deprecated
frust_text::notdef_glyph_count()is deprecated in favour ofTextContext::notdef_glyph_count().
It still returns the process-wide total, now counted once per line table when its memo is filled
rather than once per paint.
Fixed
- A frame the engine refuses no longer freezes Android/Vulkan apps: a dropped un-presented swapchain
texture leaks its image on wgpu-hal 30.0.1
(gfx-rs/wgpu#5723), so frust no longer drops an
acquired texture while its swapchain lives. The main surface presents a backstop frame, a refused
overlay keeps its texture un-presented so its previous frame stays on screen, and the swapchain
reconfigures afterMAX_TRANSIENT_SKIPSconsecutive acquire timeouts
(engine-scheduler-skip-on-escalation,wgpu-vulkan-discard-texture-noop). - An interactive edge-swipe pop honours
reduce_motion: it collapses toReducedCrossfadeon its
first paint, the drag drives the alpha, the release settles on the reduced timing, and a
PageTransition::Customfn is not called. - The motion-token conversions behind reduce-motion, navigation transitions and the switcher no
longer panic paint: each usesDuration::try_from_secs_f64and falls back on a negative,
non-finite or too-large value. - The shadcn modal drops non-finite snap points, as Material already did, which fixes a possible
drag panic, and a non-finite settle target snaps to the open detent. - A second surface no longer keeps a stale external-pass binding after
unregister_external_pass:
each surface's drain reconciles against the registry and unbinds in its own engine. - Font-cache files: stale temp files are swept on both load paths (this process's after 10 minutes,
another process's after 24 hours), every live copy of a path writes through one writer so an older
snapshot never overwrites a newer one (file format v7 unchanged), and the first failed flush a
hook sees logs at warn. - The web shell's page-lifecycle listeners are owned by a guard that removes them on drop, and the
hide flush is skipped while the web tier has no persistent font cache. - DirectWrite resolution honours generic families for a generic-only request:
Monospaceresolves
to Consolas andSerifto Times New Roman, where every generic used to resolve to the Segoe UI
fallback. - A
Checkbox/Radiowith an empty label is exactly the control size tall (20 px) instead of
taking the host UI font's line height. frust-i18n: the language-id cache is bounded (256 entries) and the currency formatter cache is
bounded (64 entries), both approximate LRU.
Known issues
- An Android app aborts when an accessibility client is active (TalkBack, or a tool that queries the
accessibility tree such asuiautomator dump) and the window then changes. This predates 0.6.6.
The fix is an upstream change toaccesskit_androidplus a pin bump, and there is no workaround in
app code. Seeandroid-accessibility-service-abortin
docs/LIMITATIONS.md.