SVG Text to PDF Text using FOP 2.0.5rc

2003-01-07 Thread Eric Prevost
Does somebody knows how convert an SVG text to an PDF with text.

when i try it  using this fo:block my result is a good pdf but with line
art.


fo:block
fo:external-graphic src='testfont001.svg'/
/fo:block

my svg :
style type=text/css![CDATA[
text.t1 {font-family:'Arial',sans-serif;font-size:40;fill:#00}
]]/style
g id=Page_1
text class=t1tspan x=1588 y=149SOP/tspantspan x=1672 y
=149
/tspantspan x=1730 y=149:/tspantspan x=1741 y
=149
/tspantspan x=1815 y=149LX/tspantspan x=1864 y
=149-/tspan
/text
text class=t1tspan x=227 y=3282C:/tspan/text
text class=t1tspan x=445,501,561,621,677 y
=559TYVEK/tspan/text
/g
/svg


E.P.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Fop 0.20.5rc and external-graphic SVG problem

2002-12-19 Thread Eric Prevost
I am trying to integrate an SVG file with embedded text and when i try to
use it in FOP


SVG and XML-fo included in this mail.

I am working on W2K SP1, JDK 1.3

With FOP 0.20.5rc the result is :
[INFO] Using org.apache.xerces.parsers.SAXParser as SAX2 Parser
[INFO] FOP 0.20.5rc
[INFO] Using org.apache.xerces.parsers.SAXParser as SAX2 Parser
[INFO] building formatting object tree
[INFO] setting up fonts
[INFO] [1]
[ERROR] Could not load external SVG: null
[ERROR] Error while creating area : No ImageReader for this type of image
(file:/Temp/testfont001.svg)
[INFO] Parsing of document complete, stopping renderer

If i use FOP 0.20.4 with same files the result is 5000 lines of java error.

XSL-FO
?xml version=1.0 encoding=utf-8?
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
  !-- defines page layout --
  fo:layout-master-set
!-- layout for the first page --
fo:simple-page-master master-name=only
  page-height=297mm
  page-width=210mm
  margin-top=0mm
  margin-bottom=0mm
  margin-left=0mm
  margin-right=0mm
  fo:region-body
margin-top=10mm margin-bottom=10mm
column-count=1 column-gap=0.25in/
  fo:region-before extent=10mm/
  fo:region-after extent=10mm/
/fo:simple-page-master
  /fo:layout-master-set
  !-- actual layout --
  fo:page-sequence master-reference=only
fo:static-content flow-name=xsl-region-before
  fo:blockEric Prevost Demo/fo:block
  /fo:static-content
  fo:static-content flow-name=xsl-region-after
  fo:blockPage fo:page-number//fo:page-number-citation
ref-id=Terminator//fo:block
  /fo:static-content
fo:flow flow-name=xsl-region-body
  !-- Block 0 --
fo:block
fo:external-graphic src='file:/Temp/testfont001.svg'/
/fo:block
fo:block id=Terminator/fo:block
/fo:flow
  /fo:page-sequence
/fo:root




SVG file :
?xml version=1.0 standalone=no?
!DOCTYPE svg PUBLIC -//W3C//DTD SVG 20001102//EN
http://www.w3.org/TR/2000/CR-SVG-20001102/DTD/svg-20001102.dtd;
svg width=210.0mm height=297.0mm
  viewBox=0 0 2381 3368 preserveAspectRatio=xMinYMin kerning=0
xml:space=preserve
  xmlns=http://www.w3.org/2000/svg;
  xmlns:xlink=http://www.w3.org/1999/xlink;
  xmlns:svgmaker=http://www.svgmaker.com/svgns;
svgmaker:init width=210.0mm height=297.0mm viewBox=0 0 2381 3368
view=one2one
  crop=none cropWidth=193.0mm cropHeight=292.4mm cropBox=0 1 2188
3315/
titleMicrosoft Word - AD-1600.doc/title
desc
  Generated by SVGmaker Version 1.10.2A31.32
  Evaluation Version
  DEC-16-2002, 08:06
/desc

style type=text/css![CDATA[
path {fill-rule:nonzero; stroke-linecap:round; stroke-linejoin:round}
rect {stroke-linejoin:miter}
text.t1 {font-family:'Svg Arial';font-size:40;fill:#00}
text.t2 {font-family:'Svg Arial';font-size:24;fill:#00}
text.t3 {font-family:'Svg Times New Roman Bold';font-size:72;fill:
#00;font-weight:700}
text.t4 {font-family:'Svg Times New Roman Bold';font-size:46;fill:
#00;font-weight:700}
text.t5 {font-family:'Svg Times New Roman';font-size:44;fill:#00}
text.t6 {font-family:'Svg Times New Roman Bold';font-size:56;fill:
#00;font-weight:700}
text.t7 {font-family:'Svg Times New Roman';font-size:48;fill:#00}
text.t8 {font-family:'Svg Times New Roman Bold';font-size:48;fill:
#00;font-weight:700}
text.t9 {font-family:'Svg Times New Roman Bold';font-size:44;fill:
#00;font-weight:700}
text.t10 {font-family:'Svg Times New Roman';font-size:40;fill:#00}
text.t11 {font-family:'Svg Times New Roman Italic';font-size:32;fill:
#00;font-style:italic}
]]/style
defs
font horiz-adv-x=904
 font-face font-family=Svg Arial units-per-em=2048 panose-1=2 11 6 4
2 2 2 2 2 4 ascent=1854 descent=434 alphabetic=0/
 missing-glyph horiz-adv-x=1536 d=M 256,0 l 0,1280 1024,0 0,-1280
-1024,0 z m 32,32 l 960,0 0,1216 -960,0 0,-1216 z/
 glyph unicode=  horiz-adv-x=569 d=/
 glyph unicode=- horiz-adv-x=682 d=M 65,440 l 0,181 553,0 0,-181
-553,0 z/
 glyph unicode=. horiz-adv-x=569 d=M 186,0 l 0,205 205,0 0,-205
-205,0 z/
 glyph unicode=0 horiz-adv-x=1139 d=M 85,723 q 0,260 53.5,418.5
53.5,158.5 159,244.5 105.5,86 265.5,86 118,0 207,-47.5 89,-47.5 147,-137
58,-89.5 91,-218 33,-128.5 33,-346.5 0,-258 -53,-416.5 -53,-158.5 -158.5,
-245 -105.5,-86.5 -266.5,-86.5 -212,0 -333,152 -145,183 -145,596 z m 185,0
q 0,-361 84.5,-480.5 84.5,-119.5 208.5,-119.5 124,0 208.5,120 84.5,120
84.5,480 0,362 -84.5,481 -84.5,119 -210.5,119 -124,0 -198,-105 -93,-134
-93,-495 z/
 glyph unicode=1 horiz-adv-x=1139 d=M 763,0 l -180,0 0,1147 q -65,-62
-170.5,-124 -105.5,-62 -189.5,-93 l 0,174 q 151,71 264,172 113,101 160,196
l 116,0 0,-1472 z/
 glyph unicode=3 horiz-adv-x=1139 d=M 86,387 l 180,24 q 31,-153
105.5,-220.5 74.5,-67.5 181.5,-67.5 127,0 214.5,88 87.5,88 87.5,218 0,124
-81,204.5 -81,80.5 -206,80.5 -51,0 -127,-20 l 20,158 q 18,-2 29,-2 115,0
207,60 92,60 92,185 0,99 -67,164 -67,65 -173,65 -105,0 -175,-66 -70,-66
-90,-198 l -180,32 q 

Re: Error while loading a local image

2002-12-18 Thread Eric Prevost

Return Receipt
   
Your  Re: Error while loading a local image
document   
:  
   
was   Eric Prevost/Luxembourg/IBM  
received   
by:
   
at:   18/12/2002 13:54:11  
   





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Fop and external-graphic SVG problem

2002-12-17 Thread Eric Prevost

I am trying to integrate an SVG file with embedded text and when i try to
use it in FOP

I am working on W2K SP1, JDK 1.3, FOP 0.20.4rc ,Batik 1.1.1 or Batik
1.5

fop produce This result  :

[INFO] FOP 0.20.4rc
[INFO] building formatting object tree
[INFO] [1]
Exception in thread main java.lang.NoSuchMethodError
at org.apache.fop.image.analyser.SVGReader.loadImage(Unknown
Source)
at org.apache.fop.image.analyser.SVGReader.verifySignature(Unknown
Source)
at org.apache.fop.image.analyser.ImageReaderFactory.Make(Unknown
Source)
at org.apache.fop.image.FopImageFactory.Make(Unknown Source)
at org.apache.fop.fo.flow.ExternalGraphic.layout(Unknown Source)
at org.apache.fop.fo.flow.Block.layout(Unknown Source)
at org.apache.fop.fo.flow.Flow.layout(Unknown Source)
at org.apache.fop.fo.flow.Flow.layout(Unknown Source)
at org.apache.fop.fo.pagination.PageSequence.format(Unknown Source)
at org.apache.fop.apps.StreamRenderer.render(Unknown Source)
at org.apache.fop.fo.FOTreeBuilder.endElement(Unknown Source)
at
org.apache.xerces.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:559)
at
org.apache.xerces.impl.XMLNamespaceBinder.handleEndElement(XMLNamespaceBinder.java:853)
at
org.apache.xerces.impl.XMLNamespaceBinder.endElement(XMLNamespaceBinder.java:643)
at
org.apache.xerces.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:2978)
at
org.apache.xerces.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:918)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.handleEndElement(XMLDocumentFragmentScannerImpl.java:1145)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:988)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1446)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:333)
at
org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardParserConfiguration.java:529)
at
org.apache.xerces.parsers.StandardParserConfiguration.parse(StandardParserConfiguration.java:585)
at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:147)
at
org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1148)
at org.apache.fop.apps.Driver.render(Unknown Source)
at org.apache.fop.apps.CommandLineStarter.run(Unknown Source)
at org.apache.fop.apps.Fop.main(Unknown Source)

XSL-FO
?xml version=1.0 encoding=utf-8?
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
  !-- defines page layout --
  fo:layout-master-set
!-- layout for the first page --
fo:simple-page-master master-name=only
  page-height=297mm
  page-width=210mm
  margin-top=0mm
  margin-bottom=0mm
  margin-left=0mm
  margin-right=0mm
  fo:region-body
margin-top=10mm margin-bottom=10mm
column-count=1 column-gap=0.25in/
  fo:region-before extent=10mm/
  fo:region-after extent=10mm/
/fo:simple-page-master
  /fo:layout-master-set
  !-- actual layout --
  fo:page-sequence master-reference=only
fo:static-content flow-name=xsl-region-before
  fo:blockEric Prevost Demo/fo:block
  /fo:static-content
  fo:static-content flow-name=xsl-region-after
  fo:blockPage fo:page-number//fo:page-number-citation
ref-id=Terminator//fo:block
  /fo:static-content
fo:flow flow-name=xsl-region-body
  !-- Block 0 --
fo:block
fo:external-graphic src='testfont001.svg'/
/fo:block
fo:block id=Terminator/fo:block
/fo:flow
  /fo:page-sequence
/fo:root




SVG file :
?xml version=1.0 standalone=no?
!DOCTYPE svg PUBLIC -//W3C//DTD SVG 20001102//EN
http://www.w3.org/TR/2000/CR-SVG-20001102/DTD/svg-20001102.dtd;
svg width=210.0mm height=297.0mm
  viewBox=0 0 2381 3368 preserveAspectRatio=xMinYMin kerning=0
xml:space=preserve
  xmlns=http://www.w3.org/2000/svg;
  xmlns:xlink=http://www.w3.org/1999/xlink;
  xmlns:svgmaker=http://www.svgmaker.com/svgns;
svgmaker:init width=210.0mm height=297.0mm viewBox=0 0 2381 3368
view=one2one
  crop=none cropWidth=193.0mm cropHeight=292.4mm cropBox=0 1 2188
3315/
titleMicrosoft Word - AD-1600.doc/title
desc
  Generated by SVGmaker Version 1.10.2A31.32
  Evaluation Version
  DEC-16-2002, 08:06
/desc

style type=text/css![CDATA[
path {fill-rule:nonzero; stroke-linecap:round; stroke-linejoin:round}
rect {stroke-linejoin:miter}
text.t1 {font-family:'Svg Arial';font-size:40;fill:#00}
text.t2 {font-family:'Svg Arial';font-size:24;fill:#00}
text.t3 {font-family:'Svg Times New Roman Bold';font-size:72;fill:
#00;font-weight:700}
text.t4 {font-family:'Svg Times New Roman Bold';font-size:46;fill:
#00;font-weight:700}

Fop 0.20.5rc and external-graphic SVG problem

2002-12-17 Thread Eric Prevost
I am trying to integrate an SVG file with embedded text and when i try to
use it in FOP

I am working on W2K SP1, JDK 1.3

With FOP 0.20.5rc the result is :
[INFO] Using org.apache.xerces.parsers.SAXParser as SAX2 Parser
[INFO] FOP 0.20.5rc
[INFO] Using org.apache.xerces.parsers.SAXParser as SAX2 Parser
[INFO] building formatting object tree
[INFO] setting up fonts
[INFO] [1]
[ERROR] Could not load external SVG: null
[ERROR] Error while creating area : No ImageReader for this type of image
(file:/Temp/testfont001.svg)
[INFO] Parsing of document complete, stopping renderer

If i use FOP 0.20.4 with same files the result is 5000 lines of java error.

XSL-FO
?xml version=1.0 encoding=utf-8?
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
  !-- defines page layout --
  fo:layout-master-set
!-- layout for the first page --
fo:simple-page-master master-name=only
  page-height=297mm
  page-width=210mm
  margin-top=0mm
  margin-bottom=0mm
  margin-left=0mm
  margin-right=0mm
  fo:region-body
margin-top=10mm margin-bottom=10mm
column-count=1 column-gap=0.25in/
  fo:region-before extent=10mm/
  fo:region-after extent=10mm/
/fo:simple-page-master
  /fo:layout-master-set
  !-- actual layout --
  fo:page-sequence master-reference=only
fo:static-content flow-name=xsl-region-before
  fo:blockEric Prevost Demo/fo:block
  /fo:static-content
  fo:static-content flow-name=xsl-region-after
  fo:blockPage fo:page-number//fo:page-number-citation
ref-id=Terminator//fo:block
  /fo:static-content
fo:flow flow-name=xsl-region-body
  !-- Block 0 --
fo:block
fo:external-graphic src='file:/Temp/testfont001.svg'/
/fo:block
fo:block id=Terminator/fo:block
/fo:flow
  /fo:page-sequence
/fo:root




SVG file :
?xml version=1.0 standalone=no?
!DOCTYPE svg PUBLIC -//W3C//DTD SVG 20001102//EN
http://www.w3.org/TR/2000/CR-SVG-20001102/DTD/svg-20001102.dtd;
svg width=210.0mm height=297.0mm
  viewBox=0 0 2381 3368 preserveAspectRatio=xMinYMin kerning=0
xml:space=preserve
  xmlns=http://www.w3.org/2000/svg;
  xmlns:xlink=http://www.w3.org/1999/xlink;
  xmlns:svgmaker=http://www.svgmaker.com/svgns;
svgmaker:init width=210.0mm height=297.0mm viewBox=0 0 2381 3368
view=one2one
  crop=none cropWidth=193.0mm cropHeight=292.4mm cropBox=0 1 2188
3315/
titleMicrosoft Word - AD-1600.doc/title
desc
  Generated by SVGmaker Version 1.10.2A31.32
  Evaluation Version
  DEC-16-2002, 08:06
/desc

style type=text/css![CDATA[
path {fill-rule:nonzero; stroke-linecap:round; stroke-linejoin:round}
rect {stroke-linejoin:miter}
text.t1 {font-family:'Svg Arial';font-size:40;fill:#00}
text.t2 {font-family:'Svg Arial';font-size:24;fill:#00}
text.t3 {font-family:'Svg Times New Roman Bold';font-size:72;fill:
#00;font-weight:700}
text.t4 {font-family:'Svg Times New Roman Bold';font-size:46;fill:
#00;font-weight:700}
text.t5 {font-family:'Svg Times New Roman';font-size:44;fill:#00}
text.t6 {font-family:'Svg Times New Roman Bold';font-size:56;fill:
#00;font-weight:700}
text.t7 {font-family:'Svg Times New Roman';font-size:48;fill:#00}
text.t8 {font-family:'Svg Times New Roman Bold';font-size:48;fill:
#00;font-weight:700}
text.t9 {font-family:'Svg Times New Roman Bold';font-size:44;fill:
#00;font-weight:700}
text.t10 {font-family:'Svg Times New Roman';font-size:40;fill:#00}
text.t11 {font-family:'Svg Times New Roman Italic';font-size:32;fill:
#00;font-style:italic}
]]/style
defs
font horiz-adv-x=904
 font-face font-family=Svg Arial units-per-em=2048 panose-1=2 11 6 4
2 2 2 2 2 4 ascent=1854 descent=434 alphabetic=0/
 missing-glyph horiz-adv-x=1536 d=M 256,0 l 0,1280 1024,0 0,-1280
-1024,0 z m 32,32 l 960,0 0,1216 -960,0 0,-1216 z/
 glyph unicode=  horiz-adv-x=569 d=/
 glyph unicode=- horiz-adv-x=682 d=M 65,440 l 0,181 553,0 0,-181
-553,0 z/
 glyph unicode=. horiz-adv-x=569 d=M 186,0 l 0,205 205,0 0,-205
-205,0 z/
 glyph unicode=0 horiz-adv-x=1139 d=M 85,723 q 0,260 53.5,418.5
53.5,158.5 159,244.5 105.5,86 265.5,86 118,0 207,-47.5 89,-47.5 147,-137
58,-89.5 91,-218 33,-128.5 33,-346.5 0,-258 -53,-416.5 -53,-158.5 -158.5,
-245 -105.5,-86.5 -266.5,-86.5 -212,0 -333,152 -145,183 -145,596 z m 185,0
q 0,-361 84.5,-480.5 84.5,-119.5 208.5,-119.5 124,0 208.5,120 84.5,120
84.5,480 0,362 -84.5,481 -84.5,119 -210.5,119 -124,0 -198,-105 -93,-134
-93,-495 z/
 glyph unicode=1 horiz-adv-x=1139 d=M 763,0 l -180,0 0,1147 q -65,-62
-170.5,-124 -105.5,-62 -189.5,-93 l 0,174 q 151,71 264,172 113,101 160,196
l 116,0 0,-1472 z/
 glyph unicode=3 horiz-adv-x=1139 d=M 86,387 l 180,24 q 31,-153
105.5,-220.5 74.5,-67.5 181.5,-67.5 127,0 214.5,88 87.5,88 87.5,218 0,124
-81,204.5 -81,80.5 -206,80.5 -51,0 -127,-20 l 20,158 q 18,-2 29,-2 115,0
207,60 92,60 92,185 0,99 -67,164 -67,65 -173,65 -105,0 -175,-66 -70,-66
-90,-198 l -180,32 q 33,181 150,280.5 117,99.5 291,99.5 120,0