DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=40
857>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=40857
a>
flaviostutz gmail.com changed:
What |Removed |Added
------------------------------------------------------------
----------------
Component|SVG DOM |Bridge
------- Additional Comments From flaviostutz gmail.com
2006-11-02 13:36 -------
I made the following changes to batik and it is working well
for me now:
(I just put a test in the beginning of the method:
"if(node instanceof TextNode) {"
PATCH:
Index: .
============================================================
=======
--- . (revision 469041)
+++ . (working copy)
 -585,41
+585,43 
protected void computeLaidoutText(BridgeContext ctx,
Element e,
GraphicsNode node) {
- TextNode tn = (TextNode)node;
- elemTPI.clear();
-
- AttributedString as = buildAttributedString(ctx,
e);
- if (as == null) {
- tn.setAttributedCharacterIterator(null);
- return;
- }
-
- addGlyphPositionAttributes(as, e, ctx);
- if (ctx.isDynamic()) {
- laidoutText = new
AttributedString(as.getIterator());
- }
-
- // Install the ACI in the text node.
-
tn.setAttributedCharacterIterator(as.getIterator());
-
- // Now get the real paint into - this needs to
- // wait until the text node is laidout so we can
get
- // objectBoundingBox info.
- TextPaintInfo pi = new TextPaintInfo();
- setBaseTextPaintInfo(pi, e, node, ctx);
- // This get's Overline/underline info.
- setDecorationTextPaintInfo(pi, e);
- // Install the attributes.
- addPaintAttributes(as, e, tn, pi, ctx);
-
- if (usingComplexSVGFont) {
- // Force Complex SVG fonts to be recreated, if
we have them.
-
tn.setAttributedCharacterIterator(as.getIterator());
- }
-
- if (ctx.isDynamic()) {
- checkBBoxChange();
- }
+ if(node instanceof TextNode) {
+ TextNode tn = (TextNode)node;
+ elemTPI.clear();
+
+ AttributedString as = buildAttributedString(ctx,
e);
+ if (as == null) {
+ tn.setAttributedCharacterIterator(null);
+ return;
+ }
+
+ addGlyphPositionAttributes(as, e, ctx);
+ if (ctx.isDynamic()) {
+ laidoutText = new
AttributedString(as.getIterator());
+ }
+
+ // Install the ACI in the text node.
+
tn.setAttributedCharacterIterator(as.getIterator());
+
+ // Now get the real paint into - this needs to
+ // wait until the text node is laidout so we can
get
+ // objectBoundingBox info.
+ TextPaintInfo pi = new TextPaintInfo();
+ setBaseTextPaintInfo(pi, e, node, ctx);
+ // This get's Overline/underline info.
+ setDecorationTextPaintInfo(pi, e);
+ // Install the attributes.
+ addPaintAttributes(as, e, tn, pi, ctx);
+
+ if (usingComplexSVGFont) {
+ // Force Complex SVG fonts to be recreated, if
we have them.
+
tn.setAttributedCharacterIterator(as.getIterator());
+ }
+
+ if (ctx.isDynamic()) {
+ checkBBoxChange();
+ }
+ }
}
/**
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=ema
il
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the
assignee.
------------------------------------------------------------
---------
To unsubscribe, e-mail: batik-dev-unsubscribe xmlgraphics.apache.org
For additional commands, e-mail: batik-dev-help xmlgraphics.apache.org
|