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 "Przybilla, Frank" <fr...@maxess.de> on 2002/09/30 18:38:34 UTC
Problems with hyphenation in fop
Hello all,
I have a problem with fop which I have already posted to the
cocoon mailing list, because I use fop within cocoon. But now it is
clear that it is not a cocoon but a fop problem. Therefore I think it is
better to discuss this problem in the fop mailing list.
Here my problem again:
There is a problem with hyphenation which has the bad effect that fop
is sometimes messing up words which must be hyphanated. The word
Kaiserslautern
(the town in Germany where I live) is e.g printed like this:
sla
ute
Kaiserrn
instead of
Kaisers-
lautern.
The problems only occurs when using fop-0-20.{3,4} together with Xalan2.2.0
which
is used in cocoon. Running fop with Xalan2.0.0 works.
Joerg Pietschmann wrote referring to this issue:
Ah, the problem with parts of hyphenated word jumping around
is actually a FOP bug. Yes, it depends on the parser, more
specific, it depends on how the parser passes text up.
The bug is fixed in CVS (maintenance branch).
Now I retrieved fop from branch fop-0_20_2-maintain and built fop.
When running this with my testfiles I got the follwing error during
fop tree creation:
[ERROR] Couldn't find hyphenation pattern de
[ERROR] Error building hyphenation tree for language de
java.io.InvalidClassException:
org.apache.fop.layout.hyphenation.HyphenationTree
; local class incompatible: stream classdesc serialVersionUID =
-778451683547287
1478, local class serialVersionUID = 6956085100635965297
I fixed this with adding static final long serialVersionUID=
-7784516835472871478L; in class
org.apache.fop.layout.hyphenation.HyphenationTree. But then I got the
follwing error:
[ERROR] Error building hyphenation tree for language de
java.lang.ClassCastException: cannot assign instance of java.util.Hashtable
to field org.apache.fop.layout.hyphenation.HyphenationTree.stoplist of type
java.util.HashMap in instance of
org.apache.fop.layout.hyphenation.HyphenationTree
at
java.io.ObjectStreamClass$FieldReflector.setObjFieldValues(ObjectStreamClass
.java:1840)
at
java.io.ObjectStreamClass.setObjFieldValues(ObjectStreamClass.java:1062)
at
java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1851)
at
java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1769)
at
java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1646)
at
java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324)
at
org.apache.fop.layout.hyphenation.Hyphenator.getFopHyphenationTree(Unknown
Source)
at
org.apache.fop.layout.hyphenation.Hyphenator.getHyphenationTree(Unknown
Source)
at org.apache.fop.layout.hyphenation.Hyphenator.hyphenate(Unknown
Source)
at org.apache.fop.layout.LineArea.doHyphenation(Unknown Source)
Is this a bug or how could this be solved?
With best regards
Frank.
> --------------------------------------------------------------------------
> ---------
> Frank Przybilla @xdecision
> (Dipl.-Inform.)
> maxess systemhaus gmbh
> Europaallee 3-5 Phone: +49 (0) 631.303-2500
> 67657 Kaiserslautern Fax: +49 (0) 631.303-2501
> E-Mail: mailto:przybilla@maxess.de
> Germany www: http://www.maxess.de
> --------------------------------------------------------------------------
> --------
>
>
>
Re: Problems with hyphenation in fop
Posted by "J.Pietschmann" <j3...@yahoo.de>.
Przybilla, Frank wrote:
> Is this a bug or how could this be solved?
Already solved.
J.Pietschmann