Re: negative background-position-horizontal values?

2007-11-26 Thread Jerzy Jalocha N
> FOP only evaluates background-position-horizontal if background-repeat
> is "repeat-y" or "no-repeat", and background-position-vertical if
> background-repeat is "repeat-x" or "no-repeat".

Honestly, this dependency on the 'background-repeat' is quite
counter-intuitive for me, but once I about know this, it's no longer a
problem.

I tested my markup with background-repeat="no-repeat", and it works
flawlessly, both with positive and negative values for
'background-position-*'. I am very glad and grateful that the
development team is going into such great detail when interpreting the
specifications. Some commercial implementations don't seem to care as
much as you do.

As for the project I am working now, your workaround is very
straightforward, and it renders my document perfectly. And it has the
added bonus that it will probably allow me to put the SVG markup
inline, inside the 'fo:block' element --a feature that could become
quite important for me in the future.

Thank you very much for your help, Jeremias!

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



change the icon image in the bookmark

2007-11-26 Thread Daling Xu
Hi,
   
  I am using the FOP to generate a PDF file.
   
  In the PDF, I have a bookmark tree. Now in each of the bookmark, there is an 
image icon which is ( I believe) the default icon from Acrobat. Is there any 
way I can customize this icon using my own image file?
   
  Thanks
   
  Linda

   
-
Be a better sports nut! Let your teams follow you with Yahoo Mobile. Try it now.

Re: Problem generating PDF with FOP 0.20.5 and Latin Modern fonts

2007-11-26 Thread Vincent Hennebert
Hi Daniel,

Daniel Rosenberg wrote:
> Yes,
> 
> but isn't this characteristics of 'differently sized' fonts there to
> optimize readability and aesthetics of a font when typesetted in
> different sizes?

You’re right. Those numbers are indeed sizes and correspond to an 
optimal point size at which the font looks best. Even if, being 
described in a vectorial format, they can be scaled to any size.

I don’t think the way you did will work, although that would be the most 
desirable one. I believe the only way is to “cheat” by hard-coding the 
font size in the family name:

  


In your FO document, you would change the font family in addition to
changing the font size:
 Scaling works fine, but I guess the result will be
> even better if all availabe fonts are utilized?
> 
> / Daniel
> 
> 
> On Mon, 2007-11-26 at 09:25 +0100, Jeremias Maerki wrote:
>> I think you've got that wrong. The numbers behind the font names are not
>> sizes. I don't know the English word for the typography term, but in
>> this font family: the lower the number, the wider the individual
>> characters and the character spacing.
>>
>> Type 1 fonts are scalable, so you don't need different fonts for
>> different sizes.
>>
>> Jeremias Maerki
>>
>>
>>
>> On 25.11.2007 02:17:30 Daniel Rosenberg wrote:
>>> Hi, I have another question. The Latin Modern fonts have different
>>> versions of different sizes of fonts. Can I utilize this in my
>>> generated PDF document?
>>>
>>> For example, I'd like to include something like
>>>
>>> >> embed-file="type1/public/lm/lmr10.pfb">
>>> 
>>> 
>>> >> embed-file="type1/public/lm/lmr12.pfb">
>>> 
>>> 
>>> >> embed-file="type1/public/lm/lmr17.pfb">
>>> 
>>> 
>>>
>>> in my userconfig.xml and then (in some way) switch between the
>>> differently sized fonts.
>>>
>>> / Daniel

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



RE: Problem generating PDF with FOP 0.94

2007-11-26 Thread Andries Burger
Hi Chris,

Thanks. I've been so pre-occupied with the XSL file, I never thought to
look at the XML that I'm transforming.

It indeed has two printspecification tags. 

I'll see why I'm getting the two items there and if there is no reason
for them being there, I'll have a new XML generated and test again.

Many thanks again.

Andries Burger
Snr. C++ Unix Analyst Developer
Digital Healthcare Switch (Pty) Ltd
PO Box 7045, Halfway House, 1685
Tel: 011 265 5527
Fax: 011 265 5470
E-mail: [EMAIL PROTECTED]
Web: www.switchonline.co.za

This e-mail is subject to an e-mail disclaimer. 
To read our e-mail disclaimer notice go to:
http://www.dhsolutions.co.za/disclaimer/email/
Alternatively please contact us on +27 11 265 5400

