Struct x11rb::properties::WmSizeHints[][src]

pub struct WmSizeHints {
    pub position: Option<(WmSizeHintsSpecification, i32, i32)>,
    pub size: Option<(WmSizeHintsSpecification, i32, i32)>,
    pub min_size: Option<(i32, i32)>,
    pub max_size: Option<(i32, i32)>,
    pub size_increment: Option<(i32, i32)>,
    pub aspect: Option<(AspectRatio, AspectRatio)>,
    pub base_size: Option<(i32, i32)>,
    pub win_gravity: Option<Gravity>,
}

A structure representing a WM_SIZE_HINTS property.

Fields

position: Option<(WmSizeHintsSpecification, i32, i32)>

The position that the window should be assigned.

Note that current versions of ICCCM only make use of the WmSizeHintsSpecification field. The later two fields exist only for backwards compatibility.

size: Option<(WmSizeHintsSpecification, i32, i32)>

The size that the window should be assigned.

Note that current versions of ICCCM only make use of the WmSizeHintsSpecification field. The later two fields exist only for backwards compatibility.

min_size: Option<(i32, i32)>

The minimum size that the window may be assigned.

max_size: Option<(i32, i32)>

The maximum size that the window may be assigned.

size_increment: Option<(i32, i32)>

The increment to be used for sizing the window together with base_size.

aspect: Option<(AspectRatio, AspectRatio)>

The minimum and maximum aspect ratio.

base_size: Option<(i32, i32)>

The base size of the window.

This is used together with size_increment.

win_gravity: Option<Gravity>

The gravity that is used to make room for window decorations.

Implementations

impl WmSizeHints[src]

pub fn new() -> Self[src]

Get a new, empty WmSizeHints structure.

pub fn get<C: RequestConnection>(
    conn: &C,
    window: Window,
    property: impl Into<Atom>
) -> Result<WmSizeHintsCookie<'_, C>, ConnectionError>
[src]

Send a GetProperty request for the given property of the given window

pub fn get_normal_hints<C: RequestConnection>(
    conn: &C,
    window: Window
) -> Result<WmSizeHintsCookie<'_, C>, ConnectionError>
[src]

Send a GetProperty request for the WM_NORMAL_HINTS property of the given window

pub fn from_reply(reply: &GetPropertyReply) -> Result<Self, ParseError>[src]

Construct a new WmSizeHints instance from a GetPropertyReply.

The original WmSizeHints request must have been for a WM_SIZE_HINTS property for this function to return sensible results.

pub fn set_normal_hints<'a, C: RequestConnection + ?Sized>(
    &self,
    conn: &'a C,
    window: Window
) -> Result<VoidCookie<'a, C>, ConnectionError>
[src]

Set these WM_SIZE_HINTS on some window as the WM_NORMAL_HINTS property.

pub fn set<'a, C: RequestConnection + ?Sized>(
    &self,
    conn: &'a C,
    window: Window,
    property: impl Into<Atom>
) -> Result<VoidCookie<'a, C>, ConnectionError>
[src]

Set these WM_SIZE_HINTS on some window as the given property.

Trait Implementations

impl Clone for WmSizeHints[src]

impl Copy for WmSizeHints[src]

impl Debug for WmSizeHints[src]

impl Default for WmSizeHints[src]

impl Serialize for WmSizeHints[src]

type Bytes = Vec<u8>

The value returned by serialize. Read more

impl TryParse for WmSizeHints[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.

impl<T> TryParseFd for T where
    T: TryParse
[src]