/** * Returns the URI of the referenced stylesheet. */ public String getStyleSheetURI() { SVGOMDocument svgDoc = (SVGOMDocument) getOwnerDocument(); ParsedURL url = svgDoc.getParsedURL(); String href = getPseudoAttributes().get("href"); if (url != null) { return new ParsedURL(url, href).toString(); } return href; }
/** * Returns the URI of the referenced stylesheet. */ public String getStyleSheetURI() { SVGOMDocument svgDoc = (SVGOMDocument) getOwnerDocument(); ParsedURL url = svgDoc.getParsedURL(); String href = (String)getPseudoAttributes().get("href"); if (url != null) { return new ParsedURL(url, href).toString(); } return href; }
/** * Returns the associated style-sheet. */ public StyleSheet getCSSStyleSheet() { if (styleSheet == null) { HashMap<String, String> attrs = getPseudoAttributes(); String type = attrs.get("type"); if ("text/css".equals(type)) { String title = attrs.get("title"); String media = attrs.get("media"); String href = attrs.get("href"); String alternate = attrs.get("alternate"); SVGOMDocument doc = (SVGOMDocument)getOwnerDocument(); ParsedURL durl = doc.getParsedURL(); ParsedURL burl = new ParsedURL(durl, href); CSSEngine e = doc.getCSSEngine(); styleSheet = e.parseStyleSheet(burl, media); styleSheet.setAlternate("yes".equals(alternate)); styleSheet.setTitle(title); } } return styleSheet; }
/** * Returns the associated style-sheet. */ public StyleSheet getCSSStyleSheet() { if (styleSheet == null) { HashMap<String, String> attrs = getPseudoAttributes(); String type = attrs.get("type"); if ("text/css".equals(type)) { String title = attrs.get("title"); String media = attrs.get("media"); String href = attrs.get("href"); String alternate = attrs.get("alternate"); SVGOMDocument doc = (SVGOMDocument)getOwnerDocument(); ParsedURL durl = doc.getParsedURL(); ParsedURL burl = new ParsedURL(durl, href); CSSEngine e = doc.getCSSEngine(); styleSheet = e.parseStyleSheet(burl, media); styleSheet.setAlternate("yes".equals(alternate)); styleSheet.setTitle(title); } } return styleSheet; }
public void run() { try { ParsedURL burl; burl = ((SVGOMDocument)document).getParsedURL(); final ParsedURL purl = new ParsedURL(burl, uri); String e = null;
public CSSEngine createCSSEngine(AbstractStylableDocument doc, CSSContext ctx, ExtendedParser ep, ValueManager [] vms, ShorthandManager [] sms) { ParsedURL durl = ((SVGOMDocument)doc).getParsedURL(); CSSEngine result = new SVGCSSEngine(doc, durl, ep, vms, sms, ctx); URL url = getClass().getResource("resources/UserAgentStyleSheet.css"); if (url != null) { ParsedURL purl = new ParsedURL(url); InputSource is = new InputSource(purl.toString()); result.setUserAgentStyleSheet (result.parseStyleSheet(is, purl, "all")); } return result; }
public void run() { try { ParsedURL burl; burl = ((SVGOMDocument)document).getParsedURL(); final ParsedURL purl = new ParsedURL(burl, uri); String e = null;
public CSSEngine createCSSEngine(AbstractStylableDocument doc, CSSContext ctx, ExtendedParser ep, ValueManager [] vms, ShorthandManager [] sms) { ParsedURL durl = ((SVGOMDocument)doc).getParsedURL(); CSSEngine result = new SVGCSSEngine(doc, durl, ep, vms, sms, ctx); URL url = getClass().getResource("resources/UserAgentStyleSheet.css"); if (url != null) { ParsedURL purl = new ParsedURL(url); InputSource is = new InputSource(purl.toString()); result.setUserAgentStyleSheet (result.parseStyleSheet(is, purl, "all")); } return result; }
public CSSEngine createCSSEngine(AbstractStylableDocument doc, CSSContext ctx, ExtendedParser ep, ValueManager [] vms, ShorthandManager [] sms) { ParsedURL durl = ((SVGOMDocument)doc).getParsedURL(); CSSEngine result = new SVG12CSSEngine(doc, durl, ep, vms, sms, ctx); URL url = getClass().getResource("resources/UserAgentStyleSheet.css"); if (url != null) { ParsedURL purl = new ParsedURL(url); InputSource is = new InputSource(purl.toString()); result.setUserAgentStyleSheet (result.parseStyleSheet(is, purl, "all")); } return result; }
public void run() { try { ParsedURL burl; burl = ((SVGOMDocument)document).getParsedURL(); final ParsedURL purl = new ParsedURL(burl, uri); String e = null;
public CSSEngine createCSSEngine(AbstractStylableDocument doc, CSSContext ctx, ExtendedParser ep, ValueManager [] vms, ShorthandManager [] sms) { ParsedURL durl = ((SVGOMDocument)doc).getParsedURL(); CSSEngine result = new SVGCSSEngine(doc, durl, ep, vms, sms, ctx); URL url = getClass().getResource("resources/UserAgentStyleSheet.css"); if (url != null) { ParsedURL purl = new ParsedURL(url); InputSource is = new InputSource(purl.toString()); result.setUserAgentStyleSheet (result.parseStyleSheet(is, purl, "all")); } return result; }
public CSSEngine createCSSEngine(AbstractStylableDocument doc, CSSContext ctx, ExtendedParser ep, ValueManager [] vms, ShorthandManager [] sms) { ParsedURL durl = ((SVGOMDocument)doc).getParsedURL(); CSSEngine result = new SVG12CSSEngine(doc, durl, ep, vms, sms, ctx); URL url = getClass().getResource("resources/UserAgentStyleSheet.css"); if (url != null) { ParsedURL purl = new ParsedURL(url); InputSource is = new InputSource(purl.toString()); result.setUserAgentStyleSheet (result.parseStyleSheet(is, purl, "all")); } return result; }
public CSSEngine createCSSEngine(AbstractStylableDocument doc, CSSContext ctx, ExtendedParser ep, ValueManager [] vms, ShorthandManager [] sms) { ParsedURL durl = ((SVGOMDocument)doc).getParsedURL(); CSSEngine result = new SVG12CSSEngine(doc, durl, ep, vms, sms, ctx); URL url = getClass().getResource("resources/UserAgentStyleSheet.css"); if (url != null) { ParsedURL purl = new ParsedURL(url); InputSource is = new InputSource(purl.toString()); result.setUserAgentStyleSheet (result.parseStyleSheet(is, purl, "all")); } return result; }
/** * Returns the URI of the referenced stylesheet. */ public String getStyleSheetURI() { SVGOMDocument svgDoc = (SVGOMDocument) getOwnerDocument(); ParsedURL url = svgDoc.getParsedURL(); String href = (String)getPseudoAttributes().get("href"); if (url != null) { return new ParsedURL(url, href).toString(); } return href; }
/** * Returns the associated style-sheet. */ public StyleSheet getCSSStyleSheet() { if (styleSheet == null) { HashTable attrs = getPseudoAttributes(); String type = (String)attrs.get("type"); if ("text/css".equals(type)) { String title = (String)attrs.get("title"); String media = (String)attrs.get("media"); String href = (String)attrs.get("href"); String alternate = (String)attrs.get("alternate"); SVGOMDocument doc = (SVGOMDocument)getOwnerDocument(); ParsedURL durl = doc.getParsedURL(); ParsedURL burl = new ParsedURL(durl, href); CSSEngine e = doc.getCSSEngine(); styleSheet = e.parseStyleSheet(burl, media); styleSheet.setAlternate("yes".equals(alternate)); styleSheet.setTitle(title); } } return styleSheet; }
public void run() { userAgent.setSVGCursor(holder.getCursor()); String href = elt.getHref().getAnimVal(); ParsedURL purl = new ParsedURL(elt.getBaseURI(), href); SVGOMDocument doc = (SVGOMDocument) elt.getOwnerDocument(); ParsedURL durl = doc.getParsedURL(); if (purl.sameFile(durl)) { String frag = purl.getRef(); if (frag != null && frag.length() != 0) { Element refElt = doc.getElementById(frag); if (refElt instanceof SVGOMAnimationElement) { SVGOMAnimationElement aelt = (SVGOMAnimationElement) refElt; float t = aelt.getHyperlinkBeginTime(); if (Float.isNaN(t)) { aelt.beginElement(); } else { doc.getRootElement().setCurrentTime(t); } return; } } } userAgent.openLink(elt); } }
public void run() { userAgent.setSVGCursor(holder.getCursor()); String href = elt.getHref().getAnimVal(); ParsedURL purl = new ParsedURL(elt.getBaseURI(), href); SVGOMDocument doc = (SVGOMDocument) elt.getOwnerDocument(); ParsedURL durl = doc.getParsedURL(); if (purl.sameFile(durl)) { String frag = purl.getRef(); if (frag != null && frag.length() != 0) { Element refElt = doc.getElementById(frag); if (refElt instanceof SVGOMAnimationElement) { SVGOMAnimationElement aelt = (SVGOMAnimationElement) refElt; float t = aelt.getHyperlinkBeginTime(); if (Float.isNaN(t)) { aelt.beginElement(); } else { doc.getRootElement().setCurrentTime(t); } return; } } } userAgent.openLink(elt); } }
public void run() { userAgent.setSVGCursor(holder.getCursor()); String href = elt.getHref().getAnimVal(); ParsedURL purl = new ParsedURL(elt.getBaseURI(), href); SVGOMDocument doc = (SVGOMDocument) elt.getOwnerDocument(); ParsedURL durl = doc.getParsedURL(); if (purl.sameFile(durl)) { String frag = purl.getRef(); if (frag != null && frag.length() != 0) { Element refElt = doc.getElementById(frag); if (refElt instanceof SVGOMAnimationElement) { SVGOMAnimationElement aelt = (SVGOMAnimationElement) refElt; float t = aelt.getHyperlinkBeginTime(); if (Float.isNaN(t)) { aelt.beginElement(); } else { doc.getRootElement().setCurrentTime(t); } return; } } } userAgent.openLink(elt); } }