Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Eclipse Gravatar Plug-in

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 docs
Octocat-spinner-32 org.github.avatar.ui
Octocat-spinner-32 .gitignore
Octocat-spinner-32 LICENSE
Octocat-spinner-32 README.md
Octocat-spinner-32 pom.xml
README.md

Eclipse Gravatar Plug-in

This is a plug-in to add Gravatar support to Eclipse.

The org.avatar.github plug-in contains a persistent store of fetched Gravatar images that can be used directly to get Image/ImageData instances for a specific hash or e-mail address.

This plug-in also contains LabelProvider and WorkbenchAdapter classes that provide images for objects that can provide a hash.

Avatar Example

Fetching an avatar from the plug-in store

Avatar avatar = AvatarPlugin.getDefault().getAvatars().loadAvatarByEmail("name@example.com");
Image image = new AvatarImage(avatar).getScaledImage(32);

Getting a cached avatar from the plug-in store

Avatar avatar = AvatarPlugin.getDefault().getAvatars().getAvatarByEmail("name@example.com");
Image image =  new AvatarImage(avatar).getScaledImage(32);

Creating a table viewer with Gravatar images

TableViewer viewer = new TableViewer(parent, SWT.H_SCROLL | SWT.V_SCROLL);
viewer.setContentProvider(new ArrayContentProvider());
viewer.setLabelProvider(new AvatarLabelProvider(viewer));
//Replace with a valid e-mail address
viewer.setInput(new Object[] { "name@example.com" });

Other

Eclipse Public License

As of May 14th, 2011 parts of this project have been donated to the Mylyn Commons Identity API as part of Bug 343602.

Something went wrong with that request. Please try again.