aboutsummaryrefslogtreecommitdiffstats
path: root/src/java/org/apache/fop/render/RenderingContext.java
diff options
context:
space:
mode:
authorJeremias Maerki <jeremias@apache.org>2008-08-05 15:31:00 +0000
committerJeremias Maerki <jeremias@apache.org>2008-08-05 15:31:00 +0000
commit83abc0b9b18852ffed4533d18f27e1b27df081b5 (patch)
tree7659b6be4f8f6183f8625a343caed2f7606f6909 /src/java/org/apache/fop/render/RenderingContext.java
parent46631569e9ccd7e2a179b0c6d1349fa7451ccc70 (diff)
downloadxmlgraphics-fop-83abc0b9b18852ffed4533d18f27e1b27df081b5.tar.gz
xmlgraphics-fop-83abc0b9b18852ffed4533d18f27e1b27df081b5.zip
First steps at unified image handling as proposed on http://wiki.apache.org/xmlgraphics-fop/ImageSupport/ImageHandler. This shall serve as a preview to motivate early feedback if anyone is interested.
Basic external-graphic support now available for PDF and SVG painters (for PDF: RenderedImage, SVG, JPEG, CCITT and Java2D, for SVG: embedded SVG and RFC2397 data URLs containing PNG and JPEG images) Change to IFPainter: added support for foreign attributes for the "image" tag. PDFContentGenerator introduced to hold the most important objects for PDF generation (unification for renderer and painter). Re-routed most image handling through the new image handling code (not fully done, yet, some code duplication remains). git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_AreaTreeNewDesign@682757 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/render/RenderingContext.java')
-rw-r--r--src/java/org/apache/fop/render/RenderingContext.java43
1 files changed, 43 insertions, 0 deletions
diff --git a/src/java/org/apache/fop/render/RenderingContext.java b/src/java/org/apache/fop/render/RenderingContext.java
new file mode 100644
index 000000000..a6f958328
--- /dev/null
+++ b/src/java/org/apache/fop/render/RenderingContext.java
@@ -0,0 +1,43 @@
+/*
+ * 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.
+ */
+
+/* $Id$ */
+
+package org.apache.fop.render;
+
+import org.apache.fop.apps.FOUserAgent;
+
+/**
+ * Implementations of this interface provide context information needed by supporting classes
+ * during specific tasks (like image rendering).
+ */
+public interface RenderingContext {
+
+ /**
+ * Returns the MIME type associated with the current output format.
+ * @return the MIME type (ex. application/pdf)
+ */
+ String getMimeType();
+
+ /**
+ * Returns the user agent. The user agent is used to access configuration and other information
+ * for the rendering process.
+ * @return the user agent
+ */
+ FOUserAgent getUserAgent();
+
+}