NewIconFromBitmap returns a new Icon, using the specified Bitmap as source.
(bmp *Bitmap)
| 196 | |
| 197 | // NewIconFromBitmap returns a new Icon, using the specified Bitmap as source. |
| 198 | func NewIconFromBitmap(bmp *Bitmap) (ic *Icon, err error) { |
| 199 | hIcon, err := createAlphaCursorOrIconFromBitmap(bmp, Point{}, true) |
| 200 | if err != nil { |
| 201 | return nil, err |
| 202 | } |
| 203 | return newIconFromHICONAndSize(hIcon, bmp.Size(), bmp.dpi), nil |
| 204 | } |
| 205 | |
| 206 | // NewIconFromHICON returns a new Icon at 96dpi, using the specified win.HICON as source. |
| 207 | // |
no test coverage detected
searching dependent graphs…