You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Trac3r-rust/doc/wayland_client/protocol/wl_subsurface/trait.RequestsTrait.html

78 lines
16 KiB

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="API documentation for the Rust `RequestsTrait` trait in crate `wayland_client`."><meta name="keywords" content="rust, rustlang, rust-lang, RequestsTrait"><title>wayland_client::protocol::wl_subsurface::RequestsTrait - Rust</title><link rel="stylesheet" type="text/css" href="../../../normalize.css"><link rel="stylesheet" type="text/css" href="../../../rustdoc.css" id="mainThemeStyle"><link rel="stylesheet" type="text/css" href="../../../dark.css"><link rel="stylesheet" type="text/css" href="../../../light.css" id="themeStyle"><script src="../../../storage.js"></script><noscript><link rel="stylesheet" href="../../../noscript.css"></noscript><link rel="shortcut icon" href="../../../favicon.ico"><style type="text/css">#crate-search{background-image:url("../../../down-arrow.svg");}</style></head><body class="rustdoc trait"><!--[if lte IE 8]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="sidebar"><div class="sidebar-menu">&#9776;</div><a href='../../../wayland_client/index.html'><div class='logo-container'><img src='../../../rust-logo.png' alt='logo'></div></a><p class='location'>Trait RequestsTrait</p><div class="sidebar-elems"><div class="block items"><a class="sidebar-title" href="#required-methods">Required Methods</a><div class="sidebar-links"><a href="#tymethod.destroy">destroy</a><a href="#tymethod.place_above">place_above</a><a href="#tymethod.place_below">place_below</a><a href="#tymethod.set_desync">set_desync</a><a href="#tymethod.set_position">set_position</a><a href="#tymethod.set_sync">set_sync</a></div><a class="sidebar-title" href="#implementors">Implementors</a></div><p class='location'><a href='../../index.html'>wayland_client</a>::<wbr><a href='../index.html'>protocol</a>::<wbr><a href='index.html'>wl_subsurface</a></p><script>window.sidebarCurrent = {name: 'RequestsTrait', ty: 'trait', relpath: ''};</script><script defer src="sidebar-items.js"></script></div></nav><div class="theme-picker"><button id="theme-picker" aria-label="Pick another theme!"><img src="../../../brush.svg" width="18" alt="Pick another theme!"></button><div id="theme-choices"></div></div><script src="../../../theme.js"></script><nav class="sub"><form class="search-form js-only"><div class="search-container"><div><select id="crate-search"><option value="All crates">All crates</option></select><input class="search-input" name="search" autocomplete="off" spellcheck="false" placeholder="Click or press S to search, ? for more options…" type="search"></div><a id="settings-menu" href="../../../settings.html"><img src="../../../wheel.svg" width="18" alt="Change settings"></a></div></form></nav><section id="main" class="content"><h1 class='fqn'><span class='out-of-band'><span id='render-detail'><a id="toggle-all-docs" href="javascript:void(0)" title="collapse all docs">[<span class='inner'>&#x2212;</span>]</a></span><a class='srclink' href='../../../src/wayland_client/home/mrh/source/Trac3r-rust/target/debug/build/wayland-client-893466244f089367/out/wayland_c_api.rs.html#1' title='goto source code'>[src]</a></span><span class='in-band'>Trait <a href='../../index.html'>wayland_client</a>::<wbr><a href='../index.html'>protocol</a>::<wbr><a href='index.html'>wl_subsurface</a>::<wbr><a class="trait" href=''>RequestsTrait</a></span></h1><div class="docblock type-decl hidden-by-usual-hider"><pre class='rust trait'>pub trait RequestsTrait {
fn <a href='#tymethod.destroy' class='fnname'>destroy</a>(&amp;self);
<div class='item-spacer'></div> fn <a href='#tymethod.set_position' class='fnname'>set_position</a>(&amp;self, x: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i32.html">i32</a>, y: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i32.html">i32</a>);
<div class='item-spacer'></div> fn <a href='#tymethod.place_above' class='fnname'>place_above</a>(&amp;self, sibling: &amp;<a class="struct" href="../../../wayland_client/struct.Proxy.html" title="struct wayland_client::Proxy">Proxy</a>&lt;<a class="struct" href="../../../wayland_client/protocol/wl_surface/struct.WlSurface.html" title="struct wayland_client::protocol::wl_surface::WlSurface">WlSurface</a>&gt;);
<div class='item-spacer'></div> fn <a href='#tymethod.place_below' class='fnname'>place_below</a>(&amp;self, sibling: &amp;<a class="struct" href="../../../wayland_client/struct.Proxy.html" title="struct wayland_client::Proxy">Proxy</a>&lt;<a class="struct" href="../../../wayland_client/protocol/wl_surface/struct.WlSurface.html" title="struct wayland_client::protocol::wl_surface::WlSurface">WlSurface</a>&gt;);
<div class='item-spacer'></div> fn <a href='#tymethod.set_sync' class='fnname'>set_sync</a>(&amp;self);
<div class='item-spacer'></div> fn <a href='#tymethod.set_desync' class='fnname'>set_desync</a>(&amp;self);
}</pre></div>
<h2 id='required-methods' class='small-section-header'>Required methods<a href='#required-methods' class='anchor'></a></h2><div class='methods'><h3 id='tymethod.destroy' class='method'><code id='destroy.v'>fn <a href='#tymethod.destroy' class='fnname'>destroy</a>(&amp;self)</code></h3><div class='docblock'><p>remove sub-surface interface</p>
<p>The sub-surface interface is removed from the wl_surface object
that was turned into a sub-surface with a
wl_subcompositor.get_subsurface request. The wl_surface's association
to the parent is deleted, and the wl_surface loses its role as
a sub-surface. The wl_surface is unmapped.</p>
<p>This is a destructor, you cannot send requests to this object any longer once this method is called.</p>
</div><h3 id='tymethod.set_position' class='method'><code id='set_position.v'>fn <a href='#tymethod.set_position' class='fnname'>set_position</a>(&amp;self, x: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i32.html">i32</a>, y: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i32.html">i32</a>)</code></h3><div class='docblock'><p>reposition the sub-surface</p>
<p>This schedules a sub-surface position change.
The sub-surface will be moved so that its origin (top left
corner pixel) will be at the location x, y of the parent surface
coordinate system. The coordinates are not restricted to the parent
surface area. Negative values are allowed.</p>
<p>The scheduled coordinates will take effect whenever the state of the
parent surface is applied. When this happens depends on whether the
parent surface is in synchronized mode or not. See
wl_subsurface.set_sync and wl_subsurface.set_desync for details.</p>
<p>If more than one set_position request is invoked by the client before
the commit of the parent surface, the position of a new request always
replaces the scheduled position from any previous request.</p>
<p>The initial position is 0, 0.</p>
</div><h3 id='tymethod.place_above' class='method'><code id='place_above.v'>fn <a href='#tymethod.place_above' class='fnname'>place_above</a>(&amp;self, sibling: &amp;<a class="struct" href="../../../wayland_client/struct.Proxy.html" title="struct wayland_client::Proxy">Proxy</a>&lt;<a class="struct" href="../../../wayland_client/protocol/wl_surface/struct.WlSurface.html" title="struct wayland_client::protocol::wl_surface::WlSurface">WlSurface</a>&gt;)</code></h3><div class='docblock'><p>restack the sub-surface</p>
<p>This sub-surface is taken from the stack, and put back just
above the reference surface, changing the z-order of the sub-surfaces.
The reference surface must be one of the sibling surfaces, or the
parent surface. Using any other surface, including this sub-surface,
will cause a protocol error.</p>
<p>The z-order is double-buffered. Requests are handled in order and
applied immediately to a pending state. The final pending state is
copied to the active state the next time the state of the parent
surface is applied. When this happens depends on whether the parent
surface is in synchronized mode or not. See wl_subsurface.set_sync and
wl_subsurface.set_desync for details.</p>
<p>A new sub-surface is initially added as the top-most in the stack
of its siblings and parent.</p>
</div><h3 id='tymethod.place_below' class='method'><code id='place_below.v'>fn <a href='#tymethod.place_below' class='fnname'>place_below</a>(&amp;self, sibling: &amp;<a class="struct" href="../../../wayland_client/struct.Proxy.html" title="struct wayland_client::Proxy">Proxy</a>&lt;<a class="struct" href="../../../wayland_client/protocol/wl_surface/struct.WlSurface.html" title="struct wayland_client::protocol::wl_surface::WlSurface">WlSurface</a>&gt;)</code></h3><div class='docblock'><p>restack the sub-surface</p>
<p>The sub-surface is placed just below the reference surface.
See wl_subsurface.place_above.</p>
</div><h3 id='tymethod.set_sync' class='method'><code id='set_sync.v'>fn <a href='#tymethod.set_sync' class='fnname'>set_sync</a>(&amp;self)</code></h3><div class='docblock'><p>set sub-surface to synchronized mode</p>
<p>Change the commit behaviour of the sub-surface to synchronized
mode, also described as the parent dependent mode.</p>
<p>In synchronized mode, wl_surface.commit on a sub-surface will
accumulate the committed state in a cache, but the state will
not be applied and hence will not change the compositor output.
The cached state is applied to the sub-surface immediately after
the parent surface's state is applied. This ensures atomic
updates of the parent and all its synchronized sub-surfaces.
Applying the cached state will invalidate the cache, so further
parent surface commits do not (re-)apply old state.</p>
<p>See wl_subsurface for the recursive effect of this mode.</p>
</div><h3 id='tymethod.set_desync' class='method'><code id='set_desync.v'>fn <a href='#tymethod.set_desync' class='fnname'>set_desync</a>(&amp;self)</code></h3><div class='docblock'><p>set sub-surface to desynchronized mode</p>
<p>Change the commit behaviour of the sub-surface to desynchronized
mode, also described as independent or freely running mode.</p>
<p>In desynchronized mode, wl_surface.commit on a sub-surface will
apply the pending state directly, without caching, as happens
normally with a wl_surface. Calling wl_surface.commit on the
parent surface has no effect on the sub-surface's wl_surface
state. This mode allows a sub-surface to be updated on its own.</p>
<p>If cached state exists when wl_surface.commit is called in
desynchronized mode, the pending state is added to the cached
state, and applied as a whole. This invalidates the cache.</p>
<p>Note: even if a sub-surface is set to desynchronized, a parent
sub-surface may override it to behave as synchronized. For details,
see wl_subsurface.</p>
<p>If a surface's parent surface behaves as desynchronized, then
the cached state is applied on set_desync.</p>
</div></div><span class='loading-content'>Loading content...</span>
<h2 id='implementors' class='small-section-header'>Implementors<a href='#implementors' class='anchor'></a></h2><div class='item-list' id='implementors-list'><h3 id='impl-RequestsTrait' class='impl'><code class='in-band'>impl RequestsTrait for <a class="struct" href="../../../wayland_client/struct.Proxy.html" title="struct wayland_client::Proxy">Proxy</a>&lt;<a class="struct" href="../../../wayland_client/protocol/wl_subsurface/struct.WlSubsurface.html" title="struct wayland_client::protocol::wl_subsurface::WlSubsurface">WlSubsurface</a>&gt;</code><a href='#impl-RequestsTrait' class='anchor'></a><a class='srclink' href='../../../src/wayland_client/home/mrh/source/Trac3r-rust/target/debug/build/wayland-client-893466244f089367/out/wayland_c_api.rs.html#1' title='goto source code'>[src]</a></h3><div class='impl-items'><h4 id='method.destroy' class="method hidden"><code id='destroy.v-1'>fn <a href='#method.destroy' class='fnname'>destroy</a>(&amp;self)</code><a class='srclink' href='../../../src/wayland_client/home/mrh/source/Trac3r-rust/target/debug/build/wayland-client-893466244f089367/out/wayland_c_api.rs.html#1' title='goto source code'>[src]</a></h4><h4 id='method.set_position' class="method hidden"><code id='set_position.v-1'>fn <a href='#method.set_position' class='fnname'>set_position</a>(&amp;self, x: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i32.html">i32</a>, y: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.i32.html">i32</a>)</code><a class='srclink' href='../../../src/wayland_client/home/mrh/source/Trac3r-rust/target/debug/build/wayland-client-893466244f089367/out/wayland_c_api.rs.html#1' title='goto source code'>[src]</a></h4><h4 id='method.place_above' class="method hidden"><code id='place_above.v-1'>fn <a href='#method.place_above' class='fnname'>place_above</a>(&amp;self, sibling: &amp;<a class="struct" href="../../../wayland_client/struct.Proxy.html" title="struct wayland_client::Proxy">Proxy</a>&lt;<a class="struct" href="../../../wayland_client/protocol/wl_surface/struct.WlSurface.html" title="struct wayland_client::protocol::wl_surface::WlSurface">WlSurface</a>&gt;)</code><a class='srclink' href='../../../src/wayland_client/home/mrh/source/Trac3r-rust/target/debug/build/wayland-client-893466244f089367/out/wayland_c_api.rs.html#1' title='goto source code'>[src]</a></h4><h4 id='method.place_below' class="method hidden"><code id='place_below.v-1'>fn <a href='#method.place_below' class='fnname'>place_below</a>(&amp;self, sibling: &amp;<a class="struct" href="../../../wayland_client/struct.Proxy.html" title="struct wayland_client::Proxy">Proxy</a>&lt;<a class="struct" href="../../../wayland_client/protocol/wl_surface/struct.WlSurface.html" title="struct wayland_client::protocol::wl_surface::WlSurface">WlSurface</a>&gt;)</code><a class='srclink' href='../../../src/wayland_client/home/mrh/source/Trac3r-rust/target/debug/build/wayland-client-893466244f089367/out/wayland_c_api.rs.html#1' title='goto source code'>[src]</a></h4><h4 id='method.set_sync' class="method hidden"><code id='set_sync.v-1'>fn <a href='#method.set_sync' class='fnname'>set_sync</a>(&amp;self)</code><a class='srclink' href='../../../src/wayland_client/home/mrh/source/Trac3r-rust/target/debug/build/wayland-client-893466244f089367/out/wayland_c_api.rs.html#1' title='goto source code'>[src]</a></h4><h4 id='method.set_desync' class="method hidden"><code id='set_desync.v-1'>fn <a href='#method.set_desync' class='fnname'>set_desync</a>(&amp;self)</code><a class='srclink' href='../../../src/wayland_client/home/mrh/source/Trac3r-rust/target/debug/build/wayland-client-893466244f089367/out/wayland_c_api.rs.html#1' title='goto source code'>[src]</a></h4></div></div><span class='loading-content'>Loading content...</span><script type="text/javascript">window.inlined_types=new Set([]);</script><script type="text/javascript" async
src="../../../implementors/wayland_client/protocol/wl_subsurface/trait.RequestsTrait.js">
</script></section><section id="search" class="content hidden"></section><section class="footer"></section><aside id="help" class="hidden"><div><h1 class="hidden">Help</h1><div class="shortcuts"><h2>Keyboard Shortcuts</h2><dl><dt><kbd>?</kbd></dt><dd>Show this help dialog</dd><dt><kbd>S</kbd></dt><dd>Focus the search field</dd><dt><kbd></kbd></dt><dd>Move up in search results</dd><dt><kbd></kbd></dt><dd>Move down in search results</dd><dt><kbd></kbd></dt><dd>Switch tab</dd><dt><kbd>&#9166;</kbd></dt><dd>Go to active search result</dd><dt><kbd>+</kbd></dt><dd>Expand all sections</dd><dt><kbd>-</kbd></dt><dd>Collapse all sections</dd></dl></div><div class="infos"><h2>Search Tricks</h2><p>Prefix searches with a type followed by a colon (e.g., <code>fn:</code>) to restrict the search to a given type.</p><p>Accepted types are: <code>fn</code>, <code>mod</code>, <code>struct</code>, <code>enum</code>, <code>trait</code>, <code>type</code>, <code>macro</code>, and <code>const</code>.</p><p>Search functions by type signature (e.g., <code>vec -> usize</code> or <code>* -> vec</code>)</p><p>Search multiple things at once by splitting your query with comma (e.g., <code>str,u8</code> or <code>String,struct:Vec,test</code>)</p></div></div></aside><script>window.rootPath = "../../../";window.currentCrate = "wayland_client";</script><script src="../../../aliases.js"></script><script src="../../../main.js"></script><script defer src="../../../search-index.js"></script></body></html>