cairo
Version, currently 0.2.09 versions
github.com/TamasSzekeres/cairo-cr
Cairo bindings for Crystal language.
33 stars
0 dependents
License: MIT
Nothing has been indexed for 0.2.0 yet. The tag is recorded, its shard.yml has not been read, so the manifest and dependency list below are empty because they are unknown rather than because they are absent.
Installation
# Add this to your shard.yml
dependencies:
cairo:
github: TamasSzekeres/cairo-cr
version: ~> 0.2.0Then run:
shards installshard.yml
No shard.yml has been indexed for 0.2.0. You can read it on the repository.
Dependencies
Unknown: the shard.yml for this version has not been read yet.
README
This README is the one indexed from the repository at its latest ref, not from the tag for this version.
# cairo-cr
[Cairo](https://cairographics.org/) bindings for Crystal language.

[](https://github.com/TamasSzekeres/cairo-cr/releases)
[](https://tamasszekeres.github.io/cairo-cr/)
## Installation
First install cairo:
```bash
sudo apt-get install libcairo2 libcairo2-dev
```
Add this to your application's `shard.yml`:
```yaml
dependencies:
cairo:
github: TamasSzekeres/cairo-cr
```
Then run in terminal:
```bash
shards install
```
See also: [x11-cr](https://github.com/TamasSzekeres/x11-cr)
## Usage
```crystal
require "x11"
require "cairo"
module YourModule
include X11::C # for low-level usage
include Cairo::C # for low-level usage
include X11 # for high-level usage
include Cairo # for high-level usage
end
```
For more details see the sample in [/examples](/examples) folder.
## Sample
Build and run the low-level sample:
```shell
cd examples/sample_window
shards build
./bin/sample_window
```

Build and run the high-level sample:
```shell
cd examples/sample_window_hl
shards build
./bin/sample_window
```
## Documentation
You can generate documentation for yourself:
```shell
crystal doc
```
Then you can open `/docs/index.html` in your browser.
Or you can view last commited documentation online at: [https://tamasszekeres.github.io/cairo-cr/](https://tamasszekeres.github.io/cairo-cr/).
## Contributing
1. Fork it (<https://github.com/TamasSzekeres/cairo-cr/fork>)
2. Create your feature branch (git checkout -b my-new-feature)
3. Commit your changes (git commit -am 'Add some feature')
4. Push to the branch (git push origin my-new-feature)
5. Create a new Pull Request
## Contributors
- [Tamás Szekeres](https://github.com/TamasSzekeres) - creator, maintainer
Documentation
Built from the current release. The first visit to a release nobody has asked for starts its build.
Links
This release
- Version
0.2.0- Tagged
- Jun 12, 2022
- Commit
797a93ceaab5- Indexed
- not yet
Dependents
No indexed shard depends on this one yet.
Repository
github.com/TamasSzekeres/cairo-cr
Metadata
- Created
- Aug 12, 2026
- Updated
- Aug 12, 2026
- Synced
- Aug 12, 2026
- Versions
- 9