I’m building a form with Eto and want to use a bitmap from the assembly resources as a button image.
Accessing the bitmap in winforms is as simple as “Resources.Load” but how can I reference the same bitmap in Eto.
I’ve tried using the below, but it cannot locate the the resource in the assembly (GH). I’ve tried all path combinations too without any luck:
loadButton.Image = Eto.Drawing.Bitmap.FromResource("Resources.Load");
I’ve looked through the assembly and found the correct “path” and also found it via the resourcemanager, but Eto cannot see it…
If I do the following I get an image, but it seems over the top:
loadButton.Image = new Eto.Drawing.Bitmap((byte)converter.ConvertTo(Resources.Load, typeof(byte)));
What is the best way to do this?