Class DefaultCssResolver

java.lang.Object
com.itextpdf.html2pdf.css.resolve.DefaultCssResolver
All Implemented Interfaces:
com.itextpdf.styledxmlparser.css.ICssResolver

public class DefaultCssResolver extends Object implements com.itextpdf.styledxmlparser.css.ICssResolver
Default implementation of the ICssResolver interface.
  • Constructor Details

    • DefaultCssResolver

      public DefaultCssResolver (com.itextpdf.styledxmlparser.node.INode treeRoot, com.itextpdf.styledxmlparser.css.media.MediaDeviceDescription mediaDeviceDescription, com.itextpdf.styledxmlparser.resolver.resource.ResourceResolver resourceResolver)
      Creates a new DefaultCssResolver instance.
      Parameters:
      treeRoot - the root node
      mediaDeviceDescription - the media device description
      resourceResolver - the resource resolver
    • DefaultCssResolver

      public DefaultCssResolver (com.itextpdf.styledxmlparser.node.INode treeRoot, ProcessorContext context)
      Creates a new DefaultCssResolver instance.
      Parameters:
      treeRoot - the root node
      context - the processor context
  • Method Details

    • getFonts

      public List getFonts()
      Gets the list of fonts.
      Returns:
      the list of CssFontFaceRule instances
    • resolveContentAndCountersStyles

      public void resolveContentAndCountersStyles (com.itextpdf.styledxmlparser.node.INode node, CssContext context)
      Resolves content and counter(s) styles of a node given the passed context.
      Parameters:
      node - the node
      context - the CSS context (RootFontSize, etc.)
    • resolveStyles

      public Map<String,String> resolveStyles (com.itextpdf.styledxmlparser.node.INode element, com.itextpdf.styledxmlparser.css.resolve.AbstractCssContext context)
      Specified by:
      resolveStyles in interface com.itextpdf.styledxmlparser.css.ICssResolver