Dear friends,
We all know about special effects in the movies, but I can tell you: also ExtendScript can entertain us with such. It appears to be a conjurer of the good old style. It all happens on the stage of FM version 13.0.5.547.
Information for the uninitiated:
- The script creates a menu with some entries
- Two entries immediately open a panel to work with special markers
- Other entries open the pdf documentation, open a panel for document settings or run functions through the document.
- Debugging is not possible when functions are called via the menu. Hence for debugging I disable the set-up of the menu and present a selection list with the jumps to the functions.
- I unregister the script each time before I start it again (either in ESTK or via script catalogue).
The Ghost
When opening one of the panels via menu it happens that in the top left corner a small selection list appears with contents from a previous call:
I can create this illusion at will with the following sequence of magic tricks. No, it's not an illusion: Putting the cursor into the selection list the display can be changed with the arrow keys, so it's some sort of real...
- Leave all script activity (panels)
- Unregister the script
- Open a panel by the still 'active' menu in FM
- Voilà! The ghost appears in top left corner
The slave
From time to time (magic does not happen by schedule) the following effect can be seen:
- Starting the script before an FM document is open
- Invoking a script action via menu
- I do not see the panel - it is in the background
- Not certain about an error I bring the console window to the foreground
- Not seeing anything suspicious I dismiss the console window to get a fresh version for an error.
- At the same time the panel disappears, following 'his master' immediately to the nirvana.
Unfortunately I can not reproduce this at will... Hence I do not know whether an open ESTK (with nothing in there) has any influence.
The twins
I discovered this after a small update of my script and hence guessed the reason for it there - but my update was in a mathematical function, not in the area of the user interface:
- Open FM and then create a new document
- Invoke the script via catalogue and select a panel function from the menu
- The contents of the panel is duplicated
- Each 'content' is active independently of the other - see the different tabs in the screen shot.
- But I am not certain which one really performs the function in the document.
- Hence I dismiss these Siamese twins.
- Then I opened a document which behaved 'last time'
- Unregister script, start script again, open panel via menu
- Same effect
- Now I left FM and started afresh
- The magic did not appear any more (sorry folks!).
Big entertainment, isn't it? But frustrating when trying to get a good script...
What can we learn from these tricks?