Trait GridFns

Source
pub trait GridFns:
    AsComponent
    + Child
    + ComponentPtr
    + Parent {
    // Provided methods
    fn add_to_form<'a>(&'a self, form: &mut Form<'a>) -> Result<()> { ... }
    fn get_size(&self) -> (i32, i32) { ... }
    fn place(&self, left: i32, top: i32) { ... }
}
Expand description

Implements functions shared by Grids.

Provided Methods§

Source

fn add_to_form<'a>(&'a self, form: &mut Form<'a>) -> Result<()>

Add Grid to a Form.

  • form - The form to add the Grid to.
Source

fn get_size(&self) -> (i32, i32)

Get the size of the Grid.

Returns the width and height as a tuple (width, height).

Source

fn place(&self, left: i32, top: i32)

Move the Grid to a specified location.

  • left - The left-most position of the Grid.
  • top - The top-most position of the Grid.

Implementors§