{"id":15047564,"url":"https://github.com/jube/cairopp","last_synced_at":"2026-02-25T05:15:32.407Z","repository":{"id":255735341,"uuid":"849215846","full_name":"jube/cairopp","owner":"jube","description":"C++17 binding for cairo","archived":false,"fork":false,"pushed_at":"2024-09-06T19:39:53.000Z","size":4005,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-07T11:49:22.403Z","etag":null,"topics":["binding","cairo","cairo-drawing","cpp","cpp17"],"latest_commit_sha":null,"homepage":"","language":"C++","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/jube.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-29T07:29:27.000Z","updated_at":"2024-09-06T19:39:57.000Z","dependencies_parsed_at":"2024-09-06T23:25:05.123Z","dependency_job_id":null,"html_url":"https://github.com/jube/cairopp","commit_stats":null,"previous_names":["jube/cairopp"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jube/cairopp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jube%2Fcairopp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jube%2Fcairopp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jube%2Fcairopp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jube%2Fcairopp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jube","download_url":"https://codeload.github.com/jube/cairopp/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jube%2Fcairopp/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29811531,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-25T03:30:18.102Z","status":"ssl_error","status_checked_at":"2026-02-25T03:30:17.799Z","response_time":61,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["binding","cairo","cairo-drawing","cpp","cpp17"],"created_at":"2024-09-24T21:00:22.233Z","updated_at":"2026-02-25T05:15:32.377Z","avatar_url":"https://github.com/jube.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cairopp, C++17 binding for cairo\n\n**cairopp** is a C++17 binding for [cairo](https://cairographics.org/) (\u003e= 1.16).\n\n## Features\n\n- **Ease of use**: everything is in a single header, just drop the header in your source tree.\n- **Strict binding**: the API is exactly the same as cairo with just unavoidable exceptions.\n- **Quality of life**: additional structs for points, rectangles, colors, etc.\n\nEverything is in the `cairo` namespace.\n\n## How to\n\n### Naming\n\nThe binding sticks to the original cairo library. A function `cairo_foo_do_something` is generally transformed in a member function `do_something` of class `Foo` in the `cairo` namespace: `cairo::Foo::do_something`. The `get_` prefix are removed.\n\nThe enumeration members lose their prefix, but as they are in an `enum class`, an enumeration member `CAIRO_BAR_BAZ` is generally transformed into `cairo::Bar::Baz`.\n\n### Contructors\n\nTo follow the [binding guidelines](https://cairographics.org/manual/language-bindings.html), many constructors are replaced with static member functions. In particular, all surfaces are created with static member functions.\n\n### Overloads\n\nFor each member function that have `x` and `y` *or* `width` and `height`, an overload is provided with a `Vec2F` (for `double`s) or `Vec2I` (for `int`s) parameter. For each member function that have `x` and `y` *and* `width` and `height`, an overload is provided with a `RectF` (for `double`s) or `RectI` (for `int`s) parameter For each member function that have a `red`, `green`, `blue` and possibly `alpha`, an overload is provided with a `Color` parameter.\n\nWhen two parameters represents an array and the size of the array, a templated overload is provided that use `std::data` and `std::size` to get the associated data and size of the templated container. So it can be used with `std::array`, `std::vector` and even with `std::initializer_list`.\n\n### Missing things\n\nThey are a number of missing things, it can be because there are callbacks (and I have to find a good way to handle them), or because it's not yet here (e.g. the many surfaces and devices), or because I don't want to support them. Anyway, pull requests are welcome to complete the binding.\n\nKnown missing classes:\n\n- `user_scaled_font`\n- `user_font_face`\n- `surface_observer`\n- `raster_source_pattern`\n- `region`\n\nKnown missing member functions:\n\n- `*::get_reference_count`\n- `*::get_user_data`\n- `*::set_user_data`\n- `surface::write_to_png_stream`\n- `surface::set_mime_data`\n- `surface::get_mime_data`\n- `surface::supports_mime_type`\n- `image_surface::create_from_png_stream`\n\n### Versioning\n\nThe binding handles the different versions from 1.16. If you need support for version handling before 1.16, patches are welcome.\n\n## License\n\nThis binding is released under the MIT license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjube%2Fcairopp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjube%2Fcairopp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjube%2Fcairopp/lists"}