Hi Glenn,

For whatever reason, the addition JVM options are not yielding any extra
output.

It seems that FOP is simply not picking up any of my installed fonts.

I have ttf files in ./fonts/, and I'm using the following configuration:
<fop version="1.0">

  <!-- Base URL for resolving relative URLs -->

<base>/home/marcintustin/webapps/django/oneclickcosvirt/oneclickcos/java</base>

  <!-- Source resolution in dpi (dots/pixels per inch) for determining the
size of pixels in SVG and bitmap images, default: 72dpi -->
  <source-resolution>72</source-resolution>
  <!-- Target resolution in dpi (dots/pixels per inch) for specifying the
target resolution for generated bitmaps, default: 72dpi -->
  <target-resolution>300</target-resolution>

  <!-- Default page-height and page-width, in case
       value is specified as auto -->
  <default-page-settings height="297mm" width="210"/>

  <!-- Information for specific renderers -->
  <!-- Uses renderer mime type for renderers -->
  <renderers>
    <renderer mime="application/vnd.hp-PCL">
        <text-rendering>bitmap</text-rendering>
        <fonts>
            <directory recursive="true">./fonts</directory>
            <auto-detect/>
        </fonts>
    </renderer>

  </renderers>

</fop>

This is loaded with:
DefaultConfigurationBuilder cfgBuilder = new DefaultConfigurationBuilder();
fopFactory.setUserConfig(fopConfig);
fopFactory.getFontManager().setFontBaseURL("file:///home/marcintustin/webapps/django/oneclickcosvirt/oneclickcos/java/fonts/");

Is there anything I'm missing? I've been tearing my hair out over this for
the last 10 hours, and I've made absolutely no progress in getting FOP to
recognise these fonts, or in fact any fonts other than the one default font
it seems to use.

Thanks,
Marcin

On Mon, May 28, 2012 at 3:13 PM, Glenn Adams <gl...@skynav.com> wrote:

> not really (more documentation), other than source code
>
> you could also enable more logging, e.g., by adding a JVM argument:
>
> -Djava.util.logging.config.file=logging.properties
>
> with file logging.properties (in the same directory you invoke JVM)
> containing:
>
> handlers = java.util.logging.ConsoleHandler
> java.util.logging.ConsoleHandler.level = FINEST
> java.util.logging.ConsoleHandler.formatter =
> java.util.logging.SimpleFormatter
> .level = WARNING
> org.apache.fop.fonts.level = FINEST
> org.apache.fop.fonts.truetype.level = WARNING
>
> this might provide you with some additional clues
>
> On Mon, May 28, 2012 at 6:55 AM, Marcin Tustin <marcin.tus...@gmail.com>wrote:
>
>> OK, thanks for this.
>>
>> Is there any more extensive documentation on font configuration than
>> http://xmlgraphics.apache.org/fop/1.0/fonts.html ? I ask because having
>> looked at my logs, it looks like FOP in my linux environment is basically
>> not finding any fonts.
>>
>> Marcin
>>
>>
>> On Mon, May 28, 2012 at 1:47 PM, Glenn Adams <gl...@skynav.com> wrote:
>>
>>> possible workarounds
>>>
>>> (1) don't use any of the base 14 fonts
>>> (2) or, specify <text-rendering>bitmap</text-rendering> in your config
>>> file
>>>
>>> it sounds like you are encountering the problem described in
>>> https://issues.apache.org/bugzilla/show_bug.cgi?id=51076
>>>
>>> On Mon, May 28, 2012 at 4:52 AM, Marcin Tustin 
>>> <marcin.tus...@gmail.com>wrote:
>>>
>>>> Hi all,
>>>>
>>>> I'm using FOP (as contained in fop-20120423.jar) to generate PCL.
>>>> However, the output on windows and linux are completely different (examples
>>>> attached).
>>>>
>>>> On windows, font rendering is incredibly blocky (not a problem -
>>>> windows is only my dev environment) and correctly spaced.
>>>>
>>>> On linux font rendering is crisp (good), but there are weird extra
>>>> spaces inserted in the output. This does not happen with PDF output, and it
>>>> does not happen on windows, so I infer that the FO input is fine. I am at a
>>>> loss to imagine what might be the cause of this issue.
>>>>
>>>> Any suggestions on possible workarounds, or possible fixes would be
>>>> greatly appreciated. This issue is very urgent for me, although I
>>>> understand that it may not be an issue for other users.
>>>>
>>>> Thanks,
>>>> Marcin
>>>>
>>>>
>>>> --
>>>> Marcin Tustin
>>>> Tel: 07773 787 105
>>>>
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: fop-users-unsubscr...@xmlgraphics.apache.org
>>>> For additional commands, e-mail: fop-users-h...@xmlgraphics.apache.org
>>>>
>>>
>>>
>>
>>
>> --
>> Marcin Tustin
>> Tel: 07773 787 105
>>
>>
>


-- 
Marcin Tustin
Tel: 07773 787 105

Reply via email to