[Pharo-project] OBMorphicIcons (was Re: this style looks cool)
Message: 4 Date: Mon, 30 Aug 2010 03:41:45 +0200 From: Tudor Girba <tudor.girba@gmail.com> Subject: Re: [Pharo-project] this style looks cool To: Pharo-project@lists.gforge.inria.fr Message-ID: <6950297A-3FF9-46B5-9AC5-CAA382233986@gmail.com> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes
Hi Bill,
As I said, all you have to do is to override #browserIcon on the class side of your class to return a symbol that corresponds to a method in OBMorphicIcons. Please look at the implementors of #browserIcon.
For example:
Announcement class>>browserIcon ^ #announcement
OBMorphicIcons>>announcement ^ ((ColorForm extent: 12@12 depth: 8 fromArray: ...
Cheers, Doru
This looks useful; how do you turn an image into a method, though? Thank you, Rob
This looks useful; how do you turn an image into a method, though?
Hi! Have a look at the class side of MenuIcons. There are a bunch of import/export methods. Cheers, Alexandre -- _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
*contents := (StandardFileStream fileNamed: 'loop_icon.jpg') contents. encondedContents := (Base64MimeConverter mimeEncode: contents readStream) .* That basically gives you the string you have to embed in a method... Cheers, Guille On Mon, Aug 30, 2010 at 9:42 AM, Alexandre Bergel <alexandre@bergel.eu>wrote:
This looks useful; how do you turn an image into a method, though?
Hi!
Have a look at the class side of MenuIcons. There are a bunch of import/export methods.
Cheers, Alexandre -- _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
_______________________________________________ Pharo-project mailing list Pharo-project@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
participants (3)
-
Alexandre Bergel -
Guillermo Polito -
Rob Rothwell