Abstract

The Python scripting language is a good match with Quartz for a number of reasons. First, Python is an object-oriented language and the Quartz Python bindings allow Quartz objects such as contexts and images to be treated as Python objects. Second, it is a popular scripting language that makes it easy to perform complex operations with Quartz without writing any C code. Third, Python can be used interactively from the command line to experiment with Quartz programming. Python scripts can create PDF documents by using Quartz to draw to a PDF context. Similarly, they can create a bit-based graphics file by using Quartz to draw to a bitmap context and export those bits to an external file. One can use Quartz and Python to create PNG, JPEG, GIF, or TIFF representations of Quartz drawing by creating a bitmap context, drawing to that context, then exporting the bits in the context to a file. A script that creates bits is useful to serve up data-driven web pages in a format that is recognized by any web browser.

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call

Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.