]> _ Git - cubeextranet.git/commitdiff
(no commit message)
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Fri, 19 Aug 2011 14:38:29 +0000 (14:38 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Fri, 19 Aug 2011 14:38:29 +0000 (14:38 +0000)
77 files changed:
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginMarkedContentSequence.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginMarkedContentSequenceWithProperties.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginText.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/CloseAndStrokePath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/Concatenate.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/EndMarkedContentSequence.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/EndText.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/GRestore.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/GSave.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/Invoke.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveAndShow.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveText.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveTextSetLeading.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/NextLine.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/OperatorProcessor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetCharSpacing.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetGraphicsStateParameters.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetHorizontalTextScaling.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineCapStyle.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineDashPattern.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineJoinStyle.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineMiterLimit.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineWidth.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetMatrix.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetMoveAndShow.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingCMYKColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingCalRGBColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingColorSpace.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingDeviceN.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingGrayColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingICCBasedColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingRGBColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingSeparation.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingCMYKColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingCalRGBColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingColorSpace.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingDeviceN.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingGrayColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingICCBasedColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingRGBColor.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingSeparation.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextFont.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextLeading.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextRenderingMode.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextRise.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetWordSpacing.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/ShowText.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/ShowTextGlyph.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/package.html [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/BeginInlineImage.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClipEvenOddRule.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClipNonZeroRule.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CloseFillEvenOddAndStrokePath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CloseFillNonZeroAndStrokePath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClosePath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveTo.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveToReplicateFinalPoint.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveToReplicateInitialPoint.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/EndPath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillEvenOddAndStrokePath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillEvenOddRule.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillNonZeroAndStrokePath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillNonZeroRule.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/Invoke.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/LineTo.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/MoveTo.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SHFill.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineCapStyle.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineDashPattern.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineJoinStyle.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineMiterLimit.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineWidth.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/StrokePath.java [deleted file]
fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/package.html [deleted file]

diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginMarkedContentSequence.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginMarkedContentSequence.java
deleted file mode 100644 (file)
index 2db3667..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.util.PDFMarkedContentExtractor;
-import org.apache.pdfbox.util.PDFOperator;
-/**
- * BMC : Begins a marked-content sequence.
- * @author koch
- * @version $Revision$
- *
- */
-public class BeginMarkedContentSequence extends OperatorProcessor
-{
-
-    /**
-     * {@inheritDoc} 
-     */
-    @Override
-    public void process(PDFOperator operator, List<COSBase> arguments)
-        throws IOException
-    {
-        COSName tag = null;
-        for (COSBase argument : arguments)
-        {
-            if (argument instanceof COSName)
-            {
-                tag = (COSName) argument;
-            }
-        }
-        if (this.context instanceof PDFMarkedContentExtractor)
-        {
-            ((PDFMarkedContentExtractor) this.context).beginMarkedContentSequence(tag, null);
-        }
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginMarkedContentSequenceWithProperties.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginMarkedContentSequenceWithProperties.java
deleted file mode 100644 (file)
index 4357e14..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSDictionary;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.util.PDFMarkedContentExtractor;
-import org.apache.pdfbox.util.PDFOperator;
-/**
- * BDC : Begins a marked-content sequence with property list.
- *
- * @author koch
- * @version $Revision$
- */
-public class BeginMarkedContentSequenceWithProperties extends OperatorProcessor
-{
-
-    /**
-     * {@inheritDoc}
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-        throws IOException
-    {
-        COSName tag = null;
-        COSDictionary properties = null;
-        for (COSBase argument : arguments)
-        {
-            if (argument instanceof COSName)
-            {
-                tag = (COSName) argument;
-            }
-            else if (argument instanceof COSDictionary)
-            {
-                properties = (COSDictionary) argument;
-            }
-        }
-        if (this.context instanceof PDFMarkedContentExtractor)
-        {
-            ((PDFMarkedContentExtractor) this.context).beginMarkedContentSequence(tag, properties);
-        }
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginText.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/BeginText.java
deleted file mode 100644 (file)
index fae97cf..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.Matrix;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @author Huault : huault@free.fr
- * @version $Revision: 1.5 $
- */
-public class BeginText extends OperatorProcessor
-{
-
-    /**
-     * process : BT : Begin text object.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        context.setTextMatrix( new Matrix());
-        context.setTextLineMatrix( new Matrix() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/CloseAndStrokePath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/CloseAndStrokePath.java
deleted file mode 100644 (file)
index e560da7..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class CloseAndStrokePath extends OperatorProcessor
-{
-
-    /**
-     * s close and stroke the path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        context.processOperator( "h", arguments );
-        context.processOperator( "S", arguments );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/Concatenate.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/Concatenate.java
deleted file mode 100644 (file)
index 98b04b1..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-import java.io.IOException;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.Matrix;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- *
- * @author Huault : huault@free.fr
- * @version $Revision: 1.5 $
- */
-
-public class Concatenate extends OperatorProcessor
-{
-
-    /**
-     * process : cm : Concatenate matrix to current transformation matrix.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If there is an error processing the operator.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-
-        //concatenate matrix to current transformation matrix
-        COSNumber a = (COSNumber) arguments.get(0);
-        COSNumber b = (COSNumber) arguments.get(1);
-        COSNumber c = (COSNumber) arguments.get(2);
-        COSNumber d = (COSNumber) arguments.get(3);
-        COSNumber e = (COSNumber) arguments.get(4);
-        COSNumber f = (COSNumber) arguments.get(5);
-
-        Matrix newMatrix = new Matrix();
-        newMatrix.setValue(0, 0, a.floatValue());
-        newMatrix.setValue(0, 1, b.floatValue());
-        newMatrix.setValue(1, 0, c.floatValue());
-        newMatrix.setValue(1, 1, d.floatValue());
-        newMatrix.setValue(2, 0, e.floatValue());
-        newMatrix.setValue(2, 1, f.floatValue());
-
-        //this line has changed
-        context.getGraphicsState().setCurrentTransformationMatrix(
-                newMatrix.multiply( context.getGraphicsState().getCurrentTransformationMatrix() ) );
-
-
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/EndMarkedContentSequence.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/EndMarkedContentSequence.java
deleted file mode 100644 (file)
index 992095c..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.PDFMarkedContentExtractor;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * EMC : Ends a marked-content sequence begun by BMC or BDC.
- * @author koch
- * @version $Revision: $
- */
-public class EndMarkedContentSequence extends OperatorProcessor
-{
-
-    /**
-     * {@inheritDoc}
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-        throws IOException
-    {
-        if (this.context instanceof PDFMarkedContentExtractor)
-        {
-            ((PDFMarkedContentExtractor) this.context).endMarkedContentSequence();
-        }
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/EndText.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/EndText.java
deleted file mode 100644 (file)
index bc7fa6f..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.PDFOperator;
-/**
- *
- * @author Huault : huault@free.fr
- * @version $Revision: 1.4 $
- */
-public class EndText extends OperatorProcessor
-{
-
-    /**
-     * process : ET : End text object.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        context.setTextMatrix( null);
-        context.setTextLineMatrix( null);
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/GRestore.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/GRestore.java
deleted file mode 100644 (file)
index 896ace9..0000000
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdmodel.graphics.PDGraphicsState;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- *
- * @author Huault : huault@free.fr
- * @version $Revision: 1.4 $
- */
-public class GRestore extends OperatorProcessor
-{
-    /**
-     * process : Q : Restore graphics state.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        context.setGraphicsState( (PDGraphicsState)context.getGraphicsStack().pop() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/GSave.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/GSave.java
deleted file mode 100644 (file)
index bca1273..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdmodel.graphics.PDGraphicsState;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- *
- * @author Huault : huault@free.fr
- * @version $Revision: 1.4 $
- */
-
-public class GSave extends OperatorProcessor
-{
-    /**
-     * process : q : Save graphics state.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        context.getGraphicsStack().push( (PDGraphicsState)context.getGraphicsState().clone() );
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/Invoke.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/Invoke.java
deleted file mode 100644 (file)
index 92c1b7b..0000000
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.cos.COSStream;
-import org.apache.pdfbox.pdmodel.PDPage;
-import org.apache.pdfbox.pdmodel.PDResources;
-import org.apache.pdfbox.pdmodel.graphics.xobject.PDXObject;
-import org.apache.pdfbox.pdmodel.graphics.xobject.PDXObjectForm;
-import org.apache.pdfbox.util.PDFMarkedContentExtractor;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-import java.util.List;
-import java.util.Map;
-
-/**
- * Invoke named XObject.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @author Mario Ivankovits
- *
- * @version $Revision: 1.9 $
- */
-public class Invoke extends OperatorProcessor
-{
-    //private Set inProcess = new TreeSet();
-
-    /**
-     * process : Do - Invoke a named xobject.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If there is an error processing this operator.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSName name = (COSName) arguments.get( 0 );
-
-        Map xobjects = context.getXObjects();
-        PDXObject xobject = (PDXObject) xobjects.get(name.getName());
-        if (this.context instanceof PDFMarkedContentExtractor)
-        {
-            ((PDFMarkedContentExtractor) this.context).xobject(xobject);
-        }
-
-        if(xobject instanceof PDXObjectForm)
-        {
-            PDXObjectForm form = (PDXObjectForm)xobject;
-            COSStream invoke = (COSStream)form.getCOSObject();
-            PDResources pdResources = form.getResources();
-            PDPage page = context.getCurrentPage();
-            if(pdResources == null)
-            {
-                pdResources = page.findResources();
-            }
-
-            getContext().processSubStream( page, pdResources, invoke );
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveAndShow.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveAndShow.java
deleted file mode 100644 (file)
index 58266dd..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.5 $
- */
-public class MoveAndShow extends OperatorProcessor
-{
-    /**
-     * ' Move to next line and show text.
-     * @param arguments List
-     * @param operator The operator that is being executed.
-     * @throws IOException If there is an error processing the operator.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        // Move to start of next text line, and show text
-        //
-
-        context.processOperator("T*", null);
-        context.processOperator("Tj", arguments);
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveText.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveText.java
deleted file mode 100644 (file)
index d7cac88..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.Matrix;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- *
- * @author Huault : huault@free.fr
- * @version $Revision: 1.4 $
- */
-public class MoveText extends OperatorProcessor
-{
-
-    /**
-     * process : Td : Move text position.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        COSNumber x = (COSNumber)arguments.get( 0 );
-        COSNumber y = (COSNumber)arguments.get( 1 );
-        Matrix td = new Matrix();
-        td.setValue( 2, 0, x.floatValue() );
-        td.setValue( 2, 1, y.floatValue() );
-        context.setTextLineMatrix( td.multiply( context.getTextLineMatrix() ) );
-        context.setTextMatrix( context.getTextLineMatrix().copy() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveTextSetLeading.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/MoveTextSetLeading.java
deleted file mode 100644 (file)
index 7b399bd..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSFloat;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- *
- * @author Huault : huault@free.fr
- * @version $Revision: 1.5 $
- */
-public class MoveTextSetLeading extends OperatorProcessor
-{
-
-    /**
-     * process : TD Move text position and set leading.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If there is an error during processing.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        //move text position and set leading
-        COSNumber y = (COSNumber)arguments.get( 1 );
-
-        ArrayList<COSBase> args = new ArrayList<COSBase>();
-        args.add(new COSFloat(-1*y.floatValue()));
-        context.processOperator("TL", args);
-        context.processOperator("Td", arguments);
-
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/NextLine.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/NextLine.java
deleted file mode 100644 (file)
index 34db42f..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSFloat;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- *
- * @author Huault : huault@free.fr
- * @version $Revision: 1.5 $
- */
-public class NextLine extends OperatorProcessor
-{
-    /**
-     * process : T* Move to start of next text line.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If there is an error during processing.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        //move to start of next text line
-        ArrayList<COSBase> args = new ArrayList<COSBase>();
-        args.add(new COSFloat(0.0f));
-        // this must be -leading instead of just leading as written in the
-        // specification (p.369) the acrobat reader seems to implement it the same way
-        args.add(new COSFloat(-1*context.getGraphicsState().getTextState().getLeading()));
-        // use Td instead of repeating code
-        context.processOperator("Td", args);
-
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/OperatorProcessor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/OperatorProcessor.java
deleted file mode 100644 (file)
index 610991e..0000000
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.PDFStreamEngine;
-import java.util.List;
-import java.io.IOException;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.3 $
- */
-public abstract class OperatorProcessor
-{
-
-    /**
-     * The stream engine processing context.
-     */
-    protected PDFStreamEngine context = null;
-
-    /**
-     * Constructor.
-     *
-     */
-    protected OperatorProcessor()
-    {
-    }
-
-    /**
-     * Get the context for processing.
-     *
-     * @return The processing context.
-     */
-    protected PDFStreamEngine getContext()
-    {
-        return context;
-    }
-
-    /**
-     * Set the processing context.
-     *
-     * @param ctx The context for processing.
-     */
-    public void setContext(PDFStreamEngine ctx)
-    {
-        context = ctx;
-    }
-
-    /**
-     * process the operator.
-     * @param operator The operator that is being processed.
-     * @param arguments arguments needed by this operator.
-     *
-     * @throws IOException If there is an error processing the operator.
-     */
-    public abstract void process(PDFOperator operator, List<COSBase> arguments) throws IOException;
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetCharSpacing.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetCharSpacing.java
deleted file mode 100644 (file)
index da1c134..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- *
- * @author Huault : huault@free.fr
- * @version $Revision: 1.5 $
- */
-public class SetCharSpacing extends OperatorProcessor
-{
-    /**
-     * process : Tc Set character spacing.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        //set character spacing
-        if( arguments.size() > 0 )
-        {
-            //There are some documents which are incorrectly structured, and have
-            //a wrong number of arguments to this, so we will assume the last argument
-            //in the list
-            Object charSpacing = arguments.get( arguments.size()-1 );
-            if( charSpacing instanceof COSNumber )
-            {
-                COSNumber characterSpacing = (COSNumber)charSpacing;
-                context.getGraphicsState().getTextState().setCharacterSpacing( characterSpacing.floatValue() );
-            }
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetGraphicsStateParameters.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetGraphicsStateParameters.java
deleted file mode 100644 (file)
index 3d17877..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.pdmodel.graphics.PDExtendedGraphicsState;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.5 $
- */
-
-public class SetGraphicsStateParameters extends OperatorProcessor
-{
-    /**
-     * gs Set parameters from graphics state parameter dictionary.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        //set parameters from graphics state parameter dictionary
-        COSName graphicsName = (COSName)arguments.get( 0 );
-        PDExtendedGraphicsState gs = (PDExtendedGraphicsState)context.getGraphicsStates().get( graphicsName.getName() );
-        gs.copyIntoGraphicsState( context.getGraphicsState() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetHorizontalTextScaling.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetHorizontalTextScaling.java
deleted file mode 100644 (file)
index 62c67d5..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.5 $
- */
-
-public class SetHorizontalTextScaling extends OperatorProcessor
-{
-    /**
-     * Tz Set horizontal text scaling.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSNumber scaling = (COSNumber)arguments.get(0);
-        context.getGraphicsState().getTextState().setHorizontalScalingPercent( scaling.floatValue() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineCapStyle.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineCapStyle.java
deleted file mode 100644 (file)
index 855ab8b..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:andreas@lehmi.de>Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetLineCapStyle extends OperatorProcessor
-{
-
-    /**
-     * Set the line cap style.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        int lineCapStyle = ((COSNumber)arguments.get( 0 )).intValue();
-        context.getGraphicsState().setLineCap( lineCapStyle );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineDashPattern.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineDashPattern.java
deleted file mode 100644 (file)
index d480be7..0000000
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSArray;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.PDLineDashPattern;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.1 $
- */
-public class SetLineDashPattern extends OperatorProcessor
-{
-
-    /**
-     * Set the line dash pattern.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSArray dashArray = (COSArray)arguments.get( 0 );
-        int dashPhase = ((COSNumber)arguments.get( 1 )).intValue();
-        PDLineDashPattern lineDash = new PDLineDashPattern( dashArray, dashPhase );
-        context.getGraphicsState().setLineDashPattern( lineDash );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineJoinStyle.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineJoinStyle.java
deleted file mode 100644 (file)
index 88964f2..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:andreas@lehmi.de>Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetLineJoinStyle extends OperatorProcessor
-{
-
-    /**
-     * Set the line cap style.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        int lineJoinStyle = ((COSNumber)arguments.get( 0 )).intValue();
-        context.getGraphicsState().setLineJoin( lineJoinStyle );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineMiterLimit.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineMiterLimit.java
deleted file mode 100644 (file)
index 2f8a917..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-
-public class SetLineMiterLimit extends OperatorProcessor
-{
-    /**
-     * w Set miter limit.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSNumber miterLimit = (COSNumber)arguments.get( 0 );
-        context.getGraphicsState().setMiterLimit( miterLimit.doubleValue() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineWidth.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetLineWidth.java
deleted file mode 100644 (file)
index d36be94..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.5 $
- */
-
-public class SetLineWidth extends OperatorProcessor
-{
-    /**
-     * w Set line width.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSNumber width = (COSNumber)arguments.get( 0 );
-        context.getGraphicsState().setLineWidth( width.doubleValue() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetMatrix.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetMatrix.java
deleted file mode 100644 (file)
index 7499ea6..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.Matrix;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.4 $
- */
-
-public class SetMatrix extends OperatorProcessor
-{
-
-    /**
-     * Tm Set text matrix and text line matrix.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        //Set text matrix and text line matrix
-        COSNumber a = (COSNumber)arguments.get( 0 );
-        COSNumber b = (COSNumber)arguments.get( 1 );
-        COSNumber c = (COSNumber)arguments.get( 2 );
-        COSNumber d = (COSNumber)arguments.get( 3 );
-        COSNumber e = (COSNumber)arguments.get( 4 );
-        COSNumber f = (COSNumber)arguments.get( 5 );
-
-        Matrix textMatrix = new Matrix();
-        textMatrix.setValue( 0, 0, a.floatValue() );
-        textMatrix.setValue( 0, 1, b.floatValue() );
-        textMatrix.setValue( 1, 0, c.floatValue() );
-        textMatrix.setValue( 1, 1, d.floatValue() );
-        textMatrix.setValue( 2, 0, e.floatValue() );
-        textMatrix.setValue( 2, 1, f.floatValue() );
-        context.setTextMatrix( textMatrix );
-        context.setTextLineMatrix( textMatrix.copy() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetMoveAndShow.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetMoveAndShow.java
deleted file mode 100644 (file)
index 778875b..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.6 $
- */
-
-public class SetMoveAndShow extends OperatorProcessor
-{
-    /**
-     * " Set word and character spacing, move to next line, and show text.
-     * @param operator The operator that is being executed.
-     * @param arguments List.
-     * @throws IOException If there is an error processing the operator.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        //Set word and character spacing, move to next line, and show text
-        //
-        context.processOperator("Tw", arguments.subList(0,1));
-        context.processOperator("Tc", arguments.subList(1,2));
-        context.processOperator("'", arguments.subList(2,3));
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingCMYKColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingCMYKColor.java
deleted file mode 100644 (file)
index 8b6b0d1..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Set the non stroking color space.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.4 $
- */
-public class SetNonStrokingCMYKColor extends OperatorProcessor
-{
-    /**
-     * k Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorSpace cs = PDDeviceCMYK.INSTANCE;
-        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
-        colorInstance.setColorSpace( cs );
-        float[] values = new float[4];
-        for( int i=0; i<arguments.size(); i++ )
-        {
-            values[i] = ((COSNumber)arguments.get( i )).floatValue();
-        }
-        colorInstance.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingCalRGBColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingCalRGBColor.java
deleted file mode 100644 (file)
index 02fef3f..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Set the non stroking color space.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.3 $
- */
-public class SetNonStrokingCalRGBColor extends OperatorProcessor
-{
-    /**
-     * rg Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
-        float[] values = new float[3];
-        for( int i=0; i<arguments.size(); i++ )
-        {
-            values[i] = ((COSNumber)arguments.get( i )).floatValue();
-        }
-        colorInstance.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingColor.java
deleted file mode 100644 (file)
index c1d74b1..0000000
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceGray;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceN;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceRGB;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
-import org.apache.pdfbox.pdmodel.graphics.color.PDICCBased;
-import org.apache.pdfbox.pdmodel.graphics.color.PDCalRGB;
-import org.apache.pdfbox.pdmodel.graphics.color.PDSeparation;
-import org.apache.pdfbox.util.PDFOperator;
-import java.io.IOException;
-
-/**
- * <p>Set the non stroking color space.</p>
- * 
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetNonStrokingColor extends OperatorProcessor 
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(SetNonStrokingColor.class);
-
-    /**
-     * sc,scn Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorSpace colorSpace = context.getGraphicsState().getNonStrokingColor().getColorSpace();
-        if (colorSpace != null) 
-        {
-            OperatorProcessor newOperator = null;
-            if (colorSpace instanceof PDDeviceGray) 
-            {
-                newOperator = new SetNonStrokingGrayColor();
-            }
-            else if (colorSpace instanceof PDDeviceRGB)
-            {
-                newOperator = new SetNonStrokingRGBColor();
-            }
-            else if (colorSpace instanceof PDDeviceCMYK)
-            {
-                newOperator = new SetNonStrokingCMYKColor();
-            }
-            else if (colorSpace instanceof PDICCBased)
-            {
-                newOperator = new SetNonStrokingICCBasedColor();
-            }
-            else if (colorSpace instanceof PDCalRGB)
-            {
-                newOperator = new SetNonStrokingCalRGBColor();
-            }   
-            else if (colorSpace instanceof PDSeparation)
-            {
-                newOperator = new SetNonStrokingSeparation();
-            }
-            else if (colorSpace instanceof PDDeviceN)
-            {
-                newOperator = new SetNonStrokingDeviceN();
-            }
-
-            if (newOperator != null) 
-            {
-                newOperator.setContext(getContext());
-                newOperator.process(operator, arguments);
-            }
-            else 
-            {
-                log.warn("Not supported colorspace "+colorSpace.getName() 
-                        + " within operator "+operator.getOperation());
-            }
-        }
-        else
-        {
-            log.warn("Colorspace not found in "+getClass().getName()+".process!!");
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingColorSpace.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingColorSpace.java
deleted file mode 100644 (file)
index 539b1ba..0000000
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpaceFactory;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Set the non stroking color space.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.4 $
- */
-public class SetNonStrokingColorSpace extends OperatorProcessor
-{
-    private static final float[] EMPTY_FLOAT_ARRAY = new float[0];
-
-    /**
-     * cs Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-//      (PDF 1.1) Set color space for stroking operations
-        COSName name = (COSName)arguments.get( 0 );
-        PDColorSpace cs = PDColorSpaceFactory.createColorSpace( name, context.getColorSpaces() );
-        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
-        colorInstance.setColorSpace( cs );
-        int numComponents = cs.getNumberOfComponents();
-        float[] values = EMPTY_FLOAT_ARRAY;
-        if( numComponents >= 0 )
-        {
-            values = new float[numComponents];
-            for( int i=0; i<numComponents; i++ )
-            {
-                values[i] = 0f;
-            }
-            if( cs instanceof PDDeviceCMYK )
-            {
-                values[3] = 1f;
-            }
-        }
-        colorInstance.setColorSpaceValue( values );
-    }
-}
\ No newline at end of file
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingDeviceN.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingDeviceN.java
deleted file mode 100644 (file)
index b0306b8..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdmodel.graphics.color.PDCalRGB;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceGray;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceRGB;
-import org.apache.pdfbox.pdmodel.graphics.color.PDICCBased;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceN;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * 
- * @version $Revision: 1.0 $
- */
-public class SetNonStrokingDeviceN extends OperatorProcessor 
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log =
-        LogFactory.getLog(SetNonStrokingDeviceN.class);
-
-    /**
-     * scn Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
-        PDColorSpace colorSpace = colorInstance.getColorSpace();
-        
-        if (colorSpace != null) 
-        {
-            List<COSBase> argList = arguments;
-            OperatorProcessor newOperator = null;
-
-            if (colorSpace instanceof PDDeviceN) {
-                PDDeviceN sep = (PDDeviceN) colorSpace;
-                colorSpace = sep.getAlternateColorSpace();
-                argList = sep.calculateColorValues(arguments).toList();
-            }
-
-            if (colorSpace instanceof PDDeviceGray)
-            {
-                newOperator = new SetNonStrokingGrayColor();
-            }
-            else if (colorSpace instanceof PDDeviceRGB)
-            {
-                newOperator = new SetNonStrokingRGBColor();
-            }
-            else if (colorSpace instanceof PDDeviceCMYK)
-            {
-                newOperator = new SetNonStrokingCMYKColor();
-            }
-            else if (colorSpace instanceof PDICCBased)
-            {
-                newOperator = new SetNonStrokingICCBasedColor();
-            }
-            else if (colorSpace instanceof PDCalRGB)
-            {
-                newOperator = new SetNonStrokingCalRGBColor();
-            }
-    
-            if (newOperator != null) 
-            {
-                colorInstance.setColorSpace(colorSpace);
-                newOperator.setContext(getContext());
-                newOperator.process(operator, argList);
-            }
-            else
-            {
-                log.warn("Not supported colorspace "+colorSpace.getName() 
-                        + " within operator "+operator.getOperation());
-            }
-        }
-        
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingGrayColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingGrayColor.java
deleted file mode 100644 (file)
index 27b3410..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceGray;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Set the non stroking color space.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.1 $
- */
-public class SetNonStrokingGrayColor extends OperatorProcessor
-{
-    /**
-     * rg Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorSpace cs = new PDDeviceGray();
-        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
-        colorInstance.setColorSpace( cs );
-        float[] values = new float[1];
-        if( arguments.size() >= 1 )
-        {
-            values[0] = ((COSNumber)arguments.get( 0 )).floatValue();
-        }
-        else
-        {
-            throw new IOException( "Error: Expected at least one argument when setting non stroking gray color");
-        }
-        colorInstance.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingICCBasedColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingICCBasedColor.java
deleted file mode 100644 (file)
index d124cf5..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * 
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetNonStrokingICCBasedColor extends OperatorProcessor 
-{
-    /**
-     * scn Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
-        PDColorSpace cs = colorInstance.getColorSpace();
-        int numberOfComponents = cs.getNumberOfComponents();
-        float[] values = new float[numberOfComponents];
-        for( int i=0; i<numberOfComponents; i++ )
-        {
-            values[i] = ((COSNumber)arguments.get( i )).floatValue();
-        }
-        colorInstance.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingRGBColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingRGBColor.java
deleted file mode 100644 (file)
index 6cb6339..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceRGB;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Set the non stroking color space.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.3 $
- */
-public class SetNonStrokingRGBColor extends OperatorProcessor
-{
-    /**
-     * rg Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorSpace cs = PDDeviceRGB.INSTANCE;
-        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
-        colorInstance.setColorSpace( cs );
-        float[] values = new float[3];
-        for( int i=0; i<arguments.size(); i++ )
-        {
-            values[i] = ((COSNumber)arguments.get( i )).floatValue();
-        }
-        colorInstance.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingSeparation.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetNonStrokingSeparation.java
deleted file mode 100644 (file)
index cc38284..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSArray;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDSeparation;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * 
- * @author <a href="mailto:WilliamstonConsulting@GMail.com">Daniel Wilson</a>
- * @version $Revision: 1.0 $
- */
-public class SetNonStrokingSeparation extends OperatorProcessor 
-{
-
-    /**
-     * scn Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
-        PDColorSpace colorSpace = colorInstance.getColorSpace();
-        
-        if (colorSpace != null) 
-        {
-            PDSeparation sep = (PDSeparation) colorSpace;
-            colorSpace = sep.getAlternateColorSpace();
-            COSArray values = sep.calculateColorValues(arguments.get(0));
-            colorInstance.setColorSpaceValue(values.toFloatArray());
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingCMYKColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingCMYKColor.java
deleted file mode 100644 (file)
index 2df4725..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.4 $
- */
-public class SetStrokingCMYKColor extends OperatorProcessor
-{
-    /**
-     * K Set color space for stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState color = context.getGraphicsState().getStrokingColor();
-        color.setColorSpace( PDDeviceCMYK.INSTANCE );
-        float[] values = new float[4];
-        for( int i=0; i<arguments.size(); i++ )
-        {
-            values[i] = ((COSNumber)arguments.get( i )).floatValue();
-        }
-        color.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingCalRGBColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingCalRGBColor.java
deleted file mode 100644 (file)
index bcb1628..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Structural modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is replaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.3 $
- */
-public class SetStrokingCalRGBColor extends OperatorProcessor
-{
-    /**
-     * RG Set color space for stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState color = context.getGraphicsState().getStrokingColor();
-        float[] values = new float[3];
-        for( int i=0; i<arguments.size(); i++ )
-        {
-            values[i] = ((COSNumber)arguments.get( i )).floatValue();
-        }
-        color.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingColor.java
deleted file mode 100644 (file)
index 9d95fc1..0000000
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceGray;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceN;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceRGB;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
-import org.apache.pdfbox.pdmodel.graphics.color.PDICCBased;
-import org.apache.pdfbox.pdmodel.graphics.color.PDCalRGB;
-import org.apache.pdfbox.pdmodel.graphics.color.PDSeparation;
-import org.apache.pdfbox.util.PDFOperator;
-import java.io.IOException;
-
-/**
- * <p>Set the stroking color space.</p>
- * 
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetStrokingColor extends OperatorProcessor 
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(SetStrokingColor.class);
-
-    /**
-     * SC,SCN Set color space for stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorSpace colorSpace = context.getGraphicsState().getStrokingColor().getColorSpace();
-        if (colorSpace != null) 
-        {
-            OperatorProcessor newOperator = null;
-            if (colorSpace instanceof PDDeviceGray)
-            {
-                newOperator = new SetStrokingGrayColor();
-            }
-            else if (colorSpace instanceof PDDeviceRGB)
-            {
-                newOperator = new SetStrokingRGBColor();
-            }
-            else if (colorSpace instanceof PDDeviceCMYK)
-            {
-                newOperator = new SetStrokingCMYKColor();
-            }
-            else if (colorSpace instanceof PDICCBased)
-            {
-                newOperator = new SetStrokingICCBasedColor();
-            }
-            else if (colorSpace instanceof PDCalRGB)
-            {
-                newOperator = new SetStrokingCalRGBColor();
-            }   
-            else if (colorSpace instanceof PDSeparation)
-            {
-                newOperator = new SetStrokingSeparation();
-            }
-            else if (colorSpace instanceof PDDeviceN)
-            {
-                newOperator = new SetStrokingDeviceN();
-            }
-
-            if (newOperator != null) 
-            {
-                newOperator.setContext(getContext());
-                newOperator.process(operator, arguments);
-            }
-            else
-            {
-                log.info("Not supported colorspace "+colorSpace.getName() 
-                        + " within operator "+operator.getOperation());
-            }
-        }
-        else 
-        {
-            log.warn("Colorspace not found in "+getClass().getName()+".process!!");
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingColorSpace.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingColorSpace.java
deleted file mode 100644 (file)
index eeaf34b..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpaceFactory;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.5 $
- */
-
-public class SetStrokingColorSpace extends OperatorProcessor
-{
-    private static final float[] EMPTY_FLOAT_ARRAY = new float[0];
-
-    /**
-     * CS Set color space for stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        //(PDF 1.1) Set color space for stroking operations
-        COSName name = (COSName)arguments.get( 0 );
-        PDColorSpace cs = PDColorSpaceFactory.createColorSpace( name, context.getColorSpaces() );
-        PDColorState color = context.getGraphicsState().getStrokingColor();
-        color.setColorSpace( cs );
-        int numComponents = cs.getNumberOfComponents();
-        float[] values = EMPTY_FLOAT_ARRAY;
-        if( numComponents >= 0 )
-        {
-            values = new float[numComponents];
-            for( int i=0; i<numComponents; i++ )
-            {
-                values[i] = 0f;
-            }
-            if( cs instanceof PDDeviceCMYK )
-            {
-                values[3] = 1f;
-            }
-        }
-        color.setColorSpaceValue( values );
-    }
-}
\ No newline at end of file
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingDeviceN.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingDeviceN.java
deleted file mode 100644 (file)
index 65e0142..0000000
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdmodel.graphics.color.PDCalRGB;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceCMYK;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceGray;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceN;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceRGB;
-import org.apache.pdfbox.pdmodel.graphics.color.PDICCBased;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * 
- * @version $Revision: 1.0 $
- */
-public class SetStrokingDeviceN extends OperatorProcessor 
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log =
-        LogFactory.getLog(SetStrokingDeviceN.class);
-
-    /**
-     * scn Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState color = context.getGraphicsState().getStrokingColor();
-        PDColorSpace colorSpace = color.getColorSpace();
-
-        if (colorSpace != null) 
-        {
-            OperatorProcessor newOperator = null;
-            List<COSBase> argList = arguments;
-
-            if (colorSpace instanceof PDDeviceN) 
-            {
-                PDDeviceN sep = (PDDeviceN) colorSpace;
-                colorSpace = sep.getAlternateColorSpace();
-                argList = sep.calculateColorValues(arguments).toList();
-            }
-
-            if (colorSpace instanceof PDDeviceGray)
-            {
-                newOperator = new SetStrokingGrayColor();
-            }
-            else if (colorSpace instanceof PDDeviceRGB)
-            {
-                newOperator = new SetStrokingRGBColor();
-            }
-            else if (colorSpace instanceof PDDeviceCMYK)
-            {
-                newOperator = new SetStrokingCMYKColor();
-            }
-            else if (colorSpace instanceof PDICCBased)
-            {
-                newOperator = new SetStrokingICCBasedColor();
-            }
-            else if (colorSpace instanceof PDCalRGB)
-            {
-                newOperator = new SetStrokingCalRGBColor();
-            }
-
-            if (newOperator != null) 
-            {
-                color.setColorSpace(colorSpace);
-                newOperator.setContext(getContext());
-                newOperator.process(operator, argList);
-            }
-            else
-            {
-                log.warn("Not supported colorspace "+colorSpace.getName() 
-                        + " within operator "+operator.getOperation());
-            }
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingGrayColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingGrayColor.java
deleted file mode 100644 (file)
index 4122646..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceGray;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.1 $
- */
-public class SetStrokingGrayColor extends OperatorProcessor
-{
-    /**
-     * RG Set color space for stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState color = context.getGraphicsState().getStrokingColor();
-        color.setColorSpace( new PDDeviceGray() );
-        float[] values = new float[1];
-        if( arguments.size() >= 1 )
-        {
-            values[0] = ((COSNumber)arguments.get( 0 )).floatValue();
-        }
-        else
-        {
-            throw new IOException( "Error: Expected at least one argument when setting non stroking gray color");
-        }
-        color.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingICCBasedColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingICCBasedColor.java
deleted file mode 100644 (file)
index 4e3009c..0000000
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * 
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetStrokingICCBasedColor extends OperatorProcessor 
-{
-    /**
-     * scn Set color space for stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState color = context.getGraphicsState().getStrokingColor();
-        PDColorSpace cs = color.getColorSpace();
-        int numberOfComponents = cs.getNumberOfComponents();
-        float[] values = new float[numberOfComponents];
-        for( int i=0; i<numberOfComponents; i++ )
-        {
-            values[i] = ((COSNumber)arguments.get( i )).floatValue();
-        }
-        color.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingRGBColor.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingRGBColor.java
deleted file mode 100644 (file)
index 0bd4295..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDDeviceRGB;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.3 $
- */
-public class SetStrokingRGBColor extends OperatorProcessor
-{
-    /**
-     * RG Set color space for stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState color = context.getGraphicsState().getStrokingColor();
-        color.setColorSpace( PDDeviceRGB.INSTANCE );
-        float[] values = new float[3];
-        for( int i=0; i<arguments.size(); i++ )
-        {
-            values[i] = ((COSNumber)arguments.get( i )).floatValue();
-        }
-        color.setColorSpaceValue( values );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingSeparation.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetStrokingSeparation.java
deleted file mode 100644 (file)
index f013036..0000000
+++ /dev/null
@@ -1,56 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSArray;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace;
-import org.apache.pdfbox.pdmodel.graphics.color.PDColorState;
-import org.apache.pdfbox.pdmodel.graphics.color.PDSeparation;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * 
- * @author <a href="mailto:WilliamstonConsulting@GMail.com">Daniel Wilson</a>
- * @version $Revision: 1.0 $
- */
-public class SetStrokingSeparation extends OperatorProcessor 
-{
-
-    /**
-     * scn Set color space for non stroking operations.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PDColorState colorInstance = context.getGraphicsState().getStrokingColor();
-        PDColorSpace colorSpace = colorInstance.getColorSpace();
-
-        if (colorSpace != null) 
-        {
-            PDSeparation sep = (PDSeparation) colorSpace;
-            colorSpace = sep.getAlternateColorSpace();
-            COSArray values = sep.calculateColorValues(arguments.get(0));
-            colorInstance.setColorSpaceValue(values.toFloatArray());
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextFont.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextFont.java
deleted file mode 100644 (file)
index 5beeeb1..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdmodel.font.PDFont;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.5 $
- */
-
-public class SetTextFont extends OperatorProcessor
-{
-    /**
-     * Tf selectfont Set text font and size.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        //there are some documents that are incorrectly structured and
-        //arguments are in the wrong spot, so we will silently ignore them
-        //if there are no arguments
-        if( arguments.size() >= 2 )
-        {
-            //set font and size
-            COSName fontName = (COSName)arguments.get( 0 );
-            float fontSize = ((COSNumber)arguments.get( 1 ) ).floatValue();
-            context.getGraphicsState().getTextState().setFontSize( fontSize );
-
-            context.getGraphicsState().getTextState().setFont( (PDFont)context.getFonts().get( fontName.getName() ) );
-            if( context.getGraphicsState().getTextState().getFont() == null )
-            {
-                throw new IOException( "Error: Could not find font(" + fontName + ") in map=" + context.getFonts() );
-            }
-        }
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextLeading.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextLeading.java
deleted file mode 100644 (file)
index 8d07b04..0000000
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.4 $
- */
-
-public class SetTextLeading extends OperatorProcessor
-{
-    /**
-     * TL Set text leading.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        COSNumber leading = (COSNumber)arguments.get( 0 );
-        context.getGraphicsState().getTextState().setLeading( leading.floatValue() );
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextRenderingMode.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextRenderingMode.java
deleted file mode 100644 (file)
index ae40667..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.5 $
- */
-
-public class SetTextRenderingMode extends OperatorProcessor
-{
-    /**
-     * Tr Set text rendering mode.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSNumber mode = (COSNumber)arguments.get( 0 );
-        context.getGraphicsState().getTextState().setRenderingMode( mode.intValue() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextRise.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetTextRise.java
deleted file mode 100644 (file)
index e564728..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * <p>Structal modification of the PDFEngine class :
- * the long sequence of conditions in processOperator is remplaced by
- * this strategy pattern.</p>
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.5 $
- */
-
-public class SetTextRise extends OperatorProcessor
-{
-    /**
-     * Ts Set text rise.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSNumber rise = (COSNumber)arguments.get(0);
-        context.getGraphicsState().getTextState().setRise( rise.floatValue() );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetWordSpacing.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/SetWordSpacing.java
deleted file mode 100644 (file)
index bed107f..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.util.PDFOperator;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.4 $
- */
-
-public class SetWordSpacing extends OperatorProcessor
-{
-    /**
-     * Tw Set word spacing.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        //set word spacing
-        COSNumber wordSpacing = (COSNumber)arguments.get( 0 );
-        context.getGraphicsState().getTextState().setWordSpacing( wordSpacing.floatValue() );
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/ShowText.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/ShowText.java
deleted file mode 100644 (file)
index 3731368..0000000
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSString;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.io.IOException;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.4 $
- */
-
-public class ShowText extends OperatorProcessor
-{
-
-    /**
-     * Tj show Show text.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If there is an error processing this operator.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSString string = (COSString)arguments.get( 0 );
-        context.processEncodedText( string.getBytes() );
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/ShowTextGlyph.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/ShowTextGlyph.java
deleted file mode 100644 (file)
index c1d1b83..0000000
+++ /dev/null
@@ -1,71 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator;
-
-import java.util.List;
-
-import org.apache.pdfbox.util.Matrix;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.cos.COSArray;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import java.io.IOException;
-import org.apache.pdfbox.cos.COSString;
-
-/**
- * @author Huault : huault@free.fr
- * @version $Revision: 1.6 $
- */
-
-public class ShowTextGlyph extends OperatorProcessor
-{
-    /**
-     * TJ Show text, allowing individual glyph positioning.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If there is an error processing this operator.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        COSArray array = (COSArray)arguments.get( 0 );
-        int arraySize = array.size();
-        float fontsize = context.getGraphicsState().getTextState().getFontSize();
-        float horizontalScaling = context.getGraphicsState().getTextState().getHorizontalScalingPercent()/100;
-        for( int i=0; i<arraySize; i++ )
-        {
-            COSBase next = array.get( i );
-            if( next instanceof COSNumber )
-            {
-                float adjustment = ((COSNumber)next).floatValue();
-                Matrix adjMatrix = new Matrix();
-                adjustment=-(adjustment/1000)*horizontalScaling*fontsize;
-                // TODO vertical writing mode
-                adjMatrix.setValue( 2, 0, adjustment );
-                context.setTextMatrix( adjMatrix.multiply(context.getTextMatrix(), adjMatrix) );
-            }
-            else if( next instanceof COSString )
-            {
-                context.processEncodedText( ((COSString)next).getBytes() );
-            }
-            else
-            {
-                throw new IOException( "Unknown type in array for TJ operation:" + next );
-            }
-        }
-    }
-
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/package.html b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/package.html
deleted file mode 100644 (file)
index b3774c2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-<!--
- ! Licensed to the Apache Software Foundation (ASF) under one or more
- ! contributor license agreements.  See the NOTICE file distributed with
- ! this work for additional information regarding copyright ownership.
- ! The ASF licenses this file to You under the Apache License, Version 2.0
- ! (the "License"); you may not use this file except in compliance with
- ! the License.  You may obtain a copy of the License at
- !
- !      http://www.apache.org/licenses/LICENSE-2.0
- !
- ! Unless required by applicable law or agreed to in writing, software
- ! distributed under the License is distributed on an "AS IS" BASIS,
- ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- ! See the License for the specific language governing permissions and
- ! limitations under the License.
- !-->
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-
-</head>
-<body>
-This package contains implementations of all of the PDF operators.
-</body>
-</html>
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/AppendRectangleToPath.java
deleted file mode 100644 (file)
index 0b04318..0000000
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.GeneralPath;
-import java.awt.geom.Point2D;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.3 $
- */
-public class AppendRectangleToPath extends OperatorProcessor
-{
-
-
-    /**
-     * process : re : append rectangle to path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        PageDrawer drawer = (PageDrawer)context;
-
-        COSNumber x = (COSNumber)arguments.get( 0 );
-        COSNumber y = (COSNumber)arguments.get( 1 );
-        COSNumber w = (COSNumber)arguments.get( 2 );
-        COSNumber h = (COSNumber)arguments.get( 3 );
-
-        double x1 = x.doubleValue();
-        double y1 = y.doubleValue();
-        // create a pair of coordinates for the transformation 
-        double x2 = w.doubleValue()+x1;
-        double y2 = h.doubleValue()+y1;
-
-        Point2D startCoords = drawer.transformedPoint(x1,y1);
-        Point2D endCoords = drawer.transformedPoint(x2,y2);
-
-        float width = (float)(endCoords.getX()-startCoords.getX());
-        float height = (float)(endCoords.getY()-startCoords.getY());
-        float xStart = (float)startCoords.getX();
-        float yStart = (float)startCoords.getY();
-
-        // To ensure that the path is created in the right direction,
-        // we have to create it by combining single lines instead of
-        // creating a simple rectangle
-        GeneralPath path = drawer.getLinePath();
-        path.moveTo(xStart, yStart);
-        path.lineTo(xStart+width, yStart);
-        path.lineTo(xStart+width, yStart+height);
-        path.lineTo(xStart, yStart+height);
-        path.lineTo(xStart, yStart);
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/BeginInlineImage.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/BeginInlineImage.java
deleted file mode 100644 (file)
index 0a41c42..0000000
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.AffineTransform;
-import java.awt.image.BufferedImage;
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.pdmodel.PDPage;
-import org.apache.pdfbox.pdmodel.graphics.xobject.PDInlinedImage;
-import org.apache.pdfbox.util.ImageParameters;
-import org.apache.pdfbox.util.Matrix;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class BeginInlineImage extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(BeginInlineImage.class);
-
-    /**
-     * process : BI : begin inline image.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If there is an error displaying the inline image.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)  throws IOException
-    {
-        PageDrawer drawer = (PageDrawer)context;
-        PDPage page = drawer.getPage();
-        //begin inline image object
-        ImageParameters params = operator.getImageParameters();
-        PDInlinedImage image = new PDInlinedImage();
-        image.setImageParameters( params );
-        image.setImageData( operator.getImageData() );
-        BufferedImage awtImage = image.createImage( context.getColorSpaces() );
-
-        if (awtImage == null) 
-        {
-            log.warn("BeginInlineImage.process(): createImage returned NULL");
-            return;
-        }
-        int imageWidth = awtImage.getWidth();
-        int imageHeight = awtImage.getHeight();
-        double pageHeight = drawer.getPageSize().getHeight();
-        
-        Matrix ctm = drawer.getGraphicsState().getCurrentTransformationMatrix();
-        int pageRotation = page.findRotation();
-
-        AffineTransform ctmAT = ctm.createAffineTransform();
-        ctmAT.scale(1f/imageWidth, 1f/imageHeight);
-        Matrix rotationMatrix = new Matrix();
-        rotationMatrix.setFromAffineTransform( ctmAT );
-        // calculate the inverse rotation angle
-        // scaleX = m00 = cos
-        // shearX = m01 = -sin
-        // tan = sin/cos
-        double angle = Math.atan(ctmAT.getShearX()/ctmAT.getScaleX());
-        Matrix translationMatrix = null;
-        if (pageRotation == 0 || pageRotation == 180) 
-        {
-            translationMatrix = Matrix.getTranslatingInstance((float)(Math.sin(angle)*ctm.getXScale()), (float)(pageHeight-2*ctm.getYPosition()-Math.cos(angle)*ctm.getYScale())); 
-        }
-        else if (pageRotation == 90 || pageRotation == 270) 
-        {
-            translationMatrix = Matrix.getTranslatingInstance((float)(Math.sin(angle)*ctm.getYScale()), (float)(pageHeight-2*ctm.getYPosition())); 
-        }
-        rotationMatrix = rotationMatrix.multiply(translationMatrix);
-        rotationMatrix.setValue(0, 1, (-1)*rotationMatrix.getValue(0, 1));
-        rotationMatrix.setValue(1, 0, (-1)*rotationMatrix.getValue(1, 0));
-        AffineTransform at = new AffineTransform(
-                rotationMatrix.getValue(0,0),rotationMatrix.getValue(0,1),
-                rotationMatrix.getValue(1,0), rotationMatrix.getValue( 1, 1),
-                rotationMatrix.getValue(2,0),rotationMatrix.getValue(2,1)
-                );
-        drawer.drawImage(awtImage, at);
-    }
-}
\ No newline at end of file
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClipEvenOddRule.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClipEvenOddRule.java
deleted file mode 100644 (file)
index cc642bc..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.GeneralPath;
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:Daniel.Wilson@BlackLocustSoftware.com">Daniel Wilson</a>
- * @version $Revision: 1.1 $
- */
-public class ClipEvenOddRule extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(ClipEvenOddRule.class);
-
-    /**
-     * process : W* : set clipping path using even odd rule.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException if there is an error during execution.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-
-        try 
-        {
-            PageDrawer drawer = (PageDrawer)context;
-            drawer.setClippingPath(GeneralPath.WIND_EVEN_ODD);
-        } 
-        catch (Exception e) 
-        {
-            log.warn(e, e);
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClipNonZeroRule.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClipNonZeroRule.java
deleted file mode 100644 (file)
index bff5046..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.GeneralPath;
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:Daniel.Wilson@BlackLocustSoftware.com">Daniel Wilson</a>
- * @version $Revision: 1.1 $
- */
-public class ClipNonZeroRule extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(ClipNonZeroRule.class);
-
-    /**
-     * process : W : Set the clipping path using non zero winding rule.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If there is an error during the processing.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-
-        try 
-        {
-            PageDrawer drawer = (PageDrawer)context;
-            drawer.setClippingPath(GeneralPath.WIND_NON_ZERO);
-        } 
-        catch (Exception e) 
-        {
-            log.warn(e, e);
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CloseFillEvenOddAndStrokePath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CloseFillEvenOddAndStrokePath.java
deleted file mode 100644 (file)
index a3bc43d..0000000
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.PDFOperator;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class CloseFillEvenOddAndStrokePath extends org.apache.pdfbox.util.operator.OperatorProcessor
-{
-
-    /**
-     * fill and stroke the path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        context.processOperator( "h", arguments );
-
-        context.processOperator( "f*", arguments );
-
-        context.processOperator( "S", arguments );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CloseFillNonZeroAndStrokePath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CloseFillNonZeroAndStrokePath.java
deleted file mode 100644 (file)
index a076f6d..0000000
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.1 $
- */
-public class CloseFillNonZeroAndStrokePath extends OperatorProcessor
-{
-
-    /**
-     * fill and stroke the path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        context.processOperator( "h", arguments );
-
-        context.processOperator( "f", arguments );
-
-        context.processOperator( "S", arguments );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClosePath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/ClosePath.java
deleted file mode 100644 (file)
index e13323b..0000000
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-import java.io.IOException;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.3 $
- */
-public class ClosePath extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(ClosePath.class);
-
-    /**
-     * process : h : Close path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * 
-     * @throws IOException if something went wrong during logging
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PageDrawer drawer = (PageDrawer)context;
-        try
-        {
-            drawer.getLinePath().closePath();
-        }
-        catch( Throwable t )
-        {
-            log.warn(t, t);
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveTo.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveTo.java
deleted file mode 100644 (file)
index 1175574..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-import java.awt.geom.Point2D;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class CurveTo extends OperatorProcessor
-{
-
-
-    /**
-     * process : c : Append curved segment to path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        PageDrawer drawer = (PageDrawer)context;
-
-        COSNumber x1 = (COSNumber)arguments.get( 0 );
-        COSNumber y1 = (COSNumber)arguments.get( 1 );
-        COSNumber x2 = (COSNumber)arguments.get( 2 );
-        COSNumber y2 = (COSNumber)arguments.get( 3 );
-        COSNumber x3 = (COSNumber)arguments.get( 4 );
-        COSNumber y3 = (COSNumber)arguments.get( 5 );
-
-        Point2D point1 = drawer.transformedPoint(x1.doubleValue(), y1.doubleValue());
-        Point2D point2 = drawer.transformedPoint(x2.doubleValue(), y2.doubleValue());
-        Point2D point3 = drawer.transformedPoint(x3.doubleValue(), y3.doubleValue());
-
-        drawer.getLinePath().curveTo((float)point1.getX(), (float)point1.getY(), 
-                (float)point2.getX(), (float)point2.getY(), (float)point3.getX(), (float)point3.getY());
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveToReplicateFinalPoint.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveToReplicateFinalPoint.java
deleted file mode 100644 (file)
index a6ac69b..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-import java.awt.geom.Point2D;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class CurveToReplicateFinalPoint extends OperatorProcessor
-{
-
-
-    /**
-     * process : y : Append curved segment to path (final point replicated).
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        PageDrawer drawer = (PageDrawer)context;
-
-        COSNumber x1 = (COSNumber)arguments.get( 0 );
-        COSNumber y1 = (COSNumber)arguments.get( 1 );
-        COSNumber x3 = (COSNumber)arguments.get( 2 );
-        COSNumber y3 = (COSNumber)arguments.get( 3 );
-
-        Point2D point1 = drawer.transformedPoint(x1.doubleValue(), y1.doubleValue());
-        Point2D point3 = drawer.transformedPoint(x3.doubleValue(), y3.doubleValue());
-
-        drawer.getLinePath().curveTo((float)point1.getX(), (float)point1.getY(), 
-                (float)point3.getX(), (float)point3.getY(), (float)point3.getX(), (float)point3.getY());
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveToReplicateInitialPoint.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/CurveToReplicateInitialPoint.java
deleted file mode 100644 (file)
index d89fca2..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.GeneralPath;
-import java.awt.geom.Point2D;
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class CurveToReplicateInitialPoint extends OperatorProcessor
-{
-
-
-    /**
-     * process : v : Append curved segment to path (initial point replicated).
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        PageDrawer drawer = (PageDrawer)context;
-
-        COSNumber x2 = (COSNumber)arguments.get( 0 );
-        COSNumber y2 = (COSNumber)arguments.get( 1 );
-        COSNumber x3 = (COSNumber)arguments.get( 2 );
-        COSNumber y3 = (COSNumber)arguments.get( 3 );
-        GeneralPath path = drawer.getLinePath();
-        Point2D currentPoint = path.getCurrentPoint();
-
-        Point2D point2 = drawer.transformedPoint(x2.doubleValue(), y2.doubleValue());
-        Point2D point3 = drawer.transformedPoint(x3.doubleValue(), y3.doubleValue());
-
-        drawer.getLinePath().curveTo((float)currentPoint.getX(), (float)currentPoint.getY(),
-                (float)point2.getX(), (float)point2.getY(), (float)point3.getX(), (float)point3.getY());
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/EndPath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/EndPath.java
deleted file mode 100644 (file)
index 1c68edd..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class EndPath extends OperatorProcessor
-{
-
-
-    /**
-     * process : n : End path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        PageDrawer drawer = (PageDrawer)context;
-        drawer.getLinePath().reset();
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillEvenOddAndStrokePath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillEvenOddAndStrokePath.java
deleted file mode 100644 (file)
index abaeb47..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.awt.geom.GeneralPath;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 101 $
- */
-public class FillEvenOddAndStrokePath extends org.apache.pdfbox.util.operator.OperatorProcessor
-{
-
-    /**
-     * fill and stroke the path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PageDrawer drawer = (PageDrawer)context;
-        GeneralPath currentPath = (GeneralPath)drawer.getLinePath().clone();
-
-        context.processOperator( "f*", arguments );
-        drawer.setLinePath( currentPath );
-
-        context.processOperator( "S", arguments );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillEvenOddRule.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillEvenOddRule.java
deleted file mode 100644 (file)
index d8f9b11..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.GeneralPath;
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.5 $
- */
-public class FillEvenOddRule extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(FillEvenOddRule.class);
-
-    /**
-     * process : f* : fill path using even odd rule.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException if there is an error during execution.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        try 
-        {
-            ///dwilson refactoring
-            PageDrawer drawer = (PageDrawer)context;
-            drawer.fillPath(GeneralPath.WIND_EVEN_ODD);
-        } 
-        catch (Exception e) 
-        {
-            log.warn(e, e);
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillNonZeroAndStrokePath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillNonZeroAndStrokePath.java
deleted file mode 100644 (file)
index 6dbe214..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.awt.geom.GeneralPath;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.1 $
- */
-public class FillNonZeroAndStrokePath extends org.apache.pdfbox.util.operator.OperatorProcessor
-{
-
-    /**
-     * fill and stroke the path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PageDrawer drawer = (PageDrawer)context;
-        GeneralPath currentPath = (GeneralPath)drawer.getLinePath().clone();
-
-        context.processOperator( "f", arguments );
-        drawer.setLinePath( currentPath );
-
-        context.processOperator( "S", arguments );
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillNonZeroRule.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/FillNonZeroRule.java
deleted file mode 100644 (file)
index ab2a3b4..0000000
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.GeneralPath;
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.5 $
- */
-public class FillNonZeroRule extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(FillNonZeroRule.class);
-
-    /**
-     * process : F/f : fill path using non zero winding rule.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If there is an error during the processing.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-
-        try 
-        {
-            ///dwilson refactoring
-            PageDrawer drawer = (PageDrawer)context;
-            drawer.fillPath(GeneralPath.WIND_NON_ZERO);
-        } 
-        catch (Exception e) 
-        {
-            log.warn(e, e);
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/Invoke.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/Invoke.java
deleted file mode 100644 (file)
index 01fc450..0000000
+++ /dev/null
@@ -1,136 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.AffineTransform;
-import java.awt.image.BufferedImage;
-import java.io.IOException;
-import java.util.List;
-import java.util.Map;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.cos.COSStream;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.pdmodel.PDPage;
-import org.apache.pdfbox.pdmodel.PDResources;
-import org.apache.pdfbox.pdmodel.graphics.PDGraphicsState;
-import org.apache.pdfbox.pdmodel.graphics.xobject.PDXObject;
-import org.apache.pdfbox.pdmodel.graphics.xobject.PDXObjectForm;
-import org.apache.pdfbox.pdmodel.graphics.xobject.PDXObjectImage;
-import org.apache.pdfbox.util.Matrix;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.4 $
- */
-public class Invoke extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(Invoke.class);
-
-    /**
-     * process : Do : Paint the specified XObject (section 4.7).
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If there is an error invoking the sub object.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        PageDrawer drawer = (PageDrawer)context;
-        PDPage page = drawer.getPage();
-        COSName objectName = (COSName)arguments.get( 0 );
-        Map xobjects = drawer.getResources().getXObjects();
-        PDXObject xobject = (PDXObject)xobjects.get( objectName.getName() );
-        if ( xobject == null )
-        {
-            log.warn("Can't find the XObject for '"+objectName.getName()+"'");
-        }
-        else if( xobject instanceof PDXObjectImage )
-        {
-            PDXObjectImage image = (PDXObjectImage)xobject;
-            try
-            {
-                image.setGraphicsState(drawer.getGraphicsState());
-                BufferedImage awtImage = image.getRGBImage();
-                if (awtImage == null) 
-                {
-                    log.warn("getRGBImage returned NULL");
-                    return;//TODO PKOCH
-                }
-                int imageWidth = awtImage.getWidth();
-                int imageHeight = awtImage.getHeight();
-                double pageHeight = drawer.getPageSize().getHeight();
-
-                log.debug("imageWidth: " + imageWidth + "\t\timageHeight: " + imageHeight);
-        
-                Matrix ctm = drawer.getGraphicsState().getCurrentTransformationMatrix();
-                float yScaling = ctm.getYScale();
-                float angle = (float)Math.acos(ctm.getValue(0, 0)/ctm.getXScale());
-                if (ctm.getValue(0, 1) < 0 && ctm.getValue(1, 0) > 0)
-                    angle = (-1)*angle;
-                ctm.setValue(2, 1, (float)(pageHeight - ctm.getYPosition() - Math.cos(angle)*yScaling));
-                ctm.setValue(2, 0, (float)(ctm.getXPosition() - Math.sin(angle)*yScaling));
-                // because of the moved 0,0-reference, we have to shear in the opposite direction
-                ctm.setValue(0, 1, (-1)*ctm.getValue(0, 1));
-                ctm.setValue(1, 0, (-1)*ctm.getValue(1, 0));
-                AffineTransform ctmAT = ctm.createAffineTransform();
-                ctmAT.scale(1f/imageWidth, 1f/imageHeight);
-                drawer.drawImage( awtImage, ctmAT ); 
-            }
-            catch( Exception e )
-            {
-                e.printStackTrace();
-                log.error(e, e);
-            }
-        }
-        else if(xobject instanceof PDXObjectForm)
-        {
-            // save the graphics state
-            context.getGraphicsStack().push( (PDGraphicsState)context.getGraphicsState().clone() );
-            
-            PDXObjectForm form = (PDXObjectForm)xobject;
-            COSStream invoke = (COSStream)form.getCOSObject();
-            PDResources pdResources = form.getResources();
-            if(pdResources == null)
-            {
-                pdResources = page.findResources();
-            }
-            // if there is an optional form matrix, we have to
-            // map the form space to the user space
-            Matrix matrix = form.getMatrix();
-            if (matrix != null) 
-            {
-                Matrix xobjectCTM = matrix.multiply( context.getGraphicsState().getCurrentTransformationMatrix());
-                context.getGraphicsState().setCurrentTransformationMatrix(xobjectCTM);
-            }
-            getContext().processSubStream( page, pdResources, invoke );
-            
-            // restore the graphics state
-            context.setGraphicsState( (PDGraphicsState)context.getGraphicsStack().pop() );
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/LineTo.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/LineTo.java
deleted file mode 100644 (file)
index 16a48a8..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-import java.awt.geom.Point2D;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class LineTo extends OperatorProcessor
-{
-
-
-    /**
-     * process : l : Append straight line segment to path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments)
-    {
-        PageDrawer drawer = (PageDrawer)context;
-
-        //append straight line segment from the current point to the point.
-        COSNumber x = (COSNumber)arguments.get( 0 );
-        COSNumber y = (COSNumber)arguments.get( 1 );
-
-        Point2D pos = drawer.transformedPoint(x.doubleValue(), y.doubleValue());
-        drawer.getLinePath().lineTo((float)pos.getX(), (float)pos.getY());
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/MoveTo.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/MoveTo.java
deleted file mode 100644 (file)
index 4d177c1..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.Point2D;
-import java.util.List;
-import java.io.IOException;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSNumber;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class MoveTo extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(MoveTo.class);
-
-    /**
-     * process : m : Begin new subpath.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If there is an error processing the operator.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        try
-        {
-            PageDrawer drawer = (PageDrawer)context;
-            COSNumber x = (COSNumber)arguments.get( 0 );
-            COSNumber y = (COSNumber)arguments.get( 1 );
-            Point2D pos = drawer.transformedPoint(x.doubleValue(), y.doubleValue());
-            drawer.getLinePath().moveTo((float)pos.getX(), (float)pos.getY());
-        }
-        catch (Exception exception)
-        {
-            log.warn( exception, exception);
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SHFill.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SHFill.java
deleted file mode 100644 (file)
index 6c1246a..0000000
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.awt.geom.GeneralPath;
-import java.io.IOException;
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.cos.COSName;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-/**
- * Implementation of sh operator for page drawer.
- *  See section 4.6.3 of the PDF 1.7 specification.
- *
- * @author <a href="mailto:Daniel.Wilson@BlackLocustSoftware.com">Daniel Wilson</a>
- * @version $Revision: 1.0 $
- */
-public class SHFill extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(SHFill.class);
-
-    /**
-     * process : sh : shade fill the path or clipping area.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException if there is an error during execution.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        try 
-        {
-            PageDrawer drawer = (PageDrawer)context;
-            drawer.SHFill((COSName)(arguments.get(0)));
-            
-        } 
-        catch (Exception e) 
-        {
-            log.warn(e, e);
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineCapStyle.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineCapStyle.java
deleted file mode 100644 (file)
index bee3b1b..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.awt.BasicStroke;
-import java.awt.Graphics2D;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:andreas@lehmi.de>Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetLineCapStyle extends org.apache.pdfbox.util.operator.SetLineCapStyle
-{
-
-    /**
-     * Set the line cap style.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        super.process( operator, arguments );
-        int lineCapStyle = context.getGraphicsState().getLineCap();
-        PageDrawer drawer = (PageDrawer)context;
-        BasicStroke stroke = (BasicStroke)drawer.getStroke();
-        if (stroke == null)
-        {
-            drawer.setStroke( new BasicStroke(1,lineCapStyle,BasicStroke.JOIN_MITER) );
-        }
-        else
-        {
-            drawer.setStroke( new BasicStroke(stroke.getLineWidth(), lineCapStyle, stroke.getLineJoin(), 
-                    stroke.getMiterLimit(), stroke.getDashArray(), stroke.getDashPhase()));
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineDashPattern.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineDashPattern.java
deleted file mode 100644 (file)
index 17d5d43..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.pdmodel.graphics.PDLineDashPattern;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.awt.BasicStroke;
-import java.awt.Graphics2D;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetLineDashPattern extends org.apache.pdfbox.util.operator.SetLineDashPattern
-{
-
-    /**
-     * Set the line dash pattern.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        super.process( operator, arguments );
-        PDLineDashPattern lineDashPattern = context.getGraphicsState().getLineDashPattern();
-        PageDrawer drawer = (PageDrawer)context;
-        BasicStroke stroke = (BasicStroke)drawer.getStroke();
-        if (stroke == null) 
-        {
-            if (lineDashPattern.isDashPatternEmpty()) 
-            {
-                drawer.setStroke(new BasicStroke(1, BasicStroke.CAP_SQUARE, BasicStroke.JOIN_MITER, 10.0f) );
-            }
-            else
-            {
-                drawer.setStroke(new BasicStroke(1, BasicStroke.CAP_SQUARE, BasicStroke.JOIN_MITER, 10.0f, 
-                        lineDashPattern.getCOSDashPattern().toFloatArray(), lineDashPattern.getPhaseStart()) );
-            }
-        }
-        else 
-        {
-            if (lineDashPattern.isDashPatternEmpty()) 
-            {
-                drawer.setStroke( new BasicStroke(stroke.getLineWidth(), stroke.getEndCap(), 
-                        stroke.getLineJoin(), stroke.getMiterLimit()) );
-            }
-            else
-            {
-                drawer.setStroke( new BasicStroke(stroke.getLineWidth(), stroke.getEndCap(), stroke.getLineJoin(), 
-                        stroke.getMiterLimit(), lineDashPattern.getCOSDashPattern().toFloatArray(), 
-                        lineDashPattern.getPhaseStart()) );
-            }
-        }
-    }
-    
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineJoinStyle.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineJoinStyle.java
deleted file mode 100644 (file)
index ad22605..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.awt.BasicStroke;
-import java.awt.Graphics2D;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:andreas@lehmi.de>Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetLineJoinStyle extends org.apache.pdfbox.util.operator.SetLineJoinStyle
-{
-
-    /**
-     * Set the line cap style.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        super.process( operator, arguments );
-        int lineJoinStyle = context.getGraphicsState().getLineJoin();
-        PageDrawer drawer = (PageDrawer)context;
-        BasicStroke stroke = (BasicStroke)drawer.getStroke();
-        if (stroke == null)
-        {
-            drawer.setStroke( new BasicStroke(1,BasicStroke.CAP_SQUARE,lineJoinStyle) );
-        }
-        else
-        {
-            drawer.setStroke( new BasicStroke(stroke.getLineWidth(), stroke.getEndCap(), lineJoinStyle,
-                    stroke.getMiterLimit(), stroke.getDashArray(), stroke.getDashPhase()) );
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineMiterLimit.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineMiterLimit.java
deleted file mode 100644 (file)
index a9e138e..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-import java.awt.BasicStroke;
-import java.awt.Graphics2D;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:andreas@lehmi.de">Andreas Lehmkühler</a>
- * @version $Revision: 1.0 $
- */
-public class SetLineMiterLimit extends org.apache.pdfbox.util.operator.SetLineMiterLimit
-{
-
-    /**
-     * Set the line dash pattern.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        super.process(operator, arguments);
-        float miterLimit = (float)context.getGraphicsState().getMiterLimit();
-        PageDrawer drawer = (PageDrawer)context;
-        BasicStroke stroke = (BasicStroke)drawer.getStroke();
-        if (stroke == null)
-        {
-            drawer.setStroke(new BasicStroke(1, BasicStroke.CAP_SQUARE, BasicStroke.JOIN_MITER, 
-                    miterLimit, null, 0.0f));
-        }
-        else
-        {
-            drawer.setStroke( new BasicStroke(stroke.getLineWidth(), stroke.getEndCap(), stroke.getLineJoin(), 
-                    miterLimit, null, 0.0f));
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineWidth.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/SetLineWidth.java
deleted file mode 100644 (file)
index a7444f9..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.PDFOperator;
-
-import java.awt.BasicStroke;
-import java.awt.Graphics2D;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.2 $
- */
-public class SetLineWidth extends org.apache.pdfbox.util.operator.SetLineWidth
-{
-
-    /**
-     * w Set line width.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        super.process( operator, arguments );
-        float lineWidth = (float)context.getGraphicsState().getLineWidth();
-        if (lineWidth == 0) 
-        {
-            lineWidth = 1;
-        }
-        PageDrawer drawer = (PageDrawer)context;
-        BasicStroke stroke = (BasicStroke)drawer.getStroke();
-        if (stroke == null)
-        {
-            drawer.setStroke( new BasicStroke( lineWidth ) );
-        }
-        else
-        {
-            drawer.setStroke( new BasicStroke(lineWidth, stroke.getEndCap(), stroke.getLineJoin(), 
-                    stroke.getMiterLimit(), stroke.getDashArray(), stroke.getDashPhase()) );
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/StrokePath.java b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/StrokePath.java
deleted file mode 100644 (file)
index 0baeaae..0000000
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.pdfbox.util.operator.pagedrawer;
-
-import java.util.List;
-
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.pdfbox.cos.COSBase;
-import org.apache.pdfbox.pdfviewer.PageDrawer;
-import org.apache.pdfbox.util.Matrix;
-import org.apache.pdfbox.util.PDFOperator;
-import org.apache.pdfbox.util.operator.OperatorProcessor;
-
-import java.awt.BasicStroke;
-import java.awt.Graphics2D;
-import java.io.IOException;
-
-/**
- * Implementation of content stream operator for page drawer.
- *
- * @author <a href="mailto:ben@benlitchfield.com">Ben Litchfield</a>
- * @version $Revision: 1.3 $
- */
-public class StrokePath extends OperatorProcessor
-{
-
-    /**
-     * Log instance.
-     */
-    private static final Log log = LogFactory.getLog(StrokePath.class);
-
-    /**
-     * S stroke the path.
-     * @param operator The operator that is being executed.
-     * @param arguments List
-     *
-     * @throws IOException If an error occurs while processing the font.
-     */
-    public void process(PDFOperator operator, List<COSBase> arguments) throws IOException
-    {
-        ///dwilson 3/19/07 refactor
-        try
-        {
-            PageDrawer drawer = (PageDrawer)context;
-    
-            float lineWidth = (float)context.getGraphicsState().getLineWidth();
-            Matrix ctm = context.getGraphicsState().getCurrentTransformationMatrix();
-            if ( ctm != null && ctm.getXScale() > 0) 
-            {
-                lineWidth = lineWidth * ctm.getXScale();
-            }
-            
-            BasicStroke stroke = (BasicStroke)drawer.getStroke();
-            if (stroke == null)
-            {
-                drawer.setStroke( new BasicStroke( lineWidth ) );
-            }
-            else
-            {
-                drawer.setStroke( new BasicStroke(lineWidth, stroke.getEndCap(), stroke.getLineJoin(), 
-                        stroke.getMiterLimit(), stroke.getDashArray(), stroke.getDashPhase()) );
-            }
-            drawer.strokePath();
-        }
-        catch (Exception exception)
-        {
-            log.warn(exception, exception);
-        }
-    }
-}
diff --git a/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/package.html b/fluidbook/tools/fwstk/src/org/apache/pdfbox/util/operator/pagedrawer/package.html
deleted file mode 100644 (file)
index b3774c2..0000000
+++ /dev/null
@@ -1,25 +0,0 @@
-<!--
- ! Licensed to the Apache Software Foundation (ASF) under one or more
- ! contributor license agreements.  See the NOTICE file distributed with
- ! this work for additional information regarding copyright ownership.
- ! The ASF licenses this file to You under the Apache License, Version 2.0
- ! (the "License"); you may not use this file except in compliance with
- ! the License.  You may obtain a copy of the License at
- !
- !      http://www.apache.org/licenses/LICENSE-2.0
- !
- ! Unless required by applicable law or agreed to in writing, software
- ! distributed under the License is distributed on an "AS IS" BASIS,
- ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- ! See the License for the specific language governing permissions and
- ! limitations under the License.
- !-->
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
-<html>
-<head>
-
-</head>
-<body>
-This package contains implementations of all of the PDF operators.
-</body>
-</html>