mirror of
https://github.com/Insality/druid
synced 2025-06-27 18:37:45 +02:00
192 lines
4.8 KiB
HTML
192 lines
4.8 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/base.back_handler.html">base.back_handler</a></li>
|
|
<li><a href="../modules/base.blocker.html">base.blocker</a></li>
|
|
<li><a href="../modules/base.button.html">base.button</a></li>
|
|
<li><a href="../modules/base.checkbox.html">base.checkbox</a></li>
|
|
<li><a href="../modules/base.checkbox_group.html">base.checkbox_group</a></li>
|
|
<li><a href="../modules/base.grid.html">base.grid</a></li>
|
|
<li><a href="../modules/base.progress.html">base.progress</a></li>
|
|
<li><a href="../modules/base.checkbox_group.html">base.checkbox_group</a></li>
|
|
<li><a href="../modules/base.scroll.html">base.scroll</a></li>
|
|
<li><a href="../modules/base.slider.html">base.slider</a></li>
|
|
<li><a href="../modules/base.text.html">base.text</a></li>
|
|
<li><a href="../modules/base.timer.html">base.timer</a></li>
|
|
<li><a href="../modules/constants.html">constants</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><strong>helper.formats</strong></li>
|
|
<li><a href="../modules/rich.progress_rich.html">rich.progress_rich</a></li>
|
|
<li><a href="../modules/settings.html">settings</a></li>
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
<div id="content">
|
|
|
|
<h1>Module <code>helper.formats</code></h1>
|
|
<p>Druid module with utils on string formats</p>
|
|
<p></p>
|
|
|
|
|
|
<h2><a href="#Functions">Functions</a></h2>
|
|
<table class="function_list">
|
|
<tr>
|
|
<td class="name" nowrap><a href="#add_prefix_zeros">add_prefix_zeros(num, count)</a></td>
|
|
<td class="summary">Return number with zero number prefix</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="name" nowrap><a href="#second_string_min">second_string_min(sec)</a></td>
|
|
<td class="summary">Convert seconds to string minutes:seconds</td>
|
|
</tr>
|
|
<tr>
|
|
<td class="name" nowrap><a href="#second_string_min">second_string_min(s, tab)</a></td>
|
|
<td class="summary">Interpolate string with named Parameters in Table</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<br/>
|
|
<br/>
|
|
|
|
|
|
<h2 class="section-header "><a name="Functions"></a>Functions</h2>
|
|
|
|
<dl class="function">
|
|
<dt>
|
|
<a name = "add_prefix_zeros"></a>
|
|
<strong>add_prefix_zeros(num, count)</strong>
|
|
</dt>
|
|
<dd>
|
|
Return number with zero number prefix
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">num</span>
|
|
<span class="types"><span class="type">number</span></span>
|
|
Number for conversion
|
|
</li>
|
|
<li><span class="parameter">count</span>
|
|
<span class="types"><span class="type">number</span></span>
|
|
Count of numerals
|
|
</li>
|
|
</ul>
|
|
|
|
<h3>Returns:</h3>
|
|
<ol>
|
|
|
|
string with need count of zero (1,3) -> 001
|
|
</ol>
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
<dt>
|
|
<a name = "second_string_min"></a>
|
|
<strong>second_string_min(sec)</strong>
|
|
</dt>
|
|
<dd>
|
|
Convert seconds to string minutes:seconds
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">sec</span>
|
|
<span class="types"><span class="type">number</span></span>
|
|
Seconds
|
|
</li>
|
|
</ul>
|
|
|
|
<h3>Returns:</h3>
|
|
<ol>
|
|
|
|
string minutes:seconds
|
|
</ol>
|
|
|
|
|
|
|
|
|
|
</dd>
|
|
<dt>
|
|
<a name = "second_string_min"></a>
|
|
<strong>second_string_min(s, tab)</strong>
|
|
</dt>
|
|
<dd>
|
|
Interpolate string with named Parameters in Table
|
|
|
|
|
|
<h3>Parameters:</h3>
|
|
<ul>
|
|
<li><span class="parameter">s</span>
|
|
<span class="types"><a class="type" href="https://www.lua.org/manual/5.3/manual.html#6.4">string</a></span>
|
|
Target string
|
|
</li>
|
|
<li><span class="parameter">tab</span>
|
|
<span class="types"><a class="type" href="https://www.lua.org/manual/5.3/manual.html#6.6">table</a></span>
|
|
Table with parameters
|
|
</li>
|
|
</ul>
|
|
|
|
<h3>Returns:</h3>
|
|
<ol>
|
|
|
|
string with replaced parameters
|
|
</ol>
|
|
|
|
|
|
|
|
|
|
</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 2019-12-05 22:04:11 </i>
|
|
</div> <!-- id="about" -->
|
|
</div> <!-- id="container" -->
|
|
</body>
|
|
</html>
|