/** * @param e */ protected Element getParentForm(Element e, LayoutContext context) { Node node = e; do { node = node.getParentNode(); } while (node.getNodeType() == Node.ELEMENT_NODE && !context.getNamespaceHandler().isFormElement((Element) node)); if (node.getNodeType() != Node.ELEMENT_NODE) { return null; } return (Element) node; }
/** * @param e */ protected Element getParentForm(Element e, LayoutContext context) { Node node = e; do { node = node.getParentNode(); } while (node.getNodeType() == Node.ELEMENT_NODE && !context.getNamespaceHandler().isFormElement((Element) node)); if (node.getNodeType() != Node.ELEMENT_NODE) { return null; } return (Element) node; }
/** * @param e */ protected Element getParentForm(Element e, LayoutContext context) { Node node = e; XhtmlNamespaceHandler nsh = (XhtmlNamespaceHandler) context .getNamespaceHandler(); do { node = node.getParentNode(); } while (node.getNodeType() == Node.ELEMENT_NODE && !nsh.isFormElement((Element) node)); if (node.getNodeType() != Node.ELEMENT_NODE) { return null; } return (Element) node; }
public ReplacedElement createReplacedElement(LayoutContext c, BlockBox box, UserAgentCallback uac, int cssWidth, int cssHeight) { Element e = box.getElement(); if (e == null) { return null; } // images if (c.getNamespaceHandler().isImageElement(e)) { return replaceImage(uac, c, e, cssWidth, cssHeight); } return null; }
private void addBoxID(LayoutContext c) { if (! isAnonymous()) { String name = c.getNamespaceHandler().getAnchorName(getElement()); if (name != null) { c.addBoxId(name, this); } String id = c.getNamespaceHandler().getID(getElement()); if (id != null) { c.addBoxId(id, this); } } }
private void addBoxID(LayoutContext c) { if (! isAnonymous()) { String name = c.getNamespaceHandler().getAnchorName(getElement()); if (name != null) { c.addBoxId(name, this); } String id = c.getNamespaceHandler().getID(getElement()); if (id != null) { c.addBoxId(id, this); } } }
if (images.getLength() > 0) { Element img = (Element) images.item(0); String uri = c.getNamespaceHandler().getImageSourceURI(img); ImageResource res = uac.getImageResource(uri); SWTFSImage fsi = (SWTFSImage) res.getImage();
public void reset(LayoutContext c) { resetChildren(c); if (_layer != null) { _layer.detach(); _layer = null; } setContainingLayer(null); setLayer(null); setPaintingInfo(null); setContentWidth(0); _workingMargin = null; String anchorName = c.getNamespaceHandler().getAnchorName(getElement()); if (anchorName != null) { c.removeBoxId(anchorName); } Element e = getElement(); if (e != null) { String id = c.getNamespaceHandler().getID(e); if (id != null) { c.removeBoxId(id); } } }
public void reset(LayoutContext c) { resetChildren(c); if (_layer != null) { _layer.detach(); _layer = null; } setContainingLayer(null); setLayer(null); setPaintingInfo(null); setContentWidth(0); _workingMargin = null; String anchorName = c.getNamespaceHandler().getAnchorName(getElement()); if (anchorName != null) { c.removeBoxId(anchorName); } Element e = getElement(); if (e != null) { String id = c.getNamespaceHandler().getID(e); if (id != null) { c.removeBoxId(id); } } }
cssHeight); if (re == null && c.getNamespaceHandler() instanceof XhtmlNamespaceHandler && !c.isPrint()) { XhtmlNamespaceHandler nsh = (XhtmlNamespaceHandler) c .getNamespaceHandler(); Element e = box.getElement(); if (e == null) {
if (re == null) { Image im = null; String imageSrc = context.getNamespaceHandler().getImageSourceURI(elem); if (imageSrc == null || imageSrc.length() == 0) { XRLog.layout(Level.WARNING, "No source provided for img element.");
String imageSrc = context.getNamespaceHandler().getImageSourceURI(elem); String ruri = uac.resolveURI(imageSrc); re = lookupImageReplacedElement(elem, ruri, cssWidth, cssHeight);
if (context.getNamespaceHandler().isImageElement(e)) { return replaceImage(uac, context, e, cssWidth, cssHeight); } else {
String imageSrc = context.getNamespaceHandler().getImageSourceURI( elem); if (imageSrc == null || imageSrc.length() == 0) {
if (context.getNamespaceHandler().isImageElement(e)) { return replaceImage(uac, context, e, cssWidth, cssHeight); } else {
String name = c.getNamespaceHandler().getAnchorName(currentIB.getElement()); if (name != null) { c.addBoxId(name, currentIB); String id = c.getNamespaceHandler().getID(currentIB.getElement()); if (id != null) { c.addBoxId(id, currentIB);
String name = c.getNamespaceHandler().getAnchorName(currentIB.getElement()); if (name != null) { c.addBoxId(name, currentIB); String id = c.getNamespaceHandler().getID(currentIB.getElement()); if (id != null) { c.addBoxId(id, currentIB);