tiny.filigree.drawFallbackUtf8
Defined in tiny.filigree.
Reuses caller-provisioned output; replaces its prior run.
Source
Source: lib/filigree/src/render/text.zig:96
zig
/// Reuses caller-provisioned output; replaces its prior run.pub fn drawFallbackUtf8( allocator: std.mem.Allocator, output: *shape.Output, canvas: Canvas, shaped_font: *const shape.Font, fallback_candidates: []const fallback.Candidate, text: []const u8, pixel_size: i32, origin_x: i32, origin_y: i32, options: DrawOptions,) !Metrics { var context = try fallback.Context.init(allocator, .{ .script_runs = .{ .max_source_units = text.len }, .output = output.capacity.limits, }); defer context.deinit(); var segments: std.ArrayListUnmanaged(fallback.Segment) = .empty; defer segments.deinit(allocator); const input = fallback.Input{ .base = .{ .font = shaped_font, .text = .{ .utf8 = text }, }, .candidates = fallback_candidates, }; try context.shapeRunSegmented(input, output, allocator, &segments); return try drawFallbackGlyphRun( allocator, canvas, input, output.run(), segments.items, pixel_size, origin_x, origin_y, options, );}Source: lib/filigree/src/root.zig:109
zig
pub const drawFallbackUtf8 = render.drawFallbackUtf8;Also reachable as
Audit
| Definitions | 1 |
|---|---|
| Public names | 2 |
| Members | 0 |
| Version | 26.7.0 |
| Revision | daab053ee433 |