Struct droom_ui::image::ImageRgb
[−]
[src]
pub struct ImageRgb(_);
A three-channel image to be shown on a label, button, toggle, or as a cursor.
See the IUP Image Documentation.
Trait Implementations
impl ImageElement for ImageRgb
[src]
type Pixel = (u8, u8, u8)
The type of a single pixel of this image.
fn new<U>(width: u32, height: u32, pixels: U) -> ImageRgb where U: AsRef<[(u8, u8, u8)]>
Creates a new image element with the specified dimensions from the specified pixel array. Read more
fn with<'a>(pixels: InPixels<'a, Self::Pixel>) -> Self
Creates a new image element from the output of the pixels!
macro. Read more
impl Element for ImageRgb
[src]
fn raw(&self) -> *mut Ihandle
Gets the raw IUP handle associated with this element.
unsafe fn from_raw_unchecked(ih: *mut Ihandle) -> Self
Constructs an Element from a raw IUP handle. Read more
unsafe fn target_classname() -> &'static str
Gets the [class name][1] the derived object should be targeting. [1]: http://webserver2.tecgraf.puc-rio.br/iup/en/func/iupgetclassname.html Read more
fn from_handle(handle: Handle) -> Result<Self, Handle>
Constructs a specialized Element object from a general Handle if they are compatible.
fn from_name<S: Into<String>>(name: S) -> Option<Handle>
Constructs from a name associated with a element handle (with Element::add_handle_name
or LED).
fn from_raw(ih: *mut Ihandle) -> Self
Constructs an Element from a raw IUP handle. Read more
unsafe fn classname(&self) -> &CStr
Gets the [class name][1] of this element. [1]: http://webserver2.tecgraf.puc-rio.br/iup/en/func/iupgetclassname.html Read more
fn destroy(self)
Destroys an interface element and all its children. Read more
fn does_attrib_exist(&self, cname: &CString) -> bool
Checks if a specific attribute exists in the element.
fn attribs(&self) -> Vec<String>
Returns the names of all attributes of an element that are set in its internal hash table only. Read more
fn set_attrib<S1, S2>(&mut self, name: S1, value: S2) -> Self where S1: Into<String>, S2: Into<String>
Sets an interface element attribute. Read more
fn attrib<S: Into<String>>(&self, name: S) -> Option<String>
Gets an interface element attribute. Read more
fn set_attrib_data<S1>(&mut self, name: S1, data: *const c_void) -> Self where S1: Into<String>
Sets a raw interface element attribute. Read more
fn attrib_data<S1>(&mut self, name: S1) -> *mut c_void where S1: Into<String>
Gets a raw interface element attribute.
fn set_attrib_handle<S1, E>(&mut self, name: S1, elem: E) -> Self where S1: Into<String>, E: Element
Associates a element with an attribute. Read more
fn attrib_handle<S1>(&mut self, name: S1) -> Option<Handle> where S1: Into<String>
Gets the handle associated with an attribute.
fn clear_attrib<S: Into<String>>(&mut self, name: S) -> Self
Clears the value associated with an attribute and use the default value.
fn reset_attrib<S: Into<String>>(&mut self, name: S) -> Self
Removes an attribute from element and its children if the attrib is inheritable. Read more
fn handle_name(&self) -> Option<String>
Returns the identifier of an interface element that has an associated handle name using Element::add_handle_name
or using LED. Read more
fn add_handle_name<S: Into<String>>(&self, name: S) -> Option<Handle>
Associates a handle name with an interface element. Read more
fn clear_handle_name<S: Into<String>>(name: S) -> Option<Handle>
Clears the handle name association on the specified name. Read more
impl Debug for ImageRgb
[src]
impl Copy for ImageRgb
[src]
impl Clone for ImageRgb
[src]
fn clone(&self) -> ImageRgb
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more