RSS/Atom feed Twitter
Site is read-only, email is disabled

Autocrop Buggy

This discussion is connected to the gimp-user-list.gnome.org mailing list which is provided by the GIMP developers and not related to gimpusers.com.

This is a read-only list on gimpusers.com so this discussion thread is read-only, too.

4 of 4 messages available
Toggle history

Please log in to manage your subscriptions.

Autocrop Buggy FierySwordswoman 31 Oct 07:34
  Autocrop Buggy Ofnuts 01 Nov 11:30
   Autocrop Buggy Ofnuts 01 Nov 18:43
    Autocrop Buggy FierySwordswoman 01 Nov 23:02
FierySwordswoman
2016-10-31 07:34:53 UTC (about 8 years ago)

Autocrop Buggy

Straight to the point. The Autocrop layer function is weird. Take something simple

for X in image.layers:
pdb.plug_in_autocrop_layer(image, X)

and it still doesn't work, giving a variety of strange bugs. Why?

Ofnuts
2016-11-01 11:30:53 UTC (about 8 years ago)

Autocrop Buggy

On 31/10/16 08:34, FierySwordswoman wrote:

Straight to the point. The Autocrop layer function is weird. Take something simple

for X in image.layers:
pdb.plug_in_autocrop_layer(image, X)

and it still doesn't work, giving a variety of strange bugs. Why?

Looks like a bug in plugin-autocrop-layer. It crops the active layer using the crop coordinates computed on the target layer. Just reported it on bugzilla.gnome.org: https://bugzilla.gnome.org/show_bug.cgi?id=773774

Ofnuts
2016-11-01 18:43:46 UTC (about 8 years ago)

Autocrop Buggy

On 01/11/16 12:30, Ofnuts wrote:

On 31/10/16 08:34, FierySwordswoman wrote:

Straight to the point. The Autocrop layer function is weird. Take something simple

for X in image.layers:
pdb.plug_in_autocrop_layer(image, X)

and it still doesn't work, giving a variety of strange bugs. Why?

Looks like a bug in plugin-autocrop-layer. It crops the active layer using the crop coordinates computed on the target layer. Just reported it on bugzilla.gnome.org:
https://bugzilla.gnome.org/show_bug.cgi?id=773774

And the reply is.... working as designed (devs admit it's brain dead, though :) So just change your code to do

saveActive=image.active_layer for X in image.layers:
image.active_layer=X
pdb.plug_in_autocrop_layer(image, X) image.active_layer=saveActive

FierySwordswoman
2016-11-01 23:02:57 UTC (about 8 years ago)

Autocrop Buggy

That's.... really weird.
You'd think they'd just make it take a 3rd argument if that was the functionality they wanted - (Image, source layer, target layer)