{"id":22694374,"url":"https://github.com/ringtailsoftware/zvterm","last_synced_at":"2025-10-23T19:51:11.345Z","repository":{"id":267169399,"uuid":"900444337","full_name":"ringtailsoftware/zvterm","owner":"ringtailsoftware","description":"Zig binding for libvterm, a terminal emulator core","archived":false,"fork":false,"pushed_at":"2025-01-01T23:10:30.000Z","size":1614,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-10T22:40:50.442Z","etag":null,"topics":["libvterm","terminal","terminal-emulator","zig","zig-package"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ringtailsoftware.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-12-08T19:36:46.000Z","updated_at":"2025-03-17T21:21:22.000Z","dependencies_parsed_at":"2025-01-01T13:22:28.421Z","dependency_job_id":"1185d9f6-605d-4689-84c4-e15f15724605","html_url":"https://github.com/ringtailsoftware/zvterm","commit_stats":null,"previous_names":["ringtailsoftware/zvterm"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringtailsoftware%2Fzvterm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringtailsoftware%2Fzvterm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringtailsoftware%2Fzvterm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ringtailsoftware%2Fzvterm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ringtailsoftware","download_url":"https://codeload.github.com/ringtailsoftware/zvterm/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248535192,"owners_count":21120504,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["libvterm","terminal","terminal-emulator","zig","zig-package"],"created_at":"2024-12-10T03:07:33.379Z","updated_at":"2025-10-23T19:51:11.255Z","avatar_url":"https://github.com/ringtailsoftware.png","language":"C","readme":"# ZVTerm\n\nA Zig wrapper for [libvterm](https://www.leonerd.org.uk/code/libvterm/), exposing a small subset in a native Zig API.\n\nBuild with zig 0.14.0\n\n(Just enough to build a working toy terminal emulator)\n\n![](sdlzvterm/demo.gif)\n\nSee `examples/helloworld.zig` for usage.\n\nSee `sdlzvterm/` for a janky terminal implementation in SDL.\n\n```zig\n    // setup an 80x24 terminal\n    var term = try ZVTerm.init(allocator, 80, 24);\n    defer term.deinit();\n    // get a writer to send data to the terminal\n    var writer = term.getWriter();\n    // write terminal escape codes\n    try writer.print(\"\\x1b[10;10HHello world\", .{});\n\n    // read back the screen state for each x,y position\n    for (0..term.height) |y| {\n        for (0..term.width) |x| {\n            const cell = term.getCell(x, y);\n            // paint cell.char:u8 using cell.fg and cell.bg colours\n            ...\n        }\n    }\n```\n\nTo build and run the simple demo,\n\n    zig build helloworld\n\nTo build and run the SDL demo terminal,\n\n    cd sdlzvterm\n    zig build run\n\n\n\n# Use\n\nFirst we add the library as a dependency in our `build.zig.zon` file.\n\n`zig fetch --save git+https://github.com/ringtailsoftware/zvterm.git`\n\nAnd add it to `build.zig` file.\n```zig\nconst zvterm_dep = b.dependency(\"zvterm\", .{\n    .target = target,\n    .optimize = optimize,\n});\n\nexe.root_module.addImport(\"zvterm\", zvterm_dep.module(\"zvterm\"));\n```\n\n# Status\n\nThere's plenty to add in order to make a real terminal emulator. libvterm is capable, but the zig API needs extending to do more\n\n - unicode\n - bell\n - more selective damage callbacks to know which areas of screen to redraw\n\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fringtailsoftware%2Fzvterm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fringtailsoftware%2Fzvterm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fringtailsoftware%2Fzvterm/lists"}