[Q] adding tiles to Plugin?
Anindita
anindita at media.mit.edu
Wed May 15 20:58:21 PDT 2002
Hi,
I was just trying to add tiles and categories to the Plugin and the
solution that worked for Squeak 3.x for some reason doesn't seem to be
working. . .
Basically, I tried the original solution-- wrote a method under
Player>>scripts-standard and added an entry into Morph class>>
additionsToViewerCategories, but no new tiles appeared. It was a command,
not a slot tile, so I'm pretty sure I wrote everything in the right
places. Then to debug this (in case my method was buggy), I tried to just
move some tiles around, so something that's normally under miscellaneous
would be under basic-- copied and pasted between
additionsToViewerCategoriesMiscellaneous and Basic, but nothing moved in
the viewer. I think I'm missing a step somewhere. Finally, I tried to
add a new viewer category by writing an additionsToViewerCategoriesX and
adding it into additionsToViewerCategories, but when it appeared, it
wasn't part of the main group of categories. It was separated by a line,
like the text category. And again, none of the new tiles appeared. What
are the other classes I need to modify in order to add tiles and modify
categories in the Plugin?
Thanks!
Anindita
On Sun, 14 Apr 2002, Ted Kaehler wrote:
> Anindita,
> See the method TextMorph class>>additionsToViewerCategories.
> That is where you need to add a line for each new tile you want.
> Make a duplicate of the inner array below, and edit it.
>
> #((basic "The category name in the viewer" (
> (slot characters "name on the tile"
> 'The characters in my contents' "balloon help string"
> String "Type that it returns"
> readWrite "both setting and getting"
> Player "put into viewers on objects of this class"
> getCharacters "getter selector (your method name goes here)"
> Player "put into viewers on objects of this class"
> setCharacters: "setter selector (your method name goes here)")
> "another slot" )))
>
> --Ted.
More information about the Squeakland
mailing list