Struct wayland_protocols::wp::viewporter::client::wp_viewporter::WpViewporter
source · pub struct WpViewporter {
id: ObjectId,
version: u32,
data: Option<Arc<dyn ObjectData>>,
backend: WeakBackend,
}
Expand description
surface cropping and scaling
The global interface exposing surface cropping and scaling capabilities is used to instantiate an interface extension for a wl_surface object. This extended interface will then allow cropping and scaling the surface contents, effectively disconnecting the direct relationship between the buffer and the surface size.
This interface has no events.
Fields§
§id: ObjectId
§version: u32
§data: Option<Arc<dyn ObjectData>>
§backend: WeakBackend
Implementations§
source§impl WpViewporter
impl WpViewporter
sourcepub fn destroy(&self)
pub fn destroy(&self)
unbind from the cropping and scaling interface
Informs the server that the client will not be using this protocol object anymore. This does not affect any other objects, wp_viewport objects included.
sourcepub fn get_viewport<U: Send + Sync + 'static, D: Dispatch<WpViewport, U> + 'static>(
&self,
surface: &WlSurface,
qh: &QueueHandle<D>,
udata: U,
) -> WpViewport
pub fn get_viewport<U: Send + Sync + 'static, D: Dispatch<WpViewport, U> + 'static>( &self, surface: &WlSurface, qh: &QueueHandle<D>, udata: U, ) -> WpViewport
extend surface interface for crop and scale
Instantiate an interface extension for the given wl_surface to crop and scale its content. If the given wl_surface already has a wp_viewport object associated, the viewport_exists protocol error is raised.
Trait Implementations§
source§impl Borrow<ObjectId> for WpViewporter
impl Borrow<ObjectId> for WpViewporter
source§impl Clone for WpViewporter
impl Clone for WpViewporter
source§fn clone(&self) -> WpViewporter
fn clone(&self) -> WpViewporter
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for WpViewporter
impl Debug for WpViewporter
source§impl Hash for WpViewporter
impl Hash for WpViewporter
source§impl PartialEq<Weak<WpViewporter>> for WpViewporter
impl PartialEq<Weak<WpViewporter>> for WpViewporter
source§impl PartialEq for WpViewporter
impl PartialEq for WpViewporter
source§fn eq(&self, other: &WpViewporter) -> bool
fn eq(&self, other: &WpViewporter) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl Proxy for WpViewporter
impl Proxy for WpViewporter
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 WpViewporter
Auto Trait Implementations§
impl Freeze for WpViewporter
impl !RefUnwindSafe for WpViewporter
impl Send for WpViewporter
impl Sync for WpViewporter
impl Unpin for WpViewporter
impl !UnwindSafe for WpViewporter
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.