skip to Main Content

Is there any way to hide extras (specifically the selection/marching ants) using Javascript in photoshop? I have an action that I frequently use to make a selection, and inevitably always follow it up with Cmd + H to hide the selection. Curious if there’s a way with a script I could reduce three keystrokes to just one. I’ve spent a while googling and it seems like it might not be possible, but I also didn’t find anyone asking this specific question.
Thanks in advance!

2

Answers


  1. As far as I am aware there is no way either via scriptlistener or JavaScript to do that.

    // this is pseudo code
    activeDocument.selection.selectAll().show(false);
    // this doesn't work
    

    There are few things that are beyond the scope of Photoshop scripting and that is (sadly) show extras is one of them. But by all means prove me wrong.

    Login or Signup to reply.
  2. Toggling Extras (Cmd + H) can be scripted the following way:

    app.runMenuItem (app.stringIDToTypeID ("toggleShowExtras"));
    

    If you prefer to include this step in an action you’re currently recording, don’t directly select the View > Extra command, but use “Insert Menu Item…” from the contextual menu located at the upper right of the Actions palette/panel, then select the command while the dialog is displayed and click OK.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search