rusty_snek_gaem/target/doc/window/struct.WindowSettings.html
2018-10-28 21:14:05 -05:00

156 lines
39 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!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 `WindowSettings` struct in crate `window`."><meta name="keywords" content="rust, rustlang, rust-lang, WindowSettings"><title>window::WindowSettings - 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></head><body class="rustdoc struct"><!--[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><p class='location'>Struct WindowSettings</p><div class="sidebar-elems"><div class="block items"><a class="sidebar-title" href="#methods">Methods</a><div class="sidebar-links"><a href="#method.new">new</a><a href="#method.build">build</a><a href="#method.get_title">get_title</a><a href="#method.set_title">set_title</a><a href="#method.title">title</a><a href="#method.get_size">get_size</a><a href="#method.set_size">set_size</a><a href="#method.size">size</a><a href="#method.get_fullscreen">get_fullscreen</a><a href="#method.set_fullscreen">set_fullscreen</a><a href="#method.fullscreen">fullscreen</a><a href="#method.get_exit_on_esc">get_exit_on_esc</a><a href="#method.set_exit_on_esc">set_exit_on_esc</a><a href="#method.exit_on_esc">exit_on_esc</a><a href="#method.get_samples">get_samples</a><a href="#method.set_samples">set_samples</a><a href="#method.samples">samples</a><a href="#method.get_vsync">get_vsync</a><a href="#method.set_vsync">set_vsync</a><a href="#method.vsync">vsync</a><a href="#method.get_maybe_opengl">get_maybe_opengl</a><a href="#method.set_maybe_opengl">set_maybe_opengl</a><a href="#method.maybe_opengl">maybe_opengl</a><a href="#method.set_opengl">set_opengl</a><a href="#method.opengl">opengl</a><a href="#method.get_srgb">get_srgb</a><a href="#method.set_srgb">set_srgb</a><a href="#method.srgb">srgb</a><a href="#method.get_resizable">get_resizable</a><a href="#method.set_resizable">set_resizable</a><a href="#method.resizable">resizable</a><a href="#method.get_decorated">get_decorated</a><a href="#method.set_decorated">set_decorated</a><a href="#method.decorated">decorated</a><a href="#method.get_controllers">get_controllers</a><a href="#method.set_controllers">set_controllers</a><a href="#method.controllers">controllers</a></div><a class="sidebar-title" href="#implementations">Trait Implementations</a><div class="sidebar-links"><a href="#impl-Clone">Clone</a></div><a class="sidebar-title" href="#synthetic-implementations">Auto Trait Implementations</a><div class="sidebar-links"><a href="#impl-Send">Send</a><a href="#impl-Sync">Sync</a></div></div><p class='location'><a href='index.html'>window</a></p><script>window.sidebarCurrent = {name: 'WindowSettings', ty: 'struct', 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"><input class="search-input" name="search" autocomplete="off" placeholder="Click or press S to search, ? for more options…" type="search"><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='in-band'>Struct <a href='index.html'>window</a>::<wbr><a class="struct" href=''>WindowSettings</a></span><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/window/lib.rs.html#339-351' title='goto source code'>[src]</a></span></h1><div class="docblock type-decl"><pre class='rust struct'>pub struct WindowSettings { /* fields omitted */ }</pre></div><div class='docblock'><p>Settings structure for window behavior.</p>
<p>This structure stores everything that needs to be customized when
constructing most windows. This structure makes it easy to create multiple
windows with the same settings, and it also makes piston's multiple backends
easier to implement for piston devs.</p>
</div><h2 id='methods' class='small-section-header'>Methods<a href='#methods' class='anchor'></a></h2><h3 id='impl' class='impl'><span class='in-band'><table class='table-display'><tbody><tr><td><code>impl <a class="struct" href="../window/struct.WindowSettings.html" title="struct window::WindowSettings">WindowSettings</a></code><a href='#impl' class='anchor'></a></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#353-713' title='goto source code'>[src]</a></span></td></tr></tbody></table></h3><div class='impl-items'><h4 id='method.new' class="method"><span id='new.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.new' class='fnname'>new</a>&lt;T:&nbsp;<a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;<a class="struct" href="https://doc.rust-lang.org/nightly/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>&gt;, S:&nbsp;<a class="trait" href="https://doc.rust-lang.org/nightly/core/convert/trait.Into.html" title="trait core::convert::Into">Into</a>&lt;<a class="struct" href="../window/struct.Size.html" title="struct window::Size">Size</a>&gt;&gt;(title: T, size: S) -&gt; <a class="struct" href="../window/struct.WindowSettings.html" title="struct window::WindowSettings">WindowSettings</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#364-378' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Creates window settings with defaults.</p>
<ul>
<li>samples: 0</li>
<li>fullscreen: false</li>
<li>exit_on_esc: false</li>
<li>vsync: false</li>
<li>srgb: true</li>
<li>resizable: true</li>
<li>decorated: true</li>
<li>controllers: true</li>
</ul>
</div><h4 id='method.build' class="method"><span id='build.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.build' class='fnname'>build</a>&lt;W:&nbsp;<a class="trait" href="../window/trait.BuildFromWindowSettings.html" title="trait window::BuildFromWindowSettings">BuildFromWindowSettings</a>&gt;(&amp;self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/result/enum.Result.html" title="enum core::result::Result">Result</a>&lt;W, <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>&gt;</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#391-393' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Builds window from the given settings.</p>
<p>The return value is ambiguous, to allow for operation on multiple
backends. Clients should explicitly name the return type. See the
Guide to using Piston Windows for more info and examples.</p>
<h1 id="errors" class="section-header"><a href="#errors">Errors</a></h1>
<p>This function will return an error if your backend returns an error.
See your backend's documentation on <code>build_from_window_settings()</code>
for more details.</p>
</div><h4 id='method.get_title' class="method"><span id='get_title.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_title' class='fnname'>get_title</a>(&amp;self) -&gt; <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/string/struct.String.html" title="struct alloc::string::String">String</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#396-398' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets the title of built windows.</p>
</div><h4 id='method.set_title' class="method"><span id='set_title.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_title' class='fnname'>set_title</a>(&amp;mut self, value: <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#401-403' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets the title of built windows.</p>
</div><h4 id='method.title' class="method"><span id='title.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.title' class='fnname'>title</a>(self, value: <a class="struct" href="https://doc.rust-lang.org/nightly/alloc/string/struct.String.html" title="struct alloc::string::String">String</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#410-413' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets the title of built windows.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_title"><code>set_title()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_size' class="method"><span id='get_size.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_size' class='fnname'>get_size</a>(&amp;self) -&gt; <a class="struct" href="../window/struct.Size.html" title="struct window::Size">Size</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#416-418' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets the size of built windows.</p>
</div><h4 id='method.set_size' class="method"><span id='set_size.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_size' class='fnname'>set_size</a>(&amp;mut self, value: <a class="struct" href="../window/struct.Size.html" title="struct window::Size">Size</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#421-423' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets the size of built windows.</p>
</div><h4 id='method.size' class="method"><span id='size.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.size' class='fnname'>size</a>(self, value: <a class="struct" href="../window/struct.Size.html" title="struct window::Size">Size</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#430-433' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets the size of built windows.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_size"><code>set_size()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_fullscreen' class="method"><span id='get_fullscreen.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_fullscreen' class='fnname'>get_fullscreen</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#436-438' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets whether built windows will be fullscreen.</p>
</div><h4 id='method.set_fullscreen' class="method"><span id='set_fullscreen.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_fullscreen' class='fnname'>set_fullscreen</a>(&amp;mut self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#441-443' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows will be fullscreen.</p>
</div><h4 id='method.fullscreen' class="method"><span id='fullscreen.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.fullscreen' class='fnname'>fullscreen</a>(self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#450-453' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows will be fullscreen.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_fullscreen"><code>set_fullscreen()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_exit_on_esc' class="method"><span id='get_exit_on_esc.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_exit_on_esc' class='fnname'>get_exit_on_esc</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#456-458' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets whether built windows should exit when the Esc key is pressed.</p>
</div><h4 id='method.set_exit_on_esc' class="method"><span id='set_exit_on_esc.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_exit_on_esc' class='fnname'>set_exit_on_esc</a>(&amp;mut self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#461-463' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should exit when the Esc key is pressed.</p>
</div><h4 id='method.exit_on_esc' class="method"><span id='exit_on_esc.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.exit_on_esc' class='fnname'>exit_on_esc</a>(self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#470-473' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should exit when the Esc key is pressed.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_exit_on_esc"><code>set_exit_on_esc()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_samples' class="method"><span id='get_samples.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_samples' class='fnname'>get_samples</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#479-481' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets the number of samples to use for anti-aliasing.</p>
<p>See https://en.wikipedia.org/wiki/Multisample_anti-aliasing
for more information.</p>
</div><h4 id='method.set_samples' class="method"><span id='set_samples.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_samples' class='fnname'>set_samples</a>(&amp;mut self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#487-489' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets the number of samples to use for anti-aliasing.</p>
<p>See https://en.wikipedia.org/wiki/Multisample_anti-aliasing
for more information.</p>
</div><h4 id='method.samples' class="method"><span id='samples.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.samples' class='fnname'>samples</a>(self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.u8.html">u8</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#499-502' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets the number of samples to use for anti-aliasing.</p>
<p>See https://en.wikipedia.org/wiki/Multisample_anti-aliasing
for more information.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_samples"><code>set_samples()</code></a>
so that it can be used in method chaining.</p>
</div><h4 id='method.get_vsync' class="method"><span id='get_vsync.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_vsync' class='fnname'>get_vsync</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#508-510' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets whether built windows should use vsync.</p>
<p>See https://en.wikipedia.org/wiki/Screen_tearing for more information
about vsync.</p>
</div><h4 id='method.set_vsync' class="method"><span id='set_vsync.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_vsync' class='fnname'>set_vsync</a>(&amp;mut self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#516-518' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should use vsync.</p>
<p>See https://en.wikipedia.org/wiki/Screen_tearing for more information
about vsync.</p>
</div><h4 id='method.vsync' class="method"><span id='vsync.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.vsync' class='fnname'>vsync</a>(self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#528-531' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should use vsync.</p>
<p>See https://en.wikipedia.org/wiki/Screen_tearing for more information
about vsync.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_vsync"><code>set_vsync()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_maybe_opengl' class="method"><span id='get_maybe_opengl.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_maybe_opengl' class='fnname'>get_maybe_opengl</a>(&amp;self) -&gt; <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="../shader_version/opengl/enum.OpenGL.html" title="enum shader_version::opengl::OpenGL">OpenGL</a>&gt;</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#541-543' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets the OpenGL version of built windows.</p>
<p>If None is returned, the default OpenGL version is being used. This
is often a forward compatible version of OpenGL::V3_2 or
higher that works with newer versions of graphics libraries.</p>
<p>For more information about the OpenGL setting, see the
<a href="trait.OpenGLWindow.html"><code>OpenGLWindow</code></a> trait.</p>
</div><h4 id='method.set_maybe_opengl' class="method"><span id='set_maybe_opengl.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_maybe_opengl' class='fnname'>set_maybe_opengl</a>(&amp;mut self, value: <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="../shader_version/opengl/enum.OpenGL.html" title="enum shader_version::opengl::OpenGL">OpenGL</a>&gt;)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#553-555' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets OpenGL version of built windows.</p>
<p>If None is passed, the default OpenGL version is used. This
is often a forward compatible version of OpenGL::V3_2 or
higher that works with newer versions of graphics libraries.</p>
<p>For more information about the OpenGL setting, see the
<a href="trait.OpenGLWindow.html"><code>OpenGLWindow</code></a> trait.</p>
</div><h4 id='method.maybe_opengl' class="method"><span id='maybe_opengl.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.maybe_opengl' class='fnname'>maybe_opengl</a>(self, value: <a class="enum" href="https://doc.rust-lang.org/nightly/core/option/enum.Option.html" title="enum core::option::Option">Option</a>&lt;<a class="enum" href="../shader_version/opengl/enum.OpenGL.html" title="enum shader_version::opengl::OpenGL">OpenGL</a>&gt;) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#569-572' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets OpenGL version of built windows.</p>
<p>If None is passed, the default OpenGL version is used. This
is often a forward compatible version of OpenGL::V3_2 or
higher that works with newer versions of graphics libraries.</p>
<p>For more information about the OpenGL setting, see the
<a href="./trait.OpenGLWindow.html"><code>OpenGLWindow</code></a> trait.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_maybe_opengl"><code>set_maybe_opengl()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.set_opengl' class="method"><span id='set_opengl.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_opengl' class='fnname'>set_opengl</a>(&amp;mut self, value: <a class="enum" href="../shader_version/opengl/enum.OpenGL.html" title="enum shader_version::opengl::OpenGL">OpenGL</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#581-583' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets OpenGL version of built windows.</p>
<p>For setting the OpenGL version back to default, see
<a href="#method.set_maybe_opengl"><code>set_maybe_opengl()</code></a>.</p>
<p>For more information about the opengl setting, see the
<a href="./trait.OpenGLWindow.html"><code>OpenGLWindow</code></a> trait.</p>
</div><h4 id='method.opengl' class="method"><span id='opengl.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.opengl' class='fnname'>opengl</a>(self, value: <a class="enum" href="../shader_version/opengl/enum.OpenGL.html" title="enum shader_version::opengl::OpenGL">OpenGL</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#596-599' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets the OpenGL version of built windows.</p>
<p>For setting the OpenGL version back to default, see
<a href="#method.maybe_opengl"><code>maybe_opengl()</code></a>.</p>
<p>For more information about the opengl setting, see the
<a href="./trait.OpenGLWindow.html"><code>OpenGLWindow</code></a> trait.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_opengl"><code>set_opengl()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_srgb' class="method"><span id='get_srgb.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_srgb' class='fnname'>get_srgb</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#611-613' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets whether built windows should use hardware accelerated color conversion.</p>
<p>If true, the graphics hardware uses customized circuitry
to convert colors from sRGB to linear color space in graphics
shaders, and then converts pixel fragments back to sRGB
depending on the color format of the frame buffer. This feature
is supported by most graphics hardware and set to true by
default.</p>
<p>See https://en.wikipedia.org/wiki/SRGB for more information.</p>
</div><h4 id='method.set_srgb' class="method"><span id='set_srgb.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_srgb' class='fnname'>set_srgb</a>(&amp;mut self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#619-621' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should use hardware accelerated color conversion.</p>
<p>See <a href="#method.get_srgb"><code>get_srgb()</code></a> for more information about
the srgb setting.</p>
</div><h4 id='method.srgb' class="method"><span id='srgb.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.srgb' class='fnname'>srgb</a>(self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#631-634' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should use hardware accelerated color conversion.</p>
<p>See <a href="#method.get_srgb"><code>get_srgb()</code></a> for more information about
the srgb setting.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_srgb"><code>set_srgb()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_resizable' class="method"><span id='get_resizable.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_resizable' class='fnname'>get_resizable</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#637-639' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets whether built windows should be resizable.</p>
</div><h4 id='method.set_resizable' class="method"><span id='set_resizable.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_resizable' class='fnname'>set_resizable</a>(&amp;mut self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#642-644' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should be resizable.</p>
</div><h4 id='method.resizable' class="method"><span id='resizable.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.resizable' class='fnname'>resizable</a>(self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#651-654' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should be resizable.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_resizable"><code>set_resizable()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_decorated' class="method"><span id='get_decorated.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_decorated' class='fnname'>get_decorated</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#663-665' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets whether built windows should be decorated.</p>
<p>Decoration on a window refers to the Operating System's
header above the window, and the window border.</p>
<p>For more information, see
https://en.wikipedia.org/wiki/Window_decoration</p>
</div><h4 id='method.set_decorated' class="method"><span id='set_decorated.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_decorated' class='fnname'>set_decorated</a>(&amp;mut self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#674-676' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should be decorated.</p>
<p>Decoration on a window refers to the Operating System's
header above the window, and the window border.</p>
<p>For more information, see
https://en.wikipedia.org/wiki/Window_decoration</p>
</div><h4 id='method.decorated' class="method"><span id='decorated.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.decorated' class='fnname'>decorated</a>(self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#689-692' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should be decorated.</p>
<p>Decoration on a window refers to the Operating System's
header above the window, and the window border.</p>
<p>For more information, see
https://en.wikipedia.org/wiki/Window_decoration</p>
<p>This method moves the current window data,
unlike <a href="#method.set_decorated"><code>set_decorated()</code></a>,
so that it can be used in method chaining.</p>
</div><h4 id='method.get_controllers' class="method"><span id='get_controllers.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.get_controllers' class='fnname'>get_controllers</a>(&amp;self) -&gt; <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#695-697' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Gets whether built windows should listen to controller input.</p>
</div><h4 id='method.set_controllers' class="method"><span id='set_controllers.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.set_controllers' class='fnname'>set_controllers</a>(&amp;mut self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#700-702' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether built windows should listen to controller input.</p>
</div><h4 id='method.controllers' class="method"><span id='controllers.v' class='invisible'><table class='table-display'><tbody><tr><td><code>pub fn <a href='#method.controllers' class='fnname'>controllers</a>(self, value: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.bool.html">bool</a>) -&gt; Self</code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#709-712' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Sets whether build windows should listen to controller input.</p>
<p>This method moves the current window data,
unlike <a href="#method.set_controllers"><code>set_controllers()</code></a>,
so that it can be used in method chaining.</p>
</div></div><h2 id='implementations' class='small-section-header'>Trait Implementations<a href='#implementations' class='anchor'></a></h2><div id='implementations-list'><h3 id='impl-Clone' class='impl'><span class='in-band'><table class='table-display'><tbody><tr><td><code>impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html" title="trait core::clone::Clone">Clone</a> for <a class="struct" href="../window/struct.WindowSettings.html" title="struct window::WindowSettings">WindowSettings</a></code><a href='#impl-Clone' class='anchor'></a></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#338' title='goto source code'>[src]</a></span></td></tr></tbody></table></h3><div class='impl-items'><h4 id='method.clone' class="method"><span id='clone.v' class='invisible'><table class='table-display'><tbody><tr><td><code>fn <a href='https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#tymethod.clone' class='fnname'>clone</a>(&amp;self) -&gt; <a class="struct" href="../window/struct.WindowSettings.html" title="struct window::WindowSettings">WindowSettings</a></code></span></td><td><span class='out-of-band'><div class='ghost'></div><a class='srclink' href='../src/window/lib.rs.html#338' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Returns a copy of the value. <a href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#tymethod.clone">Read more</a></p>
</div><h4 id='method.clone_from' class="method"><span id='clone_from.v' class='invisible'><table class='table-display'><tbody><tr><td><code>fn <a href='https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#method.clone_from' class='fnname'>clone_from</a>(&amp;mut self, source: <a class="primitive" href="https://doc.rust-lang.org/nightly/std/primitive.reference.html">&amp;</a>Self)</code></span></td><td><span class='out-of-band'><div class='ghost'></div><div class='since' title='Stable since Rust version 1.0.0'>1.0.0</div><a class='srclink' href='https://doc.rust-lang.org/nightly/src/core/clone.rs.html#130-132' title='goto source code'>[src]</a></td></tr></tbody></table></span></h4><div class='docblock'><p>Performs copy-assignment from <code>source</code>. <a href="https://doc.rust-lang.org/nightly/core/clone/trait.Clone.html#method.clone_from">Read more</a></p>
</div></div></div><h2 id='synthetic-implementations' class='small-section-header'>Auto Trait Implementations<a href='#synthetic-implementations' class='anchor'></a></h2><div id='synthetic-implementations-list'><h3 id='impl-Send' class='impl'><span class='in-band'><table class='table-display'><tbody><tr><td><code>impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> for <a class="struct" href="../window/struct.WindowSettings.html" title="struct window::WindowSettings">WindowSettings</a></code><a href='#impl-Send' class='anchor'></a></span></td><td><span class='out-of-band'></span></td></tr></tbody></table></h3><div class='impl-items'></div><h3 id='impl-Sync' class='impl'><span class='in-band'><table class='table-display'><tbody><tr><td><code>impl <a class="trait" href="https://doc.rust-lang.org/nightly/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> for <a class="struct" href="../window/struct.WindowSettings.html" title="struct window::WindowSettings">WindowSettings</a></code><a href='#impl-Sync' class='anchor'></a></span></td><td><span class='out-of-band'></span></td></tr></tbody></table></h3><div class='impl-items'></div></div></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 = "window";</script><script src="../aliases.js"></script><script src="../main.js"></script><script defer src="../search-index.js"></script></body></html>