gimp_edit_copy(): doesn't behave like docs or 2.10
Possibly this is just a reminder to update the docs.
Reproduction
- Starting fresh GIMP, open wilber.png
- Enlarge the canvas
- Drag out a selection off the layer, but in the canvas, say in lower right, in the checkerboard area.
- In the SF Console (gimp-edit-copy 1 #(2)) meaning copy the selection out of layer with ID 2.
Expected result: SF Console prints (0) meaning boolean result is false.
Actual result: prints (1)
Per the PDB Browser, which says " This procedure will fail if the selected area lies completely outside the bounds of the current drawables and there is nothing to copy from."
BTW, it should say "procedure will return false..." since the procedure can fail harder: the PDB procedure failed to return anything.
You can probably reproduce without using the ScriptFu Console. Choose Edit>Copy. Then Edit>Paste should remain disabled i.e. greyed out because the copy failed to put anything on the clipboard? But its not disabled, and if e.g. you choose Edit>PasteAs>NewImage you get a new image that seems devoid of pixels.
Additional information
Behaves differently in 2.10, similar steps do print (0).
If the change in behavior is intended, the annotations for the PDB procedure need updating. Otherwise, a bug.