You must be logged in to post Login

Search Forums:


 






ScriptUI palette breaks keyboard

UserPost

12:21 pm
January 20, 2012


brother.gabriel

Community Member

posts 13

Salve!

Folks, I am at a complete loss with this problem.

I have created a simple palette window, but when I run it, it steals all the keyboard control away from InDesign. I can’t type anything in InDesign! Other programs work fine. If I close the palette window, I can type again in InDesign as before.

Here is my simple palette script:

#targetengine testpalette
var PaletteWindow = new Window(‘palette’, "Test");
PaletteWindow.show();

Please advise me! I have made some beautiful palette scripts, but can’t use them!  Am I doing something wrong?

8:00 am
January 21, 2012


brother.gabriel

Community Member

posts 13

Hello?  Is there anyone out there?

9:06 am
February 17, 2012


David Blatner

Admin

posts 823

I think ALL panels do that in InDesign, don't they? If you open a panel, it puts the focus there. What happens if you press Escape or Enter? Does it put the focus back on the page?

co-host, InDesignSecrets.com

10:27 pm
February 19, 2012


brother.gabriel

Community Member

posts 13

Thanks for answering, Mr. Blatner!

Well, when I open the panel, and then click back into InDesign, I can still work with everything using the mouse.  But if I try to type, I can't.  The panels steal up the keyboard.  If I click away to another program and then click back to InDesign, the palettes aren't active, and so I can type again.

It seems like once I activate a script UI panel that I can't get it to un-activate.  No, enter or escape don't work.  These are pallettes and not dialogs, so they *should* be able to remain on the screen without having to be closed out.

3:15 pm
February 21, 2012


brother.gabriel

Community Member

posts 13

Hello?  ello… llo…  o…

6:13 pm
April 7, 2012


brother.gabriel

Community Member

posts 13

I am *still* having this problem!

It seems that as long as a script palette is open, I cannot type into InDesign.  I even tried without the target.

var PaletteWindow = new Window(‘palette’, "Test");
PaletteWindow.show();

6:28 pm
April 7, 2012


brother.gabriel

Community Member

posts 13

Hello!  I found this post, with a workaround:

http://forums.adobe.com/thread…..p;tstart=0

It doesn't solve the issue, however.

I have also posted here:

http://stackoverflow.com/quest…..0#10059680

6:39 pm
April 7, 2012


brother.gabriel

Community Member

posts 13

Okay, folks, I think I solved the issue.  I posted the answer also on Stack Overflow.  Basically, if you add app.activate(); to the buttons on the palette, and also add app.activate(); just after you show the palette, then your palette will give focus to InDesign on its startup, and then you can push buttons on the palette as you will.