{"id":28393580,"url":"https://github.com/pistondevelopers/gfx_text","last_synced_at":"2025-06-26T11:32:41.681Z","repository":{"id":31924327,"uuid":"35493689","full_name":"PistonDevelopers/gfx_text","owner":"PistonDevelopers","description":"Draw text for gfx using freetype","archived":false,"fork":false,"pushed_at":"2023-11-14T20:25:18.000Z","size":493,"stargazers_count":22,"open_issues_count":10,"forks_count":12,"subscribers_count":45,"default_branch":"master","last_synced_at":"2025-06-24T21:51:37.666Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://docs.piston.rs/gfx_text/gfx_text/","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PistonDevelopers.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-05-12T14:40:37.000Z","updated_at":"2023-10-16T07:07:18.000Z","dependencies_parsed_at":"2023-01-14T20:07:07.998Z","dependency_job_id":null,"html_url":"https://github.com/PistonDevelopers/gfx_text","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/PistonDevelopers/gfx_text","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PistonDevelopers%2Fgfx_text","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PistonDevelopers%2Fgfx_text/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PistonDevelopers%2Fgfx_text/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PistonDevelopers%2Fgfx_text/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PistonDevelopers","download_url":"https://codeload.github.com/PistonDevelopers/gfx_text/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PistonDevelopers%2Fgfx_text/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262056260,"owners_count":23251639,"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":[],"created_at":"2025-05-31T16:38:50.484Z","updated_at":"2025-06-26T11:32:41.670Z","avatar_url":"https://github.com/PistonDevelopers.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# gfx_text [![Build Status](https://travis-ci.org/PistonDevelopers/gfx_text.png?branch=master)](https://travis-ci.org/PistonDevelopers/gfx_text) [![crates.io](https://img.shields.io/crates/v/gfx_text.svg)](https://crates.io/crates/gfx_text)\n\nLibrary for drawing text for [gfx-rs](https://github.com/gfx-rs/gfx-rs) graphics API. Uses [freetype-rs](https://github.com/PistonDevelopers/freetype-rs) underneath.\n\n## Usage\n\nBasic usage:\n\n```rust\n// Initialize text renderer.\nlet mut text = gfx_text::new(factory).build().unwrap();\n\n// In render loop:\n\n// Add some text 10 pixels down and right from the top left screen corner.\ntext.add(\n    \"The quick brown fox jumps over the lazy dog\",  // Text to add\n    [10, 10],                                       // Position\n    [0.65, 0.16, 0.16, 1.0],                        // Text color\n);\n\n// Draw text.\ntext.draw(\u0026mut stream);\n```\n\nSee [API documentation](http://docs.piston.rs/gfx_text/gfx_text/) for overview of all available methods.\n\nYou can skip default font by disabling `include-font` feature:\n\n```\n[dependencies.gfx_text]\nversion = \"*\"\ndefault-features = false\n```\n\n## Examples\n\nSee [this example](./examples/styles.rs) on how to draw text in various styles: different sizes, colors, fonts, etc.\n\nOutput:\n\n[![](https://raw.githubusercontent.com/PistonDevelopers/gfx_text/images/styles.png)](https://raw.githubusercontent.com/PistonDevelopers/gfx_text/images/styles.png)\n\n## License\n\n* gfx_text licensed under [MIT License](./LICENSE)\n* Included by default Noto Sans font uses [Apache License 2.0](./assets/LICENSE.txt)\n* Ubuntu Font used in examples has [Ubuntu Font Licence 1.0](./examples/assets/LICENSE.txt)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpistondevelopers%2Fgfx_text","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpistondevelopers%2Fgfx_text","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpistondevelopers%2Fgfx_text/lists"}