Skip to content
  • Jehan's avatar
    app: salvage loaded group and text layer of dimension 0. · 465bedf6
    Jehan authored
    Whereas normal layers of dimension 0x0 are definitely broken, group and
    text layers depend on their contents, which will be able to resize the
    layer appropriately and fix whatever rendering. This commit allows to
    salvage such layers, hence make XCF loading even more resistant to
    certain form of file corruption.
    
    This commit (and the previous one) are not theoretical but the result of
    discovering some old corrupted file, with an empty group of size 0x0
    (saved by GIMP itself, because of some old bug). Rather than destroying
    these layer groups, this just allows us to reopen them without any kind
    of loss!
    
    (cherry picked from commit 06be0746)
    465bedf6