Struct xcb::x::ChangeProperty
source · pub struct ChangeProperty<'a, P: PropEl> {
pub mode: PropMode,
pub window: Window,
pub property: Atom,
pub type: Atom,
pub data: &'a [P],
}
Expand description
Changes a window property
Sets or updates a property on the specified window
. Properties are for
example the window title (WM_NAME
) or its minimum size (WM_NORMAL_HINTS
).
Protocols such as EWMH also use properties - for example EWMH defines the
window title, encoded as UTF-8 string, in the _NET_WM_NAME
property.
§Example
// Set the WM_NAME property of the window "XCB Example".
conn.send_request(&x::ChangeProperty {
mode: x::PropMode::Replace,
window,
property: x::ATOM_WM_NAME,
r#type: x::ATOM_STRING,
data: b"XCB Example",
});
This request has no reply.
Associated cookie types are VoidCookie and VoidCookieChecked.
Fields§
§mode: PropMode
§window: Window
The window whose property you want to change.
property: Atom
The property you want to change (an atom).
type: Atom
The type of the property you want to change (an atom).
data: &'a [P]
The property data.
Trait Implementations§
source§impl<'a, P: Clone + PropEl> Clone for ChangeProperty<'a, P>
impl<'a, P: Clone + PropEl> Clone for ChangeProperty<'a, P>
source§fn clone(&self) -> ChangeProperty<'a, P>
fn clone(&self) -> ChangeProperty<'a, P>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'a, P: PropEl> RawRequest for ChangeProperty<'a, P>
impl<'a, P: PropEl> RawRequest for ChangeProperty<'a, P>
source§fn raw_request(&self, c: &Connection, checked: bool) -> u64
fn raw_request(&self, c: &Connection, checked: bool) -> u64
Actual implementation of the request sending Read more
source§impl<'a, P: PropEl> Request for ChangeProperty<'a, P>
impl<'a, P: PropEl> Request for ChangeProperty<'a, P>
impl<'a, P: PropEl> RequestWithoutReply for ChangeProperty<'a, P>
Auto Trait Implementations§
impl<'a, P> Freeze for ChangeProperty<'a, P>
impl<'a, P> RefUnwindSafe for ChangeProperty<'a, P>where
P: RefUnwindSafe,
impl<'a, P> Send for ChangeProperty<'a, P>where
P: Sync,
impl<'a, P> Sync for ChangeProperty<'a, P>where
P: Sync,
impl<'a, P> Unpin for ChangeProperty<'a, P>
impl<'a, P> UnwindSafe for ChangeProperty<'a, P>where
P: RefUnwindSafe,
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)