[][src]Struct native_windows_gui::Icon

pub struct Icon {
    pub handle: HANDLE,
    // some fields omitted
}

A wrapper over a icon file (*.ico)

Note that icon object are only used as display resources (ie: it's impossible to read pixels or resized it). If those features are needed, see the image-decoder feature.

To display a icon in an application, see the ImageFrame control.

Example:

use native_windows_gui as nwg;

fn load_icon() -> nwg::Icon {
    let mut icon = nwg::Icon::default();

    nwg::Icon::builder()
        .source_file(Some("Hello.cur"))
        .strict(true)
        .build(&mut icon);

    icon
}

Fields

handle: HANDLE

Implementations

impl Icon[src]

pub fn builder<'a>() -> IconBuilder<'a>[src]

Trait Implementations

impl Default for Icon[src]

impl PartialEq<Icon> for Icon[src]

Auto Trait Implementations

impl RefUnwindSafe for Icon

impl !Send for Icon

impl !Sync for Icon

impl Unpin for Icon

impl UnwindSafe for Icon

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.