/** * Creates {@link WebPageOutputOptions} used to serve up an HTML 4 page, possibly including * MathML and other XML islands. These islands would normally need further processing before * hitting a browser, so this output is probably not useful on its own. * * <h3>Technical notes</h3> * * The JEuclid process hooks in here. */ public static final WebPageOutputOptions createHTML4Options() { WebPageOutputOptions options = new WebPageOutputOptions(); options.setSerializationMethod(SerializationMethod.HTML); return options; }
/** * Creates {@link WebPageOutputOptions} used to serve up an XHTML page, possibly including * MathML and other XML islands. These islands would normally need further processing before * hitting a browser, so this output is probably not useful on its own. * * <h3>Technical notes</h3> * * The JEuclid process hooks in here. */ public static final WebPageOutputOptions createXHTMLOptions() { WebPageOutputOptions options = new WebPageOutputOptions(); options.setSerializationMethod(SerializationMethod.XHTML); return options; }
/** * Creates {@link WebPageOutputOptions} suitable for creating an XHTML + MathML web page, * using MathJax for cross-browser rendering of the MathML. * <p> * This is one of the most effective web page outputs. * * @see #createHTML5MathJaxOptions() */ public static final WebPageOutputOptions createXHTMLMathJaxOptions() { WebPageOutputOptions options = new WebPageOutputOptions(); options.setSerializationMethod(SerializationMethod.XHTML); options.setIncludingXMLDeclaration(false); options.setMathJax(true); return options; }
/** * Creates {@link WebPageOutputOptions} used to serve up an HTML 5 page, with MathML and any * other XML islands "adopted" into HTML 4 by having their namespace details removed. * <p> * These islands would normally need further processing before * hitting a browser, so this output is probably not useful on its own. * * <h3>Technical notes</h3> * * The JEuclid process hooks in here. */ public static final WebPageOutputOptions createHTML5Options() { WebPageOutputOptions options = new WebPageOutputOptions(); options.setSerializationMethod(SerializationMethod.STRICTLY_HTML); options.setErrorOutputOptions(ErrorOutputOptions.XHTML); options.setHtml5(true); return options; } }
public static final WebPageOutputOptions createUniversalStylesheetOptions(String clientStylesheetUrl, String rendererPreference) { WebPageOutputOptions options = new WebPageOutputOptions(); options.setSerializationMethod(SerializationMethod.XML); options.setIncludingXMLDeclaration(true); options.setMathPrefRenderer(rendererPreference); options.setClientSideXSLTStylesheetURLs(clientStylesheetUrl); return options; }
snuggleOptions = requestedWebOutput ? WebPageOutputOptionsTemplates.createWebPageOptions(webPageType) : new WebPageOutputOptions();
snuggleOptions = requestedWebOutput ? WebPageOutputOptionsTemplates.createWebPageOptions(webPageType) : new WebPageOutputOptions();
/** * Creates {@link WebPageOutputOptions} suitable for deploying solely in a Mozilla-based * browser, such as Firefox, using its native support for MathML. * <p> * This is a niche output kept around for legacy purposes. You should look at some of the * newer HTML5 + MathJax-related options for better compatibility and easier deployment. * * <h3>Technical notes</h3> * * This generates XHTML + MathML; no XML declaration; no DOCTYPE. * <p> * This is intended to be served as <tt>application/xhtml+xml</tt> with * encoding declared via HTTP header and <tt>meta</tt> element. * <p> * This will display as an XML tree on IE, which is not useful. */ public static final WebPageOutputOptions createMozillaSpecificOptions() { WebPageOutputOptions options = new WebPageOutputOptions(); options.setMathJax(false); options.setSerializationMethod(SerializationMethod.XHTML); options.setIncludingXMLDeclaration(false); options.setContentType("application/xhtml+xml"); return options; }
/** * Creates {@link WebPageOutputOptions} suitable for deploying solely in Internet * Explorer having the MathPlayer plug-in installed. * <p> * This is a niche output kept around for legacy purposes. You should look at some of the * newer HTML5 + MathJax-related options for better compatibility and easier deployment. * * <h3>Technical notes</h3> * * Intended to be served as <tt>text/html</tt>, containing prefixed MathML islands. * <p> * This only works on IE clients with the MathPlayer plug-in preinstalled, * but is a good option if that's your target audience. * <p> * This will display wrongly on IE6/7 if MathPlayer is not installed. */ public static final WebPageOutputOptions createIEMathPlayerSpecificOptions() { WebPageOutputOptions options = new WebPageOutputOptions(); options.setSerializationMethod(SerializationMethod.HTML); options.setContentType("text/html"); options.setPrefixingMathML(true); options.setAddingMathPlayerImport(true); return options; }
snuggleOptions = requestedWebOutput ? WebPageOutputOptionsTemplates.createWebPageOptions(webPageType) : new WebPageOutputOptions();
WebPageOutputOptions options = new WebPageOutputOptions(); options.setMathJax(false); options.setSerializationMethod(SerializationMethod.XHTML);
public static WebPageOutputOptions createWebPageOptions(WebPageType webPageType) { ConstraintUtilities.ensureNotNull(webPageType, "webPageType"); WebPageOutputOptions options = new WebPageOutputOptions(); switch (webPageType) { case MOZILLA:
WebPageOutputOptions options = new WebPageOutputOptions(); options.setWebPageType(webPageType); switch (webPageType) {
WebPageOutputOptions options = new WebPageOutputOptions(); options.setWebPageType(webPageType); switch (webPageType) {