You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Sanjeev Kulshreshtha <sa...@gmail.com> on 2010/06/21 18:33:42 UTC

Problem in Rendering Bold text to PCL using XSLFO

Hi All,

 I am trying to process and xml message that contains some in line
bold text marked with <b> some text </b> and i am using

	<xsl:template match="b">
		<fo:inline font-weight="bold">
			<xsl:apply-templates />
		</fo:inline>
	</xsl:template>
to convert it to XSL FO and similar thing is done for underlining as
	<xsl:template match="u">
		<fo:inline text-decoration="underline">
			<xsl:apply-templates />
		</fo:inline>
	</xsl:template>

Problem arises when i convert the created XSL FO to a pcl and print
it. In the print i see arbitrary spaces before or after the bolded /
underlined text.

Can any one help me in this regard ?

Thanks!
Sanjeev

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problem in Rendering Bold text to PCL using XSLFO

Posted by Craig Ringer <cr...@postnewspapers.com.au>.
On 22/06/10 00:33, Sanjeev Kulshreshtha wrote:

> Problem arises when i convert the created XSL FO to a pcl and print
> it. In the print i see arbitrary spaces before or after the bolded /
> underlined text.
> 
> Can any one help me in this regard ?

Sanjeev,

I'm new here and no expert in XSL-FO, so it's hard for me to help you
with your question directly. I thought I'd pop up with a few suggestions
that'll help you improve your chances of getting a useful answer, though.

The fop mailing list guidelines:

  http://xmlgraphics.apache.org/fop/maillist.html#fop-user-policy

tell you to include a complete XSL-FO file if asking a question, rather
than just posting XSLT or fo fragments. If you think about it, you'
ll see that it's hard for anyone who doesn't have your source XML and
whole stylesheet to reproduce the problem and investigate it.
Additionally, they're not really interested in your source XML and your
stylesheet, just in the FO. So, if your issue is with FO, you should
probably post the FO document.

You should also mention things relevant to your question, like:

- Your version of fop
- Your version of Java
- Your operating system and version
- Your printer model and what printer driver+version you are using
  (since your issue is with printed output)
- What fonts are used in the document and what format they are
  (TTF, Type 1, OpenType, "base 14" builtins, etc).
- The fop command line being used to produce the document
- any relevant fop configuration
- whether the same issue applies with other output formats like pdf
- Whether the issue persists when you use a different font

In your case, when I tried to think about your problem it was impossible
to progress, because I didn't even know what fonts you were using,
whether you were producing PCL via intermediate mode or not, etc.

Perhaps you should post again with a more complete example of the problem?

( and yes, I've since realized that my own question isn't really all
that FOP specific and is as much generic XSL-FO, so I've broken some of
those guidelines myself...).

--
Craig Ringer

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Problem in Rendering Bold text to PCL using XSLFO

Posted by Jeremias Maerki <de...@jeremias-maerki.ch>.
Sanjeev,
I've tested with FOP 0.95 and FOP Trunk but haven't seen any such
effects that you describe. So, as Craig indicated, we need a bit more
information.

On 21.06.2010 18:33:42 Sanjeev Kulshreshtha wrote:
> Hi All,
> 
>  I am trying to process and xml message that contains some in line
> bold text marked with <b> some text </b> and i am using
> 
> 	<xsl:template match="b">
> 		<fo:inline font-weight="bold">
> 			<xsl:apply-templates />
> 		</fo:inline>
> 	</xsl:template>
> to convert it to XSL FO and similar thing is done for underlining as
> 	<xsl:template match="u">
> 		<fo:inline text-decoration="underline">
> 			<xsl:apply-templates />
> 		</fo:inline>
> 	</xsl:template>
> 
> Problem arises when i convert the created XSL FO to a pcl and print
> it. In the print i see arbitrary spaces before or after the bolded /
> underlined text.
> 
> Can any one help me in this regard ?
> 
> Thanks!
> Sanjeev



Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org