mirror of
https://github.com/storytold/texturecraft.git
synced 2026-11-21 15:00:42 +01:00
resource.text draws one or more lines of text, shaped with harfrust (kerning, ligatures, joined scripts) from the font's outlines (skrifa) and filled by a non-zero scanline rasterizer, cropped to the ink, as an image resource: white for the brush alpha, or a color for a decal. text.fonts lists the installed families and styles, read from each font file's name table only (246 families in 80 ms here); Ubuntu Light and Hack from the UI's built-in fonts are always there and are the fallback in the browser. - Properties > Alpha > Text: the text, a font and style, Use as brush alpha and Place as decal (in the tool's base color). - Image alphas keep their proportions (their longer side spans the stamp), so a line of text stays a line; image thumbnails are letterboxed and show alpha. - harfrust 0.12 and skrifa 0.44 are the versions egui already builds, so the lockfile gains no packages. Fixes #40