<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>libthai: thai/thwcoll.h File Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.7.3 --> <div id="top"> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">libthai <span id="projectnumber">0.1.14</span></div> </td> </tr> </tbody> </table> </div> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>Globals</span></a></li> </ul> </div> </div> <div class="header"> <div class="summary"> <a href="#func-members">Functions</a> </div> <div class="headertitle"> <h1>thai/thwcoll.h File Reference</h1> </div> </div> <div class="contents"> <p>Thai wide-char string collation. <a href="#_details">More...</a></p> <table class="memberdecls"> <tr><td colspan="2"><h2><a name="func-members"></a> Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="thwcoll_8h.html#a3d4fbf3465f1d6858748a1b3ac870f44">th_wcstrcoll</a> (const <a class="el" href="thwchar_8h.html#ac574aa2199e3bc6e052d051ea720cc21">thwchar_t</a> *s1, const <a class="el" href="thwchar_8h.html#ac574aa2199e3bc6e052d051ea720cc21">thwchar_t</a> *s2)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Compare two Thai wide-char strings for collation. <a href="#a3d4fbf3465f1d6858748a1b3ac870f44"></a><br/></td></tr> <tr><td class="memItemLeft" align="right" valign="top">size_t </td><td class="memItemRight" valign="bottom"><a class="el" href="thwcoll_8h.html#a233a97c07b230d8e30ece80bdd31266f">th_wcstrxfrm</a> (<a class="el" href="thwchar_8h.html#ac574aa2199e3bc6e052d051ea720cc21">thwchar_t</a> dest[], const <a class="el" href="thwchar_8h.html#ac574aa2199e3bc6e052d051ea720cc21">thwchar_t</a> *src, size_t n)</td></tr> <tr><td class="mdescLeft"> </td><td class="mdescRight">Transform wide-char string into collatable form. <a href="#a233a97c07b230d8e30ece80bdd31266f"></a><br/></td></tr> </table> <hr/><a name="_details"></a><h2>Detailed Description</h2> <div class="textblock"><p>Thai wide-char string collation. </p> </div><hr/><h2>Function Documentation</h2> <a class="anchor" id="a3d4fbf3465f1d6858748a1b3ac870f44"></a><!-- doxytag: member="thwcoll.h::th_wcstrcoll" ref="a3d4fbf3465f1d6858748a1b3ac870f44" args="(const thwchar_t *s1, const thwchar_t *s2)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int th_wcstrcoll </td> <td>(</td> <td class="paramtype">const <a class="el" href="thwchar_8h.html#ac574aa2199e3bc6e052d051ea720cc21">thwchar_t</a> * </td> <td class="paramname"><em>s1</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="thwchar_8h.html#ac574aa2199e3bc6e052d051ea720cc21">thwchar_t</a> * </td> <td class="paramname"><em>s2</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Compare two Thai wide-char strings for collation. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">s1</td><td>: first wide-char string (null-terminated) </td></tr> <tr><td class="paramname">s2</td><td>: second wide-char string (null-terminated)</td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>< 0 if <em>s1</em> precedes <em>s2</em>; 0 if <em>s1</em> equals <em>s2</em>; > 0 if <em>s1</em> succeeds <em>s2</em> </dd></dl> </div> </div> <a class="anchor" id="a233a97c07b230d8e30ece80bdd31266f"></a><!-- doxytag: member="thwcoll.h::th_wcstrxfrm" ref="a233a97c07b230d8e30ece80bdd31266f" args="(thwchar_t dest[], const thwchar_t *src, size_t n)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">size_t th_wcstrxfrm </td> <td>(</td> <td class="paramtype"><a class="el" href="thwchar_8h.html#ac574aa2199e3bc6e052d051ea720cc21">thwchar_t</a> </td> <td class="paramname"><em>dest</em>[], </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">const <a class="el" href="thwchar_8h.html#ac574aa2199e3bc6e052d051ea720cc21">thwchar_t</a> * </td> <td class="paramname"><em>src</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">size_t </td> <td class="paramname"><em>n</em> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Transform wide-char string into collatable form. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">dest</td><td>: the destination wide-char string buffer </td></tr> <tr><td class="paramname">src</td><td>: the wide-char string to transform </td></tr> <tr><td class="paramname">n</td><td>: the size of <em>dest</em> buffer (as number of elements)</td></tr> </table> </dd> </dl> <dl class="return"><dt><b>Returns:</b></dt><dd>the number of elements required to store the result in <em>dest</em>, excluding the terminating '\0'. If the return value >= <em>n</em>, <em>dest</em> is undefined.</dd></dl> <p>Transforms <em>src</em> into a form from which comparison using wcscmp() yields the same result as that from <a class="el" href="thwcoll_8h.html#a3d4fbf3465f1d6858748a1b3ac870f44" title="Compare two Thai wide-char strings for collation.">th_wcstrcoll()</a>. At most <em>n</em> characters are put in <em>dest</em>. </p> </div> </div> </div> <hr size="1"><address style="text-align: right;"><small> Generated for libthai by <a href="http://www.doxygen.org/ index.html"><img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.7.3</small></address> </body> </html>