• Home
  • History
  • Annotate
  • Line#
  • Navigate
  • Raw
  • Download
  • only in /macosx-10.9.5/pyobjc-42/pyobjc/pyobjc-framework-Quartz/Examples/Programming with Quartz/
1The samples in this directory are transcriptions of the 
2examples in the book "Programming with Quartz" (ISBN: 978-0-12-369473-7), except for code
3that relies on Carbon APIs like HIToolbox.
4
5The APIs in the folder "python" use the pre-Leopard bindings to CoreGraphics, which are deprecated at best.
6
7The original Readme file:
8
9These directories contain the sample source code for the Quartz Book. Note that the source files are formatted
10so that the tab indentation looks best in Xcode or BBEdit with 4 spaces per tab. 
11
12CocoaDrawingShell:
13Contains source for building the sample application created in Chapter 3.
14
15CarbonDrawingShell:
16Contains source for building the sample application created in Chapter 4.
17
18BasicDrawing:
19An application that contains the bulk of the sample code presented in the book. The directory BasicDrawing.cocoa contains an Xcode project and Cocoa specific source code for building a Cocoa version of the application. The directory BasicDrawing.carbon contains an Xcode project and Carbon specific source code for building a Carbon version of the application. The directory CommonCode contains the C code that is common to both the Cocoa and Carbon versions of the application.
20
21PDFDraw:
22This is a basic application that contains the code from Chapters 13 and 16 for opening and displaying PDF, PostScript, and EPS documents. This example is a Carbon application that uses the QDBeginCGContext/QDEndCGContext routines discussed in Chapter 4 as an alternate to using HIView. The user interface here is rudimentary; the focus of this sample is on the drawing of PDF documents and conversion of PostScript and EPS files into a PDF document that can be displayed like any other PDF file.
23
24CreatePDFDocument:
25This contains the sample code from Chapter 14 for creating new PDF documents, including those that contain links. This sample also demonstrates use of the new to Tiger API for creating encrypted PDF documents that have restricted permissions.
26
27ConfidentialStamper:
28Contains the source code for a tool that takes an input PDF document and "stamps" a second PDF document onto each page of the input file, creating a new PDF document.
29
30ParsePageContents:
31Contains the source code for a tool that takes an input PDF document and "stamps" a second PDF document onto each page of the input file, creating a new PDF document.
32
33PSConverterTool:
34Contains source code to a command line tool that uses the CGPSConverter API for converting a PostScript or EPS file into a PDF output file.
35
36python:
37Contains the sample Python scripts from Chapter 18. These are:
38
39alpharects.py, which creates a PDF document containing the alpha rectangle drawing from Chapter 2.
40pdftojpg.py, which takes an input PDF document and creates a JPEG output file for each page of the input document.
41Stamp PDF with "Confidential".py, which is a PDF workflow script that can be installed in the 
42	~/Library/PDF Services or /Library/PDF Services directory, adding a workflow item to the 
43	workflow menu in the Print dialog. Choosing this workflow item stamps the word 
44	"Confidential" onto each page of the PDF document being printed.
45
46
47