import { type FontFaceSetLike } from './faces.js'; /** Whether the engine has looked at `fontSet` before. */ export declare function isFontSetTracked(fontSet: FontFaceSetLike): boolean; /** * Look at `fontSet` again: the families whose loaded faces changed since * the last look get their measurements dropped (`evictFontFamilies`) and * are returned. The first look only records the set. Cheap when nothing * happened: the set is walked only when its size changed, while it is * loading, or once a face finished loading. `evict: false` records the * set without dropping anything (the caller drops what it knows changed). * `force: true` walks it whatever it reports: for a caller that has just * awaited `fontSet.load`, whose `loadingdone` is still to come. */ export declare function syncFontSet(fontSet?: FontFaceSetLike | null | undefined, options?: { evict?: boolean; force?: boolean; }): string[]; /** Told which families' faces changed (lower case). */ export type FontsChangedListener = (families: readonly string[]) => void; /** * Call `listener` whenever faces of a watched font set arrive or leave * (see {@link watchFonts}), after the engine has dropped what it measured * in their families: the host lays out again. Returns the unsubscribe. */ export declare function onFontsChanged(listener: FontsChangedListener): () => void; /** * Watch `fontSet` (by default `document.fonts`, or `self.fonts` in a * worker): when faces finish loading, the measurements of their families * are dropped — at most once per animation frame, however many slices a * burst brings — and the {@link onFontsChanged} listeners are told. * Calls nest; the returned function stops this watch. `prepareFonts` * starts one on the set it loads into. */ export declare function watchFonts(fontSet?: FontFaceSetLike | null | undefined): () => void; /** Whether `fontSet` is watched. */ export declare function isWatchingFonts(fontSet?: FontFaceSetLike | null | undefined): boolean; //# sourceMappingURL=fontSet.d.ts.map