PTPDFDocGenerator
@interface PTPDFDocGenerator : NSObject
The class PDFDocGenerator. A collection of static methods to create blank documents
No notes :(
-
Create a new document with one page of blank paper.
Declaration
Objective-C
+ (PTPDFDoc *)GenerateBlankPaperDoc:(double)width height:(double)height background_red:(double)background_red background_green:(double)background_green background_blue:(double)background_blue;
Swift
class func generateBlankPaperDoc(_ width: Double, height: Double, background_red: Double, background_green: Double, background_blue: Double) -> PTPDFDoc!
Parameters
width
– The page width in inches.
height
– The page height in inches.
background_red
– The red component of the background color.
background_green
– The green component of the background color.
background_blue
– The blue component of the background color.
Return Value
.
-
+GenerateGridPaperDoc:height:grid_spacing:line_thickness:red:green:blue:background_red:background_green:background_blue:
Create a new document with one page of grid paper.
Declaration
Objective-C
+ (PTPDFDoc *)GenerateGridPaperDoc:(double)width height:(double)height grid_spacing:(double)grid_spacing line_thickness:(double)line_thickness red:(double)red green:(double)green blue:(double)blue background_red:(double)background_red background_green:(double)background_green background_blue:(double)background_blue;
Swift
class func generateGridPaperDoc(_ width: Double, height: Double, grid_spacing: Double, line_thickness: Double, red: Double, green: Double, blue: Double, background_red: Double, background_green: Double, background_blue: Double) -> PTPDFDoc!
Parameters
width
– The page width in inches.
height
– The page height in inches.
grid_spacing
– The grid spacing in inches.
line_thickness
– The line thickness in points.
red
– The red component of the line color.
green
– The green component of the line color.
blue
– The blue component of the line color.
background_red
– The red component of the background color.
background_green
– The green component of the background color.
background_blue
– The blue component of the background color.
Return Value
.
-
+GenerateLinedPaperDoc:height:line_spacing:line_thickness:red:green:blue:left_margin_distance:left_margin_red:left_margin_green:left_margin_blue:right_margin_red:right_margin_green:right_margin_blue:background_red:background_green:background_blue:top_margin_distance:bottom_margin_distance:
Create a new document with one page of lined paper.
Declaration
Objective-C
+ (PTPDFDoc *)GenerateLinedPaperDoc:(double)width height:(double)height line_spacing:(double)line_spacing line_thickness:(double)line_thickness red:(double)red green:(double)green blue:(double)blue left_margin_distance:(double)left_margin_distance left_margin_red:(double)left_margin_red left_margin_green:(double)left_margin_green left_margin_blue:(double)left_margin_blue right_margin_red:(double)right_margin_red right_margin_green:(double)right_margin_green right_margin_blue:(double)right_margin_blue background_red:(double)background_red background_green:(double)background_green background_blue:(double)background_blue top_margin_distance:(double)top_margin_distance bottom_margin_distance:(double)bottom_margin_distance;
Swift
class func generateLinedPaperDoc(_ width: Double, height: Double, line_spacing: Double, line_thickness: Double, red: Double, green: Double, blue: Double, left_margin_distance: Double, left_margin_red: Double, left_margin_green: Double, left_margin_blue: Double, right_margin_red: Double, right_margin_green: Double, right_margin_blue: Double, background_red: Double, background_green: Double, background_blue: Double, top_margin_distance: Double, bottom_margin_distance: Double) -> PTPDFDoc!
Parameters
width
– The page width in inches.
height
– The page height in inches.
line_spacing
– The line spacing in inches.
line_thickness
– The line thickness in points.
red
– The red component of the line color.
green
– The green component of the line color.
blue
– The blue component of the line color.
left_margin_distance
– Distance of the margin from the left side of the page.
left_margin_red
– The red component of the left margin color.
left_margin_green
– The green component of the left margin color.
left_margin_blue
– The blue component of the left margin color.
right_margin_red
– The red component of the right margin color.
right_margin_green
– The green component of the right margin color.
right_margin_blue
– The blue component of the right margin color.
background_red
– The red component of the background color.
background_green
– The green component of the background color.
background_blue
– The blue component of the background color.
top_margin_distance
– Distance of the margin from the top of the page.
bottom_margin_distance
– Distance of the margin from the bottom of the page.
Return Value
.
-
+GenerateGraphPaperDoc:height:grid_spacing:line_thickness:weighted_line_thickness:weighted_line_freq:red:green:blue:background_red:background_green:background_blue:
Create a new document with one page of graph paper.
Declaration
Objective-C
+ (PTPDFDoc *)GenerateGraphPaperDoc:(double)width height:(double)height grid_spacing:(double)grid_spacing line_thickness:(double)line_thickness weighted_line_thickness:(double)weighted_line_thickness weighted_line_freq:(int)weighted_line_freq red:(double)red green:(double)green blue:(double)blue background_red:(double)background_red background_green:(double)background_green background_blue:(double)background_blue;
Swift
class func generateGraphPaperDoc(_ width: Double, height: Double, grid_spacing: Double, line_thickness: Double, weighted_line_thickness: Double, weighted_line_freq: Int32, red: Double, green: Double, blue: Double, background_red: Double, background_green: Double, background_blue: Double) -> PTPDFDoc!
Parameters
width
– The page width in inches.
height
– The page height in inches.
grid_spacing
– The grid spacing in inches.
line_thickness
– The line thickness in points.
weighted_line_thickness
– The weighted line thickness in points.
weighted_line_freq
– Ratio of weighted lines to normal lines.
red
– The red component of the line color.
green
– The green component of the line color.
blue
– The blue component of the line color.
background_red
– The red component of the background color.
background_green
– The green component of the background color.
background_blue
– The blue component of the background color.
Return Value
.
-
+GenerateMusicPaperDoc:height:margin:staves:linespace_size_pts:line_thickness:red:green:blue:background_red:background_green:background_blue:
Create a new document with one page of music paper.
Declaration
Objective-C
+ (PTPDFDoc *)GenerateMusicPaperDoc:(double)width height:(double)height margin:(double)margin staves:(int)staves linespace_size_pts:(double)linespace_size_pts line_thickness:(double)line_thickness red:(double)red green:(double)green blue:(double)blue background_red:(double)background_red background_green:(double)background_green background_blue:(double)background_blue;
Swift
class func generateMusicPaperDoc(_ width: Double, height: Double, margin: Double, staves: Int32, linespace_size_pts: Double, line_thickness: Double, red: Double, green: Double, blue: Double, background_red: Double, background_green: Double, background_blue: Double) -> PTPDFDoc!
Parameters
width
– The page width in inches.
height
– The page height in inches.
margin
– The page margin in inches.
staves
– Amount of staves on the page..
linespace_size_pts
– The space between lines in points.
line_thickness
– The line thickness in points.
red
– The red component of the line color.
green
– The green component of the line color.
blue
– The blue component of the line color.
background_red
– The red component of the background color.
background_green
– The green component of the background color.
background_blue
– The blue component of the background color.
Return Value
.
-
+GenerateDottedPaperDoc:height:dot_spacing:dot_size:red:green:blue:background_red:background_green:background_blue:
Create a new document with one page of dotted paper.
Declaration
Objective-C
+ (PTPDFDoc *)GenerateDottedPaperDoc:(double)width height:(double)height dot_spacing:(double)dot_spacing dot_size:(double)dot_size red:(double)red green:(double)green blue:(double)blue background_red:(double)background_red background_green:(double)background_green background_blue:(double)background_blue;
Swift
class func generateDottedPaperDoc(_ width: Double, height: Double, dot_spacing: Double, dot_size: Double, red: Double, green: Double, blue: Double, background_red: Double, background_green: Double, background_blue: Double) -> PTPDFDoc!
Parameters
width
– The page width in inches.
height
– The page height in inches.
dot_spacing
– The dot spacing in inches.
dot_size
– The dot size (diameter) in points.
red
– The red component of the line color.
green
– The green component of the line color.
blue
– The blue component of the line color.
background_red
– The red component of the background color.
background_green
– The green component of the background color.
background_blue
– The blue component of the background color.
Return Value
.
-
+GenerateIsometricDottedPaperDoc:height:dot_spacing:dot_size:red:green:blue:background_red:background_green:background_blue:
Create a new document with one page of dotted paper.
Declaration
Objective-C
+ (PTPDFDoc *)GenerateIsometricDottedPaperDoc:(double)width height:(double)height dot_spacing:(double)dot_spacing dot_size:(double)dot_size red:(double)red green:(double)green blue:(double)blue background_red:(double)background_red background_green:(double)background_green background_blue:(double)background_blue;
Swift
class func generateIsometricDottedPaperDoc(_ width: Double, height: Double, dot_spacing: Double, dot_size: Double, red: Double, green: Double, blue: Double, background_red: Double, background_green: Double, background_blue: Double) -> PTPDFDoc!
Parameters
width
– The page width in inches.
height
– The page height in inches.
dot_spacing
– The dot spacing in inches.
dot_size
– The dot size (diameter) in points.
red
– The red component of the line color.
green
– The green component of the line color.
blue
– The blue component of the line color.
background_red
– The red component of the background color.
background_green
– The green component of the background color.
background_blue
– The blue component of the background color.
Return Value
.
-
Undocumented
Declaration
Objective-C
- (instancetype)init;
Swift
init!()