Class WidthCalculator


  • public class WidthCalculator
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private CssUtils utils  
    • Constructor Summary

      Constructors 
      Constructor Description
      WidthCalculator()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      float getWidth​(Tag tag, java.util.List<java.lang.String> roottags, float pagewidth)
      Tries to calculate a width from a tag and it's ancestors.
      float getWidth​(Tag tag, java.util.List<java.lang.String> roottags, float pagewidth, float initialTotalWidth)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

    • Constructor Detail

      • WidthCalculator

        public WidthCalculator()
    • Method Detail

      • getWidth

        public float getWidth​(Tag tag,
                              java.util.List<java.lang.String> roottags,
                              float pagewidth)
        Tries to calculate a width from a tag and it's ancestors.
        Parameters:
        tag - the tag to use
        roottags - the root tags,
        pagewidth - the page width
        Returns:
        the width
      • getWidth

        public float getWidth​(Tag tag,
                              java.util.List<java.lang.String> roottags,
                              float pagewidth,
                              float initialTotalWidth)