mirror of
https://github.com/Insality/druid
synced 2025-06-27 10:27:48 +02:00
284 lines
7.9 KiB
HTML
284 lines
7.9 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
<html>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
|
<head>
|
|
<title>Defold Druid UI Library</title>
|
|
<link rel="stylesheet" href="../ldoc_pale.css" type="text/css" />
|
|
</head>
|
|
<body>
|
|
|
|
<div id="container">
|
|
|
|
<div id="product">
|
|
<div id="product_logo"></div>
|
|
<div id="product_name"><big><b></b></big></div>
|
|
<div id="product_description"></div>
|
|
</div> <!-- id="product" -->
|
|
|
|
|
|
<div id="main">
|
|
|
|
|
|
<!-- Menu -->
|
|
|
|
<div id="navigation">
|
|
<br/>
|
|
<h1>Druid</h1>
|
|
|
|
<ul>
|
|
<li><a href="../index.html">Index</a></li>
|
|
</ul>
|
|
|
|
<h2>Contents</h2>
|
|
<ul>
|
|
<li><a href="#Functions">Functions</a></li>
|
|
</ul>
|
|
|
|
|
|
<h2>Modules</h2>
|
|
<ul class="nowrap">
|
|
<li><a href="../modules/.druidback_handler.html">.druidback_handler</a></li>
|
|
<li><a href="../modules/.druidblocker.html">.druidblocker</a></li>
|
|
<li><a href="../modules/.druidbutton.html">.druidbutton</a></li>
|
|
<li><a href="../modules/.druidcheckbox.html">.druidcheckbox</a></li>
|
|
<li><a href="../modules/.druidcheckbox_group.html">.druidcheckbox_group</a></li>
|
|
<li><a href="../modules/.druidgrid.html">.druidgrid</a></li>
|
|
<li><a href="../modules/.druidtext.html">.druidtext</a></li>
|
|
<li><a href="../modules/.druidprogress.html">.druidprogress</a></li>
|
|
<li><a href="../modules/.druidcheckbox_group.html">.druidcheckbox_group</a></li>
|
|
<li><strong>.druidscroll</strong></li>
|
|
<li><a href="../modules/.druidslider.html">.druidslider</a></li>
|
|
<li><a href="../modules/.druidtext.html">.druidtext</a></li>
|
|
<li><a href="../modules/.druidtimer.html">.druidtimer</a></li>
|
|
<li><a href="../modules/const.html">const</a></li>
|
|
<li><a href="../modules/druid.html">druid</a></li>
|
|
<li><a href="../modules/helper.html">helper</a></li>
|
|
<li><a href="../modules/helper.animate.html">helper.animate</a></li>
|
|
<li><a href="../modules/helper.formats.html">helper.formats</a></li>
|
|
<li><a href="../modules/rich.progress_rich.html">rich.progress_rich</a></li>
|
|
<li><a href="../modules/component.html">component</a></li>
|
|
<li><a href="../modules/settings.html">settings</a></li>
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
<div id="content">
|
|
|
|
<h1>Module <code>.druidscroll</code></h1>
|
|
<p>Component to handle scroll content</p>
|
|
<p></p>
|
|
|
|
|
|
<h2><a href="#Functions">Functions</a></h2>
|
|
<table class="function_list">
|
|
<tr>
|
|
<td class="name" nowrap><a href="#scroll:scroll_to">scroll:scroll_to(vector3[, is_instant])</a></td>
|
|
<td class="summary">Start scroll to target point</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="name" nowrap><a href="#scroll:init">scroll:init(self, index[, skip_cb])</a></td>
|
|
<td class="summary">Scroll to item in scroll by point index</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="name" nowrap><a href="#scroll:set_points">scroll:set_points(self, points)</a></td>
|
|
<td class="summary">Set points of interest.</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="name" nowrap><a href="#scroll:set_inert">scroll:set_inert(self, state)</a></td>
|
|
<td class="summary">Enable or disable scroll inert.</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="name" nowrap><a href="#scroll:on_point_move">scroll:on_point_move(self, callback)</a></td>
|
|
<td class="summary">Set the callback on scrolling to point (if exist)</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="name" nowrap><a href="#scroll:set_border">scroll:set_border(self, border)</a></td>
|
|
<td class="summary">Set the scroll possibly area</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<br/>
|
|
<br/>
|
|
|
|
|
|
<h2 class="section-header "><a name="Functions"></a>Functions</h2>
|
|
|
|
<dl class="function">
|
|
<dt>
|
|
<a name = "scroll:scroll_to"></a>
|
|
<strong>scroll:scroll_to(vector3[, is_instant])</strong>
|
|
</dt>
|
|
<dd>
|
|
Start scroll to target point
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">vector3</span>
|
|
<span class="types"><span class="type">point</span></span>
|
|
target point
|
|
</li>
|
|
<li><span class="parameter">is_instant</span>
|
|
<span class="types"><span class="type">bool</span></span>
|
|
instant scroll flag
|
|
(<em>optional</em>)
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
<h3>Usage:</h3>
|
|
<ul>
|
|
<li><pre class="example">scroll:scroll_to(vmath.vector3(<span class="number">0</span>, <span class="number">50</span>, <span class="number">0</span>))</pre></li>
|
|
<li><pre class="example">scroll:scroll_to(vmath.vector3(<span class="number">0</span>), <span class="keyword">true</span>)</pre></li>
|
|
</ul>
|
|
|
|
</dd>
|
|
<dt>
|
|
<a name = "scroll:init"></a>
|
|
<strong>scroll:init(self, index[, skip_cb])</strong>
|
|
</dt>
|
|
<dd>
|
|
Scroll to item in scroll by point index
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">self</span>
|
|
<span class="types"><a class="type" href="https://www.lua.org/manual/5.3/manual.html#6.6">table</a></span>
|
|
Component instance
|
|
</li>
|
|
<li><span class="parameter">index</span>
|
|
<span class="types"><span class="type">number</span></span>
|
|
Point index
|
|
</li>
|
|
<li><span class="parameter">skip_cb</span>
|
|
<span class="types"><span class="type">boolean</span></span>
|
|
If true, skip the point callback
|
|
(<em>optional</em>)
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
<dt>
|
|
<a name = "scroll:set_points"></a>
|
|
<strong>scroll:set_points(self, points)</strong>
|
|
</dt>
|
|
<dd>
|
|
Set points of interest.
|
|
Scroll will always centered on closer points
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">self</span>
|
|
<span class="types"><a class="type" href="https://www.lua.org/manual/5.3/manual.html#6.6">table</a></span>
|
|
Component instance
|
|
</li>
|
|
<li><span class="parameter">points</span>
|
|
<span class="types"><a class="type" href="https://www.lua.org/manual/5.3/manual.html#6.6">table</a></span>
|
|
Array of vector3 points
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
<dt>
|
|
<a name = "scroll:set_inert"></a>
|
|
<strong>scroll:set_inert(self, state)</strong>
|
|
</dt>
|
|
<dd>
|
|
Enable or disable scroll inert.
|
|
If disabled, scroll through points (if exist)
|
|
If no points, just simple drag without inertion
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">self</span>
|
|
<span class="types"><a class="type" href="https://www.lua.org/manual/5.3/manual.html#6.6">table</a></span>
|
|
Component instance
|
|
</li>
|
|
<li><span class="parameter">state</span>
|
|
<span class="types"><span class="type">boolean</span></span>
|
|
Inert scroll state
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
<dt>
|
|
<a name = "scroll:on_point_move"></a>
|
|
<strong>scroll:on_point_move(self, callback)</strong>
|
|
</dt>
|
|
<dd>
|
|
Set the callback on scrolling to point (if exist)
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">self</span>
|
|
<span class="types"><a class="type" href="https://www.lua.org/manual/5.3/manual.html#6.6">table</a></span>
|
|
Component instance
|
|
</li>
|
|
<li><span class="parameter">callback</span>
|
|
<span class="types"><span class="type">function</span></span>
|
|
Callback on scroll to point of interest
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
<dt>
|
|
<a name = "scroll:set_border"></a>
|
|
<strong>scroll:set_border(self, border)</strong>
|
|
</dt>
|
|
<dd>
|
|
Set the scroll possibly area
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">self</span>
|
|
<span class="types"><a class="type" href="https://www.lua.org/manual/5.3/manual.html#6.6">table</a></span>
|
|
Component instance
|
|
</li>
|
|
<li><span class="parameter">border</span>
|
|
<span class="types"><span class="type">vmath.vector3</span></span>
|
|
Size of scrolling area
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
</dl>
|
|
|
|
|
|
</div> <!-- id="content" -->
|
|
</div> <!-- id="main" -->
|
|
<div id="about">
|
|
<i>generated by <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a></i>
|
|
<i style="float:right;">Last updated 2020-02-04 23:48:07 </i>
|
|
</div> <!-- id="about" -->
|
|
</div> <!-- id="container" -->
|
|
</body>
|
|
</html>
|