/t5/photoshop-ecosystem-ideas/p-quick-export-option-to-disable-transparency-trimming/idi-p/12249025Jun 16, 2015
Jun 16, 2015
Copy link to clipboard
Copied
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.
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.)
/t5/photoshop-ecosystem-ideas/p-quick-export-option-to-disable-transparency-trimming/idc-p/12768525#M13306Feb 21, 2022
Feb 21, 2022
Copy link to clipboard
Copied
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?
/*
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.');
}
/t5/photoshop-ecosystem-ideas/p-quick-export-option-to-disable-transparency-trimming/idc-p/15367993#M25654Jun 12, 2025
Jun 12, 2025
Copy link to clipboard
Copied
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.
/t5/photoshop-ecosystem-ideas/p-quick-export-option-to-disable-transparency-trimming/idc-p/15368006#M25655Jun 12, 2025
Jun 12, 2025
Copy link to clipboard
Copied
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
/t5/photoshop-ecosystem-ideas/p-quick-export-option-to-disable-transparency-trimming/idc-p/15368018#M25656Jun 12, 2025
Jun 12, 2025
Copy link to clipboard
Copied
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...
/t5/photoshop-ecosystem-ideas/p-quick-export-option-to-disable-transparency-trimming/idc-p/15368223#M25657Jun 12, 2025
Jun 12, 2025
Copy link to clipboard
Copied
LATEST
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...