/** * Invoked when an MutationEvent of type 'DOMSubtree' is fired. */ public void handleDOMSubtreeModifiedEvent(MutationEvent evt) { //an operation occured onto the children of the //text element, check if the layout was discarded if (laidoutText == null) { computeLaidoutText(ctx, e, getTextNode()); } }
/** * Invoked when an MutationEvent of type 'DOMSubtree' is fired. */ public void handleDOMSubtreeModifiedEvent(MutationEvent evt) { //an operation occured onto the children of the //text element, check if the layout was discarded if (laidoutText == null) { computeLaidoutText(ctx, e, getTextNode()); } }
/** * Invoked when an MutationEvent of type 'DOMSubtree' is fired. */ public void handleDOMSubtreeModifiedEvent(MutationEvent evt) { //an operation occured onto the children of the //text element, check if the layout was discarded if (laidoutText == null) { computeLaidoutText(ctx, e, getTextNode()); } }
/** * Invoked when the animated value of an animatable attribute has * changed on a 'tref' element. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { // Recompute the layout of the text node. textBridge.computeLaidoutText(ctx, textBridge.e, textBridge.getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); } }
/** * Invoked when the animated value of an animatable attribute has * changed on a 'tref' element. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { // Recompute the layout of the text node. textBridge.computeLaidoutText(ctx, textBridge.e, textBridge.getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); } }
/** * Invoked when the animated value of an animatable attribute has * changed on a 'tspan' element. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { // Recompute the layout of the text node. textBridge.computeLaidoutText(ctx, textBridge.e, textBridge.getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); } }
/** * Invoked when the animated value of an animatable attribute has * changed on a 'tref' element. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { // Recompute the layout of the text node. textBridge.computeLaidoutText(ctx, textBridge.e, textBridge.getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); } }
/** * Invoked when the animated value of an animatable attribute has * changed on a 'tspan' element. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { // Recompute the layout of the text node. textBridge.computeLaidoutText(ctx, textBridge.e, textBridge.getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); } }
/** * Invoked when the animated value of an animatable attribute has * changed on a 'tspan' element. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { // Recompute the layout of the text node. textBridge.computeLaidoutText(ctx, textBridge.e, textBridge.getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); } }
/** * Invoked when the animated value of an animatable attribute has changed. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { char c = ln.charAt(0); if (c == 'x' || c == 'y') { getTextNode().setLocation(getLocation(ctx, e)); } computeLaidoutText(ctx, e, getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); }
/** * Invoked when the animated value of an animatable attribute has changed. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { char c = ln.charAt(0); if (c == 'x' || c == 'y') { getTextNode().setLocation(getLocation(ctx, e)); } computeLaidoutText(ctx, e, getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); }
/** * Invoked when the animated value of an animatable attribute has changed. */ public void handleAnimatedAttributeChanged (AnimatedLiveAttributeValue alav) { if (alav.getNamespaceURI() == null) { String ln = alav.getLocalName(); if (ln.equals(SVG_X_ATTRIBUTE) || ln.equals(SVG_Y_ATTRIBUTE) || ln.equals(SVG_DX_ATTRIBUTE) || ln.equals(SVG_DY_ATTRIBUTE) || ln.equals(SVG_ROTATE_ATTRIBUTE) || ln.equals(SVG_TEXT_LENGTH_ATTRIBUTE) || ln.equals(SVG_LENGTH_ADJUST_ATTRIBUTE)) { char c = ln.charAt(0); if (c == 'x' || c == 'y') { getTextNode().setLocation(getLocation(ctx, e)); } computeLaidoutText(ctx, e, getTextNode()); return; } } super.handleAnimatedAttributeChanged(alav); }
/** * Invoked when an MutationEvent of type 'DOMNodeInserted' is fired. */ public void handleDOMNodeInsertedEvent(MutationEvent evt) { Node childNode = (Node)evt.getTarget(); //check the type of the node inserted before discard the layout //in the case of <title> or <desc> or <metadata>, the layout //is unchanged switch(childNode.getNodeType()) { case Node.TEXT_NODE: // fall-through is intended case Node.CDATA_SECTION_NODE: laidoutText = null; break; case Node.ELEMENT_NODE: { Element childElement = (Element)childNode; if (isTextChild(childElement)) { addContextToChild(ctx, childElement); laidoutText = null; } break; } } if (laidoutText == null) { computeLaidoutText(ctx, e, getTextNode()); } }
/** * Invoked when an MutationEvent of type 'DOMNodeInserted' is fired. */ public void handleDOMNodeInsertedEvent(MutationEvent evt) { Node childNode = (Node)evt.getTarget(); //check the type of the node inserted before discard the layout //in the case of <title> or <desc> or <metadata>, the layout //is unchanged switch(childNode.getNodeType()) { case Node.TEXT_NODE: // fall-through is intended case Node.CDATA_SECTION_NODE: laidoutText = null; break; case Node.ELEMENT_NODE: { Element childElement = (Element)childNode; if (isTextChild(childElement)) { addContextToChild(ctx, childElement); laidoutText = null; } break; } } if (laidoutText == null) { computeLaidoutText(ctx, e, getTextNode()); } }
/** * Invoked when an MutationEvent of type 'DOMNodeInserted' is fired. */ public void handleDOMNodeInsertedEvent(MutationEvent evt) { Node childNode = (Node)evt.getTarget(); //check the type of the node inserted before discard the layout //in the case of <title> or <desc> or <metadata>, the layout //is unchanged switch(childNode.getNodeType()) { case Node.TEXT_NODE: // fall-through is intended case Node.CDATA_SECTION_NODE: laidoutText = null; break; case Node.ELEMENT_NODE: { Element childElement = (Element)childNode; if (isTextChild(childElement)) { addContextToChild(ctx, childElement); laidoutText = null; } break; } } if (laidoutText == null) { computeLaidoutText(ctx, e, getTextNode()); } }
if (!hasNewACI) { hasNewACI = true; computeLaidoutText(ctx, e, getTextNode());
if (!hasNewACI) { hasNewACI = true; computeLaidoutText(ctx, e, getTextNode());
GraphicsNode node) { e.normalize(); computeLaidoutText(ctx, e, node);
GraphicsNode node) { e.normalize(); computeLaidoutText(ctx, e, node);
GraphicsNode node) { e.normalize(); computeLaidoutText(ctx, e, node);