-Original Message-
From: Chris Bowditch [mailto:[EMAIL PROTECTED] 
Sent: 26 November 2007 03:57 PM
To: fop-users@xmlgraphics.apache.org
Subject: Re: Problem generating PDF with FOP 0.94

Andries Burger wrote:



> a .fo file generated for the layout I want, except that I end up with 
> a double  element in the FO file.



> 
> 
> 
> 
> http://www.w3.org/1999/XSL/Format";>

Does your XML input contain 2 printspecification elements? I would guess
that is the most likely reason you end up with 2 fo:root nodes in the FO
file?



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 generating PDF with FOP 0.94

2007-11-26 Thread Chris Bowditch

Andries Burger wrote:



a .fo file generated for the layout I want, except that I end up with a 
double  element in the FO file.









http://www.w3.org/1999/XSL/Format";>


Does your XML input contain 2 printspecification elements? I would guess 
that is the most likely reason you end up with 2 fo:root nodes in the FO 
file?




Chris



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



Table of Contens fo:leader Problem

2007-11-26 Thread Dirk Bromberg

Hi Users,

i've a small problem with the usage of a leader.

When i will render a TOC, i use this code:

1 Demo Demo Demo Demo Demo Demo Demo 
Demo Demo Demo Demo Demo Demo Demo Demo Demo Demo Demo 
   leader-pattern="rule" rule-thickness="0.5pt"/> 555
   

The problem: When the text "Demo" is too long for the page then it 
breaks above the pagenumber and starts in a new line under the start of 
the first line. Is there way to create a style like:


---
1 Demo Demo Demo BREAK
  Demo Demo  555



Thanks.

Dirk

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



Re: Problem generating PDF with FOP 0.20.5 and Latin Modern fonts

2007-11-26 Thread Daniel Rosenberg
Yes,

but isn't this characteristics of 'differently sized' fonts there to
optimize readability and aesthetics of a font when typesetted in
different sizes? Scaling works fine, but I guess the result will be
even better if all availabe fonts are utilized?

/ Daniel


On Mon, 2007-11-26 at 09:25 +0100, Jeremias Maerki wrote:
> I think you've got that wrong. The numbers behind the font names are not
> sizes. I don't know the English word for the typography term, but in
> this font family: the lower the number, the wider the individual
> characters and the character spacing.
> 
> Type 1 fonts are scalable, so you don't need different fonts for
> different sizes.
> 
> Jeremias Maerki
> 
> 
> 
> On 25.11.2007 02:17:30 Daniel Rosenberg wrote:
> > Hi, I have another question. The Latin Modern fonts have different
> > versions of different sizes of fonts. Can I utilize this in my
> > generated PDF document?
> > 
> > For example, I'd like to include something like
> > 
> >  > embed-file="type1/public/lm/lmr10.pfb">
> > 
> > 
> >  > embed-file="type1/public/lm/lmr12.pfb">
> > 
> > 
> >  > embed-file="type1/public/lm/lmr17.pfb">
> > 
> > 
> > 
> > in my userconfig.xml and then (in some way) switch between the
> > differently sized fonts.
> > 
> > / Daniel
> 
> 
> -
> 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 generating PDF with FOP 0.20.5 and Latin Modern fonts

2007-11-26 Thread Jeremias Maerki
I think you've got that wrong. The numbers behind the font names are not
sizes. I don't know the English word for the typography term, but in
this font family: the lower the number, the wider the individual
characters and the character spacing.

Type 1 fonts are scalable, so you don't need different fonts for
different sizes.

Jeremias Maerki



On 25.11.2007 02:17:30 Daniel Rosenberg wrote:
> Hi, I have another question. The Latin Modern fonts have different
> versions of different sizes of fonts. Can I utilize this in my
> generated PDF document?
> 
> For example, I'd like to include something like
> 
>  embed-file="type1/public/lm/lmr10.pfb">
> 
> 
>  embed-file="type1/public/lm/lmr12.pfb">
> 
> 
>  embed-file="type1/public/lm/lmr17.pfb">
> 
> 
> 
> in my userconfig.xml and then (in some way) switch between the
> differently sized fonts.
> 
> / Daniel


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



Re: problem with custom fonts: ,400,normal not found

2007-11-26 Thread Jeremias Maerki
Most probably, the problem you experience is simply to do the missing
spaces in the font-triplet. You specified "Frutiger45Light" in the
configuration, but "Frutiger 45 Light" in the FO.

More details below.

On 24.11.2007 17:03:15 Diana Walther wrote:
> Hi there,
> 
> I've got trouble using customized fonts with FOP 0.94 on a Windows XP
> machine. My java version is: 1.6.02.
> 
> I know the problem has been discussed before. However, none of the
> suggestions given here or in other mailing lists or forums worked for
> me.
> 
> My problem:
> ---
> I get an error message like
> 
>   "Font Frutiger 45 Light, 400, normal not found"
> 
> during pdf compilation, the system is using the standard font. I also 
> tried to apply the bold or the italics font triplet, but the system 
> can't find them either.
> 
> What has worked so far? I followed the route given here:
> http://xmlgraphics.apache.org/fop/trunk/fonts.html
> 
> 1. I built font-metrics xml files for my desired font with the TFReader. 
> The related ttf-file has been discribed to me as, say "Frutiger 45 
> Light" and I assume that it contains at least the triplets for the 
> style="normal" and weight="normal".
> 
> 2. I specified a baseDir and an fontDir in my config file for fop (in my 
>   case, both are similar).
> 
> Here is a part of my fop config file:
> 
> -- part starts --
> 
> baseDir
> D:\fop094
>   
> 
> fontBaseDir
> D:\fop094
>   
> 
> --- end of part ---
> 
> I also registered my font in the config file:
> 
> -- part starts --
> 
> 
> 
> 
> 
> --- end of part ---
> 
> 3. The XML font metrics file and ttf file are in the font basedir. to be 
> sure, I also put them
> a) into the directory where the xslt-file is stored and
> b) in the directory where the batch file that calls fop.bat (the one in 
>   fop basedir) is located.
> 
> 4. I refer to new custom font name via "font-family" in the xslt-file.
> As font name, I use the one that is given in the font metrics xml-file
> and during font metrics building process in the dos shell (I have tried 
> with and without the spaces).
> 
> 5.  I used the config file on the command line (i.e, in a simple batch
> file). It seems to be used (my hyphenation specifiations, also given in
> the config file, are used), so why can't it find my font files?
> 
> 
> Maybe I made a mistake regarding the following two things?
> 
> 1. How do I know which font-triplet (regarding italics, bold) goes with
> which ttf-file? Can I only use a)  the name of the file as indicator or
> b) the information given during font metrics file compilation? In the
> examples given in the fop config file, some files go with multiple
> triplets, others do not.

