fp_tui 0.2.2

A very basic tui library
Documentation
/// #### Description
/// A set of distances in the 2D plane
///
#[derive(Debug, Clone, Copy)]
pub struct Dimensions {
    /// #### Description
    /// Distance in the X dimension
    ///
    width: u32,

    /// #### Descritpion
    /// Distance in the Y dimension
    ///
    height: u32
}

impl Dimensions {
    /// #### Description
    /// Creates a set of distances with the give width and height
    ///
    /// #### Arguments
    /// * `width`: [u32] - The value for the distance in the X dimension
    /// * `height`: [u32] - The value for the distance in the Y dimensions
    ///
    /// #### Returns
    /// [Dimensions] - Dimensions of the specified width and height
    ///
    pub fn new(width: u32, height: u32) -> Self {
        return Self {width, height};
    }

    /// #### Description
    /// Retrieves the distance in the X dimension
    ///
    /// #### Returns
    /// [u32] - The distance in the X dimension
    ///
    pub fn get_width(&self) -> u32 {
        return self.width;
    }

    /// #### Description
    /// Sets the distance in the X dimension
    ///
    /// #### Arguments
    /// * `value`: [u32] - The value to set the width to
    ///
    pub fn set_width(&mut self, value: u32) {
        self.width = value;
    }

    /// #### Description
    /// Retrieves the distance in the Y dimension
    ///
    /// #### Returns
    /// [u32] - The distance in the Y dimension
    ///
    pub fn get_height(&self) -> u32 {
        return self.height;
    }

    /// #### Description
    /// Sets the distance in the Y dimension
    ///
    /// #### Arguments
    /// * `value`: [u32] - The value to set the height to
    ///
    pub fn set_height(&mut self, value: u32) {
        self.height = value;
    }
}