{"id":13463183,"url":"https://github.com/prawnpdf/prawn","last_synced_at":"2025-05-13T11:07:17.039Z","repository":{"id":389496,"uuid":"7050","full_name":"prawnpdf/prawn","owner":"prawnpdf","description":"Fast, Nimble PDF Writer for Ruby","archived":false,"fork":false,"pushed_at":"2025-05-02T06:47:10.000Z","size":44277,"stargazers_count":4730,"open_issues_count":93,"forks_count":696,"subscribers_count":95,"default_branch":"master","last_synced_at":"2025-05-13T11:07:09.794Z","etag":null,"topics":["pdf","pdf-generator","prawn","ruby"],"latest_commit_sha":null,"homepage":"https://prawnpdf.org","language":"Ruby","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/prawnpdf.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"COPYING","code_of_conduct":"CODE_OF_CONDUCT.md","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,"zenodo":null}},"created_at":"2008-04-04T22:37:39.000Z","updated_at":"2025-05-11T09:16:39.000Z","dependencies_parsed_at":"2023-07-09T07:01:43.890Z","dependency_job_id":"5c6ca0d3-5b6d-493e-84ed-4623b83533d1","html_url":"https://github.com/prawnpdf/prawn","commit_stats":{"total_commits":2685,"total_committers":197,"mean_commits":"13.629441624365482","dds":0.6797020484171322,"last_synced_commit":"c531f87e8cedda95afffbe6207e5c6f3a2de7609"},"previous_names":[],"tags_count":52,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prawnpdf%2Fprawn","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prawnpdf%2Fprawn/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prawnpdf%2Fprawn/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/prawnpdf%2Fprawn/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/prawnpdf","download_url":"https://codeload.github.com/prawnpdf/prawn/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253929365,"owners_count":21985802,"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":["pdf","pdf-generator","prawn","ruby"],"created_at":"2024-07-31T13:00:47.503Z","updated_at":"2025-05-13T11:07:16.999Z","avatar_url":"https://github.com/prawnpdf.png","language":"Ruby","readme":"# Prawn: Fast, Nimble PDF Generation For Ruby\n\n[![Gem Version](https://badge.fury.io/rb/prawn.svg)](http://badge.fury.io/rb/prawn)\n[![Build Status](https://github.com/prawnpdf/prawn/workflows/CI/badge.svg)](https://github.com/prawnpdf/prawn/actions?query=branch%3Amaster)\n[![Code Climate](https://codeclimate.com/github/prawnpdf/prawn/badges/gpa.svg)](https://codeclimate.com/github/prawnpdf/prawn)\n![Maintained: yes](https://img.shields.io/badge/maintained-yes-brightgreen.svg)\n\nPrawn is a pure Ruby PDF generation library that provides a lot of great\nfunctionality while trying to remain simple and reasonably performant. Here are\nsome of the important features we provide:\n\n* Vector drawing support, including lines, polygons, curves, ellipses, etc.\n* Extensive text rendering support, including flowing text and limited inline\n  formatting options.\n* Support for both PDF builtin fonts as well as embedded TrueType fonts\n* A variety of low level tools for basic layout needs, including a simple grid\n  system\n* PNG and JPG image embedding, with flexible scaling options\n* Security features including encryption and password protection\n* Tools for rendering repeatable content (i.e headers, footers, and page\n  numbers)\n* Comprehensive internationalization features, including full support for UTF-8\n  based fonts, right-to-left text rendering, fallback font support, and extension\n  points for customizable text wrapping.\n* Support for PDF outlines for document navigation\n* Low level PDF features, allowing users to create custom extensions by dropping\n  down all the way to the PDF object tree layer. (Mostly useful to those with\n  knowledge of the PDF specification)\n* Lots of other stuff!\n\n## Should You Use Prawn?\n\nIf you are looking for a highly flexible PDF document generation system, Prawn\nmight be the tool for you. It is not a reporting tool or a publishing toolchain,\nthough it could be fairly easily used to build those things.\n\nOne thing Prawn is not, and will never be, is an HTML to PDF generator. For\nthose needs, consider looking into [Ferrum](https://github.com/excid3/ferrum_pdf). We do have basic support for inline styling\nbut it is limited to a very small subset of functionality and is not suitable\nfor rendering rich HTML documents.\n\n## Supported Ruby Versions and Implementations\n\nBecause Prawn is pure Ruby and all of its runtime dependencies are maintained by\nus, it should work pretty much anywhere. We officially support all Ruby versions\nsuported by Ruby Core Team and JRuby versions of matching Ruby version. However\nwe will accept patches to fix problems on other Ruby platforms if they aren't\ntoo invasive.\n\n\n## Installing Prawn\n\nPrawn is distributed via RubyGems, and can be installed the usual way that you\ninstall gems: by simply typing `gem install prawn` on the command line.\n\nYou can also install from git if you'd like, the _master_ branch contains the\nlatest developments. We're trying to keep `master` branch in working order but\nyou may encounter some rough edges and fresh bugs along with bugfixes. We\nencourage you to try `master` branch with your application.\n\n## Hello World!\n\nIf the following code runs and produces a working PDF file, you've successfully\ninstalled Prawn.\n\n```ruby\nrequire \"prawn\"\n\nPrawn::Document.generate(\"hello.pdf\") do\n  text \"Hello World!\"\nend\n```\n\nOf course, you'll probably want to do more interesting things than that...\n\n\n## Manual\n\nThe manual is a series of examples that demonstrate use of the wide range of\nfeatures Prawn provides. You can get a generated version of the latest released\nPrawn version on the [Prawn website](https://prawnpdf.org/). The examples\nthemselves can be found in the `manual` directory in this repository.\n\nPlease note that while the manual is a great introduction and guide to Prawn\nit's not exhaustive. Please refer to API docs for more complete information on\nwhat Prawn provides and how to use it.\n\nTo build the manual, here's what you need to do:\n\n1. Clone the repository\n3. Run `gem install -g`\n4. Run `rake manual`, which will generate _manual.pdf_ in the project root\n\n\n## Release Policies\n\nWe're trying to not break things unnecessarily but we don't formally follow\nSemantic Versioning. The reason is that we release a number of experimental\nAPIs. We don't make any promises on their stability. You can assume the stable\nportion of the API follows Semantic Versioning.\n\nAlso note that bug fixes can change behaviour. We don't consider that to be\na breaking change for the purposes of versioning. Please test your applications\nafter updating Prawn.\n\nBe sure to read the release notes in\n[CHANGELOG.md](https://github.com/prawnpdf/prawn/blob/master/CHANGELOG.md) each\ntime we cut a new release, and lock your gems accordingly.\n\n\n## Support\n\nThe easiest way to get help with Prawn is to post a message to our\n[Discussions](https://github.com/orgs/prawnpdf/discussions).\n\nFeel free to post any Prawn related question there, our community is very\nresponsive and will be happy to help you figure out how to use Prawn, or help\nyou determine whether it's the right tool for the task you are working on.\n\nPlease make your posts as specific as possible, including code samples and\noutput where relevant. Do not post any information that should not be shared\npublicly, and be sure to reduce your example code as much as possible so that\nthose who are responding to your question can more easily see what the issue\nmight be.\n\n\n## Code of Conduct\n\nPrawn adheres to the [Contributor Covenant](CODE_OF_CONDUCT.md). Unacceptable\nbehavior can be reported to conduct@prawnpdf.org which is monitored by the core\nteam.\n\n\n## Contributing\n\nIf you've found a bug or want to submit a patch, please enter a ticket into our\n[GitHub tracker](http://github.com/prawnpdf/prawn/issues).\n\nWe strongly encourage bug reports to come with failing tests or at least a\nreduced example that demonstrates the problem. Similarly, patches should include\ntests, API documentation, and an update to the manual where relevant. Feel free\nto send a pull request early though, if you just want some feedback or a code\nreview before preparing your code to be merged.\n\nIf you are unsure about whether or not you've found a bug, or want to check to\nsee whether we'd be interested in the feature you want to add before you start\nworking on it, feel free to post to our mailing list.\n\nYou can run our test suite in a few different ways:\n\n1. Running `rake` will run the entire test suite excluding any unresolved issues\n2. Running `rspec` will run the entire test suite including unresolved issues\n3. Running `rspec -t unresolved` will run *only* unresolved issues\n4. Running `rspec -t issue:NUMBER` will run the tests for a specific issue\n\nThese filters make it possible for us to add failing test cases for bugs that\nare currently being researched or worked on, without breaking the typical full\nsuite run.\n\n## Maintenance team\n\nPrawn has always been heavily dependent on community contributions, with dozens\nof people contributing code over the years. In that sense, the lines have\nblurred to the point where we no longer have a strong distinction between core\ndevelopers and contributors.\n\nThat said, there are a few folks who have been responsible for cutting releases,\nmerging important pull requests, and making major decisions about the overall\ndirection of the project.\n\n### Current maintainers\n\nThese are the folks to contact if you have a maintenance-related issue with\nPrawn:\n\n* Alexander Mankuta ([PointlessOne](https://github.com/PointlessOne))\n\n### Inactive maintainers\n\nThese folks have helped out in a maintenance role in the past, but are no longer\nactively involved in the project:\n\n* Gregory Brown ([practicingruby](https://github.com/practicingruby))\n* Brad Ediger ([bradediger](https://github.com/bradediger))\n* James Healy ([yob](https://github.com/yob))\n* Daniel Nelson ([Bluejade](https://github.com/Bluejade))\n* Jonathan Greenberg ([jonsgreen](https://github.com/jonsgreen))\n* Jamis Buck ([jamis](https://github.com/jamis))\n* Evan Sharp ([PacketMonkey](https://github.com/PacketMonkey))\n\n## License\n\nPrawn is released under a slightly modified form of the License of Ruby,\nallowing you to choose between Matz's terms, the GPLv2, or GPLv3. For details,\nplease see the LICENSE, GPLv2, and GPLv3 files.\n\nIf you contribute to Prawn, you will retain your own copyright but must agree to\nlicense your code under the same terms as the project itself.\n\n## History\n\nPrawn was originally developed by [Gregory\nBrown](https://practicingdeveloper.com/), under the auspices of the Ruby\nMendicant Project, a grassroots initiative in which the Ruby community\ncollectively provided funding so that Gregory could take several months off from\nwork to focus on this project.\n\nOver the last several years, we've received code contributions from dozens of\npeople, which is amazing considering the low-level nature of this project. You\ncan find the full list of folks who have at least one patch accepted to Prawn on\nGitHub [Contributors](https://github.com/prawnpdf/prawn/contributors) page.\n\nAfter a long period of inactivity, Prawn reached its 1.0 milestone in 2014\nthanks to some modest funding provided to Gregory by Madriska, Inc. (Brad\nEdiger's company).\n","funding_links":[],"categories":["Documents \u0026 Reports","Web 后端","Ruby","PDF","Misc","Generators","PDF Processing","PDF generation","Gems","Libraries"],"sub_categories":["PDF Generation","Misc","Ruby"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprawnpdf%2Fprawn","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprawnpdf%2Fprawn","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprawnpdf%2Fprawn/lists"}