The triplet associates the name, style and weight with a particular font.
You can associate multiple triplets with one font. So if you use 
"Frutiger45Light"
in the triplet, you have to use "Frutiger45Light" in the FO, not "Frutiger 45 
Light".

You could, for example, do this:

  
  


> 2. How do I get the correct font name? Is it the one given in the font
> metrics file? Or is it the one given during font metrics file
> compilation (in my cases, the second one has spaces).

The name in the metrics file is irrelevant and not used at all. Again,
it's the triplet that plays the tune here.

> Thanks for any answers and best regards,
> Diana

HTH
Jeremias Maerki


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



Re: negative background-position-horizontal values?

2007-11-26 Thread Jeremias Maerki
FOP only evaluates background-position-horizontal if background-repeat
is "repeat-y" or "no-repeat", and background-position-vertical if
background-repeat is "repeat-x" or "no-repeat". Whether this behaviour
is conformant or not is possibly a different question as I think there
is some room for interpretation in the spec. But the properties are
called "background-position-*", not "background-shift-*". And adding to
that the description of percent values reinforces my belief that the
current implementation is correct. But of course, we could be wrong.

However, there's a work-around for what you want to do:
You can place a fixed positioned block-container in the region-before.


  

  



Jeremias Maerki



On 24.11.2007 00:29:02 Jerzy Jalocha N wrote:
> Hi, I'm new to this list, so I'd like to say hello to everybody here, first.
> 
> I am confused about the use of negative  values with the
> 'background-position-horizontal' and 'background-position-vertical'
> attributes. In my current use-case, FOP just ignores these negative
> values. I am not quite sure if this behavior is correct or this is a
> bug.
> 
> The XSL 1.1 (http://www.w3.org/TR/xsl/#background-position-horizontal";
> recommendation does not mention negative values. But it declares this
> as "A Property Derived from a CSS2 Property".
> 
> The CSS2 specification
> (http://www.w3.org/TR/REC-CSS2/colors.html#background-properties) says
> for the 'background-position' property that "Negative positions are
> allowed", without any further clarifications.
> 
> Thus, I am not quite sure, how this translates to XSL-FO.
> 
> I am running the following system:
> * fop-0.94-bin-jdk1.4.tar.gz
> 
> * Sun java version 1.6.0_03
> * Ubuntu 7.10 Gutsy Gibbon
> * linux 2.6.22-14-generic (i686)
> 
> I am using the properties in the following context:
> 
> http://www.w3.org/1999/XSL/Format";>
>
>page-height="8.5in" page-width="11in"
> margin-top="0" margin-left="0" margin-right="0" margin-bottom="0">
>  border-style="none" border-width="thin"
>margin-top="16mm" margin-left="16mm"
> margin-right="16mm" margin-bottom="16mm"
>background-image="url('layout.svg')"
>background-position-horizontal="-16mm"
>background-position-vertical="-16mm" />
> [etc]
> 
> BTW: What I am trying to do, is to add some page-decorations that are
> larger than my region-body. Sadly, 'simple-page-master' does not
> accept background properties.
> 
> -
> 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]