Help for setting in FOP 0.20.5

2008-02-18 Thread Gregan, Miroslav
Hi all,
 
I know I should upgrade to the latest FOP, and it will be done for our
next tool's release (finally...).
(I have solved already this problem with FOP 0.94)
 
But until that next release... I have a font problem with the old
version.
 
So I'm using FOP 0.20.5 embedded in a java program, I have a
parameterized XSL sheet and an on the fly built XML document (stored in
DOM object).
 
The thing is that I need to print Unicode characters and I want to use a
specific font (DejaVuSans.ttf).
 
Knowing that the tool using FOP has an unknown location, I need to use a
relative path.
 
Can I make something like that: (set XSL parameter + define config
file)?
 
If so, how do I set the config.xml or/and the userconfig.xml and what
path should I put in that config file for the font?
 
 
 
This is the code I'm using, with a commented try to use something else
(starter + commandLineOptions) but I cannot set XSL parameters.
 
FileOutputStream outputStream = null;
try {
outputStream = new FileOutputStream(new
File(reportParameters.getOutputFileName()));
Driver driver = new Driver();
driver.setOutputStream(outputStream);
driver.setRenderer(Driver.RENDER_PDF);
driver.setLogger(logger);
 
sheetsMap = loadResources();
String sUrl = sheetsMap.get(reportParameters.getReportType());
URL urlpath = new URL(sUrl);
 
Transformer transformer =
TransformerFactory.newInstance().newTransformer(new StreamSource(new
File(urlpath.getPath(;
transformer = setTransformationParams(transformer,
reportParameters);
 
transformer.transform(new StreamSource(new
StringReader(rh.toString())), new
SAXResult(driver.getContentHandler()));
 
// TransformerFactory transformerFactory =
TransformerFactoryImpl.newInstance();
// transformerFactory.
// URL configUrl =
FileLocator.find(ReportsPlugin.getDefault().getBundle(), new
Path(ReportsPlugin.getReportsResourceString
(TRANSFORMATION_FOP_CONFIGFILE_LOCATION)), null); 
//
// String[] args = new String[]{-c,
FileLocator.resolve(configUrl).getFile(), -fo,
reportParameters.getOutputFileName()+.fo, -pdf,
reportParameters.getOutputFileName()};
// CommandLineOptions commandLineOptions = new
CommandLineOptions(args);
// Starter starter = commandLineOptions.getStarter();
// starter.run();
 
} catch (OutOfMemoryError outOfMemoryError) {
throw new ReportException(ReportException.OUT_OF_MEMORY_ERROR);
} finally {
if (outputStream != null) {
outputStream.close();
}
}
 
 
 
 
the config.xml content (metrics file are generated, correctly I suppose,
because I couldn't test it until now):
 
...
font metrics-file=font/DejaVuSans.xml
embed-file=font/DejaVuSans.ttf kerning=yes
font-triplet name=DejaVuSans style=normal
weight=normal /
/font
font metrics-file=font/DejaVuSans-Bold.xml
embed-file=font/DejaVuSans-Bold.ttf kerning=yes
font-triplet name=DejaVuSans style=normal weight=bold
/ 
/font
/fonts
 
 
Should I set other triplets style and weight and use a different name
when I need to use the bold font?
Where should be the font directory location if I set this path (see
config.xml content)?
 
 
Thanks for your help.
 
Cheers,
 
Miro


Help for setting in FOP 0.20.5

2008-02-18 Thread Gregan, Miroslav
Hi all,
 
I know I should upgrade to the latest FOP, and it will be done for our
next tool's release (finally...).
(I have solved already this problem with FOP 0.94)
 
But until that next release... I have a font problem with the old
version.
 
So I'm using FOP 0.20.5 embedded in a java program, I have a
parameterized XSL sheet and an on the fly built XML document (stored in
DOM object).
 
The thing is that I need to print Unicode characters and I want to use a
specific font (DejaVuSans.ttf).
 
Knowing that the tool using FOP has an unknown location, I need to use a
relative path.
 
Can I make something like that: (set XSL parameter + define config
file)?
 
If so, how do I set the config.xml or/and the userconfig.xml and what
path should I put in that config file for the font?
 
 
 
This is the code I'm using, with a commented try to use something else
(starter + commandLineOptions) but I cannot set XSL parameters.
 
FileOutputStream outputStream = null;
try {
outputStream = new FileOutputStream(new
File(reportParameters.getOutputFileName()));
Driver driver = new Driver();
driver.setOutputStream(outputStream);
driver.setRenderer(Driver.RENDER_PDF);
driver.setLogger(logger);
 
sheetsMap = loadResources();
String sUrl = sheetsMap.get(reportParameters.getReportType());
URL urlpath = new URL(sUrl);
 
Transformer transformer =
TransformerFactory.newInstance().newTransformer(new StreamSource(new
File(urlpath.getPath(;
transformer = setTransformationParams(transformer,
reportParameters);
 
transformer.transform(new StreamSource(new
StringReader(rh.toString())), new
SAXResult(driver.getContentHandler()));
 
// TransformerFactory transformerFactory =
TransformerFactoryImpl.newInstance();
// transformerFactory.
// URL configUrl =
FileLocator.find(ReportsPlugin.getDefault().getBundle(), new
Path(ReportsPlugin.getReportsResourceString
(TRANSFORMATION_FOP_CONFIGFILE_LOCATION)), null); 
//
// String[] args = new String[]{-c,
FileLocator.resolve(configUrl).getFile(), -fo,
reportParameters.getOutputFileName()+.fo, -pdf,
reportParameters.getOutputFileName()};
// CommandLineOptions commandLineOptions = new
CommandLineOptions(args);
// Starter starter = commandLineOptions.getStarter();
// starter.run();
 
} catch (OutOfMemoryError outOfMemoryError) {
throw new ReportException(ReportException.OUT_OF_MEMORY_ERROR);
} finally {
if (outputStream != null) {
outputStream.close();
}
}
 
 
 
 
the config.xml content (metrics file are generated, correctly I suppose,
because I couldn't test it until now):
 
...
font metrics-file=font/DejaVuSans.xml
embed-file=font/DejaVuSans.ttf kerning=yes
font-triplet name=DejaVuSans style=normal
weight=normal /
/font
font metrics-file=font/DejaVuSans-Bold.xml
embed-file=font/DejaVuSans-Bold.ttf kerning=yes
font-triplet name=DejaVuSans style=normal weight=bold
/ 
/font
/fonts
 
 
Should I set other triplets style and weight and use a different name
when I need to use the bold font?
Where should be the font directory location if I set this path (see
config.xml content)?
 
 
Thanks for your help.
 
Cheers,
 
Miro


Total page numbering example only for FOP 0.20.5

2007-11-14 Thread Gregan, Miroslav

Hi,

I found a document that is not up to date:

http://xmlgraphics.apache.org/fop/fo.html#fo-total-pages

A new example like the following should be added for FOP 0.94 (or
replace the current FOP 0.20.5)

class rendtest {

  public static void main(File fo, File pdf) {
OutputStream out = null;
try {
  FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
  out = new FileOutputStream(pdf);
  out = new BufferedOutputStream(out);
  Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF, foUserAgent,
out);
  TransformerFactory factory = TransformerFactory.newInstance();
  Transformer transformer = factory.newTransformer();
  Source src = new StreamSource(fo);
  Result res = new SAXResult(fop.getDefaultHandler());
  transformer.transform(src, res);

  // Read total page number and set the FO's page-count parameter
  transformer.setParameter(page-count,
Integer.toString(fop.getResults().getPageCount()));

  transformer.transform(src, res);
}
catch( Exception e) {
  e.printStackTrace();
}
finally {
  if (out != null) {
out.close();
  }
}
  }
}

Cheers,

Miro

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



how to set the logger?

2007-11-13 Thread Gregan, Miroslav
Hi,
 
I need to use FOP 0.94 embedded, in a big project composed by different 
Eclipse's plug-ins where 2 of them define an org.apache.commons.logging.Log 
library, which causes me the following error:
 
Invalid class loader hierarchy. You have more than one version of 
'org.apache.commons.logging.Log' visible, which is not allowed.

Is there a way how to set the logger manually like it was done before in FOP 
0.20.5 by setting the Driver object?

Thank you.

Miro

__

 

Ing. Miroslav Gregáň

Member of the Siemens IT Solutions and Services department
from the PSE SK SES TEC SK2 team

Program and System Engineering
Slovakia
Software Engineering Services
Technology Competences
Skupina 2 (Java and OpenSource Technologies)

Siemens Program and System Engineering s.r.o.
Dubravska cesta 4
845 37 Bratislava
Slovak Republic

 


How to code infinite page sequence loop?

2007-10-31 Thread Gregan, Miroslav
Hi all,

I'm trying to implement an infinite loop of page-sequences (expecting to spare 
memory to render big pdf) I tested my code with both fop 0.20.5 and 0.94, but 
no changes with memory consumption were visible. So I suppose (hope also) that 
I coded something wrong in the XSL file or in the XML one:

XSL file content:

?xml version=1.0 encoding=UTF-8?
xsl:stylesheet version=1.0 xmlns:xsl=http://www.w3.org/1999/XSL/Transform; 
xmlns:fo=http://www.w3.org/1999/XSL/Format;
  xsl:decimal-format decimal-separator=, grouping-separator= /

  xsl:param name=label-pageNumber select='page'/
  xsl:param name=pageheight select='29.7cm'/
  xsl:param name=pagewidth select='21cm'/
  xsl:param name=margin select='0.5cm'/

  xsl:template match=/
fo:root xmlns:fo=http://www.w3.org/1999/XSL/Format;
  fo:layout-master-set
fo:simple-page-master master-name=Portrait 
page-height={$pageheight} page-width={$pagewidth}  margin={$margin}
  fo:region-body margin-top=2.5cm margin-bottom=1cm/
  fo:region-before extent=2.5cm/
  fo:region-after extent=0.5cm/
  /fo:simple-page-master
  fo:simple-page-master master-name=Landscape 
page-height={$pageheight} page-width={$pagewidth} margin={$margin}
  fo:region-body margin-top=2.5cm margin-bottom=1cm/
  fo:region-before extent=2.5cm/
  fo:region-after extent=0.5cm/
/fo:simple-page-master
  /fo:layout-master-set

  xsl:apply-templates select=report/pagesequence/

/fo:root
  /xsl:template

  xsl:template match=report/pagesequence
fo:page-sequence 
master-reference={/report/pagesequence/orientation/@value}

  !--HEADER--
  fo:static-content flow-name=xsl-region-before
...
  /fo:static-content

  !--FOOTER--
  fo:static-content flow-name=xsl-region-after
...
  /fo:static-content

  !--BODY--
  fo:flow flow-name=xsl-region-body
  fo:table border-width=0.37px border-style=solid
  fo:table-column column-width=proportional-column-width(1)/
fo:table-column column-width=proportional-column-width(1)/
  xsl:apply-templates select=table/
/fo:table

!--fo:block id=theEnd/--

  /fo:flow
/fo:page-sequence
  /xsl:template



And then in the XML file I have a succession of the following block (I don't 
know how much of them)

?xml version=1.0 encoding=UTF-8?
  report
pagesequence
  orientation value=Portrait/
  header
  /header
  footer/
  table
  /table
/pagesequence
pagesequence
  orientation value=Portrait/
  header
  /header
  footer/
  table
  /table
/pagesequence

I was only using one page sequence until now and experiencing memory problems 
for average sized report (500 pages) with -Xmx500M already so I though that 
using multiple page sequences, would spare me some memory (I have a lot of fo 
element), but nothing, the report looks exactly the same! I expected a page 
break after each pagesequences in the PDF, page numbering problems and so on, 
but nothing like that happened. Good news afterwards, but on the other hand I 
still got OutOfMemoryException if I try to report more than 500 pages. Even 
disabling the total page numbering brings nothing.

So I hope that someone can tell me what I coded wrong.

Thank you for your help,

Miro


__
 
Ing. Miroslav Gregáň
Member of the Siemens IT Solutions and Services department
from the PSE SK SES TEC SK2 team
Program and System Engineering
Slovakia
Software Engineering Services
Technology Competences
Skupina 2 (Java and OpenSource Technologies)
Siemens Program and System Engineering s.r.o.
Dubravska cesta 4
845 37 Bratislava
Slovak Republic

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



[INFO] area contents overflows area in line

2007-04-11 Thread Gregan, Miroslav
Hello all,
 
I'm using fop 0.20.5 embedded in a java 5.0 program and sometimes I get
an infinite loop when using the hyphenate function.
 
The console prints [INFO] area contents overflows area in line.
 
Is it normal? Shouldn't it print the unhyphenated text anyway if the
function doesn't succeed?
 
Kind regards,
 
Miroslav Gregan
 
Siemens PSE-SK KB SK2
Dubravska cesta 4
84104 Bratislava
Slovakia
 


RE: Multi-line in a cell

2007-03-16 Thread Gregan, Miroslav
Thank you very much for your help.
 
Miroslav



From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Friday, March 16, 2007 1:54 PM
To: fop-users@xmlgraphics.apache.org
Subject: RE: Multi-line in a cell



Move the block outside of your loop.  The 'instream-foreign-object' is a
flow object so it will stay on the same line in the cell.  If you need a
new line, put the data in separate blocks. 

I did not check your code, but it looks OK. 

-Lou 

Gregan, Miroslav [EMAIL PROTECTED] wrote on 03/16/2007
08:35:22 AM:

 ok, I'm sorry I should have made a small expected result, here a 
 picture of it. 
 so this feature would be used only for the table-header. For some 
 cells I need to write vertically and for other horizontally. 
 As I wrote I do not know how many lines I will have write, so it can
 be between 1 and N. 
   
 so the solution I should use would be something like? 
   
   
 fo:table-cell border-width=0.37px language=en border-
 style=solid padding-left=3px padding-before=2.5px
padding-after=0.5px 
  xsl:for-each select=@values
   fo:block 
fo:instream-foreign-object 
 svg width=10 height=100 xmlns=http://www.w3.org/2000/svg; 
  g transform=translate(7,98) 
  g transform=rotate(-90) font-family=SansSerif 
   text x=0 y=0xsl:value-of select=@value//text 
  /g 
  /g 
 /svg 
/fo:instream-foreign-object 
   /fo:block  
  /xsl:for-each 
 /fo:table-cell 
 If this code should work, I have an other question, how are the 
 block inserted in a cell, is it predictable? 
 Because I though that the block would be put under the precedent 
 one, not on the precedents right. 
   
 Could someone confirm that the code up will put as many vertical 
 lines in a cell as I want to. (After It's my problem to define the 
 cell size of course) 
   
 and that the following will put as many horizontal lines in a cell 
 as I want to. 
   
  xsl:template match=header/column 
fo:table-cell border-width=0.37px language=en border-
 style=solid padding-left=3px padding-before=2.5px padding-
 after=0.5px 
  fo:block hyphenate=true font-size=10pt font-weight=bold 
xsl:for-each select=@values 
  fo:block 
xsl:value-of select=@value/ 
  /fo:block 
/xsl:for-each 
  /fo:block 
/fo:table-cell 
  /xsl:template 
   
   
 Thank you for your help 
   
 Miroslav 
 
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
 Sent: Friday, March 16, 2007 12:56 PM
 To: fop-users@xmlgraphics.apache.org
 Subject: Re: Multi-line in a cell

 
 Miroslav: 
 
 Not exactly sure of the layout you want, but did you try: 
 
 fo:table-cell border-width=0.37px language=en border-
 style=solid padding-left=3px padding-before=2.5px
padding-after=0.5px
 fo:block 
 fo:instream-foreign-object 
   svg width=10 height=100 xmlns=http://www.w3.org/2000/svg; 
 g transform=translate(7,98) 
 g transform=rotate(-90) font-family=SansSerif 
 text x=0 y=0xsl:value-of select=@value//text 
 /g 
 /g 
 /svg 
 /fo:instream-foreign-object 
 fo:instream-foreign-object !--SECOND LINE HERE-- 
 svg width=10 height=100 xmlns=http://www.w3.org/2000/svg; 
 g transform=translate(7,98) 
 g transform=rotate(-90) font-family=SansSerif 
 text x=0 y=0xsl:value-of select=@value//text 
 /g 
 /g 
 /svg 
 /fo:instream-foreign-object 
 /fo:block 
 /fo:table-cell 
 
 This will produce multiple vertical lines, running bottom to top, 
 left to right.  Example: 
 
 3 6 
 2 5 
 1 4 
 
 
 -Lou 
 
 
 Gregan, Miroslav [EMAIL PROTECTED] wrote on 03/15/2007
 11:51:51 AM:
 
  Hello all, 

  I need a little help from you. 
  I have to put manual line breaks in fo:table-cells. 
  So as I understood I need to insert each line in a separate block in
  the cell like in this XSL code, is it correct? 

  xsl:template match=header/column 
fo:table-cell border-width=0.37px language=en
border-style=solid
  padding-left=3px padding-before=2.5px padding-after=0.5px 
  fo:block hyphenate=true font-size=10pt font-weight=bold 
xsl:for-each select=@values 
  fo:block 
xsl:value-of select=@value/ 
  /fo:block 
/xsl:for-each 
  /fo:block 
/fo:table-cell 
  /xsl:template 

  But I need to implement this feature also for text written 
  vertically, so using SVG, 
  knowing that I use the same structure values containing 1 to N 
  value to stores the datas, how should I modify this? 

  xsl:template match=header/column 
fo:table-cell border-width=0.37px language=en
border-style=solid
  padding-left=3px padding-before=2.5px padding-after=0.5px 
  fo:block 
fo:instream-foreign-object 
  svg width=10 height=100
xmlns=http://www.w3.org/2000/svg; 
g transform=translate(7,98) 
g transform=rotate(-90) font-family=SansSerif 
  text x=0 y=0xsl:value-of select=@value//text

/g 
/g 
  /svg 
/fo:instream-foreign-object 
  /fo:block

RE: XSL - NewLine

2007-02-13 Thread Gregan, Miroslav
Thanks you for your answers

Actually I afraid I did not ask my question clearly enough.
The @value which is the content of an XML File's element which contains
a String.
This String has to be formatted (a little bit if possible :-) ) with new
lines.
So that the text:

Mister TNewLineCharHannibal SmithNewLineCharLooping

Where NewLineChar should be the expected character

After rendering FOP will look like in PDF format to:

Mister T
Hannibal Smith
Looping


Is it possible? Or should I find a way to use multiple blocks?

Thank you.

Miroslav




-Original Message-
From: Abel Braaksma [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, February 13, 2007 10:14 AM
To: fop-users@xmlgraphics.apache.org
Subject: Re: XSL - NewLine

Just use:

xsl:text#13;#10;/xsl:text
or
xsl:text#xD;#xA;/xsl:text

You can also add an entity to your doctype if you tend to use this kind 
of newlines more often:
!ENTITY newline #38;#x0D;#38;#x0A; 

and use it as follows:
xsl:textnewline;/xsl:text

which will be rendered as a \r\n by the serializer. Of course, you could

also use an xsl:variable to do the same.

Why do you want a \r *and* a \n? Because if you output XML (which you 
do: XSL-FO) the serializer will make sure that all \r\n will become \n. 
Which means that

xsl:text#xD;#xA;/xsl:text

is semantically equivalent with:
xsl:text#xA;/xsl:text

which means that the newline entity definition will do exactly the same 
when defined thus:
!ENTITY newline #38;#x0A; 

(not so when you output as text, but that is another story)

If you *have* to have both the \r and the \n in the serialized output (I

have no idea why, I think you don't) then your only bet is XSLT 2.0 
which allows you to put in late-serialization replacements with 
xsl:character-map.

Cheers,
-- Abel Braaksma


Gregan, Miroslav wrote:
 Hello all,
  
 I need to put manually new line in a pdf document and it has to be for

 the @value field.
 I know, to put a new line I should use a new block, but Is it possible

 to put some kind of \r\n string into the value to format it?

 fo:block hyphenate=true font-size=10pt font-weight=bold
 xsl:value-of select=@value/
 /fo:block

 This XSL document is used to convert an XML document to PDF with 
 either FOP 0.20.5 or 0.93 used embedded in a java 5.0 code.
  
 Thank you for your help.
  
 Kind regards,
  
 Miroslav Gregan
  
 Siemens PSE-SK KB SK2
 Dubravska cesta 4
 84104 Bratislava
 Slovakia
  


-
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: word-spacing

2007-02-12 Thread Gregan, Miroslav

Hi,
According to the known issues:

http://xmlgraphics.apache.org/fop/0.93/knownissues_overview.html

block_word-spacing.xml (block word-spacing):
Word-spacing may not work as expected.

Miroslav


-Original Message-
From: Olivier Mansour [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 12, 2007 2:39 PM
To: fop-users@xmlgraphics.apache.org
Subject: word-spacing

Hello

does FOP deal with the word-spacing attribute in blocks ?

thx you
Olivier


--
Olivier Mansour  http://www.clever-age.com
Clever Age Lyon - conseil en architecture technique
GSM: +33 6 11 03 23 77  Tél: +33 4 78 89 46 45

Clever Age vous invite à ses petits déjeuners du Jeudi
http://www.clever-age.com/actualites/petits-dejeuners/



-
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]



XSL - NewLine

2007-02-12 Thread Gregan, Miroslav
Hello all,
 
I need to put manually new line in a pdf document and it has to be for
the @value field.
I know, to put a new line I should use a new block, but Is it possible
to put some kind of \r\n string into the value to format it?
fo:block hyphenate=true font-size=10pt font-weight=bold
xsl:value-of select=@value/
/fo:block

This XSL document is used to convert an XML document to PDF with either
FOP 0.20.5 or 0.93 used embedded in a java 5.0 code.
 
Thank you for your help.
 
Kind regards,
 
Miroslav Gregan
 
Siemens PSE-SK KB SK2
Dubravska cesta 4
84104 Bratislava
Slovakia
 


RE: Table troubles

2007-02-09 Thread Gregan, Miroslav
Hi,
Could you send the XSL:FO file,
it's quite hard to answer you without.
Thanks

Miro 

-Original Message-
From: Vincenzo Mazzeo [mailto:[EMAIL PROTECTED] 
Sent: Friday, February 09, 2007 4:09 PM
To: fop-users@xmlgraphics.apache.org
Subject: Table troubles

Hi all,
I have upgraded fop from 0.25 to 0.93 and I have some troubles with
tables.

1. On page break table doesn't have the bottom border even if I set it.
2. On the last page, if there isn't enough data, table doesn't fill all
available space even if I set the 'height' attribute to 100%.

Moreover I have some cells with the 'display-align' attribute set to
'after'. Because of I can't use the 'keep-together' attribute on rows,
it happens that if a row is shared on two pages the 'display-align'
doesn't work and the value appears on the former page instead of the
latter.

Does anyone have idea about these troubles?

Regards
Vincenzo


-
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: Need help on PDF generation using XSL-FO

2007-02-08 Thread Gregan, Miroslav
Try to use iText.
It can edit a pdf and changes it's properties.
 
http://www.lowagie.com/iText/
 
hope it helps.



From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] 
Sent: Thursday, February 08, 2007 10:53 AM
To: fop-users@xmlgraphics.apache.org
Subject: Need help on PDF generation using XSL-FO



Hi All,

 

We have a project requirement to generate a PDF document out of XML in
multiple languages. We have been successful in generating the PDF in
multiple languages.

On top of this, we have another requirement of disabling the PRINT, SAVE
and EDIT options in the PDF. It looks like we can't disable the PRINT
option using XSL-FO.

We are still exploring on disabling SAVE and EDIT using XSL-FO. If any
body has got idea on disabling these options using any other freeware,
please provide the info/URL to get the information.

 

Thanks  Regards

Sowjanya


The information contained in this electronic message and any attachments
to this message are intended for the exclusive use of the addressee(s)
and may contain proprietary, confidential or privileged information. If
you are not the intended recipient, you should not disseminate,
distribute or copy this e-mail. Please notify the sender immediately and
destroy all copies of this message and any attachments. 

WARNING: Computer viruses can be transmitted via email. The recipient
should check this email and any attachments for the presence of viruses.
The company accepts no liability for any damage caused by any virus
transmitted by this email.

www.wipro.com



RE: wrap text in table-cell question

2007-01-23 Thread Gregan, Miroslav
Thank you for your solution, it works great and does exactly want I need
with FOP 0.20.5,
but it doesn't work with FOP 0.93 :-(
 
this is what my xsl sheet looks like:
fo:table-body

fo:table-row background-color=white

fo:table-cell border-width=0px padding-left=1px

fo:block hyphenate=true font-size=16pt

xsl:value-of select=/report/header/site-properties/@name/

/fo:block

/fo:table-cell




From: mahmoudi ould abdel vetah [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 23, 2007 10:34 AM
To: fop-users@xmlgraphics.apache.org
Subject: Re: wrap text in table-cell question


hi,
 
in your cell, you can make:
 
fo:table-cell
  fo:block hyphenate=true
language=enB/fo:block
/fo:table-cell
 
i hope this help you.
 


 
2007/1/22, J.Pietschmann [EMAIL PROTECTED]: 

Gregan, Miroslav wrote:
 When I write text in table-cells, it may happen that the text
is longer
 than the cell (ex. hyperlinks)
 Is there a way to have the text break on the next line if too
long or
 the end cut so that the text isn't written on the next cell?

This is a FAQ:
http://xmlgraphics.apache.org/fop/faq.html#cells-overflow

A more high tech approach is to use a customized hyphenation
pattern file.

J.Pietschmann


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






RE: wrap text in table-cell question

2007-01-23 Thread Gregan, Miroslav
I just downloaded the package fop-hyph.jar.
And set a language (language=en)
It's funny works good with English language,
just that when I have technical data, it's doing nothing because he
doesn't recognise any word^^
I will have to make my own file :-(
And not forget to give a feedback as asked on the hyphenation page :-)

Thank you very much for the help you provide me, it helps me a lot.

Miro

-Original Message-
From: Chris Bowditch [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 23, 2007 2:45 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: wrap text in table-cell question

Gregan, Miroslav wrote:

 Thank you for your solution, it works great and does exactly want I
need 
 with FOP 0.20.5,
 but it doesn't work with FOP 0.93 :-(
  
 this is what my xsl sheet looks like:
 
 fo:table-body
 
 fo:table-row background-color=white
 
 fo:table-cell border-width=0px padding-left=1px
 
 fo:block hyphenate=true font-size=16pt
 
 xsl:value-of select=/report/header/site-properties/@name/
 
 /fo:block
 
 /fo:table-cell

What is your language property set to? Did you download fop-hyph.jar 
from OFFO?

http://offo.sourceforge.net/hyphenation/index.html

I believe FOP 0.20.5 was distributed with some hyphenation patterns but 
0.9x has none and you have to download fop-hyph.jar.

Chris





-
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]



wrap text in table-cell question

2007-01-22 Thread Gregan, Miroslav
Hello all,
When I write text in table-cells, it may happen that the text is longer
than the cell (ex. hyperlinks)
Is there a way to have the text break on the next line if too long or
the end cut so that the text isn't written on the next cell?
Thank you for taking time to answer me.
Miroslav


RE: between multiple table problem with spacing

2007-01-17 Thread Gregan, Miroslav
Thank you very much for your answers it solved my problem!!

-Original Message-
From: Chris Bowditch [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 16, 2007 5:54 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: between multiple table problem with spacing

Gregan, Miroslav wrote:

 Thank you for your answer, I have looked for information
 on the http://www.w3.org/TR/xsl/ page to find out how/where to use 
 space-before.conditionality=retain and
 space-after.conditionality=retain
 But I did not found any information about it.
 
 Is it a parameter for an fo:block, an fo:table, something else?
 Can you show me a small example of it's use?

You can use space-before.conditionality on any FO that works with 
space-before. I have attached your original dfg.fo file which I modified

to use space-before.conditionality=retain

Chris

snip/

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



RE: PROBLEM while trying to write text vertically with SVG

2007-01-17 Thread Gregan, Miroslav
Thank you for your answer,
The problem has been solved when I upgraded form Eclipse 3.1.1 to 3.2.1.
It must have been a problem with the class loader :-(

-Original Message-
From: Pascal Sancho [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, January 10, 2007 1:48 PM
To: fop-users@xmlgraphics.apache.org
Subject: RE: PROBLEM while trying to write text vertically with SVG

AFAIK, with FOP 0.93, related SVG libraries are:

 - batik-all-1.6.jar

 - xmlgraphics-commons-1.1.jar

Pascal


 -Message d'origine-
 De : Gregan, Miroslav [mailto:[EMAIL PROTECTED] 
 Envoyé : mercredi 10 janvier 2007 11:40
  
 Not fair, I still get nothing correct!!
 
 Even when I put no font-family property.
 Could it be a library problem?
 
 Miroslav

 Hi,
 I get a vertical text with your a fo file undezr FOP 0.93 (I 
 suppose that is what you want to get).
 
 There is only 1 minor mistake in it:
 
 Use Sans-serif instead of SansSerif in your font-family property.
 
 Pascal
 
  -Message d'origine-
  De : Gregan, Miroslav [mailto:[EMAIL PROTECTED]
  Envoyé : mercredi 10 janvier 2007 08:59
   
  I'm trying to write text vertically in a PDF by using an 
 XSL-FO with 
  SVG code.
  I use FOP 0.93 like a library in a java code under windows XP, (but 
  should also work under Linux).
  The SVG code used is working fine in an SVG file, and with FOP 20.5.
   
  BUT it is NOT working with FOP 0.93.
   
  Could someone, please, have a look at it and tell my what 
 am I doing 
  wrong?
   
  fo start file:
  http://www.filefactory.com/file/f107a9/
  http://www.filefactory.com/file/f107a9/
   
  pdf result file:
  http://www.filefactory.com/file/d30969/
  http://www.filefactory.com/file/d30969/
   
  Thank you.
   
  Kind regards,
   
  Miroslav


-
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: between multiple table problem with spacing

2007-01-16 Thread Gregan, Miroslav
Thank you for your answer, I have looked for information
on the http://www.w3.org/TR/xsl/ page to find out how/where to use 
space-before.conditionality=retain and
space-after.conditionality=retain
But I did not found any information about it.

Is it a parameter for an fo:block, an fo:table, something else?
Can you show me a small example of it's use?

Thanks a lot,

Miro



-Original Message-
From: Chris Bowditch [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, January 16, 2007 1:28 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: between multiple table problem with spacing

Gregan, Miroslav wrote:

 Hi all,
 I use FOP 0.93 like a library under windows.
 I have a spacing problem around text and tables, but only if the
tables 
 around are filled.
 Here are some examples (every time with the fo file):
 
 * dfg is the document filled, so with the spacing problem around
   TableName1.

The space-before and space-after is collapsed, which is supposed to 
happen only at the start or end of a reference area. I don't think a 
block in between 2 tables is the start of reference area!

 * dfg2 is the document not filled, so with no spacing problem.

Strange that the content in the tables is affecting the conditional 
spacing of an adjacent block. Can you raise a bug in bugzilla so this 
issue is not forgotten? Don't forget to attach the samples!

 * dfg3 is the document the same document like dfg but printed in
   landscape, no spacing problem around TableName1, but around
   TableName4.
 
 It must be a little error from me, but I have no idea.
 Do someone have an idea why this happens?

You can work around the problem using 
space-before.conditionality=retain and 
space-after.conditionality=retain I tested this on the dfg.fo sample 
file and the space does get honoured with conditionality=retain

snip/

Thanks,

Chris




-
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: PROBLEM while trying to write text vertically with SVG

2007-01-10 Thread Gregan, Miroslav
 
Not fair, I still get nothing correct!!

Even when I put no font-family property.
Could it be a library problem?

Miroslav


Hi,
I get a vertical text with your a fo file undezr FOP 0.93 (I suppose that is 
what you want to get).

There is only 1 minor mistake in it:

Use Sans-serif instead of SansSerif in your font-family property.

Pascal

 -Message d'origine-
 De : Gregan, Miroslav [mailto:[EMAIL PROTECTED] 
 Envoyé : mercredi 10 janvier 2007 08:59
  
 I'm trying to write text vertically in a PDF by using an 
 XSL-FO with SVG code.
 I use FOP 0.93 like a library in a java code under windows 
 XP, (but should also work under Linux).
 The SVG code used is working fine in an SVG file, and with FOP 20.5.
  
 BUT it is NOT working with FOP 0.93.
  
 Could someone, please, have a look at it and tell my what am 
 I doing wrong?
  
 fo start file:
 http://www.filefactory.com/file/f107a9/ 
 http://www.filefactory.com/file/f107a9/ 
  
 pdf result file:
 http://www.filefactory.com/file/d30969/ 
 http://www.filefactory.com/file/d30969/ 
  
 Thank you.
  
 Kind regards,
  
 Miroslav


-
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]



Write text vertically

2007-01-09 Thread Gregan, Miroslav
Hello all,
 
I'm trying to write text vertically from an XSL-FO file to PDF
with FOP 0.93 used like a library in a java code under windows XP, (but
should also work under Linux).
The SVG code used is working fine in an SVG file, and with FOP 20.5.
 
fo start file:
http://www.filefactory.com/file/f107a9/
http://www.filefactory.com/file/f107a9/ 
 
pdf result file:
http://www.filefactory.com/file/d30969/
http://www.filefactory.com/file/d30969/ 
 
 
If someone knows a better server where to put the files than
fileFactory,
I'll be glad if you could tell me it's address.
 
Kind regards,
 
Miroslav


PROBLEM while trying to write text vertically with SVG

2007-01-09 Thread Gregan, Miroslav
Hello all,
 
I'm trying to write text vertically in a PDF by using an XSL-FO with SVG
code.
I use FOP 0.93 like a library in a java code under windows XP, (but
should also work under Linux).
The SVG code used is working fine in an SVG file, and with FOP 20.5.
 
BUT it is NOT working with FOP 0.93.
 
Could someone, please, have a look at it and tell my what am I doing
wrong?
 
fo start file:
http://www.filefactory.com/file/f107a9/
http://www.filefactory.com/file/f107a9/ 
 
pdf result file:
http://www.filefactory.com/file/d30969/
http://www.filefactory.com/file/d30969/ 
 
Thank you.
 
Kind regards,
 
Miroslav
 
PS
If someone knows a better server where to put the files than
fileFactory,
I'll be glad if you could tell me it's address.