Re: Using arial ttf font

2006-09-19 Thread Jeremias Maerki
Right, Pascal, the Java2D-based renderers (like -awt) use a different
font subsystem that PDF output. Furthermore, FOP 0.92beta does not
support custom fonts like Arial. You'll have to download FOP Trunk (from
the Subversion repository) where this is fixed.

On 19.09.2006 10:30:10 Pascal Sancho wrote:
> > -Original Message-
> > From: kamischa [mailto:[EMAIL PROTECTED] 
> > Sent: Tuesday, September 19, 2006 9:55 AM
> > 
> > Hello,
> > i am using fop-0.92beta on a winxp system from commandline.
> > I want to use arial.ttf font in a document and convert to pdf.
> > 
> > I read the documentation and did the following steps.
> > 
> > - Creating the metric xml file from the arial.ttf file.
> > OK no erros, arial.xml  and arial.ttf files exists in 
> > directory c:\fop-0.92beta\
> > 
> > - Editing the userconfig.xml file in directory 
> > c:\fop-0.92beta\ c:\fop-0.92beta\
> > 
> >> weight="normal"/>  
> > 
> > -In my c:\fop-0.92beta\test.xsl file I use the font  > font-size="18pt" 
> >  font-family="Arial"
> >  font-style="normal"
> >  font-weight="normal"> 
> >   
> > 
> > 
> > -Start from commandline with
> > c:\fop-0.92beta\fop -c userconfig.xml -xml test.xml -xsl 
> > test.xsl -awt I always get the error message : Warning font 
> ---
> 
> Hi, in the config file, you have to define fonts set for each renderer
> (see [1]).
> AFAIK, in case of AWT renderer, I think you cannot use alternate fonts
> (but I 'm not sure)
> I guess you have set font config for the PDF renderer, check your config
> file.
> You can try your command with PDF renderer, that should work
> 
> Pascal
> 
> > 'Arial,normal,400' not found
> > 
> > I cant find an error please help.
> > Without the arial font there is no error.
> > Perhaps somebody can give me an complete working example.
> 
> [1] http://xmlgraphics.apache.org/fop/0.92/configuration.html#renderers


Jeremias Maerki


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



Re: Help needed in converting XML to Tiff

2006-09-19 Thread Jeremias Maerki
Important to note is that this only works on FOP 0.92beta or later!

If you want to try from the command-line:
fop -fo myfile.fo -tiff myfile.tiff

On 19.09.2006 10:02:54 Richard S wrote:
> can any one give sample code for converting xml or xsl or pdf to tiff 
> file. I am new to this. experts can u help me in providing with sample codes
> 
> 
> Oliver Hernàndez Valls wrote:
> 
> > You can use this to instantiate the FOP object:
> >
> > Fop fop = fopFactory.newFop(MimeConstants.MIME_TIFF, userAgent, mtiff);
> >
> >
> > where userAgent is a FOUserAgent instance that you can use to 
> > configure your tiff and mtiff is the OutputStream where you want the 
> > image to be generated.
> >
> > For further configuration (different image compressions) currently 
> > there's a developement on the trunk version of FOP and 
> > xmlgraphics-commons. That I think will be available soon.
> >
> > Salut!
> >
> > En/na Richard S ha escrit:
> >
> >> I need to convert a XML or XSL file to tiff format. Is there any 
> >> direct or indirect ways to do that.

Jeremias Maerki


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



Re: Looking for advice on "positioning" of fo:instream-foreign-object and fo:external-graphic

2006-09-19 Thread Jeremias Maerki

On 18.09.2006 17:48:46 Peter wrote:
> Gentlepeople,
> 
> I am trying to get rid of line-leading (not sure this is the correct term
> actually) when adding an instream-foreign-object or external-graphic to a
> block
> 
> As an example
> 
> 
>
>  
> style="stroke:rgb(0,0,0);stroke-width:1"/> 
>
>  
>
> 
>  
> 
> In the result (pdf using fop 0.92) the instream object (with a red
> background) is not positioned at the top but rather at a position which
> seems to (indirectly?) depend on the font-size.
> 
> One suggestion to eliminate this region is to set the line-height to 0 (see
> http://www.renderx.net/lists/xep-support/2607.html)
> 
> That does however not seem to work with FOP. The area between the top of the
> red box and the top of the page is gone, but the line is no longer
> positioned correctly, but shifted vertically.

I've seen this, too, but haven't had the time to investigate, yet. I'm
actually not 100% sure that the suggestion from RenderX is correct but
it probably is. Maybe Manuel can shed some light to this? He's our
line-building specialist. :-) I'm not solid in this area at the moment.

> If I set font-size to 0 and do not explicitly set line-height it seems to
> work with FOP.

Yep, that's our current work-around.

> So I guess I have two questions
> 
> 1) What is the advised way to eliminate this "line-leading" area (the
> approach above seems not very elegant)? 

For the moment, font-size="0pt". :-)

> 2) Is the suggestion made on the XEP list wrong and/or is there a problem in
> FOP and/or is this one of the implementation dependant areas of FO?

Manuel, do you know?

> Any guidance, as always, extremely appreciated.



Jeremias Maerki


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



Re: Font names...

2006-09-19 Thread Jeremias Maerki

On 18.09.2006 17:05:09 Luis Ferro wrote:
> 
> 
> Jeremias Maerki-2 wrote:
> > 
> > In that case we cannot use the original font
> > name because we don't embed the full font.
> 
> 2 questions then...
> 
> a) What happens if with a partial embed font it's used the same name as the
> original font name?

I don't know. We're just following the PDF specification:
"For a font subset, the PostScript name of the font—the value of the
font’s BaseFont entry and the font descriptor’s FontName entry—begins
with a tag followed by a plus sign (+). The tag consists of exactly six
uppercase letters; the choice of letters is arbitrary, but different
subsets in the same PDF file must have different tags. For example,
EOODIA+Poetica is the name of a subset of Poetica®, a Type 1 font."

> b) What happens if with a full embed font (with use of -ansi when building
> the metrics) it's used the same name as the original font name?
> 
> The questions have some significance, because the PDF file that resulted
> from fop was edited with Acrobat pro 6 (which "unembeds" the font and allows
> the edit to continue, showing a warning regarding this) and when it was
> tryed to export to ps, acrobat just refused to work because the font's didnt
> match (there was a diference between the names like "Arial,light" in the
> PDF, when the true font name is "Arial-light").
> 
> This little diference had no side-effects on the PDF, but forfeited the use
> of the PDF for anything. The PDF restarted to work well after we grabed a
> font editor and changed in the internal properties of the font the "-" for a
> ",".

Well, it could be that FOP does something wrong here. We'd have to
investigate that closely. Not sure when I'd have time for this. Do you
have time?

> Mayhappen the reasons for changing the font names when working with
> full/partial embed fonts aren't relevant anymore...
> 
> Would like to take the oportunity to suggest that a switch like "-fullembed"
> (or something like that) be used instead of the "-ansi", as a
> "clarification" of what the switch do.

