Skip to content

Add icons to the system #201

Open
Open
@jecisc

Description

@jecisc

We often need to manage custom icons in Pharo.

Maybe we could have a page on icons management and explain how to add our own icons.

One way to do it is to do:

ThemeIcons compile:  'myLogoContents
	^ ''' , (Base64MimeConverter mimeEncode: 'logo.png' asFileReference binaryReadStream) contents , '''' classified: 'Material-Design-Lite-Core'.
	
ThemeIcons compile: 'myLogoIcon
	^ icons
			at: #''myLogoIcon''
			ifAbsentPut:[ Form fromBinaryStream: self myLogoContents base64Decoded asByteArray readStream ]' classified: 'Material-Design-Lite-Core'.

Smalltalk ui icons myLogoIcon

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions