[BUG] [FIX] ArchiveViewer-createButtonBar is fragile

Dan Ingalls Dan at SqueakLand.org
Thu Dec 11 18:24:45 UTC 2003


The current method for ArchiveViewer-createButtonBar uses StrikeFont allInstances to find a narrow font.  It then assumes that the one it found is accessible through the normally registered textstyles.

If your image contains a local font --held in , eg, a class variable -- then this method will fail if it chooses that font, since it cannot be accessed through the normal registry.

The attached fix enumerates registered fonts rather than using allInstances.  It should be included wherever ArchiveViewer is maintained, as well as with Scamper, since its installation calls this method (that's where I got bitten).

	- Dan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: createButtonBar.st.gz
Type: application/mac-binhex40
Size: 1507 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20031211/6850b3b9/createButtonBar.st.hqx


More information about the Squeak-dev mailing list