1
0
Fork 0
mirror of https://github.com/geometer/FBReaderJ.git synced 2025-10-04 18:29:23 +02:00
FBReaderJ/jni/LineBreak/liblinebreak-2.0/doc/html/linebreak_8h-source.html
Nikolay Pultsin 31889171f3 jni: NDKr3 is now used
git-svn-id: https://only.mawhrin.net/repos/FBReaderJ/trunk@1322 6a642e6f-84f6-412e-ac94-c4a38d5a04b0
2010-04-30 13:09:07 +00:00

104 lines
11 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>liblinebreak: linebreak.h Source File</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.5.8 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
<li><a href="globals.html"><span>Globals</span></a></li>
</ul>
</div>
<h1>linebreak.h</h1><a href="linebreak_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/* vim: set tabstop=4 shiftwidth=4: */</span>
<a name="l00002"></a>00002
<a name="l00003"></a>00003 <span class="comment">/*</span>
<a name="l00004"></a>00004 <span class="comment"> * Line breaking in a Unicode sequence. Designed to be used in a</span>
<a name="l00005"></a>00005 <span class="comment"> * generic text renderer.</span>
<a name="l00006"></a>00006 <span class="comment"> *</span>
<a name="l00007"></a>00007 <span class="comment"> * Copyright (C) 2008-2009 Wu Yongwei &lt;wuyongwei at gmail dot com&gt;</span>
<a name="l00008"></a>00008 <span class="comment"> *</span>
<a name="l00009"></a>00009 <span class="comment"> * This software is provided 'as-is', without any express or implied</span>
<a name="l00010"></a>00010 <span class="comment"> * warranty. In no event will the author be held liable for any damages</span>
<a name="l00011"></a>00011 <span class="comment"> * arising from the use of this software.</span>
<a name="l00012"></a>00012 <span class="comment"> *</span>
<a name="l00013"></a>00013 <span class="comment"> * Permission is granted to anyone to use this software for any purpose,</span>
<a name="l00014"></a>00014 <span class="comment"> * including commercial applications, and to alter it and redistribute</span>
<a name="l00015"></a>00015 <span class="comment"> * it freely, subject to the following restrictions:</span>
<a name="l00016"></a>00016 <span class="comment"> *</span>
<a name="l00017"></a>00017 <span class="comment"> * 1. The origin of this software must not be misrepresented; you must</span>
<a name="l00018"></a>00018 <span class="comment"> * not claim that you wrote the original software. If you use this</span>
<a name="l00019"></a>00019 <span class="comment"> * software in a product, an acknowledgement in the product</span>
<a name="l00020"></a>00020 <span class="comment"> * documentation would be appreciated but is not required.</span>
<a name="l00021"></a>00021 <span class="comment"> * 2. Altered source versions must be plainly marked as such, and must</span>
<a name="l00022"></a>00022 <span class="comment"> * not be misrepresented as being the original software.</span>
<a name="l00023"></a>00023 <span class="comment"> * 3. This notice may not be removed or altered from any source</span>
<a name="l00024"></a>00024 <span class="comment"> * distribution.</span>
<a name="l00025"></a>00025 <span class="comment"> *</span>
<a name="l00026"></a>00026 <span class="comment"> * The main reference is Unicode Standard Annex 14 (UAX #14):</span>
<a name="l00027"></a>00027 <span class="comment"> * &lt;URL:http://www.unicode.org/reports/tr14/&gt;</span>
<a name="l00028"></a>00028 <span class="comment"> *</span>
<a name="l00029"></a>00029 <span class="comment"> * When this library was designed, this annex was at Revision 19, for</span>
<a name="l00030"></a>00030 <span class="comment"> * Unicode 5.0.0:</span>
<a name="l00031"></a>00031 <span class="comment"> * &lt;URL:http://www.unicode.org/reports/tr14/tr14-19.html&gt;</span>
<a name="l00032"></a>00032 <span class="comment"> *</span>
<a name="l00033"></a>00033 <span class="comment"> * This library has been updated according to Revision 24, for</span>
<a name="l00034"></a>00034 <span class="comment"> * Unicode 5.2.0:</span>
<a name="l00035"></a>00035 <span class="comment"> * &lt;URL:http://www.unicode.org/reports/tr14/tr14-24.html&gt;</span>
<a name="l00036"></a>00036 <span class="comment"> *</span>
<a name="l00037"></a>00037 <span class="comment"> * The Unicode Terms of Use are available at</span>
<a name="l00038"></a>00038 <span class="comment"> * &lt;URL:http://www.unicode.org/copyright.html&gt;</span>
<a name="l00039"></a>00039 <span class="comment"> */</span>
<a name="l00040"></a>00040
<a name="l00050"></a>00050 <span class="preprocessor">#ifndef LINEBREAK_H</span>
<a name="l00051"></a>00051 <span class="preprocessor"></span><span class="preprocessor">#define LINEBREAK_H</span>
<a name="l00052"></a>00052 <span class="preprocessor"></span>
<a name="l00053"></a>00053 <span class="preprocessor">#include &lt;stddef.h&gt;</span>
<a name="l00054"></a>00054
<a name="l00055"></a>00055 <span class="preprocessor">#ifdef __cplusplus</span>
<a name="l00056"></a>00056 <span class="preprocessor"></span><span class="keyword">extern</span> <span class="stringliteral">"C"</span> {
<a name="l00057"></a>00057 <span class="preprocessor">#endif</span>
<a name="l00058"></a>00058 <span class="preprocessor"></span>
<a name="l00059"></a><a class="code" href="linebreak_8h.html#83634cb3df4ba09faf22ba687ffc4c02">00059</a> <span class="preprocessor">#define LINEBREAK_VERSION 0x0195</span>
<a name="l00060"></a>00060 <span class="preprocessor"></span><span class="keyword">extern</span> <span class="keyword">const</span> <span class="keywordtype">int</span> <a class="code" href="linebreak_8c.html#0ac90a75aa79415fe87e66b95d8fd09b" title="Version number of the library.">linebreak_version</a>;
<a name="l00061"></a>00061
<a name="l00062"></a>00062 <span class="preprocessor">#ifndef LINEBREAK_UTF_TYPES_DEFINED</span>
<a name="l00063"></a>00063 <span class="preprocessor"></span><span class="preprocessor">#define LINEBREAK_UTF_TYPES_DEFINED</span>
<a name="l00064"></a><a class="code" href="linebreak_8h.html#6103b2105588f239c593e779e605038a">00064</a> <span class="preprocessor"></span><span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> <a class="code" href="linebreak_8h.html#6103b2105588f239c593e779e605038a" title="Type for UTF-8 data points.">utf8_t</a>;
<a name="l00065"></a><a class="code" href="linebreak_8h.html#4dce96cad338d9281612277b2d80950c">00065</a> <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">short</span> <a class="code" href="linebreak_8h.html#4dce96cad338d9281612277b2d80950c" title="Type for UTF-16 data points.">utf16_t</a>;
<a name="l00066"></a><a class="code" href="linebreak_8h.html#4f775bae0642c213be2c526018283c25">00066</a> <span class="keyword">typedef</span> <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="linebreak_8h.html#4f775bae0642c213be2c526018283c25" title="Type for UTF-32 data points.">utf32_t</a>;
<a name="l00067"></a>00067 <span class="preprocessor">#endif</span>
<a name="l00068"></a>00068 <span class="preprocessor"></span>
<a name="l00069"></a><a class="code" href="linebreak_8h.html#367d64258fd90864a467687cd1736b77">00069</a> <span class="preprocessor">#define LINEBREAK_MUSTBREAK 0 </span>
<a name="l00070"></a><a class="code" href="linebreak_8h.html#229f34b0b72ccb2e53d0936a1e61a363">00070</a> <span class="preprocessor">#define LINEBREAK_ALLOWBREAK 1 </span>
<a name="l00071"></a><a class="code" href="linebreak_8h.html#dd176a107633817050bedf6eb4f491cc">00071</a> <span class="preprocessor">#define LINEBREAK_NOBREAK 2 </span>
<a name="l00072"></a><a class="code" href="linebreak_8h.html#5adf3d4831b89cb3e40e9bd31a73a39d">00072</a> <span class="preprocessor">#define LINEBREAK_INSIDEACHAR 3 </span>
<a name="l00074"></a>00074 <span class="preprocessor">void init_linebreak(void);</span>
<a name="l00075"></a>00075 <span class="preprocessor"></span><span class="keywordtype">void</span> <a class="code" href="linebreak_8c.html#b426e9cf68117faf583a0ed54742cb28" title="Sets the line breaking information for a UTF-8 input string.">set_linebreaks_utf8</a>(
<a name="l00076"></a>00076 <span class="keyword">const</span> utf8_t *s, <span class="keywordtype">size_t</span> len, <span class="keyword">const</span> <span class="keywordtype">char</span>* lang, <span class="keywordtype">char</span> *brks);
<a name="l00077"></a>00077 <span class="keywordtype">void</span> <a class="code" href="linebreak_8c.html#1d56bce2d32cd986052172638cec43c8" title="Sets the line breaking information for a UTF-16 input string.">set_linebreaks_utf16</a>(
<a name="l00078"></a>00078 <span class="keyword">const</span> utf16_t *s, <span class="keywordtype">size_t</span> len, <span class="keyword">const</span> <span class="keywordtype">char</span>* lang, <span class="keywordtype">char</span> *brks);
<a name="l00079"></a>00079 <span class="keywordtype">void</span> <a class="code" href="linebreak_8c.html#9fdce33b4ded9d586888c16228ae9e1f" title="Sets the line breaking information for a UTF-32 input string.">set_linebreaks_utf32</a>(
<a name="l00080"></a>00080 <span class="keyword">const</span> utf32_t *s, <span class="keywordtype">size_t</span> len, <span class="keyword">const</span> <span class="keywordtype">char</span>* lang, <span class="keywordtype">char</span> *brks);
<a name="l00081"></a>00081 <span class="keywordtype">int</span> <a class="code" href="linebreak_8c.html#5761f60559b5ddb61bb095f00c7deb5c" title="Tells whether a line break can occur between two Unicode characters.">is_line_breakable</a>(utf32_t char1, utf32_t char2, <span class="keyword">const</span> <span class="keywordtype">char</span>* lang);
<a name="l00082"></a>00082
<a name="l00083"></a>00083 <span class="preprocessor">#ifdef __cplusplus</span>
<a name="l00084"></a>00084 <span class="preprocessor"></span>}
<a name="l00085"></a>00085 <span class="preprocessor">#endif</span>
<a name="l00086"></a>00086 <span class="preprocessor"></span>
<a name="l00087"></a>00087 <span class="preprocessor">#endif </span><span class="comment">/* LINEBREAK_H */</span>
</pre></div></div>
<hr size="1"><address style="text-align: right;"><small>Generated on Sun Nov 29 16:41:13 2009 for liblinebreak by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.8 </small></address>
</body>
</html>