@Override public HtmlWriter tag(CharSequence tagName, boolean voidElement) { if (useAttributes != null) { final Attributes attributes = context.extendRenderingNodeAttributes(useAttributes, getAttributes()); String sourcePositionAttribute = context.getHtmlOptions().sourcePositionAttribute; String attributeValue = attributes.getValue(sourcePositionAttribute);
@Override public void render(TextBase node, NodeRendererContext context, HtmlWriter html) { if (myOptions.assignTextAttributes) { final Attributes nodeAttributes = context.extendRenderingNodeAttributes(AttributablePart.NODE, null); if (!nodeAttributes.isEmpty()) { // has attributes then we wrap it in a span html.setAttributes(nodeAttributes).withAttr().tag("span"); context.delegateRender(); html.closeTag("span"); return; } } context.delegateRender(); } }));
private void render(Image node, NodeRendererContext context, final HtmlWriter html) { if (!(context.isDoNotRenderLinks() || CoreNodeRenderer.isSuppressedLinkPrefix(node.getUrl(), context))) { final String altText = new TextCollectingVisitor().collectAndGetText(node); ResolvedLink resolvedLink = context.resolveLink(LinkType.IMAGE, node.getUrl().unescape(), null, null); final String url = resolvedLink.getUrl(); if (node.getUrlContent().isEmpty()) { Attributes attributes = resolvedLink.getNonNullAttributes(); // need to take attributes for reference definition, then overlay them with ours attributes = context.extendRenderingNodeAttributes(node, AttributablePart.NODE, attributes); if (renderVideoImage(node, url, altText, attributes, html)) { return; } } context.delegateRender(); } }
@Override public HtmlWriter tag(CharSequence tagName, boolean voidElement) { if (useAttributes != null) { final Attributes attributes = context.extendRenderingNodeAttributes(useAttributes, getAttributes()); String sourcePositionAttribute = context.getHtmlOptions().sourcePositionAttribute; String attributeValue = attributes.getValue(sourcePositionAttribute);
attributes = context.extendRenderingNodeAttributes(reference, AttributablePart.NODE, attributes);
attributes = context.extendRenderingNodeAttributes(reference, AttributablePart.NODE, attributes);
@Override public void render(TextBase node, NodeRendererContext context, HtmlWriter html) { if (myOptions.assignTextAttributes) { final Attributes nodeAttributes = context.extendRenderingNodeAttributes(AttributablePart.NODE, null); if (!nodeAttributes.isEmpty()) { // has attributes then we wrap it in a span html.setAttributes(nodeAttributes).withAttr().tag("span"); context.delegateRender(); html.closeTag("span"); return; } } context.delegateRender(); } }));
attributes = context.extendRenderingNodeAttributes(reference, AttributablePart.NODE, attributes);
attributes = context.extendRenderingNodeAttributes(reference, AttributablePart.NODE, attributes);