code: protected Float dpiResolution(TermResolution spec)
      {
          float nval = spec.getValue();
          TermLength.Unit unit = spec.getUnit();
          
          switch (unit)
          {
              case dpi:
                  return nval;
              case dpcm:
                  return nval * 2.54f;
              case dppx:
                  return nval * getResolution();
              default:
                  return null;
          }
      }
docs: Converts a resolution from a CSS length to 'dpi'.
  @param spec the CSS resolution specification
  @return the resolution in 'dpi' or {@code null} when the unit is invalid