From 1c39ecf64f1bb4ee3c6c3740d6b5e949268017fc Mon Sep 17 00:00:00 2001 From: benfry Date: Mon, 2 Oct 2006 03:22:21 +0000 Subject: [PATCH] fix issue with setting the parent object for PDF --- pdf/src/processing/pdf/PGraphicsPDF.java | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/pdf/src/processing/pdf/PGraphicsPDF.java b/pdf/src/processing/pdf/PGraphicsPDF.java index 429e70795..4c10e753c 100644 --- a/pdf/src/processing/pdf/PGraphicsPDF.java +++ b/pdf/src/processing/pdf/PGraphicsPDF.java @@ -28,7 +28,7 @@ public class PGraphicsPDF extends PGraphicsJava2D { public PGraphicsPDF(int width, int height, PApplet applet, String path) { - super(width, height, null); + super(width, height, applet); //System.out.println("trying " + path); @@ -80,6 +80,16 @@ public class PGraphicsPDF extends PGraphicsJava2D { } + public void setMainDrawingSurface() { + // set as main drawing surface + mainDrawingSurface = true; + // this shouldn't actually affect anything + format = RGB; + // don't bother adding listeners for this guy + //parent.addListeners(); + } + + // create a temporary file and put the graphics crap there // don't start a fresh page if frameCount is zero (setup isn't its own page)