Suggestion noted but someone actually has to implement it. Not sure who
that will be.

> Cheers,
> LF
> 
> P.S.- get rid of the font metrics would just be perfect. Also perfect would
> be to note in the config file how one wants the font to be placed on the pdf
> (partial embed, full embed or reference only).

That's in the works. Date? Unknown. Chances rising in the near future. I
have some insider info about someone who'll have more time to work on
FOP (not me). ;-)


Jeremias Maerki


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



Re: Font names...

2006-09-19 Thread Jeremias Maerki
Yes, this way the whole font is embedded but you only have access to the
WinAnsi subset of characters.

On 18.09.2006 12:28:40 Luis Ferro wrote:
> 
> One of the things that appeared from the properties of the document is the
> "actual" font values.
> 
> The config i used is:
>  kerning="yes" 
>   embed-url="D:\sites\mapaterapeutico\fonts\SWZ721l.TTF">
>   
> 
> 
> And i created the font metrics with the following class call (a short fused
> version based on the fop.bat):
> 
> org.apache.fop.fonts.apps.TTFReader -enc ansi %FOP_CMD_LINE_ARGS%
> 
> With those parameters, i assume that the "full" font is embedded... as it is
> looselly refered in the import font documentation of fop...
> 
> The actual font parameters aren't setup in the PDF. Mayhappen with the
> addition of those "actual" font file, pointing the url file, the PDF could
> be editable...
> 
> Just a tought...
> 
> Cheers,
> LF
> 
> 
> 
> 
> 
> Jeremias Maerki-2 wrote:
> > 
> > I assume the problem comes from FOP's embedding only a subset of the
> > TrueType font in the PDF. In that case we cannot use the original font
> > name because we don't embed the full font. If you have to be able to
> > edit the PDF you'd need to embed the full font in which case we could
> > use the original name. FOP currently doesn't support that, though.
> > 
> > On 17.09.2006 22:51:41 Luis Ferro wrote:
> >> 
> >> The test is simple...
> >> 
> >> Prepare a font (tested with TTF fonts) for importing, one that has some
> >> "attributes" like "light".
> >> 
> >> Make a document which uses that font and produce a PDF.
> >> 
> >> Edit the PDF with acrobat pro.
> >> 
> >> What will happen is that the name the font has isn't the same name as the
> >> embed font.
> >> 
> >> The render will work ok, but the edit will mean a "warning" of font to
> >> become "unembed". That isn't a problem, except that as the font name is
> >> wrong (the font name listed in the pdf doesn't match the font name in the
> >> TTF file, what will happen is that acrobat can't find it and allow the
> >> "reembed" of it).
> >> 
> >> If needed will post files that exemplify this effect (i'm not sure if
> >> this
> >> is a FOP problem yet - will do more tests next week).


Jeremias Maerki


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



Re: € Sign

2006-09-19 Thread Jeremias Maerki
In that case, you're using a font that doesn't contain the Euro
character.

Please run the file examples/fo/basic/fonts.fo from your FOP
installation through FOP. It demonstrates the use of the Euro character.
If fonts.fo works, you need to change the font in your other document.
If fonts.fo doesn't work, you have a very old PDF viewer and you need to
use a different font, too, preferably a newer TrueType font which is
sure to contain the Euro character. Please note that not all fonts
contains the Euro character.

