After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 759194 - Unified Transform Tool fails when layer is hidden
Unified Transform Tool fails when layer is hidden
Status: RESOLVED FIXED
Product: GIMP
Classification: Other
Component: Tools
2.9.2
Other All
: Normal normal
: 2.10
Assigned To: GIMP Bugs
GIMP Bugs
Depends on:
Blocks:
 
 
Reported: 2015-12-08 17:26 UTC by C.M.Rogers
Modified: 2018-06-10 11:28 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description C.M.Rogers 2015-12-08 17:26:19 UTC
In 2.8 it was possible to hide the layer you are transforming (with perspective tool) to get the original out of the way during transform.

In 2.9 you can still hide the layer after transform has begun, but the transform will fail unless the layer is unhidden before applying the transform (it fails silently).

Steps to reproduce:
1. Make selection with rectangle (or other) selection tool.
2. Switch to Unified Transform Tool (or Perspective tool, which fails in the same way)
3. Click to begin transform, then hide the layer (removes untransformed original so you can see what you are doing).
4. Move control corners to perspective transform the layer as you would normally.
5. Hit the Enter key or otherwise apply the transformation.

The transformation fails silently, and you must begin again.

The only solution is to remember to un-hide the layer before applying the transformation.

Proposed solutions:
A. Make the original hide automatically, making it unnecessary to hide the layer during transform.
B. Make sure the transformation is applied, regardless of the hidden state of the layer.
Comment 1 peci1 2015-12-08 22:24:31 UTC
Might be related to 759212 ?
Comment 2 C.M.Rogers 2015-12-09 07:40:59 UTC
(In reply to peci1 from comment #1)
> Might be related to 759212 ?

Not sure, but just to note, this breaks even when the layers are not grouped.
Comment 3 Michael Natterer 2016-01-04 18:40:20 UTC
We suck at the transform preview, so why not add a hack here, this
is a legit use case...

commit 37de341099b7ac1efbf3fac8bfe28911c91d7b7e
Author: Michael Natterer <mitch@gimp.org>
Date:   Mon Jan 4 19:37:14 2016 +0100

    Bug 759194 - Unified Transform Tool fails when layer is hidden
    
    For the lack of a proper transform preview, add a HACK that allows to
    make the transformed layer invisible while the tool is active.

 app/tools/gimptransformtool.c | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)
Comment 4 Ell 2018-06-10 11:28:36 UTC
Re-broke and re-fixed in master:

commit cea6f1dc7308fac233d34af1a194aa7f3172f1ac
Author: Ell <ell_se@yahoo.com>
Date:   Sun Jun 10 07:22:52 2018 -0400

    Bug 759194 - Unified Transform Tool fails when layer is hidden
    
    Last commit reintroduced this bug.
    
    Allow transforming invisible layers using transform-grid tools, by
    adding a 'drawable' member to GimpTransformTool, and setting/
    clearing it when initializing/halting a GimpTransformTool.  In
    gimp_transform_tool_check_active_item(), skip the visibility check
    if the active item equals the GimpTransformTool's 'drawable'
    member.

 app/tools/gimptransformgridtool.c | 20 ++++++++++----------
 app/tools/gimptransformtool.c     |  3 ++-
 app/tools/gimptransformtool.h     |  2 ++
 3 files changed, 14 insertions(+), 11 deletions(-)

and gimp-2-10:

commit 341077e23a4ca54f8476f45a5ef6f6a32499f1c5
Author: Ell <ell_se@yahoo.com>
Date:   Sun Jun 10 07:22:52 2018 -0400

    Bug 759194 - Unified Transform Tool fails when layer is hidden
    
    Last commit reintroduced this bug.
    
    Allow transforming invisible layers using transform-grid tools, by
    adding a 'drawable' member to GimpTransformTool, and setting/
    clearing it when initializing/halting a GimpTransformTool.  In
    gimp_transform_tool_check_active_item(), skip the visibility check
    if the active item equals the GimpTransformTool's 'drawable'
    member.
    
    (cherry picked from commit cea6f1dc7308fac233d34af1a194aa7f3172f1ac)

 app/tools/gimptransformgridtool.c | 20 ++++++++++----------
 app/tools/gimptransformtool.c     |  3 ++-
 app/tools/gimptransformtool.h     |  2 ++
 3 files changed, 14 insertions(+), 11 deletions(-)