╭─────────────╮ │scroll to top│ ╰─────────────╯ ╭ SubTitle.zig ─────────────────────────────────────────────────╮ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ │ ╰───────────────────────────────────────────────────────────────╯
╭────╮ ╭ clone ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ╮ │http│ ssh │ │ ╰────╯ ╰ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ─ ╯
451 var utf8_buf: [4]u8 = undefined; 452 const len = try std.unicode.utf8Encode(cp, &utf8_buf); 453 try rows[text_row].appendSlice(allocator, utf8_buf[0..len]); 454 } 455 } 456 } 457 458 var out: std.ArrayList(u8) = .empty; 459 errdefer out.deinit(allocator); 460 try out.appendSlice(allocator, rows[0].items); 461 try out.append(allocator, '\n'); 462 try out.appendSlice(allocator, rows[1].items); 463 return out.toOwnedSlice(allocator); 464 } 465