]> git.saurik.com Git - apple/icu.git/blob - icuSources/test/letest/readme.html
ICU-57131.0.1.tar.gz
[apple/icu.git] / icuSources / test / letest / readme.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2 <html>
3 <head>
4 <meta name="generator" content=
5 "HTML Tidy for Windows (vers 26 April 2007), see www.w3.org">
6 <meta http-equiv="Content-Type" content=
7 "text/html; charset=us-ascii">
8 <meta name="Copyright" content=
9 "Copyright (c) 2001-2007, International Business Machines Corporation and others. All Rights Reserved.">
10 <meta name="Author" content="Eric Mader">
11 <meta name="GENERATOR" content=
12 "Mozilla/4.72 [en] (Windows NT 5.0; U) [Netscape]">
13 <title>Readme file for letest and gendata</title>
14 </head>
15 <body>
16 <h2>What are letest and gendata?</h2>
17 letest is a test program that you can use to verify the basic
18 functionality of the ICU LayoutEngine. It tests the LayoutEngine's
19 API and reads an XML file that contains test cases to test some of
20 the features of the LayoutEngine. These test cases are not
21 comprehensive, but they do test the most important features of
22 &nbsp;the LayoutEngine. When you have successfully run letest, you
23 can use the ICU LayoutEngine in you application knowing that the
24 basic functionality is working correctly.<br>
25 <p>gendata is a program that is used by the ICU team to build the
26 file letest.xml which contains the test cases. Unless you have
27 changed your copy of the LayoutEngine and want to validate the
28 changes on other platforms, there's no reason for you to run this
29 program.</p>
30 <p>(The ICU team first runs a Windows application which uses the
31 ICU LayoutEngine to display the text that letest uses. Once it has
32 been verified that the text is displayed correctly, gendata is run
33 to produce letest.xml, and then letest is run on Windows to verify
34 that letest still works with the new data.)<br></p>
35 <h2>How do I build letest?</h2>
36 First, you need to build ICU, including the LayoutEngine.&nbsp;
37 <p>On Windows, letest is part of the allinone project, so a normal
38 build of ICU will also build letest. On UNIX systems, connect to
39 &lt;top-build-dir&gt;/test/letest and do "make all" .<br></p>
40 <h2>How do I run letest?</h2>
41 Before you can run letest, you'll need to get the fonts it uses.
42 For legal reasons, we can't include most of them with ICU, but you
43 can download them from the web. To do this, you'll need access to a
44 computer running Windows. All of the fonts should be stored in
45 &lt;icu&gt;/source/test/testdata. Here's how to get the fonts:
46 <p>Download a recent version of the Java 2 Platform, Standard
47 Edition (J2SE) from <a href=
48 "http://java.sun.com/javase/downloads/index.html">java.sun.com</a>.
49 Click on the "Download" button for the version of Java that you
50 want to download. The page offers both JDKs and JREs. (The JRE is
51 sufficient for letest.) The download page will have a link to the
52 license agreement. Be sure to read and understand the license
53 agreement, and then click on the Accept button. Download the
54 package and install it. You'll need one font. On Windows, it will
55 be in, for example, "C:\Program Files\Java\jdk1.6.0\jre\lib\fonts".
56 The file you want is "LucidaSansRegular.ttf". Copy this file into
57 the directory from which you'll run letest.<br></p>
58 <p>Next is the Hindi font. Go to the NCST site and download
59 <a href="http://tdil.mit.gov.in/download/Raghu.htm">raghu.ttf</a>.
60 When you hit the DOWNLOAD button on the page, it will open another
61 window which contains a disclaimer and a license agreement. Be sure
62 that you understand and agree to all of this before you download
63 the font. You can download raghu.ttf into the directory from which
64 you'll run letest.<br></p>
65 <p>Then download the Thai font. Go to <a href=
66 "http://www.into-asia.com/thai_language/thaifont/">into-asia.com</a>
67 and click on the link for the Angsana font. This will download a
68 .ZIP file. Extract the font file, angsd___.ttf, into the directory
69 from which you will run letest.<br></p>
70 <p>There's still one more font to get, the Code2000 Unicode font.
71 Go to James Kass' <a href="http://www.code2000.net/">Unicode
72 Support In Your Browser</a> page and click on the link that says
73 "Click Here to download Code2000 shareware demo Unicode font." This
74 will download a .ZIP file which contains CODE2000.TTF and
75 CODE2000.HTM. Expand this .ZIP file and put the CODE2000.TTF file
76 in the directory from which you'll run letest.<br></p>
77 <p><span style="font-weight: bold;">Note:</span> The Code2000 font
78 is shareware. If you want to use it for longer than a trial period,
79 you should send a shareware fee to James. Directions for how to do
80 this are in CODE2000.HTM.</p>
81 <p>letest.xml references three other fonts:</p>
82 <ul>
83 <li>ARIALUNI.TTF is Microsoft's Arial Unicode MS font, which is
84 distributed with Microsoft Office and is licensed only for use on
85 the Windows operating system.</li>
86 <li>Devamt.ttf is a proprietary font which cannot be freely
87 downloaded.</li>
88 <li>TestFont1.otf is included with ICU.</li>
89 </ul>
90 To run letest type CTRL+F5 in Visual Studio, or "make check" in
91 UNIX.&nbsp; If everything's OK you should see something like this:
92 <blockquote><tt>&nbsp;/<br>
93 &nbsp;/api/<br>
94 &nbsp;&nbsp; ---[OK]&nbsp; ---/api/ParameterTest<br>
95 &nbsp;&nbsp; ---[OK]&nbsp; ---/api/FactoryTest<br>
96 &nbsp;/layout/<br>
97 &nbsp;&nbsp; ---[OK]&nbsp; ---/layout/AccessTest<br>
98 &nbsp;&nbsp; ---[OK]&nbsp; ---/layout/DataDrivenTest<br>
99 &nbsp;/c_api/<br>
100 &nbsp;&nbsp; ---[OK]&nbsp; ---/c_api/ParameterTest<br>
101 &nbsp;&nbsp; ---[OK]&nbsp; ---/c_api/FactoryTest<br>
102 &nbsp;/c_layout/<br>
103 &nbsp;&nbsp; ---[OK]&nbsp; ---/c_layout/AccessTest<br>
104 &nbsp;&nbsp; ---[OK]&nbsp; ---/c_layout/DataDrivenTest<br>
105 <br>
106 [All tests passed successfully...]<br>
107 Elapsed Time: 00:00:00.351<br></tt></blockquote>
108 If letest cannot open a font, it will print a warning message and
109 skip the test. letest will also check the version of the font you
110 have to make sure it's the same one that was used to generate the
111 test case. If the version doesn't match, letest will print a
112 warning message and proceed with the test.<br>
113 </body>
114 </html>