String hmm = value.substring( value.length() - 3 ); if ( "pt".equals( hmm ) ) {
String hmm = value.substring(value.length() - 2); if ("pt".equals(hmm)) {
    private static short guessType( String value ) {        short type = CSS_STRING;        if ( value != null && value.length() > 1 ) {            if ( value.endsWith( "%" ) ) {                type = CSS_PERCENTAGE;            } else if ( value.startsWith( "rgb" ) || value.startsWith( "#" ) ) {                type = CSS_RGBCOLOR;            } else {                String hmm = value.substring( value.length() - 3 );                if ( "pt".equals( hmm ) ) {                    type = CSS_PT;                } else if ( "px".equals( hmm ) ) {                    type = CSS_PX;                } else if ( "em".equals( hmm ) ) {                    type = CSS_EMS;                } else if ( "ex".equals( hmm ) ) {                    type = CSS_EXS;                } else if ( "in".equals( hmm ) ) {                    type = CSS_IN;                } else if ( "cm".equals( hmm ) ) {                    type = CSS_CM;                } else if ( "mm".equals( hmm ) ) {                    type = CSS_MM;                } else {                    try {                        new Float( value );                        type = CSS_NUMBER;                    } catch ( NumberFormatException ex ) {                        type = CSS_STRING;                    }                }            }        }        return type;    }