Struct wayland_protocols_wlr::output_management::v1::generated::client::zwlr_output_configuration_v1::ZwlrOutputConfigurationV1
source · pub struct ZwlrOutputConfigurationV1 {
id: ObjectId,
version: u32,
data: Option<Arc<dyn ObjectData>>,
backend: WeakBackend,
}
Expand description
output configuration
This object is used by the client to describe a full output configuration.
First, the client needs to setup the output configuration. Each head can be either enabled (and configured) or disabled. It is a protocol error to send two enable_head or disable_head requests with the same head. It is a protocol error to omit a head in a configuration.
Then, the client can apply or test the configuration. The compositor will then reply with a succeeded, failed or cancelled event. Finally the client should destroy the configuration object.
See also the Event enum for this interface.
Fields§
§id: ObjectId
§version: u32
§data: Option<Arc<dyn ObjectData>>
§backend: WeakBackend
Implementations§
source§impl ZwlrOutputConfigurationV1
impl ZwlrOutputConfigurationV1
sourcepub fn enable_head<U: Send + Sync + 'static, D: Dispatch<ZwlrOutputConfigurationHeadV1, U> + 'static>(
&self,
head: &ZwlrOutputHeadV1,
qh: &QueueHandle<D>,
udata: U,
) -> ZwlrOutputConfigurationHeadV1
pub fn enable_head<U: Send + Sync + 'static, D: Dispatch<ZwlrOutputConfigurationHeadV1, U> + 'static>( &self, head: &ZwlrOutputHeadV1, qh: &QueueHandle<D>, udata: U, ) -> ZwlrOutputConfigurationHeadV1
enable and configure a head
Enable a head. This request creates a head configuration object that can be used to change the head’s properties.
sourcepub fn disable_head(&self, head: &ZwlrOutputHeadV1)
pub fn disable_head(&self, head: &ZwlrOutputHeadV1)
disable a head
Disable a head.
sourcepub fn apply(&self)
pub fn apply(&self)
apply the configuration
Apply the new output configuration.
In case the configuration is successfully applied, there is no guarantee that the new output state matches completely the requested configuration. For instance, a compositor might round the scale if it doesn’t support fractional scaling.
After this request has been sent, the compositor must respond with an succeeded, failed or cancelled event. Sending a request that isn’t the destructor is a protocol error.
sourcepub fn test(&self)
pub fn test(&self)
test the configuration
Test the new output configuration. The configuration won’t be applied, but will only be validated.
Even if the compositor succeeds to test a configuration, applying it may fail.
After this request has been sent, the compositor must respond with an succeeded, failed or cancelled event. Sending a request that isn’t the destructor is a protocol error.
sourcepub fn destroy(&self)
pub fn destroy(&self)
destroy the output configuration
Using this request a client can tell the compositor that it is not going to use the configuration object anymore. Any changes to the outputs that have not been applied will be discarded.
This request also destroys wlr_output_configuration_head objects created via this object.
Trait Implementations§
source§impl Borrow<ObjectId> for ZwlrOutputConfigurationV1
impl Borrow<ObjectId> for ZwlrOutputConfigurationV1
source§impl Clone for ZwlrOutputConfigurationV1
impl Clone for ZwlrOutputConfigurationV1
source§fn clone(&self) -> ZwlrOutputConfigurationV1
fn clone(&self) -> ZwlrOutputConfigurationV1
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for ZwlrOutputConfigurationV1
impl Debug for ZwlrOutputConfigurationV1
source§impl Hash for ZwlrOutputConfigurationV1
impl Hash for ZwlrOutputConfigurationV1
source§impl PartialEq<Weak<ZwlrOutputConfigurationV1>> for ZwlrOutputConfigurationV1
impl PartialEq<Weak<ZwlrOutputConfigurationV1>> for ZwlrOutputConfigurationV1
source§impl PartialEq for ZwlrOutputConfigurationV1
impl PartialEq for ZwlrOutputConfigurationV1
source§fn eq(&self, other: &ZwlrOutputConfigurationV1) -> bool
fn eq(&self, other: &ZwlrOutputConfigurationV1) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl Proxy for ZwlrOutputConfigurationV1
impl Proxy for ZwlrOutputConfigurationV1
source§fn data<U: Send + Sync + 'static>(&self) -> Option<&U>
fn data<U: Send + Sync + 'static>(&self) -> Option<&U>
source§fn object_data(&self) -> Option<&Arc<dyn ObjectData>>
fn object_data(&self) -> Option<&Arc<dyn ObjectData>>
source§fn backend(&self) -> &WeakBackend
fn backend(&self) -> &WeakBackend
source§fn send_request(&self, req: Self::Request<'_>) -> Result<(), InvalidId>
fn send_request(&self, req: Self::Request<'_>) -> Result<(), InvalidId>
source§fn send_constructor<I: Proxy>(
&self,
req: Self::Request<'_>,
data: Arc<dyn ObjectData>,
) -> Result<I, InvalidId>
fn send_constructor<I: Proxy>( &self, req: Self::Request<'_>, data: Arc<dyn ObjectData>, ) -> Result<I, InvalidId>
source§fn from_id(conn: &Connection, id: ObjectId) -> Result<Self, InvalidId>
fn from_id(conn: &Connection, id: ObjectId) -> Result<Self, InvalidId>
source§fn inert(backend: WeakBackend) -> Self
fn inert(backend: WeakBackend) -> Self
source§fn parse_event(
conn: &Connection,
msg: Message<ObjectId, OwnedFd>,
) -> Result<(Self, Self::Event), DispatchError>
fn parse_event( conn: &Connection, msg: Message<ObjectId, OwnedFd>, ) -> Result<(Self, Self::Event), DispatchError>
source§fn write_request<'a>(
&self,
conn: &Connection,
msg: Self::Request<'a>,
) -> Result<(Message<ObjectId, BorrowedFd<'a>>, Option<(&'static Interface, u32)>), InvalidId>
fn write_request<'a>( &self, conn: &Connection, msg: Self::Request<'a>, ) -> Result<(Message<ObjectId, BorrowedFd<'a>>, Option<(&'static Interface, u32)>), InvalidId>
impl Eq for ZwlrOutputConfigurationV1
Auto Trait Implementations§
impl Freeze for ZwlrOutputConfigurationV1
impl !RefUnwindSafe for ZwlrOutputConfigurationV1
impl Send for ZwlrOutputConfigurationV1
impl Sync for ZwlrOutputConfigurationV1
impl Unpin for ZwlrOutputConfigurationV1
impl !UnwindSafe for ZwlrOutputConfigurationV1
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
source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.