[comp.sys.mac.hypercard] HC 2.0 Palette bug...

G.A.Hutchings@ecs.soton.ac.uk (Gerard Hutchings) (02/06/91)

1) How does a palette (created using the Palette Maker from the Power
Tools stack) *really* send its messages ?

2) When does the Message Watcher get to see messages ?

I ask because I have just spent a long time tracking down a problem
which was in fact caused by a simple typo in a background handler. I
have a palette which sends the message "makeTextButton" , whose
handler is in the background script.  In this handler are the
following commands:

on makeTextButton
   put the selectedChunk into buttonChunk
   ........
   set the textStyle of buttonChunk to plain
   ........
end makeTextButton

However, buttonChunk in the second command was mispelt as
"buttonChunki", which of course should result in a "Can't understand
this" message when the script is compiled. If makeTextButton is sent
from the message box, then this error message is seen.  However, if
'makeTextButton' is sent from the palette, absolutely nothing happens.
The script is never activated, and the message does not get passed up
the heirarchy in the usual manner.  Neither is the message seen in (by
?) the message Watcher.

Surely the absence of an error message is a bug ?

How long does a compilation last ? Is it cached anywhere ?

[Hypercard 2.0.2, System 6.0.5, Mac IIci, 4Mb RAM]

Gerard Hutchings
University of Southampton


--