{"id":15603235,"url":"https://github.com/hidakatsuya/prawn-emoji","last_synced_at":"2025-04-05T01:06:05.490Z","repository":{"id":3290506,"uuid":"48973552","full_name":"hidakatsuya/prawn-emoji","owner":"hidakatsuya","description":"Prawn::Emoji is an extention that adds Emoji support to Prawn.","archived":false,"fork":false,"pushed_at":"2025-03-28T11:24:06.000Z","size":12976,"stargazers_count":25,"open_issues_count":1,"forks_count":15,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-29T00:08:37.782Z","etag":null,"topics":["emoji","pdf","prawn","ruby","twemoji"],"latest_commit_sha":null,"homepage":"https://rubygems.org/gems/prawn-emoji","language":"Ruby","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/hidakatsuya.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"MIT-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":"2016-01-04T03:52:08.000Z","updated_at":"2025-03-27T16:59:23.000Z","dependencies_parsed_at":"2023-12-30T14:39:25.514Z","dependency_job_id":null,"html_url":"https://github.com/hidakatsuya/prawn-emoji","commit_stats":{"total_commits":235,"total_committers":5,"mean_commits":47.0,"dds":"0.10212765957446812","last_synced_commit":"44c6bb2c187351c4e3db89fc4fecc45b243ddc3c"},"previous_names":[],"tags_count":19,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hidakatsuya%2Fprawn-emoji","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hidakatsuya%2Fprawn-emoji/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hidakatsuya%2Fprawn-emoji/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hidakatsuya%2Fprawn-emoji/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hidakatsuya","download_url":"https://codeload.github.com/hidakatsuya/prawn-emoji/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247271528,"owners_count":20911587,"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":["emoji","pdf","prawn","ruby","twemoji"],"created_at":"2024-10-03T03:02:06.976Z","updated_at":"2025-04-05T01:06:05.478Z","avatar_url":"https://github.com/hidakatsuya.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Prawn::Emoji\n\n[![Test](https://github.com/hidakatsuya/prawn-emoji/actions/workflows/test.yml/badge.svg)](https://github.com/hidakatsuya/prawn-emoji/actions/workflows/test.yml)\n[![Gem Version](https://badge.fury.io/rb/prawn-emoji.svg)](https://badge.fury.io/rb/prawn-emoji)\n\nPrawn::Emoji is an extention that adds Emoji support to [Prawn](https://github.com/prawnpdf/prawn).\n\n```ruby\nrequire 'prawn/emoji'\n\nPrawn::Document.generate 'sushi.pdf' do\n  font 'DejaVuSans.ttf'\n  text '🐟 / 🔪 + 🍚 / 🍾 = 🍣'\nend\n```\n\nFor execute this code, you need [DejaVuSans.ttf](http://sourceforge.net/projects/dejavu/) font.\n\n## Features\n\n### Emoji\n\n  * Emoji is provided by [jdecked/twemoji](https://github.com/jdecked/twemoji)\n  * Support Singleton/Combining/Modifier/Flag/ZWJ Sequence Emoji\n\nSee [test/pdf/emoji_rendering/expect.pdf](https://github.com/hidakatsuya/prawn-emoji/blob/main/test/pdf/emoji_rendering/expect.pdf) for details.\n\n### Prawn Integration\n\n  * RTL support\n  * Character spacing support\n  * Rotation support\n  * Alignment support\n  * Font size support\n\nSee [test/pdf/prawn_integration/expect.pdf](https://github.com/hidakatsuya/prawn-emoji/blob/main/test/pdf/prawn_integration/expect.pdf) for details.\n\n### Known Issues\n\n[prawn-emoji/issues](https://github.com/hidakatsuya/prawn-emoji/labels/known%20issue)\n\n\n## Supported Versions\n\n### Emoji\n\n15.1\n\n### Prawn\n\n2.4\n\n### Ruby\n\n3.1, 3.2, 3.3, 3.4\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n```ruby\ngem 'prawn-emoji', require: false\n```\n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install prawn-emoji\n\n## Setup\n\n```ruby\nrequire 'prawn/emoji'\n```\n\n### True Type Font Required\n\nIn order to draw Emoji, you must use a True Type Font.\n\n## Configuring Emoji Regex\n\nEmoji Regex is a regular expression used to determine which emoji to draw.\n\n```ruby\nPrawn::Emoji.config.regex # =\u003e ::Unicode::Emoji::REGEX_VALID by default\n```\n\nYou can override it with [unicode-emoji's Regex](https://github.com/janlelis/unicode-emoji#regex):\n\n```ruby\nPrawn::Emoji.config.regex = ::Unicode::Emoji::REGEX_INCLUDE_TEXT\n```\n\n## Contributing\n\nBug reports and pull requests are welcome on GitHub at https://github.com/hidakatsuya/prawn-emoji.\n\n## Development\n\n### Running tests\n\nRun all tests:\n\n```\n$ bundle exec rake test\n```\n\nRun unit tests:\n\n```\n$ bundle exec rake test:units\n```\n\nRun pdf tests:\n\n```\n$ bundle exec rake test:pdf\n```\n\nIn order to run `test:pdf`, you need to install [diff-pdf](https://github.com/vslavik/diff-pdf) in your environment, or you can run test in the docker container as below.\n\n### Running tests in the docker container for development\n\nYou can use the docker container for development. This container contains the libraries required for testing, such as diff-pdf.\n\n```\ndocker pull ghcr.io/hidakatsuya/ruby-with-diff-pdf:latest\ndocker run -v $PWD:/src -it ghcr.io/hidakatsuya/ruby-with-diff-pdf bash\n\n\u003e src#\n```\n\nYou can run test:\n\n```\n\u003e src# bundle install\n\u003e src# bundle exec rake test\n```\n\nOr, you can run test instantly like this:\n\n```\n$ docker run --rm -v $PWD:/src:cached -it ghcr.io/hidakatsuya/ruby-with-diff-pdf bash -c \"bundle install \u0026\u0026 bundle exec rake test:pdf\"\n```\n\n### Updating the bundled emojis\n\n```\n$ bundle exec rake emoji:update VERSION=\u003cTwemoji version\u003e\n```\n\nThis task works the following:\n\n1. Download emoji images from https://github.com/jdecked/twemoji/\n2. Save the emoji images in the `emoji/images/`\n3. Write image list in `emoji/images/` to `emoji/index.yml`\n4. Update version in `emoji/LICENSE`\n\n## License\n\n© 2015 Katsuya HIDAKA. See MIT-LICENSE for further details.\n\n### Twemoji\n\n[Twemoji](https://github.com/jdecked/twemoji) Graphics licensed under [CC-BY4.0](https://creativecommons.org/licenses/by/4.0/). See `emoji/LICENSE` for futher details.\n\n### IPA Font\n\n[IPA Font License Agreement v1.0](http://ipafont.ipa.go.jp/ipa_font_license_v1.html)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhidakatsuya%2Fprawn-emoji","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhidakatsuya%2Fprawn-emoji","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhidakatsuya%2Fprawn-emoji/lists"}