On 19.09.2006 11:26:03 Christian Loock wrote:
> Hello,
> 
> i tried using €, or ₮ and both didn't work, i also tried using 
> ISO-8859-15 instead of ISO-8859-1 but then the PDF Generation fails with an 
> Error
> 
> [ERROR]ISO8859_15
> 
> UTF-8 didn't work too ;(
> 
> Any other ideas of how to display the €-Sign?
> 
> -Original Message-
> From: Pascal Sancho [mailto:[EMAIL PROTECTED] 
> Sent: Thursday, September 14, 2006 1:55 PM
> To: fop-users@xmlgraphics.apache.org
> Subject: RE: € Sign
> 
> > -Original Message-
> > From: Andreas Reuleaux [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, September 14, 2006 1:31 PM
> > To: fop-users@xmlgraphics.apache.org
> > Subject: Re: € Sign
> > 
> > On Thu, Sep 14, 2006 at 01:22:10PM +0200, Christian Loock wrote:
> > > Hello,
> > >  
> > > i have the problem that the € sign is not displayed in my PDF. I 
> > > Generate the PDF using FOP 0.20.5. THe Font is Arial and
> > the encoding
> > > iso-8859-1
> > >  
> > 
> > 
> > € is not in iso-8859-1, how about you try to you use utf-8 or 
> > iso-8859-15?
> > 
> > -Andreas
> 
> Hi,
> You can use character entity, witch is not encoding dependant:
> Euro symbol can be represented by either €, or ₮
> 
> That can be done with any Unicode character.
> 
> Pascal
>  



Jeremias Maerki


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



Re: Unicode Fonts!!!! (don't give up on us!)

2006-09-19 Thread Jeremias Maerki
Please wait a second before you give up and spread a wrong impression
that FOP isn't up to the task. The bits of information that were given
to you contained all the hints that were necessary to accomplish your
goal. But I can imagine it is difficult to get it all together. So let
me give you a step-by-step guide to a full Polish document with Apache
FOP:

1. Obtain a font that contains all the necessary characters.

PDF defines a set of 14 so-called base fonts (Helvetica, Times etc.)
which are expected to be available on every PDF-capable product, viewer
or producer. These fonts are defined as Type 1 fonts with a maximum of
255 distinctive glyphs. And this set does not include every character
you need for your Polish documents. That's the reason why Michael Bruns
cannot view your iText-generated PDF properly. Your Acrobat Reader maps
the Helvetica font to an Arial font which has all the necessary
characters, but Michael's system only supports the basic base 14 font
set as required by the PDF specification. So you can't be sure that your
PDF generated using iText can be viewed correctly on every system as you
depend on the fact that the viewer has a font with all the characters
available. That's why it's important to embed a font in the PDF that
contains all the necessary characters. You can make sure every PDF
viewer uses the right font that you want used. And this is best done
using a TrueType font.

A free set of TrueType fonts can be obtained from the DéjàVu project,
for example:
http://dejavu.sourceforge.net

2. Generate the XML font metrics file for each font you'd like to use.

This procedure is described in
http://xmlgraphics.apache.org/fop/0.92/fonts.html
or
http://xmlgraphics.apache.org/fop/0.20.5/fonts.html
depending on the FOP version you're using. I know this step is awkward,
but for the moment FOP still needs it. We hope that'll change soon.
There are efforts in that direction.

3. Configure the font in your FOP configuration file.

A minimal configuration file for FOP 0.92beta would look like this
(assuming you use DejaVuSans as a font):


  

  

  

  

  


4. Run FOP (with your configuration file).

On the command-line:
fop -c myconfig.xml -fo myfile.fo -pdf myfile.pdf

For embedding in Java, see the documentation.

As a proof that this actually works, please see the attached files.

BTW, I recommend you encode your XML files using UTF-8 so you have the
full Unicode spectrum available and don't have to reply on using
character entities. And yes, it works on a Mac.

On 19.09.2006 14:26:32 Paul Loy wrote:
> Hi all,
> 
> thank you for all your comments and help. I am still unable to get a 
> single character to come out in polish. I have, therefore, admitted 
> defeat and am going to ditch the old nasty code in favour of iText, a 
> free PDF generating library. It was so easy to get the characters to 
> display in the PDF using this:


> 
> and that's it! I've attached the PDF too.
> 
> I like the fact that FOP allows XSLT transformations into PDF, a very 
> powerful feature, but I can't do with it's pitiful unicode support. Make 
> it simple people! All we want to have to do is say: "this is iso-8859-2, 
> can you output the correct characters please" and for FOP to say "no 
> problem mate, if the font supports it"...
> 
> Alas, FOP is not for me at the moment. Perhaps when they sort the 
> unicode issues out it'll be worth coming back to. Good luck one and all 
> with your FOPing, I hope you manage where I have failed.




Jeremias Maerki


polish.fop.trunk.pdf
Description: Binary data


polish.fo
Description: Binary data
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

RE: xml to pdf (generic)

2006-09-19 Thread Rick Roen
To convert xml to pdf you need to have an xml file (the one below I assume)
PLUS an xslt file that will convert to XSL-FO and then you can use FOP to
convert the FO file into pdf.  You can also do this in one step with FOP -
xml + xslt -> xsl-fo = pdf output.

Now we still need your xslt file that you intend to use to convert your xml.

If you are by chance looking for someone to write an xslt transformation for
you - you've got the wrong guy here, but maybe someone else will help.

If you already have the xslt, send it so we can look at it.

Rick

-Original Message-
From: vijay [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, September 19, 2006 12:06 PM
To: fop-users@xmlgraphics.apache.org
Subject: RE: xml to pdf (generic)


sorry rick ,
 sorry rick ,  i sended you worng xml file .again i am sending my xml file .





  My Report Header 
  My Report
  My Report Footer 
 
090032ae80006f3b 
09/11/2006 05:41:26  
dm_DataDictionaryPublisher 
09/11/2006 05:41:28 AM 
   



 
090032ae80006f3e 
09/11/2006 06:10:57 
dm_DataDictionaryPublisher 
09/11/2006 06:10:58 AM 
   

 
090032ae80006f45 
09/11/2006 06:40:58
dm_DataDictionaryPublisher 
09/11/2006 06:40:59 AM 
   
  
   
090032ae80006f48 
09/11/2006 07:11:29  
dm_DataDictionaryPublisher 
09/11/2006 07:11:30 AM 
   
  
   
090032ae80006f4b 
09/11/2006 07:11:59 dm_GwmTask_Alert 
09/11/2006 07:11:59 AM 
   
   
  
090032ae80006f4f 
09/11/2006 07:41:29
dm_DataDictionaryPublisher 
09/11/2006 07:41:31 AM 
  
 
 
090032ae80006f52 
09/11/2006 08:05:30 dm_GwmTask_Alert 
09/11/2006 08:05:31 AM 
 
 
 
090032ae80006f56 
09/11/2006 08:10:30 
dm_DataDictionaryPublisher 
09/11/2006 08:10:31 AM 
 

 
090032ae80006f59 
09/11/2006 08:41:01
dm_DataDictionaryPublisher 
09/11/2006 08:41:02 AM 
 

 
090032ae80006f5c 
09/11/2006 09:00:32 dm_GwmTask_Alert 
09/11/2006 09:00:33 AM 
 

 
090032ae80006f5f 
080032ae8282 
09/11/2006 09:00:33 AM 
 

 
090032ae80006f60 
Contracts Client ReportMMDD 
09/11/2006 09:02:41 AM 
 

 
090032ae80006f62 
09/11/2006 09:11:02  
dm_DataDictionaryPublisher 
09/11/2006 09:11:04 AM 
 

 
090032ae80006f64 
DataDictionaryPublisher 
09/11/2006 09:11:04 AM 
 

 
670032ae8100 
CSEC Plugin 
06/15/2006 07:33:03 PM 
 

 


 
In previous mail  accidentally  tag was  included.

 i wrote a xsl file for generating the  pdf  .but that is not in proper way 
  I am generating pdf file from command prompt using   
   
   fop -xml pdf.xml  -xsl pdf.xsl -pdf pdf1.pdf  command 

   I am uploading  my  pdf.xsl(what i wrote for some other xml )  file. 
could you see it once please. 

Thanks 

   
Rick Roen wrote:
> 
> Vijay,
> 
> You will have to post a copy of your "coun.xslt" also.
> 
> With just the xml we cannot tell what you are trying to do to convert to
> XSL-FO 
> 
> Rick
> 
> -Original Message-
> From: vijay [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, September 19, 2006 7:38 AM
> To: fop-users@xmlgraphics.apache.org
> Subject: RE: xml to pdf (generic)
> 
> 
> Hi..
> Im hereby attaching a sample XML which im using for coversion to PDF and
> the
> desired PDF.
> 
> here is my xml file :- 
> 
> 
> 
> 
>   My Report Header 
>   My Report
>   My Report Footer 
>
> 090032ae80006f3b 
> 09/11/2006 05:41:26  
> dm_DataDictionaryPublisher 
> 09/11/2006 05:41:28 AM 
>
> 
> 
> 
>
> 090032ae80006f3e 
> 09/11/2006 06:10:57 
> dm_DataDictionaryPublisher 
> 09/11/2006 06:10:58 AM 
>
> 
>  
> 090032ae80006f45 
> 09/11/2006 06:40:58
> dm_DataDictionaryPublisher 
> 09/11/2006 06:40:59 AM 
>
>   
>
> 090032ae80006f48 
> 09/11/2006 07:11:29  
> dm_DataDictionaryPublisher 
> 09/11/2006 07:11:30 AM 
>
>   
>
> 090032ae80006f4b 
> 09/11/2006 07:11:59 dm_GwmTask_Alert 
> 09/11/2006 07:11:59 AM 
>
>
>   
> 090032ae80006f4f 
> 09/11/2006 07:41:29
> dm_DataDictionaryPublisher 
> 09/11/2006 07:41:31 AM 
>   
>  
>  
> 090032ae80006f52 
> 09/11/2006 08:05:30 dm_GwmTask_Alert 
> 09/11/2006 08:05:31 AM 
>  
>  
>  
> 090032ae80006f56 
> 09/11/2006 08:10:30 
> dm_DataDictionaryPublisher 
> 09/11/2006 08:10:31 AM 
>  
> 
>  
> 090032ae80006f59 
> 09/11/2006 08:41:01   

RE: xml to pdf (generic)

2006-09-19 Thread vijay

sorry rick ,
 sorry rick ,  i sended you worng xml file .again i am sending my xml file .  




  My Report Header 
  My Report
  My Report Footer 
 
090032ae80006f3b 
09/11/2006 05:41:26  
dm_DataDictionaryPublisher 
09/11/2006 05:41:28 AM 
   



 
090032ae80006f3e 
09/11/2006 06:10:57 
dm_DataDictionaryPublisher 
09/11/2006 06:10:58 AM 
   

 
090032ae80006f45 
09/11/2006 06:40:58
dm_DataDictionaryPublisher 
09/11/2006 06:40:59 AM 
   
  
   
090032ae80006f48 
09/11/2006 07:11:29  
dm_DataDictionaryPublisher 
09/11/2006 07:11:30 AM 
   
  
   
090032ae80006f4b 
09/11/2006 07:11:59 dm_GwmTask_Alert 
09/11/2006 07:11:59 AM 
   
   
  
090032ae80006f4f 
09/11/2006 07:41:29
dm_DataDictionaryPublisher 
09/11/2006 07:41:31 AM 
  
 
 
090032ae80006f52 
09/11/2006 08:05:30 dm_GwmTask_Alert 
09/11/2006 08:05:31 AM 
 
 
 
090032ae80006f56 
09/11/2006 08:10:30 
dm_DataDictionaryPublisher 
09/11/2006 08:10:31 AM 
 

 
090032ae80006f59 
09/11/2006 08:41:01
dm_DataDictionaryPublisher 
09/11/2006 08:41:02 AM 
 

 
090032ae80006f5c 
09/11/2006 09:00:32 dm_GwmTask_Alert 
09/11/2006 09:00:33 AM 
 

 
090032ae80006f5f 
080032ae8282 
09/11/2006 09:00:33 AM 
 

 
090032ae80006f60 
Contracts Client ReportMMDD 
09/11/2006 09:02:41 AM 
 

 
090032ae80006f62 
09/11/2006 09:11:02  
dm_DataDictionaryPublisher 
09/11/2006 09:11:04 AM 
 

 
090032ae80006f64 
DataDictionaryPublisher 
09/11/2006 09:11:04 AM 
 

 
670032ae8100 
CSEC Plugin 
06/15/2006 07:33:03 PM 
 

 


 
In previous mail  accidentally  tag was  included.

 i wrote a xsl file for generating the  pdf  .but that is not in proper way 
  I am generating pdf file from command prompt using   
   
   fop -xml pdf.xml  -xsl pdf.xsl -pdf pdf1.pdf  command 

   I am uploading  my  pdf.xsl(what i wrote for some other xml )  file. 
could you see it once please. 

Thanks 

   
Rick Roen wrote:
> 
> Vijay,
> 
> You will have to post a copy of your "coun.xslt" also.
> 
> With just the xml we cannot tell what you are trying to do to convert to
> XSL-FO 
> 
> Rick
> 
> -Original Message-
> From: vijay [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, September 19, 2006 7:38 AM
> To: fop-users@xmlgraphics.apache.org
> Subject: RE: xml to pdf (generic)
> 
> 
> Hi..
> Im hereby attaching a sample XML which im using for coversion to PDF and
> the
> desired PDF.
> 
> here is my xml file :- 
> 
> 
> 
> 
>   My Report Header 
>   My Report
>   My Report Footer 
>
> 090032ae80006f3b 
> 09/11/2006 05:41:26  
> dm_DataDictionaryPublisher 
> 09/11/2006 05:41:28 AM 
>
> 
> 
> 
>
> 090032ae80006f3e 
> 09/11/2006 06:10:57 
> dm_DataDictionaryPublisher 
> 09/11/2006 06:10:58 AM 
>
> 
>  
> 090032ae80006f45 
> 09/11/2006 06:40:58
> dm_DataDictionaryPublisher 
> 09/11/2006 06:40:59 AM 
>
>   
>
> 090032ae80006f48 
> 09/11/2006 07:11:29  
> dm_DataDictionaryPublisher 
> 09/11/2006 07:11:30 AM 
>
>   
>
> 090032ae80006f4b 
> 09/11/2006 07:11:59 dm_GwmTask_Alert 
> 09/11/2006 07:11:59 AM 
>
>
>   
> 090032ae80006f4f 
> 09/11/2006 07:41:29
> dm_DataDictionaryPublisher 
> 09/11/2006 07:41:31 AM 
>   
>  
>  
> 090032ae80006f52 
> 09/11/2006 08:05:30 dm_GwmTask_Alert 
> 09/11/2006 08:05:31 AM 
>  
>  
>  
> 090032ae80006f56 
> 09/11/2006 08:10:30 
> dm_DataDictionaryPublisher 
> 09/11/2006 08:10:31 AM 
>  
> 
>  
> 090032ae80006f59 
> 09/11/2006 08:41:01
> dm_DataDictionaryPublisher 
> 09/11/2006 08:41:02 AM 
>  
> 
>  
> 090032ae80006f5c 
> 09/11/2006 09:00:32 dm_GwmTask_Alert 
> 09/11/2006 09:00:33 AM 
>  
> 
>  
> 090032ae80006f5f 
> 080032ae8282 
> 09/11/2006 09:00:33 AM 
>  
> 
>  
> 090032ae80006f60 
> Contracts Client ReportMMDD 
> 09/11/2006 09:02:41 AM 
>  
> 
>  
> 090032ae80006f62 
> 09/11/2006 09:11:02  
> dm_DataDictionaryPublisher 
> 09/11/2006 09:11:04 AM 
>  
> 
>  
> 090032ae80006f64 
> DataDictionaryPublisher 
> 09/11/2006 09:11:04 AM 
>  
> 
>  
> 670032ae8100 
> CSEC Plugin 
> 

RE: xml to pdf (generic)

2006-09-19 Thread Rick Roen
Vijay,

You will have to post a copy of your "coun.xslt" also.

With just the xml we cannot tell what you are trying to do to convert to
XSL-FO 

Rick

-Original Message-
From: vijay [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, September 19, 2006 7:38 AM
To: fop-users@xmlgraphics.apache.org
Subject: RE: xml to pdf (generic)


Hi..
Im hereby attaching a sample XML which im using for coversion to PDF and the
desired PDF.

here is my xml file :- 




  My Report Header 
  My Report
  My Report Footer 
 
090032ae80006f3b 
09/11/2006 05:41:26  
dm_DataDictionaryPublisher 
09/11/2006 05:41:28 AM 
   



 
090032ae80006f3e 
09/11/2006 06:10:57 
dm_DataDictionaryPublisher 
09/11/2006 06:10:58 AM 
   

 
090032ae80006f45 
09/11/2006 06:40:58
dm_DataDictionaryPublisher 
09/11/2006 06:40:59 AM 
   
  
   
090032ae80006f48 
09/11/2006 07:11:29  
dm_DataDictionaryPublisher 
09/11/2006 07:11:30 AM 
   
  
   
090032ae80006f4b 
09/11/2006 07:11:59 dm_GwmTask_Alert 
09/11/2006 07:11:59 AM 
   
   
  
090032ae80006f4f 
09/11/2006 07:41:29
dm_DataDictionaryPublisher 
09/11/2006 07:41:31 AM 
  
 
 
090032ae80006f52 
09/11/2006 08:05:30 dm_GwmTask_Alert 
09/11/2006 08:05:31 AM 
 
 
 
090032ae80006f56 
09/11/2006 08:10:30 
dm_DataDictionaryPublisher 
09/11/2006 08:10:31 AM 
 

 
090032ae80006f59 
09/11/2006 08:41:01
dm_DataDictionaryPublisher 
09/11/2006 08:41:02 AM 
 

 
090032ae80006f5c 
09/11/2006 09:00:32 dm_GwmTask_Alert 
09/11/2006 09:00:33 AM 
 

 
090032ae80006f5f 
080032ae8282 
09/11/2006 09:00:33 AM 
 

 
090032ae80006f60 
Contracts Client ReportMMDD 
09/11/2006 09:02:41 AM 
 

 
090032ae80006f62 
09/11/2006 09:11:02  
dm_DataDictionaryPublisher 
09/11/2006 09:11:04 AM 
 

 
090032ae80006f64 
DataDictionaryPublisher 
09/11/2006 09:11:04 AM 
 

 
670032ae8100 
CSEC Plugin 
06/15/2006 07:33:03 PM 
 

 


Iam attaching the snapshot of the desired PDF.







Rick Roen wrote:
> 
> Vijay,
> 
> This seems more like a question about XML -> XSLT conversion.
> 
> A better group for that would be [EMAIL PROTECTED]
> 
> Perhaps if you posted your XSLT and brief example of your XML we, or
> xsl-lists could be of more help, or if I misunderstand a more complete
> explanation of your problem since I don't understand specifically what it
> is.
> 
> The general process is XML + XSLT -> XSL-FO -> PDF.  The XSL-FO -> PDF is
> quite easy and described in detail on the FOP web site.
> 
> Rick
> 
> -Original Message-
> From: vijay [mailto:[EMAIL PROTECTED] 
> Sent: Monday, September 18, 2006 7:11 AM
> To: fop-users@xmlgraphics.apache.org
> Subject: xml to pdf (generic)
> 
> 
> Hi all.
> This is a problem related to the conversion from XML to PDF.
> I have a system generated dynamic XML(where the child nodes may vary
> accordingly) that i need to convert to a PDF format file using xsl-fo. 
> In the required PDF the node values in the system XML should appear in
> proper row n column format.
> 
> for example if the XML contains 2 childs under the root node n  the child
> nodes further contain 4 childs so the table will b of the size: 2*4( i.e.
> 2
> rows n 4 cols)
> 
> 
> thanks in advance
> 
> 
> -- 
> View this message in context:
> http://www.nabble.com/xml-to-pdf-%28generic%29-tf2291175.html#a6363356
> Sent from the FOP - Users mailing list archive at Nabble.com.
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 
http://www.nabble.com/file/28/snapshot_pdf.doc snapshot_pdf.doc 
-- 
View this message in context:
http://www.nabble.com/xml-to-pdf-%28generic%29-tf2291175.html#a6388341
Sent from the FOP - Users mailing list archive at Nabble.com.


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



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



RE: xml to pdf (generic)

2006-09-19 Thread vijay

Hi..
Im hereby attaching a sample XML which im using for coversion to PDF and the
desired PDF.

here is my xml file :- 




  My Report Header 
  My Report
  My Report Footer 
 
090032ae80006f3b 
09/11/2006 05:41:26  
dm_DataDictionaryPublisher 
09/11/2006 05:41:28 AM 
   



 
090032ae80006f3e 
09/11/2006 06:10:57 
dm_DataDictionaryPublisher 
09/11/2006 06:10:58 AM 
   

 
090032ae80006f45 
09/11/2006 06:40:58
dm_DataDictionaryPublisher 
09/11/2006 06:40:59 AM 
   
  
   
090032ae80006f48 
09/11/2006 07:11:29  
dm_DataDictionaryPublisher 
09/11/2006 07:11:30 AM 
   
  
   
090032ae80006f4b 
09/11/2006 07:11:59 dm_GwmTask_Alert 
09/11/2006 07:11:59 AM 
   
   
  
090032ae80006f4f 
09/11/2006 07:41:29
dm_DataDictionaryPublisher 
09/11/2006 07:41:31 AM 
  
 
 
090032ae80006f52 
09/11/2006 08:05:30 dm_GwmTask_Alert 
09/11/2006 08:05:31 AM 
 
 
 
090032ae80006f56 
09/11/2006 08:10:30 
dm_DataDictionaryPublisher 
09/11/2006 08:10:31 AM 
 

 
090032ae80006f59 
09/11/2006 08:41:01
dm_DataDictionaryPublisher 
09/11/2006 08:41:02 AM 
 

 
090032ae80006f5c 
09/11/2006 09:00:32 dm_GwmTask_Alert 
09/11/2006 09:00:33 AM 
 

 
090032ae80006f5f 
080032ae8282 
09/11/2006 09:00:33 AM 
 

 
090032ae80006f60 
Contracts Client ReportMMDD 
09/11/2006 09:02:41 AM 
 

 
090032ae80006f62 
09/11/2006 09:11:02  
dm_DataDictionaryPublisher 
09/11/2006 09:11:04 AM 
 

 
090032ae80006f64 
DataDictionaryPublisher 
09/11/2006 09:11:04 AM 
 

 
670032ae8100 
CSEC Plugin 
06/15/2006 07:33:03 PM 
 

 


Iam attaching the snapshot of the desired PDF.







Rick Roen wrote:
> 
> Vijay,
> 
> This seems more like a question about XML -> XSLT conversion.
> 
> A better group for that would be [EMAIL PROTECTED]
> 
> Perhaps if you posted your XSLT and brief example of your XML we, or
> xsl-lists could be of more help, or if I misunderstand a more complete
> explanation of your problem since I don't understand specifically what it
> is.
> 
> The general process is XML + XSLT -> XSL-FO -> PDF.  The XSL-FO -> PDF is
> quite easy and described in detail on the FOP web site.
> 
> Rick
> 
> -Original Message-
> From: vijay [mailto:[EMAIL PROTECTED] 
> Sent: Monday, September 18, 2006 7:11 AM
> To: fop-users@xmlgraphics.apache.org
> Subject: xml to pdf (generic)
> 
> 
> Hi all.
> This is a problem related to the conversion from XML to PDF.
> I have a system generated dynamic XML(where the child nodes may vary
> accordingly) that i need to convert to a PDF format file using xsl-fo. 
> In the required PDF the node values in the system XML should appear in
> proper row n column format.
> 
> for example if the XML contains 2 childs under the root node n  the child
> nodes further contain 4 childs so the table will b of the size: 2*4( i.e.
> 2
> rows n 4 cols)
> 
> 
> thanks in advance
> 
> 
> -- 
> View this message in context:
> http://www.nabble.com/xml-to-pdf-%28generic%29-tf2291175.html#a6363356
> Sent from the FOP - Users mailing list archive at Nabble.com.
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 
http://www.nabble.com/file/28/snapshot_pdf.doc snapshot_pdf.doc 
-- 
View this message in context: 
http://www.nabble.com/xml-to-pdf-%28generic%29-tf2291175.html#a6388341
Sent from the FOP - Users mailing list archive at Nabble.com.


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



Re: Unicode Fonts!!!!

2006-09-19 Thread Paul Loy

Hi Michael,

could you take a sceenshot of the pdf so I can see what it looks like to 
you. That would be great.


Thanks,

Paul.

Michael Bruns wrote:

On 19.09.2006 14:26, Paul Loy wrote:
  
[...] 
It was so easy to get the characters to display in the PDF using this:

[...]



I don't want to spoil your joy about iText, but the PDF you attached
most likely only works correctly if the necessary "Helvetica" font is
present on the system on which the PDF is viewed.

I'm using SuSE 9.3 localized for Germany and the only Polish character I
can see in your document is the "l" with a small line in it. But as
there are some really awkward gaps in the document I suppose there ought
to be a lot more Polish characters.

So I guess if you want everybody to be able to read a document with
"strange" characters you should always attach the font to the document -
no matter if with FOP or any other library. That's at least my personal
experience.

Cheers,

Michael

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

  



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



Re: Unicode Fonts!!!!

2006-09-19 Thread Michael Bruns
On 19.09.2006 14:26, Paul Loy wrote:
> [...] 
> It was so easy to get the characters to display in the PDF using this:
> [...]

I don't want to spoil your joy about iText, but the PDF you attached
most likely only works correctly if the necessary "Helvetica" font is
present on the system on which the PDF is viewed.

I'm using SuSE 9.3 localized for Germany and the only Polish character I
can see in your document is the "l" with a small line in it. But as
there are some really awkward gaps in the document I suppose there ought
to be a lot more Polish characters.

So I guess if you want everybody to be able to read a document with
"strange" characters you should always attach the font to the document -
no matter if with FOP or any other library. That's at least my personal
experience.

Cheers,

Michael

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



Re: Unicode Fonts!!!!

2006-09-19 Thread Paul Loy




Hi all,

thank you for all your comments and help. I am still unable to get a
single character to come out in polish. I have, therefore, admitted
defeat and am going to ditch the old nasty code in favour of iText, a
free PDF generating library. It was so easy to get the characters to
display in the PDF using this:

package com.mydomain.pdf;

import java.io.FileOutputStream;
import java.io.IOException;
import java.sql.Connection;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.SQLException;

import com.lowagie.text.Document;
import com.lowagie.text.DocumentException;
import com.lowagie.text.Font;
import com.lowagie.text.Paragraph;
import com.lowagie.text.pdf.BaseFont;
import com.lowagie.text.pdf.PdfWriter;
import com.mydomain.sql.ConnectionFactory;

public class GenerateFulltextPDF {
    public static void main(String[] args) {
        String para = "";
        
        try {
            Connection con = ConnectionFactory.getConnection();
            PreparedStatement stmt = con.prepareStatement("SELECT
wstf_fulltext FROM wstf WHERE wstf_wlng_id=2 LIMIT 1");
            ResultSet res = stmt.executeQuery();
            
            if (res.last()) {
                para = res.getString(1);
            }
        } catch (SQLException e) {
            e.printStackTrace();
        }
        
        Document document = new Document();
        
        try {
            PdfWriter writer = PdfWriter.getInstance(document, new
FileOutputStream("NewPage.pdf"));
            
            BaseFont bf = BaseFont.createFont("Helvetica",
"iso-8859-2", true);
            Font f = new Font(bf, 12);
            
            document.open();
            document.add(new Paragraph(para, f));
        }
        catch(DocumentException de) {
            System.err.println(de.getMessage());
        }
        catch(IOException ioe) {
            System.err.println(ioe.getMessage());
        }
        document.close();
    }
}

and that's it! I've attached the PDF too.

I like the fact that FOP allows XSLT transformations into PDF, a very
powerful feature, but I can't do with it's pitiful unicode support.
Make it simple people! All we want to have to do is say: "this is
iso-8859-2, can you output the correct characters please" and for FOP
to say "no problem mate, if the font supports it"...

Alas, FOP is not for me at the moment. Perhaps when they sort the
unicode issues out it'll be worth coming back to. Good luck one and all
with your FOPing, I hope you manage where I have failed.

Paul.


Luis Ferro wrote:

  On my "unicode" wars... i've found one site of huge value: 

http://www.unicode.org/charts/charindex.html

This has ALL the unicode tables of ALL supported glyphs on ALL the standards
(specially important if you need just "that" glyph and you don't know it's
code).

I ended up consulting it regulary on my work.

Another page of some interest specially because of the use of Macs is: 

http://www.alanwood.net/demos/charsetdiffs.html

Which can enlight why some characters appear and some don't.

Cheers,
LF


Paul Loy wrote:
  
  
Oh, forgot to mention that I'm on a mac.

Thanks for the suggestions so far!

Paul.


Kai Mütz wrote:


  On windows systems you probably find Arial TTF files in windows fonts 
directory ("C:\Windows\Fonts" on my machine). You can use the 
TTFReader to create the metrics files as described at
 
http://xmlgraphics.apache.org/fop/trunk/fonts.html#truetype-metrics

-Original Message-
*From:*
[EMAIL PROTECTED]
   
[mailto:[EMAIL PROTECTED]]*On
Behalf Of *Paul Loy
*Sent:* Monday, September 18, 2006 6:29 PM
*To:* fop-users@xmlgraphics.apache.org
*Subject:* Re: Unicode Fonts

yeah but that still doesn't give me the fonts I need. Where are
the unicode PS fonts that I can use?

Kai Mütz wrote:
  
  
Did you check: http://xmlgraphics.apache.org/fop/trunk/fonts.html?

  


  -Original Message-
From: [EMAIL PROTECTED]
   
[mailto:[EMAIL PROTECTED]]On
Behalf Of Paul Loy
Sent: Monday, September 18, 2006 5:35 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Unicode Fonts


Do I have to translate all the foreign characters into a character
reference?

Paul Loy wrote:

  
  
Hi All,

I've inherited a poorly written system. Part of it uses FOP to
create
PDFs from an xslt. Now, we have international people on our site
which
is fine in HTML (xhtml1.1, utf-8) but when I try to use FOP I get
#
instead of any polish characters. I think this is due to the font
we
were using didn't have the unicode glyphs.

My question is, where are any unicode fonts for FOP. I just want
an
Arial or Helvetica type font, nothing fancy! Then, how do I use
this
font in my PDF? Here's a snippet of my xslt:


   
   
   
   
   
   

Re: € Sign

2006-09-19 Thread Manuel Mall
On Tuesday 19 September 2006 17:51, Pascal Sancho wrote:
> > -Original Message-
> > From: Christian Loock [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, September 19, 2006 11:26 AM
> >
> > i tried using €, or ₮ and both didn't work, i
> > also tried using ISO-8859-15 instead of ISO-8859-1 but then
> > the PDF Generation fails with an Error
> >
> > [ERROR]ISO8859_15
> >
> > UTF-8 didn't work too ;(
> >
> > Any other ideas of how to display the €-Sign?
> >
> > -Original Message-
> > From: Pascal Sancho [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, September 14, 2006 1:55 PM
> > To: fop-users@xmlgraphics.apache.org
> > Subject: RE: € Sign
> >
> > > -Original Message-
> > > From: Andreas Reuleaux [mailto:[EMAIL PROTECTED]
> > > Sent: Thursday, September 14, 2006 1:31 PM
> > > To: fop-users@xmlgraphics.apache.org
> > > Subject: Re: € Sign
> > >
> > > On Thu, Sep 14, 2006 at 01:22:10PM +0200, Christian Loock wrote:
> > > > Hello,
> > > >
> > > > i have the problem that the € sign is not displayed in my PDF.
> > > > I Generate the PDF using FOP 0.20.5. THe Font is Arial and
> > >
> > > the encoding
> > >
> > > > iso-8859-1
> > >
> > > € is not in iso-8859-1, how about you try to you use utf-8 or
> > > iso-8859-15?
> > >
> > > -Andreas
> >
> > Hi,
> > You can use character entity, witch is not encoding dependant:
> > Euro symbol can be represented by either €, or ₮
> >
> > That can be done with any Unicode character.

The following works fine for me with the latest FOP trunk version

FOP costs €0.00 which is 
NOTHING!

using a font metrics file generated from the Arial font from a standard 
English Windows 2000 installation.

Note that I used € and not ₮.
>
> Can you try it with a standard font (one of 'serif', 'sans-serif',
> 'monospace', 'Courier', 'Helvetica', or 'Times', not Arial)?
> - if that works: charset in your arial font don't embed desired
> glyphes - if that doesn't work: please provide a XSL-FO (not XSLT)
> that demonstrates your problem.
>
> FYI, encoding doesn't affect XML entities. Problem is elsewhere.
>
> Pascal

Manuel

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



RE: € Sign

2006-09-19 Thread Pascal Sancho
> -Original Message-
> From: Christian Loock [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, September 19, 2006 11:26 AM
> 
> i tried using €, or ₮ and both didn't work, i 
> also tried using ISO-8859-15 instead of ISO-8859-1 but then 
> the PDF Generation fails with an Error
> 
> [ERROR]ISO8859_15
> 
> UTF-8 didn't work too ;(
> 
> Any other ideas of how to display the €-Sign?
> 
> -Original Message-
> From: Pascal Sancho [mailto:[EMAIL PROTECTED]
> Sent: Thursday, September 14, 2006 1:55 PM
> To: fop-users@xmlgraphics.apache.org
> Subject: RE: € Sign
> 
> > -Original Message-
> > From: Andreas Reuleaux [mailto:[EMAIL PROTECTED]
> > Sent: Thursday, September 14, 2006 1:31 PM
> > To: fop-users@xmlgraphics.apache.org
> > Subject: Re: € Sign
> > 
> > On Thu, Sep 14, 2006 at 01:22:10PM +0200, Christian Loock wrote:
> > > Hello,
> > >  
> > > i have the problem that the € sign is not displayed in my PDF. I 
> > > Generate the PDF using FOP 0.20.5. THe Font is Arial and
> > the encoding
> > > iso-8859-1
> > 
> > € is not in iso-8859-1, how about you try to you use utf-8 or 
> > iso-8859-15?
> > 
> > -Andreas
> 
> Hi,
> You can use character entity, witch is not encoding dependant:
> Euro symbol can be represented by either €, or ₮
> 
> That can be done with any Unicode character.

Can you try it with a standard font (one of 'serif', 'sans-serif', 'monospace',
'Courier', 'Helvetica', or 'Times', not Arial)?
- if that works: charset in your arial font don't embed desired glyphes
- if that doesn't work: please provide a XSL-FO (not XSLT) that demonstrates 
your problem.

FYI, encoding doesn't affect XML entities. Problem is elsewhere.

Pascal


RE: € Sign

2006-09-19 Thread Christian Loock
Hello,

i tried using €, or ₮ and both didn't work, i also tried using 
ISO-8859-15 instead of ISO-8859-1 but then the PDF Generation fails with an 
Error

[ERROR]ISO8859_15

UTF-8 didn't work too ;(

Any other ideas of how to display the €-Sign?

-Original Message-
From: Pascal Sancho [mailto:[EMAIL PROTECTED] 
Sent: Thursday, September 14, 2006 1:55 PM
To: fop-users@xmlgraphics.apache.org
Subject: RE: € Sign

> -Original Message-
> From: Andreas Reuleaux [mailto:[EMAIL PROTECTED]
> Sent: Thursday, September 14, 2006 1:31 PM
> To: fop-users@xmlgraphics.apache.org
> Subject: Re: € Sign
> 
> On Thu, Sep 14, 2006 at 01:22:10PM +0200, Christian Loock wrote:
> > Hello,
> >  
> > i have the problem that the € sign is not displayed in my PDF. I 
> > Generate the PDF using FOP 0.20.5. THe Font is Arial and
> the encoding
> > iso-8859-1
> >  
> 
> 
> € is not in iso-8859-1, how about you try to you use utf-8 or 
> iso-8859-15?
> 
> -Andreas

Hi,
You can use character entity, witch is not encoding dependant:
Euro symbol can be represented by either €, or ₮

That can be done with any Unicode character.

Pascal
 


Re: Help needed in converting XML to Tiff

2006-09-19 Thread Oliver Hernàndez Valls
	public byte[] generateImage(InputStream xml, InputStream xslt) throws 
BuilderException

{

// OUTPUT STREAM CREATION
// we use a ByteArray because we don't want to generate any file
		ByteArrayOutputStream mtiff= new ByteArrayOutputStream(); // don't 
need to be closed


//don't need finally statement
		if(logger.isDebugEnabled()) logger.debug("<>>Memòria màxima 
fi:"+Runtime.getRuntime().maxMemory()/1048576d);
		if(logger.isDebugEnabled()) logger.debug(">>>Memòria lliure 
fi:"+Runtime.getRuntime().freeMemory()/1048576d);
		if(logger.isDebugEnabled()) logger.debug(">>>Memòria total 
fi:"+Runtime.getRuntime().totalMemory()/1048576d);

return mtiff.toByteArray();
}

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



RE: Using arial ttf font

2006-09-19 Thread Pascal Sancho
> -Original Message-
> From: kamischa [mailto:[EMAIL PROTECTED] 
> Sent: Tuesday, September 19, 2006 9:55 AM
> 
> Hello,
> i am using fop-0.92beta on a winxp system from commandline.
> I want to use arial.ttf font in a document and convert to pdf.
> 
> I read the documentation and did the following steps.
> 
> - Creating the metric xml file from the arial.ttf file.
> OK no erros, arial.xml  and arial.ttf files exists in 
> directory c:\fop-0.92beta\
> 
> - Editing the userconfig.xml file in directory 
> c:\fop-0.92beta\ c:\fop-0.92beta\
> 
>weight="normal"/>  
> 
> -In my c:\fop-0.92beta\test.xsl file I use the font  font-size="18pt" 
>  font-family="Arial"
>  font-style="normal"
>  font-weight="normal"> 
>   
> 
> 
> -Start from commandline with
> c:\fop-0.92beta\fop -c userconfig.xml -xml test.xml -xsl 
> test.xsl -awt I always get the error message : Warning font 
---

Hi, in the config file, you have to define fonts set for each renderer
(see [1]).
AFAIK, in case of AWT renderer, I think you cannot use alternate fonts
(but I 'm not sure)
I guess you have set font config for the PDF renderer, check your config
file.
You can try your command with PDF renderer, that should work

Pascal

> 'Arial,normal,400' not found
> 
> I cant find an error please help.
> Without the arial font there is no error.
> Perhaps somebody can give me an complete working example.

[1] http://xmlgraphics.apache.org/fop/0.92/configuration.html#renderers

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



Re: Using arial ttf font

2006-09-19 Thread Luis Ferro



kamischa wrote:
> 
> 
>   
>  
> 



  


Just use static file references to where your files are and prolly it will
work ok...as in my example...

Cheers,
LF
-- 
View this message in context: 
http://www.nabble.com/Using-arial-ttf-font-tf2297538.html#a6383911
Sent from the FOP - Users mailing list archive at Nabble.com.


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



Re: Help needed in converting XML to Tiff

2006-09-19 Thread Richard S
can any one give sample code for converting xml or xsl or pdf to tiff 
file. I am new to this. experts can u help me in providing with sample codes



Oliver Hernàndez Valls wrote:


You can use this to instantiate the FOP object:

Fop fop = fopFactory.newFop(MimeConstants.MIME_TIFF, userAgent, mtiff);


where userAgent is a FOUserAgent instance that you can use to 
configure your tiff and mtiff is the OutputStream where you want the 
image to be generated.


For further configuration (different image compressions) currently 
there's a developement on the trunk version of FOP and 
xmlgraphics-commons. That I think will be available soon.


Salut!

En/na Richard S ha escrit:

I need to convert a XML or XSL file to tiff format. Is there any 
direct or indirect ways to do that.


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




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





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



RE: Looking for advice on "positioning" of fo:instream-foreign-object and fo:external-graphic

2006-09-19 Thread Pascal Sancho
Hi,

> -Original Message-
> From: Peter [mailto:[EMAIL PROTECTED] 
> Sent: Monday, September 18, 2006 5:49 PM
> 
> Gentlepeople,
> 
> I am trying to get rid of line-leading (not sure this is the 
> correct term
> actually) when adding an instream-foreign-object or 
> external-graphic to a block
> 
> As an example
> 
> 
>
>  

Here is missing something like "

> style="stroke:rgb(0,0,0);stroke-width:1"/> 
>
>  
>
> 
>  
> 
> In the result (pdf using fop 0.92) the instream object (with a red
> background) is not positioned at the top but rather at a 
> position which seems to (indirectly?) depend on the font-size.

That is the normal behaviour.
b-p-d initial alignment depends on baseline position, witch depends on
both line-height and font-size properties.

> One suggestion to eliminate this region is to set the 
> line-height to 0 (see
> http://www.renderx.net/lists/xep-support/2607.html)

As written above, setting both line-height and font-size to 0 allows to
get desired alignment.
Since line-height defaults to font-size * 120%, you only need to
explicitely set font-size.

> That does however not seem to work with FOP. The area between 
> the top of the red box and the top of the page is gone, but 
> the line is no longer positioned correctly, but shifted vertically.
> 
> If I set font-size to 0 and do not explicitely set line-height 
> it seems to work with FOP.

That is expected behaviour, since line-height property defaults to 120%
(* font-size)

> So I guess I have two questions
> 
> 1) What is the advised way to eliminate this "line-leading" 
> area (the approach above seems not very elegant)? 

There is an example mixing text and graphics provided with FOP:
%fop_path%/examples/fo/basic/alignment.fo

> 2) Is the suggestion made on the XEP list wrong and/or is 
> there a problem in FOP and/or is this one of the 
> implementation dependant areas of FO?

I don't know about XEP list, but in this solution, font-size needs to be
changed.
Setting only line-height is not sufficient.

Pascal 


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



Using arial ttf font

2006-09-19 Thread kamischa

Hello,
i am using fop-0.92beta on a winxp system from commandline.
I want to use arial.ttf font in a document and convert to pdf.

I read the documentation and did the following steps.

- Creating the metric xml file from the arial.ttf file.
OK no erros, arial.xml  and arial.ttf files exists in directory
c:\fop-0.92beta\

- Editing the userconfig.xml file in directory c:\fop-0.92beta\
c:\fop-0.92beta\

  
 

-In my c:\fop-0.92beta\test.xsl file I use the font 
 
  


-Start from commandline with
c:\fop-0.92beta\fop -c userconfig.xml -xml test.xml -xsl test.xsl -awt
I always get the error message : Warning font 'Arial,normal,400' not found

I cant find an error please help.
Without the arial font there is no error.
Perhaps somebody can give me an complete working example.

Thanks a lot 
-- 
View this message in context: 
http://www.nabble.com/Using-arial-ttf-font-tf2297538.html#a6383513
Sent from the FOP - Users mailing list archive at Nabble.com.


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



Re: Help needed in converting XML to Tiff

2006-09-19 Thread Oliver Hernàndez Valls

You can use this to instantiate the FOP object:

Fop fop = fopFactory.newFop(MimeConstants.MIME_TIFF, userAgent, mtiff);


where userAgent is a FOUserAgent instance that you can use to configure 
your tiff and mtiff is the OutputStream where you want the image to be 
generated.


For further configuration (different image compressions) currently 
there's a developement on the trunk version of FOP and 
xmlgraphics-commons. That I think will be available soon.


Salut!

En/na Richard S ha escrit:
I need to convert a XML or XSL file to tiff format. Is there any direct 
or indirect ways to do that.


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




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



Help needed in converting XML to Tiff

2006-09-19 Thread Richard S
I need to convert a XML or XSL file to tiff format. Is there any direct 
or indirect ways to do that.


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