• Jehan's avatar
    libgimpbase: return 0 for GIMP_UNIT_PIXEL in gimp_unit_get_factor(). · f705bfb3
    Jehan authored
    Just as documented, pixel unit should always return factor 0. There is
    no need to call _gimp_unit_vtable.unit_get_factor().
    This is even more important as there is one implementation of
    unit_get_factor() in core, and another in libgimp and the one in libgimp
    is expecting unit to always be >= GIMP_UNIT_INCH. So we were getting
    CRITICALs in libgimp when calling gimp_unit_get_factor() on pixel unit
    (for instance when drawing a GimpRuler).
gimpunit.c 19.3 KB