[MonoDevelop] Stock Icons

Michael Hutchinson m.j.hutchinson at gmail.com
Fri Mar 20 11:52:42 EDT 2009


On Thu, Mar 19, 2009 at 9:34 PM, John Tindell <john at yeticode.co.uk> wrote:
> Hey,
>    I'm trying to use stock icons. I've added a file called Red.png with
> an icon name of "BuildFailed". I'm then trying to get it using the
> following code
>
> Gtk.IconSet iconSet = Gtk.IconFactory.LookupDefault("BuildFailed");
> iconSet.RenderIcon(new Gtk.Style(), Gtk.TextDirection.Ltr,
> Gtk.StateType.Normal, Gtk.IconSize.SmallToolbar, null, "");
>
> this throw a NullReferenceException. Is there anything i need to do
> within monodevelop to get this to work or am I going about this the
> wrong way?

Within MonoDevelop? Are you using this for a Monodevelop addin? If so,
we have extension points for registering icons and services for
looking them up.

-- 
Michael Hutchinson
http://mjhutchinson.com


More information about the Monodevelop-list mailing list