Skip to main content
kellyishikawa
Participating Frequently
October 9, 2018
Question

“Trim layers” PNG with coordinate information?

  • October 9, 2018
  • 2 replies
  • 6551 views

Hi everyone! I know that with “export layers to files” I can uncheck “trim layers” and the objects of each exported layer will be saved in the correct position Relative to the original documents bounds. But these are relatively large PNG files.

If I check “trim layers”, The file is, of course, smaller.

Is there any way to retain the file size advantage with the “trim layers” option while still retaining position information? These exported PNG’s will be inserted into other documents And positioning must be precise and consistent.

    This topic has been closed for replies.

    2 replies

    JJMack
    Community Expert
    Community Expert
    October 9, 2018

    Some Photoshop operations will trim transparent boarders.  For example Copying a layer to the clipboard copy pixels within the layers bounds to the  clipboard empty boarders will not be in the clipboard and File>Place will not render empty pixels for an object transparent canvas borders.  Only Pixels within the Layer bounds will be use in these operations.  When I need to preserve transparent boarders I force image file not to have any. I add 1% opacity the the top left and boton right layer  pixels with an action. No human eye will ever see these pixels without hunting for them.

    JJMack
    davescm
    Community Expert
    Community Expert
    October 9, 2018

    Hi

    I don't know of any way to do that. If the file is based on a trimmed layer then additional metadata would need to be written (and read by the receiving application) to give the original size and position.

    Dave