public int getFontSizeComplexUnit() {
        if (fontSizeUnit == null) {
            return TypedValue.COMPLEX_UNIT_DIP;
        }
        switch (fontSizeUnit) {
            case PX:
                return TypedValue.COMPLEX_UNIT_PX;
            case SP:
                return TypedValue.COMPLEX_UNIT_SP;
            default:
                return TypedValue.COMPLEX_UNIT_DIP;
        }
    }
Author: @Kongzue
Github: https://github.com/kongzue/
Homepage: http://kongzue.com/
Mail: myzcxhh@live.cn
CreateTime: 2018/11/10 22:01
DialogX/src/main/java/com/kongzue/dialogx/util/TextInfo.java