Copy link to clipboard
Copied
Is it possible to cut a section of a document and merge the other sections automatically?
Here's an example:
Let's say this is my document and I was working on 3 sections (A, B, C). Now for some reason, I think that A and C are the only sections that I want to use, but together (A above C). Can I select the B section and apply a command so it will delete that section and merge A and C (resizing the document's height) moving the guides as well? If I just move the content from C up, I won't be able to move the guides (at least I don't think there's a way to move a group of guides). Even if I don't have guides, I have to perform a lot of different steps (create a group with section C's content, move it up hoping it will align, crop the document).
Hope what I'm looking for makes sense
Thanks
Copy link to clipboard
Copied
You provide no details about your Photoshop Document. Are the sections on different layers. Are they all in the background layer which is the only layer in the document. How you would do what you want to do would depends on the document you are working on. What you want to do can be done. The steps used will vary.
Copy link to clipboard
Copied
Sorry, I thought it was implied that the document was not a flatten image...
The idea is not to cut and drag. That's what I mentioned as being too many steps.
Think of it as a "crop" but reversed. Regardless of it being a flatten image or not (99% of the time it would be for documents with layers) the concept is: make a selection and whatever is outside that selection will be kept and merged. So in this case I would select section B, use that feature (that maybe doesn't exist, but that's why I'm asking it here) and it would automatically merge both A and C.
The way you showed doesn't move the guides from section C, which in a situation with layers, that's what should be achieved. Maybe this feature doesn't exist at all...
I'm curious about your approach when using layers, though, if there's any
Copy link to clipboard
Copied
What are you written about Crop only removes or hides document content it does not recompose a doument's composition or merger anything
If the document is not flatten how many layers does it have 2 layers, 2 thousand layer what kind of layers for example smart object layer content can not be changed and the object sized can not be changed. Shape layer will distort like pixel layer if the layer resize is not constrained and how would you split up a shape layer. The steps required would be different for different document. There could be parts of many layers in selection B and different kinds of layers. A script would know the bounds of selection B but would have no idea of the contents of layers in selection B. It can get the all the layer and their layer kinds the their bounds to see if any part of a layer is in Selection B area. Find out if the Layers have layer mask. I do not think a vector layer mask could be modified into several vector layer mask should a layer need to be split into two or there layers. The layer would most likely need to rasterized and that raster layer split into pieces. How your process would be done would vary because of document content. If you know how Photoshop layers work you should know this is the case.
Personally I would not want to try to script this there are too many possible variations and the document structure will change in the process. It would be relatively easy to flatten the convert background to normal layer cut selection B and move section C to meat section A and trim.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now