Skip to main content
Participating Frequently
June 16, 2015
Open for Voting

P: Quick Export option to disable transparency trimming

  • June 16, 2015
  • 35 replies
  • 4765 views

There should be an option to disable the automatic trimming of exported elements to their transparency.
The trimming makes it problematic to easily place the exported elements in other softwares, e.g. 3D and compositing.

35 replies

Stephen Marsh
Community Expert
Community Expert
June 13, 2025
quote

yes plenty of workarounds, scripts, hidden geometry, hidden masks, actions, plug-ins etc. That is not really the point. JUST FIX the feature  so it can be used by, I guess, the majority of people. Little option ON/OFF. That is all we need.... 

at least an acknowledgement from Adobe that we have been heard...


By @Brad5E0E 

 

This idea/feature request has been open for 10 years.

 

So the point is that if you want something now (or a decade ago), there are alternatives to waiting.

Known Participant
June 12, 2025

yes plenty of workarounds, scripts, hidden geometry, hidden masks, actions, plug-ins etc. That is not really the point. JUST FIX the feature  so it can be used by, I guess, the majority of people. Little option ON/OFF. That is all we need.... 

at least an acknowledgement from Adobe that we have been heard...

Stephen Marsh
Community Expert
Community Expert
June 12, 2025
quote

but the Quick Export is great for a single layer and you get the layer name also. I would be my primary PNG save almost EVERY TIME except it is... alas... not... because it remains broken


By @Brad5E0E 

 

This would currently require a script as a workaround, which could be triggered via a custom keyboard shortcut.

Known Participant
June 12, 2025

10 years and still no option? Really. smh.

All the workarounds and other ways to save are fine, but the Quick Export is great for a single layer and you get the layer name also. It would be my primary PNG save almost EVERY TIME except it is... alas... not... because it remains broken. Did I mention 10 years we have been asking for about 10 lines of code to be added to PREFS.

 

Participant
February 6, 2023

Another workaround is using File>Generate>Image Assets and maintaining your layer structure like this:

 

 

Here I used canvas size masks on the groups with .png extensions. Just ctrl+A and add mask to group.

Here is the result. Images will be generated automatically.

 

It is faster than quick export for my workflow setup correctly.

 

I can explain better if it is not understandable.

Stephen Marsh
Community Expert
Community Expert
March 1, 2022
quote

I've spend several hours last night adding almost invisible pixels to layers just to make sure they don't get cropped upon export.

 

@Pulvertoastmann 

 

This can be automated via an action or a script:

 

/*
Transparency Bounding Pixels.jsx
Stephen Marsh
Version 1, 22nd September 2021
Adds a 1% white pixel to the upper left and lower right corners of the open document
Note: Assumes that the active layer is a raster layer can be filled!

https://community.adobe.com/t5/photoshop-ecosystem-discussions/export-as-now-crops-to-contents-instead-of-using-the-mask/td-p/12336888
Export As now crops to contents instead of using the mask
*/

#target photoshop

if (documents.length) {

    // Main script
    function main() {
        var origRuler = app.preferences.rulerUnits;
        app.preferences.rulerUnits = Units.PIXELS;

        var docWidth = app.activeDocument.width.value;
        var docHeight = app.activeDocument.height.value;

        setSelection(0, 0, 1, 1);
        whiteFill(1.000000);
        app.activeDocument.selection.deselect();

        setSelection(docHeight - 1, docWidth - 1, docHeight, docWidth);
        whiteFill(1.000000);
        app.activeDocument.selection.deselect();

        app.preferences.rulerUnits = origRuler;
    }

    app.activeDocument.suspendHistory("Run script", "main()");


    /*********** Functions ***********/

    function setSelection(top, left, bottom, right) {
        var s2t = function (s) {
            return app.stringIDToTypeID(s);
        };
        var descriptor = new ActionDescriptor();
        var descriptor2 = new ActionDescriptor();
        var reference = new ActionReference();
        reference.putProperty(s2t("channel"), s2t("selection"));
        descriptor.putReference(s2t("null"), reference);
        descriptor2.putUnitDouble(s2t("top"), s2t("pixelsUnit"), top);
        descriptor2.putUnitDouble(s2t("left"), s2t("pixelsUnit"), left);
        descriptor2.putUnitDouble(s2t("bottom"), s2t("pixelsUnit"), bottom);
        descriptor2.putUnitDouble(s2t("right"), s2t("pixelsUnit"), right);
        descriptor.putObject(s2t("to"), s2t("rectangle"), descriptor2);
        executeAction(s2t("set"), descriptor, DialogModes.NO);
    }

    function whiteFill(fillOpacity) {
        var idfill = stringIDToTypeID("fill");
        var desc279 = new ActionDescriptor();
        var idusing = stringIDToTypeID("using");
        var idfillContents = stringIDToTypeID("fillContents");
        var idwhite = stringIDToTypeID("white");
        desc279.putEnumerated(idusing, idfillContents, idwhite);
        var idopacity = stringIDToTypeID("opacity");
        var idpercentUnit = stringIDToTypeID("percentUnit");
        desc279.putUnitDouble(idopacity, idpercentUnit, fillOpacity);
        var idmode = stringIDToTypeID("mode");
        var idblendMode = stringIDToTypeID("blendMode");
        var idnormal = stringIDToTypeID("normal");
        desc279.putEnumerated(idmode, idblendMode, idnormal);
        executeAction(idfill, desc279, DialogModes.NO);
    }

} else {
    alert('There are no documents open.');
}
Daniel Racca
Participant
March 1, 2022

I agree! We need this feature!!

Pulvertoastmann
Participant
February 22, 2022

I've spend several hours last night adding almost invisible pixels to layers just to make sure they don't get cropped upon export. The layer-mask hack didn't work anymore (although it DID work for me in the past, apparently they "fixed" that in a recent update).

 

Adobe, isn't Photoshop meant to be THE tool for professionals anymore? The gold standard? Why do you make people beg for years for the most basic features to work the way one would expect them to work? Why do you keep on including useless "content aware" toys instead of fixing the tools we're using to get the actual work done?

miascugh
Inspiring
December 8, 2021

+1
I agree that this feature missing is not so much just one less nice-to-have, as a crucial omission.

Inspiring
September 25, 2019
How... how is this a thing that hasn't been solved yet?  There are more workflows that WOULDN'T want this feature than WOULD --- and besides, if you want to trim, it's a single click to do it manually!

(In the meantime, the legacy Save to Web seems to preserve canvas size and position.)