[][src]Struct native_windows_gui::ControlBase

pub struct ControlBase;

Control base is a low level interface to create base Windows handle (HWND, HMENU, TIMER, etc). This is used internally by every controls.

use native_windows_gui as nwg;

fn basic_stuff(window: &nwg::Window) -> Result<(), nwg::NwgError> {
    nwg::ControlBase::build_hwnd()
        .class_name("BUTTON")
        .forced_flags(0)
        .flags(0)
        .size((100, 100))
        .position((100, 100))
        .text("HELLO")
        .parent(Some(window.handle))
        .build()?;

    #[cfg(feature = "menu")]
    nwg::ControlBase::build_hmenu()
        .text("Item")
        .item(true)
        .parent(window.handle)
        .build()?;

    Ok(())
}

Implementations

impl ControlBase[src]

Trait Implementations

impl Clone for ControlBase[src]

impl Debug for ControlBase[src]

Auto Trait Implementations

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> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.