On Thu, Feb 4, 2016 at 7:19 AM, Aliaksei Syrel <alex.syrel@gmail.com> wrote:
Hi

For ages to access an icon we used:
Smalltalk ui icons protocolPrivateIcon

Smalltalk ui icons��returns an instance of ThemeIcons.
After refactoring (case��https://pharo.fogbugz.com/f/cases/16651) all methods to access icon (for example��protocolPrivateIcon)��were removed.

ThemeIcons>>#doesNotUnderstand: aMessage converts message sent to iconNamed:��aMessage selector which works.

BUT we have this all over the image:
Inline image 1

So, what is the best practice to access icons to use in application?
What if a class was created, MethodProtocol, that encapsulated this behaviour?�� The tools could identifiy which protocol by String (as in this method), with a 'default' or 'bucket' protocol for ones that aren't previously identified.��
Then, for categoryIconFor: string would either identify the methodProtocol instance and ask #icon.�� It might delegate however it likes - or cache it's particular icon.
Just a thought.
-cbc
��

Cheers,
Alex