From: William Victor Mote Date: Mon, 21 Apr 2003 22:12:18 +0000 (+0000) Subject: Remove duplicated content in extensions.xml & dev/extensions.xml. X-Git-Tag: Root_Temp_KnuthStylePageBreaking~1586 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=1e687c3615726adb56924b7abe419f33a9e03b0f;p=xmlgraphics-fop.git Remove duplicated content in extensions.xml & dev/extensions.xml. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@196296 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/documentation/content/xdocs/dev/extensions.xml b/src/documentation/content/xdocs/dev/extensions.xml index a87a234f0..9c77e53a8 100644 --- a/src/documentation/content/xdocs/dev/extensions.xml +++ b/src/documentation/content/xdocs/dev/extensions.xml @@ -4,94 +4,43 @@
- Extensions to FOP + Adding an Extension to FOP
-
+
Overview +

For documentation of standard FOP extenstions, see the User FOP Extensions document.

If the default funtionality of FOP needs to be extended for -some reason then you can write an extensions. -

-

-There are three types of extensions possible. An output document -extensions such as the PDF bookmarks, an instream-foreign-object -extensions such as SVG and an fo extension that creates an -area in the area tree where normal xsl:fo is not possible. -

-
-
- Default Extensions -

-These extension are available by default. They are automatically loaded -and you only need to provide the correct namespace for your embedded -xml markup. -

-
- SVG -

-Please see the SVG page for more details. -

-

-The SVG extensions gets all the xml elements in the SVG namespace -and builds an SVG DOM with batik. The SVG DOM is then rendered -to the output format using a handler for the XML content of -the instream-foreign-object. +some reason then you can write an extension.

+

There are three types of extensions possible:

+
    +
  • An output document extension such as the PDF bookmarks
  • +
  • an instream-foreign-object extensions such as SVG
  • +
  • an fo extension that creates an area in the area tree where normal xsl:fo is not possible
  • +
-
- PDF Bookmarks -

-To use this standard FOP extension, you need to add a namespace entry for - http://xml.apache.org/fop/extensions on the root element.

- -

You can provide outlines inside the root object (but outside - any page-sequences or - other formatting objects). Here's an example of an outline entry:

- - - - - Running FOP - - - Prerequisites - - - -]]> -

It works similarly to a basic-link. There is also an external-destination - property, but it isn't supported currently. The documents - on the fop-site use this extension so you can see it in action. -

-
-
-
+
Adding Your Own

To add your own extension you need to do the following things.

-

-Write code that implements your extension functionality. -There are some examples in the contrib/ directory. -

-

-Create a jar file with your classes, it must also include the -following file "/META-INF/services/org.apache.fop.fo.ElementMapping". -In this file you need to put the fully qualified classname of -your element mappings class. This class must implement the -"org.apache.fop.fo.ElementMapping" interface. -

-

-Create your fo file with the extra xml data embedded in the file -with the correct name space. The pdf documents on the fob site -use this extension, see Examples -for more examples. -

-

-Put your jar file in the classpath and then run fop over the fo file. -

+
    +
  1. Write code that implements your extension functionality. The easiest place to +start is by looking at the code in org.apache.fop.extension, and by looking at the examples in the contrib directory.
  2. +
  3. Create a jar file with your classes, it must also include the following file +"/META-INF/services/org.apache.fop.fo.ElementMapping". In this file you need +to put the fully qualified classname of your element mappings class. This +class must implement the "org.apache.fop.fo.ElementMapping" interface.
  4. +
  5. Create your XSL-FO file with the extra XML data embedded in the file with the +correct name space. +The examples for SVG and pdfoutline.fo show how this can be done. +The pdf documents on the FOP site use this extension. +See also Examples for more examples.
  6. +
  7. Put your jar file in the classpath
  8. +
  9. Run FOP using your XSL-FO file as input.
  10. +
diff --git a/src/documentation/content/xdocs/extensions.xml b/src/documentation/content/xdocs/extensions.xml index 10a78eec0..a88f280a8 100644 --- a/src/documentation/content/xdocs/extensions.xml +++ b/src/documentation/content/xdocs/extensions.xml @@ -4,29 +4,21 @@
- Extensions + Standard FOP Extensions
-

-Sometimes it is desirable to have extensions to XSL-FO in order to support -some feature of the output format which isn't covered by the XSL-FO -specification. -

-
- Default Extensions -

-These extension are available by default. They are automatically loaded -and you only need to provide the correct namespace for your embedded -XML markup. -

-
+

By "extension", we mean any data that can be placed in the input XML document that is not addressed by the XSL-FO standard. +By having a mechanism for supporting extensions, FOP is able to add features that are not covered in the specification.

+

The extensions documented here are included with FOP, and are automatically available to you. If you wish to add an extension of your own to FOP, please see the Developers' Extension Page.

+ All extensions required the correct use of an appropriate namespace in your input document. +
SVG

Please see the SVG documentation for more details.

-
- Bookmarks +
+ PDF Bookmarks

To use this standard FOP extension, you need to add a namespace entry for http://xml.apache.org/fop/extensions on the root element. @@ -53,39 +45,12 @@ property, but it isn't supported currently. See the pdfoutline.fo file in examples/fo/basic for a more complete example.

-
+
Continued-label (for table-header/-footer

Please see examples/fo/basic/contlabel.fo

-
-
- Adding Your Own -

-To add your own extension you need to do the following things. -

-
    -
  1. -Write code that implements your extension functionality. The easiest place to -start is by looking at the code in org.apache.fop.extension. -
  2. -
  3. -Create a jar file with your classes, it must also include the following file -"/META-INF/services/org.apache.fop.fo.ElementMapping". In this file you need -to put the fully qualified classname of your element mappings class. This -class must implement the "org.apache.fop.fo.ElementMapping" interface. -
  4. -
  5. -Create your XSL-FO file with the extra XML data embedded in the file with the -correct name space. The examples for SVG and pdfoutline.fo show how this can -be done. -
  6. -
  7. -Put your jar file in the classpath and then run fop over the XSL-FO file. -
  8. -
-