summaryrefslogtreecommitdiffstats
path: root/doc/kttsd/index.docbook
blob: 37b9d5fc3a5ce1a9544236911b1412f435f0984e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
<?xml version="1.0" ?>
<!DOCTYPE book PUBLIC "-//KDE//DTD DocBook XML V4.2-Based Variant V1.1//EN" "dtd/kdex.dtd" [
  <!ENTITY ktts "<application>KTTS</application>">
  <!ENTITY kappname "&ktts;">
  <!ENTITY package "tdeaccessibility">
  <!ENTITY mbrola "<application>MBROLA</application>">
  <!ENTITY % imageobjectco.module "INCLUDE">
  <!ENTITY % addindex "IGNORE">
  <!ENTITY % English "INCLUDE">
]>
<!-- Note to translators: KTTSD is meant to be built under KDE
     versions 3.2 and later.  Please avoid entities that won't
     be defined under those KDE versions.  Thanks.
-->

<!-- kdoctemplate v0.9 January 10 2003
     Changes to comments to clarify entity usage January 10 2003
     Minor update to "Credits and Licenses" section on August 24, 2000
     Removed "Revision history" section on 22 January 2001
     Changed to Installation/Help menu entities 18 October 2001
     Other minor cleanup and changes 18 October 2001 
     FPI change and minor changes November 2002 -->

<!--
This template was designed by: David Rugge davidrugge@mindspring.com
with lots of help from: Eric Bischoff ebisch@cybercable.tm.fr
and Frederik Fouvry fouvry@sfs.nphil.uni-tuebingen.de
of the KDE DocBook team.

You may freely use this template for writing any sort of KDE documentation.
If you have any changes or improvements, please let us know.

Remember:
- in XML, the case of the <tags> and attributes is relevant ;
- also, quote all attributes.

Please don't forget to remove all these comments in your final documentation,
thanks ;-).
-->

<!-- ................................................................ -->

<!-- The language must NOT be changed here. -->
<!-- If you are writing original documentation in a language other -->
<!-- than English, change the language above ONLY, not here -->
<book lang="&language;">

<!-- This header contains all of the meta-information for the document such
as Authors, publish date, the abstract, and Keywords -->

<bookinfo>
<title>The &ktts; Handbook</title>

<authorgroup>
<author>
<!-- This is just put in as an example.  For real documentation, please 
     define a general entity in entities/contributor.entities, e.g.
<!ENTITY George.N.Ugnacious "<personname><firstname>George</firstname><othername>N.</othername><surname>Ugnacious</surname></personname>">
<!ENTITY George.N.Ugnacious.mail "<email>gnu@kde.org</email>">
and use `&George.N.Ugnacious; &George.N.Ugnacious.mail;' in the author element.
 -->
<personname>
<firstname>Gary</firstname>
<othername>R.</othername>
<surname>Cramblitt</surname>
</personname>
<email>garycramblitt@comcast.net</email>
</author>

<!-- TRANS:ROLES_OF_TRANSLATORS -->

</authorgroup>

<copyright>
<year>2004-2005</year>
<holder>Gary R. Cramblitt</holder>
</copyright>
<!-- Translators: put here the copyright notice of the translation -->
<!-- Put here the FDL notice.  Read the explanation in fdl-notice.docbook 
     and in the FDL itself on how to use it. -->
<legalnotice>&FDLNotice;</legalnotice>

<!-- Date and version information of the documentation
Don't forget to include this last date and this last revision number, we
need them for translation coordination !
Please respect the format of the date (YYYY-MM-DD) and of the version
(V.MM.LL), it could be used by automation scripts.
Do NOT change these in the translation. -->

<date>2005-07-31</date>
<releaseinfo>1.05.00</releaseinfo>

<!-- Abstract about this handbook -->

<abstract>
<para>
&ktts; - the &kde; Text-to-Speech system - is
a plugin based service that
allows any &kde; (or non-&kde;) application to speak using the &DCOP; interface.
</para>

<para>&ktts; intends to be the implementation for the &kde; Text-to-Speech API.</para>

</abstract>

<!-- This is a set of Keywords for indexing by search engines.
Please at least include KDE, the KDE package it is in, the name
 of your application, and a few relevant keywords. -->

<keywordset>
<keyword>KDE</keyword>
<keyword>accessibility</keyword>
<keyword>tdeaccessibility</keyword>
<keyword>TTS</keyword>
<keyword>Text-to-Speech</keyword>
<keyword>KTTSD</keyword>
<keyword>kttsmgr</keyword>
<keyword>festival</keyword>
<keyword>flite</keyword>
<keyword>hadifix</keyword>
<keyword>MBROLA</keyword>
<keyword>freetts</keyword>
<keyword>epos</keyword>
<keyword>SSML</keyword>
</keywordset>

</bookinfo>

<!-- The contents of the documentation begin here.  Label
each chapter so with the id attribute. This is necessary for two reasons: it
allows you to easily reference the chapter from other chapters of your
document, and if there is no ID, the name of the generated HTML files will vary
from time to time making it hard to manage for maintainers and for the CVS
system. Any chapter labelled (OPTIONAL) may be left out at the author's
discretion. Other chapters should not be left out in order to maintain a
consistent documentation style across all KDE apps. -->

<!-- ====================================================================== -->

<chapter id="introduction">
<title>Introduction</title>

<!-- The introduction chapter contains a brief introduction for the
application that explains what it does and where to report
problems. Basically a long version of the abstract.  Don't include a
revision history. (see installation appendix comment) -->

<para>&ktts; is a subsysem within &kde; for producing
Text-to-Speech (TTS).  It provides a common API for &kde; programmers to give
TTS capabilities to their applications.  It provides some
nice capabilities for end users as well.</para>

<para>User features:</para>

<itemizedlist>
<listitem><para>Speak contents of a text file.</para></listitem>
<listitem><para>Speak &kde; notification events (KNotify).</para></listitem>
<listitem><para>Speak all or part of the text of a web page in &konqueror;.</para></listitem>
<listitem><para>Speak all or part of the text in &kate; text editor,
including instances where &kate; is embedded in another &kde; application.</para></listitem>
<listitem><para>Long text is parsed into sentences.  User may backup by sentence
or paragraph, replay, pause, and stop playing.</para></listitem>
<listitem><para>Audio output via &arts;, ALSA, GStreamer (version 0.8.7 or later), or aKode.</para></listitem>
<listitem><para>User-configurable filters for substituting misspoken words, choosing
speech synthesizers, and transforming XHMTL/&XML; documents.</para></listitem>
</itemizedlist>

<para>Programmer features:</para>

<itemizedlist>
<listitem><para>Priority system for screen reader outputs, warnings and messages, while still playing regular texts.</para></listitem>
<listitem><para>Plugin-based architecture for support of a wide variety of speech synthesis engines and drivers.</para></listitem>
<listitem><para>Permit generation of speech from the command line (or via shell scripts) using the &kde; &DCOP; utilities.</para></listitem>
<listitem><para>Provide a lightweight and easily usable interface for applications to generate speech output.</para></listitem>
<listitem><para>Applications need not be concerned about contention over the speech device.</para></listitem>
<listitem><para>FUTURE: Provide support for speech markup languages, such as VoiceXML, Sable, &Java; Speech Markup Language (JSML), and Speech Markup Meta-language (SMML).</para></listitem>
<listitem><para>FUTURE: Provide limited support for embedded speech markers.</para></listitem>
<listitem><para>Asynchronous to prevent system blocking.</para></listitem>
</itemizedlist>

<para>&ktts; actually consists of several programs:
<variablelist>

<varlistentry>
<term><command>kttsd</command></term>
<listitem><para>the &kde; Text-to-Speech Daemon, which is a non-&GUI;
application that provides TTS services to applications via &DCOP;.
</para></listitem></varlistentry>

<varlistentry>
<term><command>kttsmgr</command></term>
<listitem><para>a &GUI; application for configuring and controlling
kttsd.  kttsmgr sits in the system tray.
</para></listitem></varlistentry>

<varlistentry>
<term><command>libkhtmlkttsdplugin</command></term>
<listitem><para>A plugin for the &konqueror; web browser that permits you
to speak all or a portion of the text on a web page.
</para></listitem></varlistentry>

<varlistentry>
<term><command>ktexteditor_kttsd</command></term>
<listitem><para>A plugin for the &kate; text editor that permits you to speak
all or a portion of a text file.
</para></listitem></varlistentry>

</variablelist>
</para>

<!-- ...................................................................... -->

<sect1 id="support">
<title>Support</title>
<para>
In addition to the &kde; Bugzilla database (
<ulink url="http://bugs.kde.org/">http://bugs.kde.org/</ulink>
), discussions for &ktts;
currently take place in the kde-accessibility mailing list.  Subscribe at
<ulink url="https://mail.kde.org/mailman/listinfo/kde-accessibility">
https://mail.kde.org/mailman/listinfo/kde-accessibility</ulink>.  Developers
also hang out in IRC (irc.kde.org, channel #kde-accessibility).
</para>
</sect1>

</chapter>

<!-- ====================================================================== -->

<chapter id="using-kapp">
<title>Using &ktts;</title>

<para>
<warning><para>Before you can use &ktts;, you must install at least one speech
synthesis engine and make sure it is working.  See <xref linkend="installation" />.
</para></warning></para>

<!-- ...................................................................... -->


<sect1 id="starting-kttsmgr">
<title>Starting <command>kttsmgr</command></title>

<para>
To start the &ktts; system, type the following command in a &konsole;
</para>

<para><userinput>kttsmgr</userinput></para>

<para>or click on kttsmgr in the &kde; Menu.</para>

<para>If this is the first time running <command>kttsmgr</command>, or
if you have not yet configured any talkers, the <guilabel>Talkers</guilabel>
screen appears.  See <xref linkend="configure-plugin" />.
If you have already configured at least one talker, the <guilabel>General</guilabel>
screen appears.  See <xref linkend="general" />.</para>

</sect1>

<!-- ...................................................................... -->


<sect1 id="configure-plugin">
<title>Configuring Synthesis Plugins (Talkers)</title>

<para>Most text-to-speech (TTS) synthesizers offer multiple languages and voices
and may offer multiple speaking genders, volumes, and rates.  You may configure more than
one instance of a synthesizer.  Each combination of language, synthesizer, voice,
gender, volume, and rate is called a talker.  You must configure at least one talker
before you can start &ktts; and begin speaking text.</para>

<note><para>Multiple talkers for the same synthesizer is similar to multiple print
queues for a single physical printer.</para></note>

<para>When applications send text to &ktts;, they may specify the
attributes of the preferred talker to do the synthesis.  For example,
an application may request an English language female talker.  If you have
configured a talker with both the English language and female gender, that
talker will be used, otherwise the closest matching talker will be automatically
picked.  To learn more about how &ktts; picks talkers, see
<xref linkend="filters" />.</para>

<para>When you click the <guilabel>Talkers</guilabel> tab in <command>kttsmgr</command>,
the <guilabel>Talkers</guilabel> screen appears.  This screen also automatically
appears if you start <command>kttsmgr</command> and you have not yet configured
any talkers.</para>

<para>
<screenshot>
<screeninfo>The &kde; Text-to-Speech Manager (Talkers tab).</screeninfo>
	<mediaobjectco>
		<imageobjectco>
			<areaspec units="calspair">
				<area id="pt-talker-1" coords="1 1"/>
				<area id="pt-talker-2" coords="1 1"/>
				<area id="pt-talker-3" coords="1 1"/>
				<area id="pt-talker-4" coords="1 1"/>
				<area id="pt-talker-5" coords="1 1"/>
				<area id="pt-talker-6" coords="1 1"/>
			</areaspec>
			<imageobject>
				<imagedata fileref="talkers.png" format="PNG"/>
			</imageobject>
		</imageobjectco>
		<textobject>
			<phrase>The &kde; Text-to-Speech Manager (Talkers tab)</phrase>
		</textobject>
	</mediaobjectco>
</screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-talker-1"><para>Click to add a new talker.</para></callout>
<callout arearefs="pt-talker-2"><para>All the configured <guilabel>Talkers</guilabel> are listed here.  Highest priority <guilabel>Talkers</guilabel> are listed at the top.  The top-most talker will be used to do the speaking when an application does not specify a talker.</para></callout>
<callout arearefs="pt-talker-3"><para>Click on a talker in the list to highlight it and click this button to remove it.</para></callout>
<callout arearefs="pt-talker-4"><para>Click on a talker in the list to highlight it and click this button to display the synthesis plugin's configuration dialog.  See below.</para></callout>
<callout arearefs="pt-talker-5"><para>Click on a talker in the list to highlight it and click this button to move it down one row in the list.  The lower a talker appears in the list, the lower its priority.</para></callout>
<callout arearefs="pt-talker-6"><para>Click one of these buttons to apply the changes you have made to the running &ktts; system.</para></callout>
</calloutlist>
</para>

<para>When you click the <guibutton>Add</guibutton> button, the <guilabel>Add Talker</guilabel> screen appears.</para>

<para>
	<screenshot>
		<screeninfo>Add Talker screen.</screeninfo>
		<mediaobjectco>
			<imageobjectco>
				<areaspec units="calspair">
					<area id="pt-addtalker-1" coords="1 1"/>
					<area id="pt-addtalker-2" coords="1 1"/>
					<area id="pt-addtalker-3" coords="1 1"/>
				</areaspec>
				<imageobject>
					<imagedata fileref="addtalker.png" format="PNG"/>
				</imageobject>
			</imageobjectco>
			<textobject>
				<phrase>Add Talker screen</phrase>
			</textobject>
		</mediaobjectco>
	</screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-addtalker-1"><para>You can select a speech synthesis
plugin by either <guilabel>Synthesizer</guilabel> name, or by the <guilabel>Language</guilabel> the synthesizer can speak.
Check the radio button next to the corresponding box.  When the
<guilabel>Language</guilabel> radio button is checked, the
<guilabel>Language</guilabel> box displays all the languages supported by
all available synthesizers, and the <guilabel>Synthesizer</guilabel> box
displays only those synthesizers that support the chosen language.
When the <guilabel>Synthesizer</guilabel> radio button is checked,
the <guilabel>Synthesizer</guilabel> box displays all available
synthesizers, and the <guilabel>Language</guilabel> box displays
only the languages supported by the chosen synthesizer.</para></callout>
<callout arearefs="pt-addtalker-2"><para>Choose the language and
synthesizer plugin here.</para></callout>
<callout arearefs="pt-addtalker-3"><para>When you click here,
most synthesizer plugins will automatically configure themselves,
choosing a default setup.  A new talker
will appear in the list in the <guilabel>Talkers</guilabel> screen.
Click the <guibutton>Edit</guibutton> button to display or edit the talker's 
configuration.</para></callout>
</calloutlist>
</para>

<para>When you click the <guibutton>Add</guibutton> button on the
<guilabel>Talkers</guilabel> tab and add a talker that cannot
automatically configure itself, or click the
<guibutton>Edit</guibutton> button,
the <guilabel>Talker Configuration</guilabel> screen appears.
Each speech synthesis plugin has a different
<guilabel>Talker Configuration</guilabel> screen.  The following is an example for
configuring the Festival Interactive plugin.  For specifics for each
kind of plugin, see <xref linkend="configuration" />.</para>

<para>
<screenshot>
<screeninfo>Talker Configuration</screeninfo>
	<mediaobjectco>
		<imageobjectco>
			<areaspec units="calspair">
				<area id="pt-prop-1" coords="1 1"/>
				<area id="pt-prop-2" coords="1 1"/>
				<area id="pt-prop-3" coords="1 1"/>
				<area id="pt-prop-4" coords="1 1"/>
				<area id="pt-prop-5" coords="1 1"/>
				<area id="pt-prop-6" coords="1 1"/>
				<area id="pt-prop-7" coords="1 1"/>
			</areaspec>
			<imageobject>
				<imagedata fileref="festivalintconf.png" format="PNG"/>
			</imageobject>
		</imageobjectco>
		<textobject>
			<phrase>Talker Configuration</phrase>
		</textobject>
	</mediaobjectco>
</screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-prop-1"><para>Specify the path to the Festival executable program.
If Festival is in your PATH environment variable, just enter
<userinput><replaceable>festival</replaceable></userinput>.</para></callout>
<callout arearefs="pt-prop-2"><para>Click to scan for available voices.</para></callout>
<callout arearefs="pt-prop-3"><para>Select a voice.</para></callout>
<callout arearefs="pt-prop-4"><para>Select a character encoding for text sent to Festival.
For voices that are known to &ktts;, this setting will be picked for you automatically.  In general, western languages use ISO 8859-1.  Eastern European languages such
as Czech or Slovak use ISO 8859-2.</para></callout>
<callout arearefs="pt-prop-5"><para>Click to test.  You should hear a test sentence spoken.</para></callout>
<callout arearefs="pt-prop-6"><para>Use these controls to set the volume, talking speed, and
pitch (tone) of the synthesized speech.  If any of these are disabled (grayed), the chosen
voice does not support changing them.</para></callout>
<callout arearefs="pt-prop-7"><para>Some voices, such as the MultiSyn voices, are so large
that they require several seconds to load.  Checking this box will cause them to be loaded
when KTTSD is started, thereby saving time (at the expense of using more memory)
before the first sentence is synthesized.</para></callout>
</calloutlist>
</para>

<para>Click the <guibutton>OK</guibutton> button to save the talker configuration settings.</para>

<warning><para>
Be sure to click the <guibutton>Apply</guibutton> button, otherwise your
changes will not take effect in the running &ktts; system.
</para></warning>

<para>Assuming the test worked, you are almost ready to begin using &ktts;.
Now go back to the <guilabel>General</guilabel> tab and check the
<guilabel>Enable Text-to-Speech System (KTTSD)</guilabel> box.  This
will start the &kde; TTS Daemon.  See <xref linkend="general" />.
You may now begin using &ktts; to
speak text.  Click the <guilabel>Jobs</guilabel> tab to create and manage text jobs.
See <xref linkend="jobmgr" />.
</para>

</sect1>

<!-- ...................................................................... -->


<sect1 id="general">
<title>Starting KTTSD and Setting General Options</title>

<para>Once you have configured at least one talker,
you can start the &kde; Text-to-Speech System.  Click on the
<guilabel>General</guilabel> tab.  The <guilabel>General</guilabel>
screen appears.  You can also set some general options on this screen.
</para>

<para>
	<screenshot>
		<screeninfo>The &kde; Text-to-Speech Manager (General tab).</screeninfo>
		<mediaobjectco>
			<imageobjectco>
				<areaspec units="calspair">
					<area id="pt-gen-1" coords="1 1"/>
					<area id="pt-gen-2" coords="1 1"/>
					<area id="pt-gen-3" coords="1 1"/>
					<area id="pt-gen-4" coords="1 1"/>
                    <area id="pt-gen-5" coords="1 1"/>
                    <area id="pt-gen-6" coords="1 1"/>
				</areaspec>
				<imageobject>
					<imagedata fileref="general.png" format="PNG"/>
				</imageobject>
			</imageobjectco>
			<textobject>
				<phrase>The &kde; Text-to-Speech Manager (General tab)</phrase>
			</textobject>
		</mediaobjectco>
	</screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-gen-1"><para>Check this box to activate the &ktts; system.
This starts the &kde; TTS Daemon (KTTSD).  If KTTSD starts successfully,
the <guilabel>Jobs</guilabel> tab will appear.
Once KTTSD has been started, you can begin creating and speaking text jobs.
See <xref linkend="jobmgr" />.  Unchecking will stop KTTSD and deactivate the &kde; TTS system.
<note><para>If this box is disabled, you have not yet configured any talkers
(or you forgot to click the <guibutton>Apply</guibutton> button).
See <xref linkend="configure-plugin"/>.</para></note>
</para></callout>
<callout arearefs="pt-gen-2"><para>When this box is checked, an icon appears
in the system tray whenever <command>kttsmgr</command> is running.  In this
mode, clicking <guibutton>OK</guibutton> or <guibutton>Cancel</guibutton> does
not cause <command>kttsmgr</command> to exit.  Instead, the screen
disappears but <command>kttsmgr</command> continues running in the system
tray.  Click the icon to restore the screen.  To quit <command>kttsmgr</command>,
right-click on the icon in the system tray and choose <guilabel>Quit</guilabel>.
When unchecked, an icon does not appear in the system tray.  Clicking <guibutton>OK</guibutton>
or <guibutton>Cancel</guibutton> quits <command>kttsmgr</command>.
<note><para>When <command>kttsmgr</command> exits, 
&ktts; keeps running if the <guilabel>Enable Text-to-Speech System (KTTSD)</guilabel> box is checked.</para></note>
<note><para>This option does not take effect until the next time
<command>kttsmgr</command> is started.</para></note>
<note><para>This option has no effect when <command>kttsmgr</command> is
running in the &kcontrol;.</para></note>
</para></callout>
<callout arearefs="pt-gen-3"><para>When this box is checked, the <command>kttsmgr</command> screen appears when you start <command>kttsmgr</command>.  If unchecked, the
<command>kttsmgr</command> icon appears in the system tray when
<command>kttsmgr</command> is started, but the screen does not appear.
Click the icon in the system tray to make the screen appear.</para></callout>
<callout arearefs="pt-gen-4"><para>When this box is checked, and <command>kttsmgr</command> is 
not already running, it will appear in the system tray whenever KTTSD is speaking.
This gives you an opportunity to stop or otherwise manage the speaking.</para></callout>
<callout arearefs="pt-gen-5"><para>When this box is checked, and <command>kttsmgr</command>
automatically appears in the system tray whenever speaking, it will also disappear
automatically when speaking has finished.</para></callout>
<callout arearefs="pt-gen-6"><para>Be sure to click here to save your settings.</para></callout>
</calloutlist>
</para>

</sect1>

<!-- ...................................................................... -->


<sect1 id="jobmgr">
<title>Managing Text Jobs</title>

<para>When you click the <guilabel>Jobs</guilabel> tab in <command>kttsmgr</command>,
the <guilabel>Jobs</guilabel> screen appears.</para>

<para>
<screenshot>
<screeninfo>The &kde; Text-to-Speech Manager (Jobs tab).</screeninfo>
	<mediaobjectco>
		<imageobjectco>
			<areaspec units="calspair">
				<area id="pt-jobmgr-1" coords="1 1"/>
				<area id="pt-jobmgr-2" coords="1 1"/>
				<area id="pt-jobmgr-3" coords="1 1"/>
				<area id="pt-jobmgr-4" coords="1 1"/>
				<area id="pt-jobmgr-5" coords="1 1"/>
				<area id="pt-jobmgr-6" coords="1 1"/>
				<area id="pt-jobmgr-7" coords="1 1"/>
			</areaspec>
			<imageobject>
				<imagedata fileref="jobs.png" format="PNG"/>
			</imageobject>
		</imageobjectco>
		<textobject>
			<phrase>The &kde; Text-to-Speech Manager (Jobs tab)</phrase>
		</textobject>
	</mediaobjectco>
</screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-jobmgr-1"><para>All of the text jobs currently in the queue
are listed here, together with the application that queued the job,
the current job state, number of sentences in the job,
and current sentence number.  The <guilabel>Talker ID</guilabel> corresponds to the
<guilabel>ID</guilabel> column on the <guilabel>Talkers</guilabel> screen.
</para></callout>
<callout arearefs="pt-jobmgr-2"><para>The buttons in this row permit you to start,
delete, and pause text jobs.  Select a job in the list above, then click
one of these buttons.</para></callout>
<callout arearefs="pt-jobmgr-3"><para>The buttons in this row permit
you to advance or rewind by sentence within the job selected in the list
above.  (Not all jobs have multiple parts.)</para></callout>
<callout arearefs="pt-jobmgr-4"><para>The buttons in this row permit
you to speak the text currently in the &kde; clipboard, or open a text file
for speaking.  You can also refresh the list of text jobs or
change the talker for a job.  See <xref linkend="selecttalker" />.</para></callout>
<callout arearefs="pt-jobmgr-5"><para>The currently-speaking sentence
appears here.</para></callout>
<callout arearefs="pt-jobmgr-6"><para>When you click <guibutton>OK</guibutton>,
all changes to settings on other screens are applied (if any) and
<command>kttsmgr</command> minimizes to the system tray.  Click on the icon
in the system tray to restore the screen.</para></callout>
<callout arearefs="pt-jobmgr-7"><para>Drag this divider to resize
the jobs listing and <guilabel>Current sentence</guilabel> panels.</para></callout>
</calloutlist>
</para>

<note><para>The <guilabel>Jobs</guilabel> tab only appears when KTTSD is running.  If you do not see the <guilabel>Jobs</guilabel> tab, click on the
<guilabel>General</guilabel> tab and check the
<guilabel>Enable Text-to-Speech (KTTSD)</guilabel> box.</para>
</note>

<note><para>If you do not have the &arts; audio subsystem installed, but you
do have ALSA, GStreamer, or aKode installed, click the <guilabel>Audio</guilabel> tab.
See <xref linkend="audio" />.</para></note>

<note><para>Only Text jobs are listed and controlled on this screen.
Screen Reader Output, Warnings, and Messages are not displayed.  For more information
about &ktts; message types, see <xref linkend="filters" />.</para></note>

</sect1>

<!-- ...................................................................... -->

<sect1 id="audio">
<title>Audio Settings</title>

<para>When you click the <guilabel>Audio</guilabel> tab in <command>kttsmgr</command>,
the <guilabel>Audio</guilabel> screen appears.</para>

<para>
    <screenshot>
        <screeninfo>The &kde; Text-to-Speech Manager (Audio tab).</screeninfo>
        <mediaobjectco>
            <imageobjectco>
                <areaspec units="calspair">
                    <area id="pt-audio-1" coords="1 1"/>
                    <area id="pt-audio-2" coords="1 1"/>
                    <area id="pt-audio-3" coords="1 1"/>
                    <area id="pt-audio-4" coords="1 1"/>
                    <area id="pt-audio-5" coords="1 1"/>
                </areaspec>
                <imageobject>
                    <imagedata fileref="audio.png" format="PNG"/>
                </imageobject>
            </imageobjectco>
            <textobject>
                <phrase>The &kde; Text-to-Speech Manager (Audio tab)</phrase>
            </textobject>
        </mediaobjectco>
    </screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-audio-1"><para>Select the method of audio output here.
If a component is is grayed, either &ktts; was compiled
without that support for that audio plugin, or &ktts; was unable to load the
necessary libraries.
</para></callout>
<callout arearefs="pt-audio-2"><para>If GStreamer or aKode is selected for audio output,
choose the audio sink method here.  If no sinks are listed, you need
to install at least one.  If ALSA is selected, choose the PCM device here.  See <xref linkend="requirements" />.
</para></callout>
<callout arearefs="pt-audio-3"><para>Adjust the speed of talking here.
50% is approximately twice as slow as normal while 200% is approximately
twice as fast.  You must have the <command>sox</command> utility installed for this setting
to work.
</para></callout>
<callout arearefs="pt-audio-4"><para>When this box is checked, &ktts; will 
copy temporary audio files (.wav files) into the indicated folder.  Choose
any folder on your hard drive you like, but you must have write access to it.
This can be useful for creating audio files of speech for other purposes.
The files will have names of the form <filename>kttsd-J-SS</filename> where
<filename>J</filename> is the job number and <filename>SS</filename> is the sentence number.
Existing files with the same name will be deleted.
<emphasis>Do not forget to uncheck this box, otherwise your hard drive will fill up!</emphasis>
</para></callout>
<callout arearefs="pt-audio-5"><para>Be sure to click <guibutton>Apply</guibutton>
to apply the new settings to the running &ktts; system.
</para></callout>
</calloutlist>
</para>

<note><para>There are two ways to adjust the speed of speech in &ktts;.
Many of the <guilabel>Talkers</guilabel> have a <guilabel>Speed</guilabel>
setting in their configuration dialogs, which you can display by clicking
<guibutton>Edit</guibutton> on the <guilabel>Talkers</guilabel> screen.  This
<guilabel>Speed</guilabel> setting on the <guilabel>Audio</guilabel> screen
is in addition to the talker speed setting and generally can be used
even if the talker does not support a speed setting.  For this speed setting
to work, you must have the <command>sox</command>
utility installed on your system (Debian users: 
<command>apt-get install sox</command>).  Also, this speed setting is ignored
when speaking text containing SSML.  (See <xref linkend="ssml" />)</para></note>

<note><para>The list of ALSA devices includes all the ALSA PCM devices and
plugins configured in your system.  Many of the choices will not work.
You must experiment to find a device that works for you.  If in doubt,
choose <guilabel>default</guilabel>.</para></note>

</sect1>

<!-- ...................................................................... -->

<sect1 id="interruption">
<title>Text Interruption Settings</title>

<para>When you click the <guilabel>Interruption</guilabel> tab in <command>kttsmgr</command>,
the <guilabel>Interruption</guilabel> screen appears.</para>

<para>
<screenshot>
<screeninfo>The &kde; Text-to-Speech Manager (Interruption tab).</screeninfo>
	<mediaobjectco>
		<imageobjectco>
			<areaspec units="calspair">
				<area id="pt-interruption-1" coords="1 1"/>
				<area id="pt-interruption-2" coords="1 1"/>
				<area id="pt-interruption-3" coords="1 1"/>
				<area id="pt-interruption-4" coords="1 1"/>
			</areaspec>
			<imageobject>
				<imagedata fileref="interruption.png" format="PNG"/>
			</imageobject>
		</imageobjectco>
		<textobject>
			<phrase>The &kde; Text-to-Speech Manager (Interruption tab)</phrase>
		</textobject>
	</mediaobjectco>
</screenshot>
</para>

<para>This screen permits you to specify special actions to be taken whenever
a text job is interrupted by another, higher priority, message.  There are
four kinds of speech jobs that &ktts; handles:
<itemizedlist>
<listitem><para>Regular text.</para></listitem>
<listitem><para>Messages.</para></listitem>
<listitem><para>Warnings.</para></listitem>
<listitem><para>Screen Reader Output.</para></listitem>
</itemizedlist>
</para>

<para>Screen Reader Output has the highest priority.  It is reserved for use
by Screen Reader applications.  Screen Reader Output preempts all other
messages, causing those jobs to pause.  Once the Screen Reader Output has
been spoken, the preempted jobs will automatically resume.
</para>

<para>Warnings are the next highest priority.  It is reserved for high-priority
messages, such as "CPU is over-heating."  A Warning will preempt Messages
and regular text, causing those jobs to pause.  Once the Warning has been
spoken, the preempted jobs will automatically resume.</para>

<para>Messages are the next highest priority.  A Message will preempt regular
text jobs.  &kmouth; is an example of an application that uses Messages.
For example, while reading out long text from a web page,
&kmouth; can be used to greet someone who walks into the room.</para>

<para>All four kinds of jobs are queues, except for Screen Reader Output.
If a Screen Reader Output is sent from an application while
&ktts; is speaking another Screen Reader Output, the speaking message 
is stopped and discarded.</para>

<para>When a text job is interrupted by a Message, Warning, or Screen Reader Output,
&ktts; will add the audio outputs on this screen to the stream.</para>

<para>
<calloutlist>
<callout arearefs="pt-interruption-1"><para>This message is spoken whenever a regular text job is interrupted.</para></callout>
<callout arearefs="pt-interruption-2"><para>This audio file is sounded whenever a regular text job is interrupted.  If both a <guilabel>Pre-sound</guilabel>
and a <guilabel>Pre-message</guilabel> are specified, the 
<guilabel>Pre-sound</guilabel> is sounded before the <guilabel>Pre-message</guilabel>.</para></callout>
<callout arearefs="pt-interruption-3"><para>This message is spoken whenever an
interrupted text job resumes.</para></callout>
<callout arearefs="pt-interruption-4"><para>This audio file is sounded whenever an
interrupted text job resumes.  It is sounded last.</para></callout>
</calloutlist>
</para>

<note><para>The settings on this screen apply only to regular text jobs.
Messages, Warnings, and Screen Reader Outputs have no special actions when
they are preempted by a higher-priority message.</para></note>

</sect1>

<!-- ...................................................................... -->


<sect1 id="web">
<title>Speaking Text from Web Pages</title>

<para>While running the &kde; &konqueror; web browser, you can speak the text
of the web page displayed.  First ensure that &ktts; is running.
Highlight the text you want spoken and choose
<menuchoice>
  <guisubmenu>Tools</guisubmenu>
  <guisubmenu>Speak Text</guisubmenu>
</menuchoice> on the main menu.
<action>After a moment, the highlighted text should begin speaking.</action>
</para>

<tip><para>It is almost always a good idea to highlight the text on the
web page you want spoken.  You can skip this step, but you will
hear a lot of &HTML; headers and other invisible tags spoken.</para></tip>

</sect1>

<!-- ...................................................................... -->


<sect1 id="kate">
<title>Speaking Text from &kate; Text Editor</title>

<para>While running the &kde; Advanced Text Editor (&kate;), you can speak the text
displayed.  First ensure that &ktts; is running.
Highlight the text you want spoken and choose
<menuchoice>
  <guisubmenu>Tools</guisubmenu>
  <guisubmenu>Speak Text</guisubmenu>
</menuchoice> on the main menu.
<action>After a moment, the highlighted text should begin speaking.</action>
</para>

<tip><para>You do not have to first highlight text.  In this case, the entire
file will be spoken.</para></tip>

<tip><para>This also works when &kate; is running embedded in another application,
such as &konqueror; or &quanta;.</para></tip>

</sect1>

<!-- ...................................................................... -->

<sect1 id="knotify">
<title>Speaking Notifications (KNotify)</title>

<para>KNotify is the notification subsystem within &kde;, which alerts you
to events you configure within the &kde; system.  You can configure
&ktts; to speak text notifications.</para>

<para>For example, &konversation;, a &kde; IRC application, permits you
to configure a wide variety of notifications.  For instance, you can tell
&konversation; to notify you whenever a message appears in an IRC channel
with your nickname in it.  Together with &ktts; you can
have &kde; speak the text of the IRC message to you.</para>

<para>In general, if a &kde; application supports KNotify, a
<guilabel>Notifications</guilabel> menu item will appear under the
application's <guilabel>Settings</guilabel> menu.  The specifics for configuring
each application with KNotify vary from application to application.</para>

<para>To enable &ktts; to speak KNotify text notifications,
start <command>kttsmgr</command> and click the <guilabel>Notifications</guilabel> tab.
The <guilabel>Notifications</guilabel> screen appears.</para>

<para>
<screenshot>
<screeninfo>The &kde; Text-to-Speech Manager (Notifications tab).</screeninfo>
	<mediaobjectco>
		<imageobjectco>
			<areaspec units="calspair">
				<area id="pt-notify-1" coords="1 1"/>
				<area id="pt-notify-2" coords="1 1"/>
				<area id="pt-notify-3" coords="1 1"/>
				<area id="pt-notify-4" coords="1 1"/>
				<area id="pt-notify-5" coords="1 1"/>
				<area id="pt-notify-6" coords="1 1"/>
				<area id="pt-notify-7" coords="1 1"/>
				<area id="pt-notify-8" coords="1 1"/>
				<area id="pt-notify-9" coords="1 1"/>
				<area id="pt-notify-10" coords="1 1"/>
			</areaspec>
			<imageobject>
				<imagedata fileref="notifications.png" format="PNG"/>
			</imageobject>
		</imageobjectco>
		<textobject>
			<phrase>The &kde; Text-to-Speech Manager (Notification tab)</phrase>
		</textobject>
	</mediaobjectco>
</screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-notify-1"><para>Check this box to enable speaking of
&kde; notifications.  If unchecked, everything else on this screen is disabled
and &ktts; does not speak any notifications.</para></callout>
<callout arearefs="pt-notify-2"><para>When checked, any application
that sends an event with a sound will not be spoken by &ktts;.</para></callout>
<callout arearefs="pt-notify-3"><para>Use these buttons to add or delete
application events from the list below.  When you click
the <guibutton>Add</guibutton> button, a screen appears in which
you select the application and event you want to add to the list.
</para></callout>
<callout arearefs="pt-notify-4"><para>This event will speak the message
&konversation; sends when someone mentions your nickname in an Internet Relay Chat message.
</para></callout>
<callout arearefs="pt-notify-5"><para>For all other events coming from
&konversation;, no action will be taken in &ktts;.</para></callout>
<callout arearefs="pt-notify-6"><para>For all events not otherwise
specified in the list, no action will be taken in &ktts;.</para></callout>
<callout arearefs="pt-notify-7"><para>Use this box to specify what
&ktts; should do when it receives an event.  Your choices are:</para>
<para>
<variablelist>
<varlistentry>
<term>Speak event name</term>
<listitem><para>Speaks the name of the event; what you see listed in the
event list on this screen.</para></listitem>
</varlistentry>
<varlistentry>
<term>Speak the notification message</term>
<listitem><para>Speaks the message as it is sent from the application.</para></listitem>
</varlistentry>
<varlistentry>
<term>Do not speak the notification</term>
<listitem><para>Does not speak this event at all.</para></listitem>
</varlistentry>
<varlistentry>
<term>Speak custom text</term>
<listitem><para>Speaks the text you enter in the box to the right.</para></listitem>
</varlistentry>
</variablelist>
</para>
</callout>
<callout arearefs="pt-notify-8"><para>If the action is
<guilabel>Speak custom text</guilabel>, enter the text of the message
you would like spoken here.  Within the message, you may use the following
substitution strings:</para>
<para>
<variablelist>
<varlistentry>
<term>%e</term>
<listitem><para>The name of the event</para></listitem>
</varlistentry>
<varlistentry>
<term>%a</term>
<listitem><para>The name of the application that sent the event</para></listitem>
</varlistentry>
<varlistentry>
<term>%m</term>
<listitem><para>The message the application sent</para></listitem>
</varlistentry>
</variablelist>
</para>
</callout>
<callout arearefs="pt-notify-9"><para>Test the message by clicking here.</para></callout>
<callout arearefs="pt-notify-10"><para>You may specify the attributes of the
desired talker to speak the notification message here.
<command><userinput>default</userinput></command>
will use the topmost talker listed in the <guilabel>Talkers</guilabel>
screen.  See <xref linkend="selecttalker" />.
</para></callout>
</calloutlist>
</para>

<para>Notice there are three levels of events.  If an action for a specific event
of a specific application is specified, that action is taken.  Otherwise, if
an action for all other events of a specific application is specified, that
action is taken.  Otherwise, the action specified for all other events
under <guilabel>Default (all other events)</guilabel> is taken.</para>

<para>The event <guilabel>all notifications</guilabel>
for application <guilabel>Default (all other events)</guilabel>
may not be deleted from the list.  For the default all other events,
you may specify the kind of notifications that are spoken, as follows:</para>

<variablelist>
<varlistentry>
<term>none</term>
<listitem><para>None will be spoken.</para></listitem>
</varlistentry>
<varlistentry>
<term>notification dialogs</term>
<listitem><para>Notifications that display a dialog on your screen, that you must then
dismiss, will be spoken.</para></listitem>
</varlistentry>
<varlistentry>
<term>passive popups</term>
<listitem><para>Notifications that display a passive dialog on your screen,
that automatically disappear after a moment, will be spoken.</para></listitem>
</varlistentry>
<varlistentry>
<term>notification dialogs and passive popups</term>
<listitem><para>Notifications that display on screen, passively or not,
will be spoken.</para></listitem>
</varlistentry>
<varlistentry>
<term>all notifications</term>
<listitem><para>All notifications, regardless of whether they produce
a display on screen, will be spoken.</para></listitem>
</varlistentry>
</variablelist>

<tip><para>String Replacer filters are a good way to clean up messages
sent from applications if they are mispronounced or misspoken in 
&ktts;.  The <filename>kmail.xml</filename> file, which
comes with &ktts;, is a good example.  It removes <command>br</command>,
and <command>b</command> tags from the &kmail; notification messages and also removes the
phrase <command>/local/inbox/</command>, since this
may be safely assumed in most cases.  See <xref linkend="stringreplacer" />.
</para></tip>

<para>Use the <guibutton>Save</guibutton> button to save your
notification settings to a file.  Use the <guibutton>Load</guibutton>
button to load saved settings from a file.  The loaded events are merged
with existing events in the list.  If you want to start with
an empty event list, click the <guibutton>Clear</guibutton>
button first.  All events except for <guilabel>all notifications</guilabel>
will be erased.</para>

<note><para>Be sure to click <guibutton>Apply</guibutton>
or <guibutton>OK</guibutton> to save your settings.</para></note>

</sect1>

<!-- ...................................................................... -->

<sect1 id="ssml">
<title>SSML</title>

<para>The Speech Synthesis Markup Language (SSML) is a W3C standard
for marking up text for speech output.  It provides tags for controlling
voices, rate of speech, volume, gender, and pitch (tone).  It also
provides tags for controlling how words are spoken, for instance
spelling out abbreviations.  SSML is part of the VoiceXML specification,
which is also a W3C standard.</para>

<para>At this time, &ktts; provides limited and very basic support for
SSML.  It currently has the following restrictions.</para>

<itemizedlist>
<listitem><para>Works only with the Festival Interactive and Hadifix Talkers.</para></listitem>
<listitem><para>You must install the <command>rab_diphone</command>
(British male) voice, as this is the default voice Festival uses when speaking
SSML.</para></listitem>
<listitem><para>The <guilabel>Speed</guilabel> setting on the <guilabel>Audio</guilabel>
screen is ignored when speaking text containing SSML.</para></listitem>
<listitem><para>If the <guilabel>Speed</guilabel> or <guilabel>Pitch</guilabel>
settings in the Festival configuration dialog are not set to 100%, it
will usually cause the SSML text to be spoken in a monotone.</para></listitem>
</itemizedlist>

<para>The following sample text can be used to experiment with SSML.</para>

<programlisting><![CDATA[
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE speak PUBLIC "-//W3C//DTD SYNTHESIS 1.0//EN"
    "http://www.w3.org/TR/speech-synthesis/synthesis.dtd">

<speak version="1.0" xml:lang="en-US">
    <prosody pitch="low">
        Who's been sleeping in my bed?
    </prosody>
    said papa bear.
    <prosody pitch="medium">
        Who's been sleeping in my bed?
    </prosody>
    said momma bear.
    <prosody pitch="high">
        Who's been sleeping in my bed?
    </prosody>
    said baby bear.
</speak>
]]></programlisting>

<para>More robust support for SSML is planned for the next version of
&ktts;.
</para>

</sect1>

<!-- ...................................................................... -->

<sect1 id="filters">
<title>Filters (Advanced)</title>

<para>Filters are an advanced feature of &ktts;.  For the
basic operation of &ktts;, they are not needed.</para>

<para>Filters are used to pre-process text before it is sent to the
speech synthesis engine.  They are useful for enhancing speech,
substituting for misspoken words or abbreviations, choosing the
appropriate language and talker to do the speaking, or working around 
certain limitations of speech synthesizers and their voices.</para>

<!-- ...................................................................... -->

<sect2 id="msg-types">
<title>Types of &ktts; Messages</title>

<para>To understand how to use filters, it is
helpful to first understand how text is processed by &ktts;.
Text spoken by &ktts; is of four possible types.</para>

<para>
<itemizedlist>
<listitem><para>Screen Reader Output.</para></listitem>
<listitem><para>Warnings.</para></listitem>
<listitem><para>Messages</para></listitem>
<listitem><para>Text Jobs</para></listitem>
</itemizedlist>
</para>

<para>The type is determined by the application that sends the text
to &ktts;.</para>

<para>Screen Reader Output has the highest priority.  It is reserved for use
by Screen Reader applications.  Screen Reader Output preempts all other
messages, causing those jobs to pause.  Once the Screen Reader Output has
been spoken, the preempted messages will automatically resume.
</para>

<para>Warnings are the next highest priority.  It is reserved for high-priority
messages, such as "CPU is over-heating."  A Warning will preempt Messages
and regular text, causing those jobs to pause.  Once the Warning has been
spoken, the preempted messages will automatically resume.</para>

<para>Messages are the next highest priority.  A Message will preempt regular
text jobs.  &kmouth; is an example of an application that uses Messages.
For example, while reading out long text from a web page,
&kmouth; can be used to greet someone who walks into the room.
&kde; Notifications are also Messages  (see <xref linkend="knotify" />).</para>

<para>The rest are ordinary Text Jobs.  Any job you initiate from the
<guilabel>Jobs</guilabel> tab is a Text Job.  KSayit is an example
of an application that uses Text Jobs.  Text Jobs are intended for
longer speech output that is not urgent.</para>

<para>All four kinds of jobs are queues, except for Screen Reader Output.
If a Screen Reader Output is sent from an application while
&ktts; is speaking another Screen Reader Output, the speaking message 
is stopped and discarded.</para>

</sect2>

<!-- ...................................................................... -->

<sect2 id="filter-types">
<title>Types of Filters</title>

<para>The first thing you must know about filters is that they are
never applied to Screen Reader Output.  They are applied to
Warnings, Messages, and Text jobs, and also &kde; notifications (KNotify).</para>

<para>There are two kinds of filters --
ordinary filters and Sentence Boundary Detector (SBD) filters.
SBDs break text up into individual sentences.  This allows
&ktts; to begin speaking faster because it need only
synthesize the first sentence; not the entire Text Job.
It also permits you to advance or rewind by sentence in the
<guilabel>Jobs</guilabel> tab, or to stop or pause Text Jobs when
the speech synthesizer does not directly support stopping of speech.
</para>

<para>Ordinary filters process the text and pass it on to the
next filter.  There are currently three kinds of ordinary filters.
</para>

<para>
<itemizedlist>
<listitem><para>String Replacers.</para></listitem>
<listitem><para>&XML; Transformers</para></listitem>
<listitem><para>Talker Choosers.</para></listitem>
</itemizedlist>
</para>

<note><para>Filters are implemented using a plugin architecture.
In the future, there may be additional kinds of filters.</para></note>

<para>String Replacer filters substitute pieces of text with
other text.  The replaced pieces are matched either as words or
as regular expressions.  &ktts; comes with pre-defined
String Replacer filters for speaking abbreviations, speaking
chat emoticons, such as ":-)", or reformatting notification
messages from &konversation; or &kmail; into a more understandable
form.
</para>

<para>&XML; Transformers use an &XML; Style Language - Transforms (XSLT)
file to convert &XML; of one format to another format.
&ktts; comes with a couple of XSLT files for converting
&XHTML; into SSML.
</para>

<para>Talker Choosers permit you redirect jobs to a talker 
based on the contents of the text, or upon the application that sent it
to &ktts;.  For example, if you have configured a female talker
in the <guilabel>Talkers</guilabel> tab, you can direct text coming from
KSayIt to that talker.  See <xref linkend="configure-plugin" />.
</para>

<para>Each of these kinds of filters has configurable rules for when
the filter should apply itself to the text to be spoken.  If the
filter determines that it should not apply itself, the text
is passed on to the next filter unaltered.</para>

<para>When a Text Job, Message, Warning, or &kde; Notification message is sent to &ktts;,
it passes through each of the enabled filters you have configured in the
screen below.  The order is from top to bottom.  After passing through
each of the ordinary filters listed in the top portion of the screen, Text Jobs
are passed to the <guilabel>Sentence Boundary Detector</guilabel> (SBD) filters.
(&kde; Notifications, Warnings, and Messages never pass through SBD filters.)
Unlike ordinary filters, the first SBD filter that makes changes to the text
stops any further filtering.
</para>

</sect2>

<!-- ...................................................................... -->

<sect2 id="configure-filters">
<title>Configuring Filters</title>

<para>To use filters, click the <guilabel>Filters</guilabel> tab in <command>kttsmgr</command>.</para>

<para>
    <screenshot>
        <screeninfo>The &kde; Text-to-Speech Manager (Filters tab).</screeninfo>
        <mediaobjectco>
            <imageobjectco>
                <areaspec units="calspair">
                    <area id="pt-filters-1" coords="1 1"/>
                    <area id="pt-filters-2" coords="1 1"/>
                    <area id="pt-filters-3" coords="1 1"/>
                    <area id="pt-filters-4" coords="1 1"/>
                    <area id="pt-filters-5" coords="1 1"/>
                    <area id="pt-filters-6" coords="1 1"/>
                    <area id="pt-filters-7" coords="1 1"/>
                    <area id="pt-filters-8" coords="1 1"/>
                </areaspec>
                <imageobject>
                    <imagedata fileref="filters.png" format="PNG"/>
                </imageobject>
            </imageobjectco>
            <textobject>
                <phrase>The &kde; Text-to-Speech Manager (Filters tab)</phrase>
            </textobject>
        </mediaobjectco>
    </screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-filters-1"><para>This is the list of configured ordinary filters.
If unchecked, the filter is inactive and will be bypassed.
Filters are applied in the order specified here, top to bottom.</para></callout>
<callout arearefs="pt-filters-2"><para>Click here to add a new filter.  You will
be prompted for the kind of filter to add.  After choosing the kind,
see the configuration dialogs below.</para></callout>
<callout arearefs="pt-filters-3"><para>Click here to remove a filter.</para></callout>
<callout arearefs="pt-filters-4"><para>Click here to change the configuration
of a filter.  See the configuration dialogs below.</para></callout>
<callout arearefs="pt-filters-5"><para>Click these buttons to move a filter
up or down in the list.</para></callout>
<callout arearefs="pt-filters-6"><para>These are the Sentence Boundary Detector
filters.  When you first start &ktts;, the Standard Sentence Boundary Detector
is automatically configured for you.  You can change this filter's configuration,
or add additional Sentence Boundary Detectors, but we advise beginners not
to change them.</para></callout>
<callout arearefs="pt-filters-7"><para>This drop-down button permits you
to add, remove, edit, or change the order of Sentence Boundary Detector filters.</para></callout>
<callout arearefs="pt-filters-8"><para>Be sure to click here, otherwise your
settings will not take effect.</para></callout>
</calloutlist>
</para>

</sect2>

<!-- ...................................................................... -->

<sect2 id="stringreplacer">
<title>Configuring String Replacer Filters</title>

<para>You configure String Replacer filters by supplying
a list of words or regular expressions to be matched.
When the matched words or regular expressions are found in the
text, each is replaced by a substitute string you supply.
Matching is case insensitive.</para>

<para>
    <screenshot>
        <screeninfo>String Replacer</screeninfo>
        <mediaobjectco>
            <imageobjectco>
                <areaspec units="calspair">
                    <area id="pt-stringreplacer-1" coords="1 1"/>
                    <area id="pt-stringreplacer-2" coords="1 1"/>
                    <area id="pt-stringreplacer-3" coords="1 1"/>
                    <area id="pt-stringreplacer-4" coords="1 1"/>
                    <area id="pt-stringreplacer-5" coords="1 1"/>
                    <area id="pt-stringreplacer-6" coords="1 1"/>
                    <area id="pt-stringreplacer-7" coords="1 1"/>
                    <area id="pt-stringreplacer-8" coords="1 1"/>
                    <area id="pt-stringreplacer-9" coords="1 1"/>
                </areaspec>
                <imageobject>
                    <imagedata fileref="stringreplacer.png" format="PNG"/>
                </imageobject>
            </imageobjectco>
            <textobject>
                <phrase>String Replacer</phrase>
            </textobject>
        </mediaobjectco>
    </screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-stringreplacer-1"><para>Enter a name for your filter.  Use any
name you like that distinquishes it from all other filters.</para></callout>
<callout arearefs="pt-stringreplacer-2"><para>This is the list of words
and regular expressions.  The filter searches for matches on each string in
the <guilabel>Match</guilabel> column, replacing the matched string
with the string in the <guilabel>Replace With</guilabel> column.  The list
is processed in the order displayed, top to bottom.</para></callout>
<callout arearefs="pt-stringreplacer-3"><para>Click here to add another word or
regular expression to the list.</para></callout>
<callout arearefs="pt-stringreplacer-4"><para>Click here to move the currently
highlighted word or regular expression up or down in the list.</para></callout>
<callout arearefs="pt-stringreplacer-5"><para>Click to change an existing word
or regular expression in the list.</para></callout>
<callout arearefs="pt-stringreplacer-6"><para>Click to remove the currently
highlighted word or regular expression from the list.</para></callout>
<callout arearefs="pt-stringreplacer-7"><para>Use these buttons to load
a list of words or regular expression from a file, save the current list to
a file, or clear the entire list.  When loading from a file, the items in the
file are appended to the existing list.</para></callout>
<callout arearefs="pt-stringreplacer-8"><para>If not blank, the filter will
apply itself only if the job's talker language matches
the language you enter here.  Click the button to display a list of languages.
You may select more than one language by pressing
<keycap>&Ctrl;</keycap> while clicking.</para></callout>
<callout arearefs="pt-stringreplacer-9"><para>If not blank, the filter will
apply itself only if the text came from one of the applications listed.
You may enter more than one application separated by commas.
Example: <command><userinput>konversation,kmail</userinput></command></para>
<tip><para>You can discover the <guilabel>Application ID</guilabel>
of running programs using the <command>&kdcop;</command> program.
You should leave the &DCOP; numbers out.  For example, if &kdcop; shows
an Application ID of <command>kopete-3432</command>, you would just
enter <command><userinput>kopete</userinput></command>.</para></tip></callout>
</calloutlist>
</para>

<para>The String Replacer filter will only apply itself to the text
if all non-blank conditions are met in the 
<guilabel>Apply This Filter When</guilabel> box.
if all the boxes are blank, the filter will apply to all text.</para>

<para>All matching is case insensitive.</para>

<para>When matching words, the String Replacer filter internally uses a
regular expression of the form <command>\s<userinput>word</userinput>\s</command>.
In other words, the word must have word boundaries (spaces) on either side of it.</para>

<para>A discussion on how to write regular expressions is outside the scope
of this handbook.  If you have the &kde; Regular Expression editor installed,
there is a button available on the <guilabel>Add</guilabel> or
<guilabel>Edit</guilabel> screens that will assist you at
constructing regular expressions.  The &kde; Regular Expression Editor is part
of the <command>tdeutils</command> package.</para>

<para>&ktts; comes with a few word list files, including a list
of emoticons, such as ":-)", some abbreviations typically used in IRC or
instant messaging applications, and a list of other abbreviations.
There is also a list of special characters which the current version
of the Polish Festival voice cannot handle.
If you develop useful word lists of your own, use the <guibutton>Save</guibutton>
button to save them to a file and send them to the
&ktts; team for inclusion in the next version.</para>

</sect2>

<!-- ...................................................................... -->

<sect2 id="xmltransformer">
<title>Configuring &XML; Transformer Filters</title>

<para>The &XML; Transformer filter uses XSLT files to transform &XML; from
one format to another.  XSLT, the &XML; Style Language - Transforms, is a W3C
standard language for performing such transformations.
It can only be used on well-formed &XML;.  You must have the
<command>xsltproc</command> utility installed.</para>

<para>
    <screenshot>
        <screeninfo>&XML; Transformer</screeninfo>
        <mediaobjectco>
            <imageobjectco>
                <areaspec units="calspair">
                    <area id="pt-xmltransformer-1" coords="1 1"/>
                    <area id="pt-xmltransformer-2" coords="1 1"/>
                    <area id="pt-xmltransformer-3" coords="1 1"/>
                    <area id="pt-xmltransformer-4" coords="1 1"/>
                    <area id="pt-xmltransformer-5" coords="1 1"/>
                </areaspec>
                <imageobject>
                    <imagedata fileref="xmltransformer.png" format="PNG"/>
                </imageobject>
            </imageobjectco>
            <textobject>
                <phrase>&XML; Transformer</phrase>
            </textobject>
        </mediaobjectco>
    </screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-xmltransformer-1"><para>Enter a name for your filter.  Use any
name you like that distinquishes it from all other filters.</para></callout>
<callout arearefs="pt-xmltransformer-2"><para>Enter the full path
to an existing XSLT file, which will perform the transformation.</para></callout>
<callout arearefs="pt-xmltransformer-3"><para>Specify the path to the
<command>xsltproc</command> utility.  If xsltproc is in your environment
PATH, simply enter <command><userinput>xsltproc</userinput></command>.</para></callout>
<callout arearefs="pt-xmltransformer-4"><para>If not blank, the filter
will apply itself only if the &XML; has the specified root element
or a <command><![CDATA[<!DOCTYPE]]></command> specification
beginning with the entered string. This distinquishes one
form of &XML; from another.  For example,
<command><userinput>html</userinput></command> in the
<guilabel>DOCTYPE</guilabel> box will match
<command><![CDATA[<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">]]></command>.
</para></callout>
<callout arearefs="pt-xmltransformer-5"><para>If not blank, the filter will
apply itself only if the text came from one of the applications listed.
You may enter more than one application separated by commas.
Example: <command><userinput>konversation,kmail</userinput></command></para>
<tip><para>You can discover the <guilabel>Application ID</guilabel>
of running programs using the <command>&kdcop;</command> program.
You should leave the &DCOP; numbers out.  For example, if &kdcop; shows
an Application ID of <command>kopete-3432</command>, you would just
enter <command><userinput>kopete</userinput></command>.</para></tip></callout>
</calloutlist>
</para>

<para>The &XML; Transformer filter will only apply itself to the text
if the specified root element or DOCTYPE are met and if the 
application ID is met in the 
<guilabel>Apply This Filter When</guilabel> box.  If an item in this
box is blank, the test is not performed, so if all the
boxes are blank, the filter will apply itself to all text.  However,
you should fill in at least one box, since many text jobs will not be in
&XML; format.</para>

</sect2>

<!-- ...................................................................... -->

<sect2 id="talkerchooser">
<title>Configuring Talker Chooser Filters</title>

<para>Talker Chooser filters are used to direct the text to a desired
talker configured in the <guilabel>Talker</guilabel> tab, or to any
talker having specified attributes.  For example,
you can specify that text coming from <command>kmail</command>
should be spoken using a talker configured with a female voice.
See <xref linkend="configure-plugin" />.</para>

<para>Just before &ktts; begins sending text to each of the
filters, it picks a talker to speak the text.  The talker chosen is
based on the talker attributes specified by the application that sent
the text to &ktts; and the attributes of the talkers that
you have configured on the <guilabel>Talkers</guilabel> tab.
The Talker Chooser filter permits you to override the
chosen talker.
</para>

<para>
    <screenshot>
        <screeninfo>Talker Chooser</screeninfo>
        <mediaobjectco>
            <imageobjectco>
                <areaspec units="calspair">
                    <area id="pt-talkerchooser-1" coords="1 1"/>
                    <area id="pt-talkerchooser-2" coords="1 1"/>
                    <area id="pt-talkerchooser-3" coords="1 1"/>
                    <area id="pt-talkerchooser-4" coords="1 1"/>
                    <area id="pt-talkerchooser-5" coords="1 1"/>
                </areaspec>
                <imageobject>
                    <imagedata fileref="talkerchooser.png" format="PNG"/>
                </imageobject>
            </imageobjectco>
            <textobject>
                <phrase>Talker Chooser</phrase>
            </textobject>
        </mediaobjectco>
    </screenshot>
</para>

<para>
<calloutlist>
<callout arearefs="pt-talkerchooser-1"><para>Enter a name for your filter.  Use any
name you like that distinquishes it from all other filters.</para></callout>
<callout arearefs="pt-talkerchooser-2"><para>If not blank, the filter will apply
itself only if the text contains the entered regular expression.  If it is installed,
click the browse button to launch the &kde; Regular Expression Editor to assist you at entering
the regular expression.</para>
<tip><para>For better performance, try to "anchor" the regular expression to the
start of the string.  In other words, start your regular expression with
<command><userinput><![CDATA[^]]></userinput></command>.</para></tip></callout>
<callout arearefs="pt-talkerchooser-3"><para>If not blank, the filter will
apply itself only if the text came from one of the applications listed.
You may enter more than one application separated by commas.
Example: <command><userinput>konversation,kmail</userinput></command></para>
<tip><para>You can discover the <guilabel>Application ID</guilabel>
of running programs using the <command>&kdcop;</command> program.
You should leave the &DCOP; numbers out.  For example, if &kdcop; shows
an Application ID of <command>kopete-3432</command>, you would just
enter <command><userinput>kopete</userinput></command>.</para></tip></callout>
<callout arearefs="pt-talkerchooser-4"><para>Specify the attributes of the
talker you prefer to speak the text here.  If the text meets the filter
conditions above, a talker will be chosen that most closely matches
the attributes you specify here.  Click the button at the right to
display the <guilabel>Select Talker</guilabel> screen.
See <xref linkend="selecttalker" />.</para></callout>
<callout arearefs="pt-talkerchooser-5"><para>Use these buttons
to save your Talker Chooser settings, load settings from a saved file,
or clear all the settings.</para></callout>
</calloutlist>
</para>

<para>The Talker Chooser filter will only apply itself to the text
if all non-blank conditions are met in the 
<guilabel>Apply This Filter When</guilabel> box.  You must fill in
at least one of the boxes.</para>

<para>The easiest way to learn how to configure Talker Choosers is
to experiment.  Disable the Talker Chooser and submit some text.
In the <guilabel>Jobs</guilabel> tab, note the talker that
&ktts; chooses.  Click the <guibutton>Change Talker</guibutton>
button, enter some attributes, and try again to see how the choice is affected.
Of course, you must have more than one talker configured for
the Talker Chooser to do anything.</para>

</sect2>

<!-- ...................................................................... -->

<sect2 id="sbd">
<title>Configuring Sentence Boundary Detector Filters</title>

<para>Sentence Boundary Detector (SBD) filters break text up into individual sentences.
This is important because it</para>

<itemizedlist>
<listitem><para>allows &ktts; to begin speaking faster
because it need only synthesize the first sentence, rather than the entire
block of text, which might be very long, and</para></listitem>
<listitem><para>allows you to rewind and advance by sentences in the
<guilabel>Jobs</guilabel> tab, and</para></listitem>
<listitem><para>allows you to pause or stop Text Jobs in the
<guilabel>Jobs</guilabel> tab even if the speech synthesizer is not
capable of being stopped.</para></listitem>
</itemizedlist>

<para>For these reasons, the Standard Sentence Boundary Detector filter
is automatically configured the first time you run <command>kttsmgr</command>
and cannot be disabled (although you can remove it).  We advise you
not to modify this filter unless you know what you are doing.</para>

<para>You can, however, add additional SBD filters to solve certain
problems.  For example, as of February 2005, the Polish Festival voice
has the annoying attribute of speaking sentence punctuation.  It will
speak the periods at the end of each sentence, for instance.  You cannot solve this problem
by creating a String Replacer filter to remove the sentence punctuation,
because doing so will prevent the Standard SBD from recognizing any
sentences.  Instead, you can create a modified version of the
Standard SBD that recognizes sentences while simultaneously removing
the sentence punctuation.  To do this, add an SBD filter and use the
<guibutton>Load</guibutton> button to load the <filename>polish_festival_sbdrc</filename>
file that comes with &ktts;.</para>

<para>SBD filters work by matching an end-of-sentence regular expression
and inserting Tab (decimal 8) characters at the sentence boundaries.
(All Tab characters are automatically stripped from text before filtering begins.)
Note that the Standard SBD preserves the sentence punctuation.
</para>

<para>SBD filters are never applied to &kde; Notification messages (knotify),
Warnings, Messages, or Screen Reader Outputs.</para>

<para>If you accidentally remove the Standard Sentence Boundary Detectory filter,
you can get it back by loading the <filename>standard_sbdrc</filename> file,
which comes with &ktts;.</para>

</sect2>

</sect1>

<!-- ...................................................................... -->

<sect1 id="selecttalker">
<title>Selecting Talkers (Advanced)</title>

<para>You can configure
any number of talkers in the <guilabel>Talkers</guilabel> tab.
See <xref linkend="configure-plugin" />.  When applications send text
to &ktts;, they may specify the attributes of a desired
talker to speak the text.  &ktts; will pick the closest
matching talker from among the talkers you have configured to satisfy
the application's request.  For example, an application might request
the text be spoken by an English female voice.  If you have configured
a talker with English language and female gender, that talker will be used.
If you have configured all English male talkers, one of those talkers
will be used.  If an application specifies no attributes,
the default (topmost) talker listed in the <guilabel>Talkers</guilabel>
tab is used.</para>

<para>When applications specify the attributes of the desired talker,
they may indicate that certain attributes are "preferred" over other
attributes.  For example, an application may specify that it wishes
that a female loud voice speak the text, and that the loud attribute is
"preferred" over the female attribute.  If you had a female soft talker
and a male loud talker configured, &ktts; will choose the male
loud talker to do the speaking.  Since language is a critical parameter
in making speech understandable, it is always a "preferred" attribute.</para>

<para>Using the <guilabel>Select Talker</guilabel> screen, you may
override application talker settings.  The screen is displayed</para>

<itemizedlist>
<listitem><para>when you click the <guibutton>Change Talker</guibutton>
button on the <guilabel>Jobs</guilabel> tab, or</para></listitem>
<listitem><para>when you click the <guilabel>Talker</guilabel> button
on the <guilabel>Filter Configuration</guilabel> dialog for
a Talker Chooser filter, or</para></listitem>
<listitem><para>when you click the <guilabel>Talker</guilabel> button
on the <guilabel>Notifications</guilabel> tab.</para></listitem>
</itemizedlist>

<para>
    <screenshot>
        <screeninfo>Select Talker</screeninfo>
        <mediaobjectco>
            <imageobjectco>
                <areaspec units="calspair">
                    <area id="pt-selecttalker-1" coords="1 1"/>
                    <area id="pt-selecttalker-2" coords="1 1"/>
                    <area id="pt-selecttalker-3" coords="1 1"/>
                    <area id="pt-selecttalker-4" coords="1 1"/>
                    <area id="pt-selecttalker-5" coords="1 1"/>
                </areaspec>
                <imageobject>
                    <imagedata fileref="selecttalker.png" format="PNG"/>
                </imageobject>
            </imageobjectco>
            <textobject>
                <phrase>Select Talker</phrase>
            </textobject>
        </mediaobjectco>
    </screenshot>
</para>

<para>The screen offers three methods to specify desired talker
attributes:</para>

<itemizedlist>
<listitem><para>Use the default talker (topmost in the
<guilabel>Talkers</guilabel> tab).  In other words, no talker attributes
are specified.</para></listitem>
<listitem><para>Use the closest matching talker having one or more specified attributes.</para></listitem>
<listitem><para>Use the closest matching talker having all the attributes
of a configured talker.  If you don't delete or modify the talker's settings,
&ktts; will pick that specific talker.  If you delete or modify the
talker's settings, then &ktts; will pick the closest matching talker
having the talker's original attributes.</para></listitem>
</itemizedlist>

<para>
<calloutlist>
<callout arearefs="pt-selecttalker-1"><para>Choose the method for entering
the desired talker attributes by clicking one of these radio buttons.</para></callout>
<callout arearefs="pt-selecttalker-2"><para>Choose the attributes of the desired
talker here.  Leave an attribute blank if you do not care about that attribute.</para></callout>
<callout arearefs="pt-selecttalker-3"><para>Check this box if you wish the
attribute to be "preferred" over other attributes.  You may check more than one
box.</para></callout>
<callout arearefs="pt-selecttalker-4"><para>Since language is a critical factor
in making speech understandable, it is always a preferred attribute.  It is rare
that you will use this attribute.  The only time you might specify the language
attribute is when you know a specific application sends text in a language
different from your desktop.</para></callout>
<callout arearefs="pt-selecttalker-5"><para>This is a list of the talkers
you currently have configured in &ktts;.  By choosing one of these,
in effect, you are specifying all the attributes of that talker.  If that
talker is still configured when text is sent, you'll get an exact match and that
talker will be chosen.  However, if you later delete the talker, or modify
its settings, it might not be the chosen talker anymore.  The talker
most closely matching the original attributes will be chosen.</para></callout>
</calloutlist>
</para>

<para>The <guilabel>Language</guilabel> attribute is special because
text will probably be unintelligible if spoken by a talker that
speaks a language different from the text.  Therefore, language
is automatically a "preferred" attribute. If you specify a language,
it will override the chosen language, but if you leave it blank,
the existing language setting will be used.  If the application that sent the
text to &ktts; did not specify a language, &ktts; assigns
the language of the topmost talker you have configured in the
<guilabel>Talkers</guilabel> tab.  In other words, the topmost
talker is assumed to speak the language of your desktop.</para>

<tip><para>To clear all the attributes in the
<guilabel>Use closest matching Talker having</guilabel> section,
first click the <guilabel>Use default Talker</guilabel> radio button,
then click the <guilabel>Use closest matching Talker having</guilabel>
radio button.</para></tip>

</sect1>

</chapter>

<!-- ====================================================================== -->

<chapter id="commands">
<title>Command Reference</title>

<!-- (OPTIONAL, BUT RECOMMENDED) This chapter should list all of the
application windows and their menubar and toolbar commands for easy reference.
Also include any keys that have a special function but have no equivalent in the
menus or toolbars. This may not be necessary for small apps or apps with no tool
or menu bars. -->

<para>TODO</para>

</chapter>

<!--

<sect1 id="kapp-mainwindow">
<title>The main &ktts; window</title>

<sect2>
<title>The File Menu</title>
<para>
<variablelist>
<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;<keycap>N</keycap></keycombo>
</shortcut>
<guimenu>File</guimenu>
<guimenuitem>New</guimenuitem>
</menuchoice></term>
<listitem><para><action>Creates a new document</action></para></listitem>
</varlistentry>
<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;<keycap>S</keycap></keycombo>
</shortcut>
<guimenu>File</guimenu>
<guimenuitem>Save</guimenuitem>
</menuchoice></term>
<listitem><para><action>Saves the document</action></para></listitem>
</varlistentry>
<varlistentry>
<term><menuchoice>
<shortcut>
<keycombo action="simul">&Ctrl;<keycap>Q</keycap></keycombo>
</shortcut>
<guimenu>File</guimenu>
<guimenuitem>Quit</guimenuitem>
</menuchoice></term>
<listitem><para><action>Quits</action> &ktts;</para></listitem>
</varlistentry>
</variablelist>
</para>

</sect2>

-->

<!-- ====================================================================== -->

<chapter id="developers">
<title>Developer's Guide to &ktts;</title>

<para>&ktts; has two Application Programmer Interfaces (APIs):
</para>

<itemizedlist>
<listitem><para>The &kde; Text-to-Speech API, which is used by application
programmers to give their applications TTS capabilities.  Applications
communicate with KTTSD via &DCOP;.</para></listitem>
<listitem><para>The KTTSD Plugin API, which is used to add speech
synthesis plugins to KTTSD so that &ktts; will work with
a new speech synthesis engine.</para></listitem>
</itemizedlist>

<para>The following section gives a short description of the &kde; Text-to-Speech API
&DCOP; Interface.
Full documentation for both APIs is available online at the
<ulink url="http://accessibility.kde.org/developer/kttsd/">
&kde; Accessibility</ulink> web site (http://accessibility.kde.org).
</para>


<!-- ...................................................................... -->


<sect1 id="dcop-interface">
<title>The &ktts; &DCOP; Interface</title>

<para>Applications communicate requests for Text-to-Speech services via the
&kde; &DCOP; interface to program <command>kttsd</command> object <command>KSpeech</command>.
</para>

<para>Enter the following commands in a &konsole;.</para>

<para>If KTTSD is not already running</para>

<para><userinput>kttsd</userinput></para>

<para>To queue a text job to be spoken</para>

<para><userinput>dcop kttsd KSpeech setText "<replaceable>text</replaceable>"  "<replaceable>talker</replaceable>"</userinput></para>

<para>where <userinput><replaceable>text</replaceable></userinput> is the text to be spoken, and <userinput><replaceable>talker</replaceable></userinput> is a language code
such as <userinput><replaceable>en</replaceable></userinput>, <userinput><replaceable>cy</replaceable></userinput>, &etc;  This command does
not speak the text; instead it queues a text job for speaking.</para>

<para>Example.</para>

<para><userinput>dcop kttsd KSpeech setText "This is a test." "en"</userinput></para>

<para>To speak the last queued text job</para>

<para><userinput>dcop kttsd KSpeech startText <replaceable>0</replaceable></userinput></para>

<para>In this case, <userinput>0</userinput> refers to the last text job queued.  
You may also specify a specific job number.  (If no job number is given, a <userinput>0</userinput> is required.)</para>

<para>To stop the currently speaking text job</para>

<para><userinput>dcop kttsd KSpeech stopText 0</userinput></para>

<para>Depending upon the speech plugin used, speaking may not immediately stop.</para>

<para>There are many more commands that can be sent.  To see a list of possible
commands,</para>

<para><userinput>dcop kttsd KSpeech</userinput></para>

<para>or read the 
<ulink url="http://accessibility.kde.org/developer/kttsd/">
&kde; Text-to-Speech API</ulink> online.</para>

</sect1>

</chapter>

<!-- ====================================================================== -->

<chapter id="faq">
<title>Questions and Answers</title>

<!-- (OPTIONAL but recommended) This chapter should include all of the silly
(and not-so-silly) newbie questions that fill up your mailbox. This chapter
should be reserved for BRIEF questions and answers! If one question uses more
than a page or so then it should probably be part of the
"Using this Application" chapter instead. You should use links to
cross-reference questions to the parts of your documentation that answer them.
This is also a great place to provide pointers to other FAQ's if your users
must do some complicated configuration on other programs in order for your
application work. -->

&reporting.bugs;
&updating.documentation;

<qandaset id="faqlist">
<qandaentry>
<question>
<para><command>kttsmgr</command> immediately crashes when I start it.  I
compiled with debug support and I don't even get a backtrace.</para>
</question>
<answer>
<para>GStreamer has crashed taking &ktts; down with it.  You most
likely need to "register" GStreamer.  For GStreamer 0.8x, the command is
<command>gst-register-0.8</command>.  If this doesn't solve the problem,
you may have an incompatible version of GStreamer installed.  You could
try upgrading or uninstalling GStreamer.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>ALSA audio output is not working if I am playing music in another
application at the same time.  When I pause a text job, &ktts;
freezes.  I notice "unable to open PCM" in the &konsole; output.</para>
</question>
<answer>
<para>You have the ALSA device contention problem, which prevents opening
more than one PCM device at one time.  See the ALSA website (dmix) for
possible solutions. <ulink url="www.alsa-project.org">www.alsa-project.org</ulink>
</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>I need to start over.  How do I get &ktts; completely terminated?</para>
</question>
<answer>
<para>Enter the following commands in a &konsole;:
<programlisting>
killall kttsd
killall kttsmgr
</programlisting>
</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>How can I see debugging output from <command>kttsd</command>?</para>
</question>
<answer>
<para>Open two &konsole; windows.  First start <command>kttsd</command> in one
window, then start <command>kttsmgr</command> in the second.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>I have an additional Festival voice I downloaded from the Internet.
I installed it, and I can use it in Festival, but it does not show up in <command>kttsmgr</command>.</para>
</question>
<answer>
<para>Edit file <command>$KDEHOME/share/apps/kttsd/festivalint/voices</command> to
add the new voice.  The other entries can be used as a guide.  If you
successfully add a voice, please send a patch to the developers along
with the &URL; from which you obtained the voice file.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>None of the supported speech synthesizers support the language I need.
Where can I get a synth for my language?</para>
</question>
<answer>
<para>Google(tm) is your friend.  This 
<ulink url="http://tcts.fpms.ac.be/synthesis/mbrola/mbrtts.html">link</ulink>
might also help.  If you find a free synthesis engine that supports your
desired language, and want to add support for it to &ktts;, please
contact the development team.  Open source engines are especially welcome.
If you know of a commercial synth, perhaps you can pursuade the vendor
to donate a free copy to the &ktts; development team.
In the meantime, you may be able to get
the synth working using the <guilabel>Command</guilabel> plugin.
See <xref linkend="using-with-command" />.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>&ktts; is speaking too slow.  How can I speed it up?</para>
</question>
<answer>
<para>There is a <guilabel>Speed</guilabel> setting on the <guilabel>Audio</guilabel>
tab.  For this to work, you must have the <command>sox</command> utility
installed and available in the PATH.  Some synthesis plugins, such as
Festival Interactive also provide a <guilabel>Speed</guilabel>
setting in the talker configuration dialog.  Depending upon the
voice used, it may or may not be enabled.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>OK, that works for some things, but web pages are still spoken too slow.</para>
</question>
<answer>
<para>The speed settings are ignored when &ktts; is speaking
&HTML;.  (This is because the &HTML; is converted into SSML, which has its own
"rate" tags.)  Either disable the &HTML; &XML; Transformer filter
(see <xref linkend="filters"/>), or if you are brave, edit the .xsl file
in the &HTML; to SSML Transformer filter and increase the default talking rate.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>I cannot get web pages to speak in a female voice.  I have female Festival talker
configured, but &ktts; always speaks web pages in a male voice.</para>
</question>
<answer>
<para>As of Festival 1.95 beta, the SABLE GENDER tag doesn't seem to be working.
To keep Festival from producing errors, the SSML to SABLE .xsl file strips the
gender tags out.  The same applies to voice tags as well.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>I have the &HTML; &XML; Transformer filter configured, but web pages are not spoken at
all using the Festival plugin.</para>
</question>
<answer>
<para>Due to a bug in Festival 1.95 beta, you must install the
<command>rab_diphone</command> (British male) voice for SABLE to work at all, even
if you are not using that voice to speak the web pages.  Also,
make sure the <command>xsltproc</command> utility is installed and in the PATH.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>Certain characters or punctuation seem to be producing errors in the synthesizer,
making it skip entire sentences, or pronounce gibberish.  What can I do?</para>
</question>
<answer>
<para>First, make sure the <guilabel>Character encoding</guilabel> option in the
talker's configuration dialog is properly set for the language.  If certain words
or characters are causing problems, a String Replacer filter might help.
If certain sentence punctuation characters are confusing the synth, you'll need to
configure a Sentence Boundary Detector filter.  See <xref linkend="filters" />.</para>
</answer>
</qandaentry>
<qandaentry>
<question>
<para>I added a String Replacer filter of my own and now &ktts;
will not allow me to rewind or advance by sentence.  On the <guilabel>Jobs</guilabel>
tab, it claims each job has only one sentence.  What did I do wrong?</para>
</question>
<answer>
<para>You must not filter out sentence punctuation characters (period, question mark,
exclamation mark, colon, and semicolon).
For these characters, use a Sentence Boundary Detector filter instead.</para>
</answer>
</qandaentry>
</qandaset>
</chapter>

<!-- ====================================================================== -->

<chapter id="credits">

<!-- Include credits for the programmers, documentation writers, and
contributors here. The license for your software should then be included below
the credits with a reference to the appropriate license file included in the KDE
distribution. -->

<title>Credits and License</title>

<para>
&ktts;
</para>
<para>
Program Copyright &copy; 2002 Jos&#233; Pablo Ezequiel "Pupeno" Fern&#225;ndez <email>pupeno@kde.org</email> 
</para>
<para>
Current Maintainer: Gary Cramblitt <email>garycramblitt@comcast.net</email>
</para>
<para>
Contributors:
<itemizedlist>
<listitem><para>Olaf Schmidt <email>ojschmidt@kde.org</email></para>
</listitem>
<listitem><para>Gunnar Schmi Dt <email>gunnar@schmi-dt.de</email></para>
</listitem>
<listitem><para>Paul Giannaros <email>ceruleanblaze@gmail.com</email></para>
</listitem>
</itemizedlist>
</para>

<para>
Documentation Copyright &copy; 2004 Gary R. Cramblitt <email>garycramblitt@comcast.net</email>
</para>

<!-- TRANS:CREDIT_FOR_TRANSLATORS -->

&underFDL;               <!-- FDL: do not remove -->

<!-- Determine which license your application is licensed under, 
     and delete all the remaining licenses below:

     (NOTE:  All documentation are licensed under the FDL, 
     regardless of what license the application uses) -->

&underGPL;        	 <!-- GPL License -->

<note><para>Speech synthesis engines used by &ktts; have their own
licenses.  See each engine's documentation or website for details.
Some voices also have their own licensing.</para></note>

</chapter>

<!-- ====================================================================== -->

<appendix id="installation">
<title>Installation</title>

<!-- ...................................................................... -->


<sect1 id="getting-kapp">
<title>How to obtain &ktts;</title>

<!-- This first entity contains boiler plate for applications that are
part of KDE CVS.  You should remove it if you are releasing your
application --> 

<para>
&install.intro.documentation;
</para>

<para>(FUTURE) Debian Install Command: <command>apt-get install tdeaccessibility</command></para>

<note>
<para>You will find links to source and binary packages
on the <ulink url="http://accessibility.kde.org/developer/kttsd/">
&kde; Accessibility</ulink> web site (http://accessibility.kde.org).</para>

<para>If you have access to the &kde; code repository, you can download &ktts;
by checking out the <command>tdeaccessibility</command> module.  &ktts;
will be found in the <command>kttsd</command> folder.  You can also
download tarballs of the tdeaccessibility source code from
<ulink url="ftp://ftp.kde.org/pub/kde/">
ftp://ftp.kde.org/pub/kde/</ulink></para>
</note>

</sect1>

<!-- ...................................................................... -->


<sect1 id="requirements">
<title>Requirements</title>

<para>Mandatory requirements:</para>

<para>
<itemizedlist>
<listitem><para>&kde; version 3.2 or later.</para></listitem>
<listitem><para>A speech synthesis engine.  The following engines
and spoken languages are currently supported.</para>

<para>
<informaltable id="synth-engines">
<tgroup cols="2">
<tbody>

<row>
<entry>Festival</entry>
<entry>American English, British, Spanish, German, Finnish, Czech, Polish, Russian,
Italian, French Canadian, Kiswahili, Zulu, and Ibibio</entry>
</row>

<row>
<entry>Festival Lite (flite)</entry>
<entry>English</entry>
</row>

<row>
<entry>Hadifix (&mbrola; and txt2pho)</entry>
<entry>German, Hungarian</entry>
</row>

<row>
<entry>Epos</entry>
<entry>Czech, Slovak</entry>
</row>

<row>
<entry>FreeTTS</entry>
<entry>English</entry>
</row>

</tbody>
</tgroup>
</informaltable>
</para>

<para>It also works with any synthesis engine that can be run from a command in
a &konsole;.</para>

<note><para>
The languages listed above may not be comprehensive or up-to-date.
Check the specifications for each engine for a complete list of supported
languages.  Also check the
<ulink url="http://accessibility.kde.org/developer/kttsd/index.php">
&ktts;</ulink> website for additional
information that might not have made it into this handbook.
</para></note>

<note>
<para>&ktts; uses a flexible plugin architecture for
speech synthesis engines.  If you
want to enhance &ktts; to support another engine, contact the
development team.
</para>
</note>

<para>
See <xref linkend="configuration" /> for specific instructions for each
of these engines.
</para>

</listitem>

<listitem>
<para>At least one of the following audio subsystems:

<itemizedlist>
<listitem><para>&kde; &arts; Soundsystem.  &arts; is usually installed with &kde;.</para></listitem>
<listitem><para>ALSA (Advanced &Linux; Sound Architecture).  ALSA is installed with
most &Linux; systems.  (<ulink url="www.alsa-project.org">www.alsa-project.org</ulink>)</para></listitem>
<listitem><para>GStreamer version 0.8.7 or greater.  <emphasis>Note</emphasis>:
Be sure to register your GStreamer plugins by running the <command>gst-register</command> 
command prior to using GStreamer in &ktts;.  
(<ulink url="http://gstreamer.freedesktop.org">
http://gstreamer.freedesktop.org</ulink>)</para></listitem>
<listitem><para>aKode library.  aKode is a decoder library that is part of &kde;.
</para></listitem>
</itemizedlist>

<note><para>The &kde; project plans to drop &arts; starting in version 4.</para></note>

<note><para>Some users experience device contention with ALSA.  If your system
has this problem, you will not be able to simultaneously play music while speaking.
&ktts; will also freeze if you pause a text job and then
start another.  See the ALSA website (dmix) for possible solutions.</para></note>

<note><para>As of July 2005, aKode does not support a true pause capability.
When you pause a text job in &ktts; it will finish speaking the
current sentence.</para></note>

</para>
</listitem>

</itemizedlist>
</para>

<para>Optional components:</para>

<para>
<itemizedlist>

<listitem>
<para>The <command>sox</command> audio utility is needed for
adjusting overall speech speed, but not required.  Debian users can install
sox with the command <command>apt-get install sox</command>.
Sox is included on most &Linux; distribution CDs.</para>
</listitem>

<listitem>
<para>The <command>xsltproc</command> utility is needed for
SSML support and for the &XML; Transformer filter, but not required.  Debian users can install
xsltproc with the command <command>apt-get install xsltproc</command>.</para>
</listitem>

</itemizedlist>
</para>

</sect1>

<!-- ...................................................................... -->


<sect1 id="compilation">
<title>Compilation and Installation</title>

<!-- This entity contains the boilerplate text for standard -->
<!-- compilation instructions.  If your application requires any -->
<!-- special handling, remove it, and replace with your own text. -->

<!-- &install.compile.documentation; -->

<para>In order to compile &ktts;, you must have a
recent (&kde; 3.4 or greater) copy of the &kde; development files,
including tdelibs and arts.</para>

<para>If you downloaded &ktts; as a tarball, log in
as a normal user and untar the tarball to a suitable folder, 
change to that folder, and enter the following commands.</para>

<programlisting>
./configure
make
</programlisting>

<para>The following <command>configure</command> options are available:</para>

<para>
<informaltable id="configure-audio-options">
<tgroup cols="3">
<tbody>

<row>
<entry><emphasis>Default Option</emphasis></entry>
<entry><emphasis>Description</emphasis></entry>
<entry><emphasis>Alternate</emphasis></entry>
</row>
<row>
<entry>--with-arts</entry>
<entry>Builds the arts audio plugin.</entry>
<entry>--without-arts</entry>
</row>
<row>
<entry>--with-alsa=check</entry>
<entry>Builds the ALSA audio plugin.</entry>
<entry>--with-alsa=no</entry>
</row>
<row>
<entry>--with-gstreamer=no</entry>
<entry>Does not build the GStreamer audio plugin.</entry>
<entry>--with-gstreamer=check</entry>
</row>
<row>
<entry>--with-akode=no</entry>
<entry>Does not build the aKode audio plugin.</entry>
<entry>--with-akode=check</entry>
</row>
</tbody>
</tgroup>
</informaltable>
</para>

<note><para>
In &kde; 4, the &arts; plugin will likely be removed or at least not built by default.
</para></note>

<para>The following speech synthesizer plugins are all built by default.
Some of them are runtime only dependent upon non-free software.
(Non-free according to Debian Policy). The "Configure Option to
not build" column shows the configure command to not build the plugin:</para>

<para>
<informaltable id="configure-synth-options">
<tgroup cols="3">
<tbody>

<row>
<entry><emphasis>Synth</emphasis></entry>
<entry><emphasis>License</emphasis></entry>
<entry><emphasis>Configure Option to not build</emphasis></entry>
</row>
<row><entry>Festival</entry><entry>free</entry><entry>--disable-kttsd-festivalint</entry></row>
<row><entry>Festival Lite</entry><entry>free</entry><entry>--disable-kttsd-flite</entry></row>
<row><entry>Epos</entry><entry>free</entry><entry>--disable-kttsd-epos</entry></row>
<row><entry>Command</entry><entry>free</entry><entry>--disable-kttsd-command</entry></row>
<row><entry>Hadifix</entry><entry>non-free</entry><entry>--disable-kttsd-hadifix</entry></row>
<row><entry>FreeTTS</entry><entry>non-free</entry><entry>--disable-kttsd-freetts</entry></row>
</tbody></tgroup></informaltable></para>

<para>By default, the commands above will install &ktts; to
<filename>/opt/trinity</filename>.  If this folder is not in your
$<envar>KDEDIRS</envar> path, you may need to add a
<userinput>--prefix=<replaceable>target</replaceable></userinput> option.
For example,</para>

<programlisting>
./configure --prefix=/usr/local
make
</programlisting>

<note><para>On Debian systems, <filename><replaceable>/usr/local</replaceable></filename>
is the usual place to install applications compiled from source code.
</para></note>

<para>Login as root and install the compiled &ktts;
using the following commands.</para>

<programlisting>
su
make install
</programlisting>

<para>If you downloaded the &ktts; source from the
<filename>tdeaccessibility</filename> code repository module, or downloaded the nightly
tarball, use the following commands to compile and install.
</para>

<programlisting>
cd tdeaccessibility
echo kttsd>inst-apps
make -f Makefile.cvs
./configure
cd kttsd
make
su
make install
</programlisting>

</sect1>

<!-- ...................................................................... -->


<sect1 id="configuration">
<title>Configuration</title>

<para>Make sure your speech synthesis engine is working before using
&ktts;.  Follow the instructions that came with the engine.</para>

<tip>
<para>In some cases, you may need to grant write access to the audio device.</para>
<para><userinput>chmod a+rw <replaceable>/dev/dsp*</replaceable></userinput></para>
</tip>

<!-- ...................................................................... -->


<sect2 id="using-with-festival">
<title>Using with Festival (Interactive)</title>

<para>Festival is one of the best free and open source TTS
engines available.  Voice quality is generally good and there are quite
a few languages and voices supported.
For many voices, you can control the volume, 
speed of the generated speech, and pitch (tone) from &ktts;.</para>

<para>Synthesizer Name: <guilabel>Festival Interactive</guilabel></para>

<para>&URL;: <ulink url="http://www.cstr.ed.ac.uk/projects/festival/">
http://www.cstr.ed.ac.uk/projects/festival/</ulink>
</para>

<para>Debian Install Command: <userinput>apt-get install festival</userinput></para>

<para>
You will need to install at least one language.  Follow the instructions
that come with Festival.  If you will be speaking web pages,
you must install the <command>rab_diphone</command> (British Male)
voice.
</para>

<para>Additional English festival voices are available from</para>

<para><ulink url="http://hts.ics.nitech.ac.jp/">http://hts.ics.nitech.ac.jp/</ulink>.
</para>

<para>Additional Spanish, English, and German voices are available from</para>

<para><ulink url="http://cslu.cse.ogi.edu/tts/download/">
http://cslu.cse.ogi.edu/tts/download/</ulink></para>

<para>You must compile an additional module
for these voices, therefore, you must have the Festival source code.
The German voices have limited distribution.
</para>

<para>A Finnish male voice is available from </para>

<para><ulink url="http://www.ling.helsinki.fi/suopuhe/download/">
http://www.ling.helsinki.fi/suopuhe/download/</ulink>.
</para>

<para>A Polish male voice is available from </para>

<para><ulink url="http://www.artegence.com/download/voicexml/speech/festival_polish_voice.tgz">
http://www.artegence.com/download/voicexml/speech/festival_polish_voice.tgz</ulink>.
</para>

<para>A Russian male voice is available from </para>

<para><ulink url="http://nshmyrev.narod.ru/festival/festival.html">
http://nshmyrev.narod.ru/festival/festival.html
</ulink></para>

<para>You must have Festival 1.95 beta or later to use this voice.  The voice
is still in early development.  Untar to
<filename>festival/lib/voices/russian/</filename>.  When you configure the Russian
talker, the voice code is <userinput>msu_ru_nsh_diphone</userinput>.  Be sure to
select an 8-bit cryllic encoding, such as <userinput>KOI8-R</userinput>.</para>

<para>Italian voices for Festival 1.95 beta are available at</para>

<para><ulink url="http://www.csrf.pd.cnr.it/TTS/It-FESTIVAL-download.htm">
http://www.csrf.pd.cnr.it/TTS/It-FESTIVAL-download.htm</ulink>.</para>

<para>If you get CRC errors when you unzip, try downloading again.</para>

<para>Kiswahili, Zulu, and Ibibio voices for Festival 1.95 beta are available at</para>

<para><ulink url="http://www.llsti.org/">http://www.llsti.org/</ulink>.</para>

<para>Unfortunately, the Hindi voice also available there will not work with
&ktts;.</para>

<para>Commercial voices, including a French Canadian voice,
can be purchased from Cepstral, LLC at</para>

<para><ulink url="http://www.cepstral.com/">http://www.cepstral.com/</ulink></para>

<para>The FAQ on their Support page has information about using their voices
in Festival.</para>

<para>Festival is typically included with &Linux; distributions.  Check your
distro CDs to see if it is included.</para>

<note>
<para>When using the Polish, Hungarian, or Czech languages, be sure the <guilabel>Encoding</guilabel>
option is set to <userinput>ISO 8859-2</userinput>.
</para>
<para>When using the Russian voice, be sure the <guilabel>Encoding</guilabel>
option is set to an 8-bit cryllic encoding, such as <userinput>KOI8-R</userinput>.
</para>
</note>

<!-- ...................................................................... -->


<sect3 id="festival-with-mbrola">
<title>Using Festival with &mbrola;</title>

<para>Festival can be used in combination with the &mbrola; synthesizer.
In this mode, Festival does the lexical analysis and &mbrola; produces the
audio.  The &mbrola; binary and &mbrola; voice files can be downloaded from</para>

<para><ulink url="http://festvox.org/mbrola/">http://festvox.org/mbrola/</ulink>.</para>

<para>Follow the instructions in the <filename>readme.txt</filename> that comes with
the download.</para>

<para>Note that &mbrola; is not a complete Text-to-Speech system.  &mbrola; synthesizes
speech from diphone files.  You must have additional software that can produce
the diphones.  When combined with Festival, Festival produces the diphones needed
by &mbrola;.  <command>txt2pho</command> can also be used to produce diphones
from German text.  See <xref linkend="using-with-hadifix"/> for more information.</para>

<para>There are three methods of combining Festival with &mbrola;.</para>

<para>
<itemizedlist>
<listitem><para><link linkend="mbrola-wrappers">&mbrola; Wrappers</link>.
At the time of writing this Handbook,
this method is limited to English voices.</para></listitem>
<listitem><para><link linkend="ims-german-festival">IMS German Festival</link>.</para></listitem>
<listitem><para><link linkend="festival-czech">Festival-Czech</link>.</para></listitem>
</itemizedlist>
</para>

<!-- ...................................................................... -->

<sect4 id="mbrola-wrappers">
<title>Using Festival with &mbrola; Wrappers</title>

<para>In this method, additional
wrapper code is added to Festival to enable speech synthesis using
&mbrola; voice files.  Note that the &mbrola; voice files are <emphasis>not</emphasis>
installed in the &mbrola; folder tree.  Instead, they are installed
in the <filename>festival/lib/</filename> folder tree.  For instructions, see</para>

<para><ulink url="http://www.cstr.ed.ac.uk/projects/festival/mbrola.html">
http://www.cstr.ed.ac.uk/projects/festival/mbrola.html</ulink></para>

</sect4>

<!-- ...................................................................... -->

<sect4 id="ims-german-festival">
<title>Using IMS German Festival</title>

<para>IMS German Festival is a modified version of Festival that uses German &mbrola;
voices.  It works with either Festival version 1.4.1 or Festival 2.0 (1.95beta).
First install Festival and &mbrola;, if you have not already done so.
Next, download IMS German Festival, from</para>

<para>
<ulink url="http://www.ims.uni-stuttgart.de/phonetik/synthesis/festival_opensource.html">
http://www.ims.uni-stuttgart.de/phonetik/synthesis/festival_opensource.html</ulink>.</para>

<para>Follow the instructions in the <filename>README</filename> that comes with the
download.  (Note, if using in combination with Festival 2.0, it is <emphasis>not</emphasis>
necessary to apply the <filename>fixes</filename> tarball, but you must still
rebuild festival.)  Finally, add the following
lines to the <filename>festival/lib/siteinit.scm</filename> file.</para>

<para>
<programlisting>
(voice-location "german_de1_os" "/usr/local/mbrola/de1"
  "German Female, IMS Festival de1")
(voice-location "german_de2_os" "/usr/local/mbrola/de2"
  "German Male, IMS Festival de2")
(voice-location "german_de3_os" "/usr/local/mbrola/de3"
  "German Female, IMS Festival de3")
</programlisting>
</para>

<para>just above the line that reads</para>

<para>
<programlisting>
(provide 'siteinit)
</programlisting>
</para>

<para>On some systems, the file you edit is <filename>/etc/festival.scm</filename>.  
Only add the lines that correspond to the German voices you have installed.
Substitute the correct path for 
<userinput><replaceable>/usr/local/mbrola/</replaceable></userinput>.
Also note that (at the time of this writing) 
IMS German Festival does not work with the de4, de5, or de6 German voices.</para>

</sect4>

<!-- ...................................................................... -->

<sect4 id="festival-czech">
<title>Using Festival-Czech</title>

<para>This method uses some special code to enable speech synthesis
using Festival with an &mbrola; Czech voice.  To install, first download and 
install Festival and &mbrola;, and make sure both are working.  Next, download
Festival-Czech from</para>

<para><ulink url="http://www.freebsoft.org/festival-czech">
http://www.freebsoft.org/festival-czech</ulink></para>

<note><para>In the following procedures substitute the correct folder
paths as needed.</para></note>

<para>Untar the download to a suitable folder and make
the lexicon.  The Festival executable must be in your <envar>PATH</envar>.
</para>

<para>
<programlisting>
cd /usr/local
tar xvfz festival-czech.tar.gz
cd festival-czech
make
</programlisting>
</para>

<para>Download the <filename>cz2</filename> voice file from the &mbrola;
website, and unzip it in the &mbrola; folder.</para>

<para>
<programlisting>
cd /usr/local/mbrola
mkdir cz2
cd cz2
unzip cz2-001009.zip
</programlisting>
</para>

<para>Add the following lines to the <filename>festival/lib/siteinit.scm</filename> file.</para>

<para>
<programlisting>
(set! czech-lexicon-file "/usr/local/festival-czech/czech-lexicon.out")
(set! load-path (cons "/usr/local/festival-czech" load-path))
(require 'czech)
(set! czech-mbrola_database "/usr/local/mbrola/cz2/cz2")
(set! mbrola_progname "/usr/local/mbrola/mbrola")
(voice-location "czech_mbrola_cz2" "/usr/local/mbrola/cz2"
    "Czech Male, MBROLA")
(require 'czech-mbrola)
</programlisting>
</para>

<para>just above the line that reads</para>

<para>
<programlisting>
(provide 'siteinit)
</programlisting>
</para>

<para>On some systems, the file you edit is <filename>/etc/festival.scm</filename>.</para>

</sect4>

</sect3>

</sect2>

<!-- ...................................................................... -->

<sect2 id="using-with-flite">
<title>Using with Festival Lite (flite)</title>

<para>Festival Lite is a free open source engine that currently supports
a limited number of voices and languages.  It is light weight, but
sacrifices voice quality somewhat.
You cannot control the pitch, volume, or speed of this engine
from &ktts;.</para>

<para>Synthesizer Name: <guilabel>Festival Lite (flite)</guilabel></para>

<para>&URL;: <ulink url="http://www.speech.cs.cmu.edu/flite/index.html">
http://www.speech.cs.cmu.edu/flite/index.html</ulink>
</para>

<para>Debian Install Command: <userinput>apt-get install flite</userinput></para>

<para>flite is typically included with &Linux; distributions.  Check your
distro CDs to see if it is included.</para>

<para>Build and install flite following the instructions in the
<filename>README</filename> that comes with it.</para>

</sect2>

<!-- ...................................................................... -->


<sect2 id="using-with-hadifix">
<title>Using with Hadifix (&mbrola; and txt2pho)</title>

<para>Hadifix is a two-stage synthesis engine based on diphones.
The <command>txt2pho</command> utility converts text into diphones
and the &mbrola; engine synthesizes the diphones to sound.
Voice quality is good, but language support is currently somewhat limited.
You can control the voice, pitch, speed, and volume from <application>kttsmgr</application>.
</para>

<para>Synthesizer Name: <guilabel>Hadifix</guilabel></para>

<para>&URL;: see below</para>

<para>Debian Install Command: none</para>

<para>If you do not already have Hadifix installed, do this:</para>

<procedure>
<step><para>Download &mbrola; binary from
<ulink url="http://festvox.org/mbrola/">http://festvox.org/mbrola/</ulink>.</para></step>
<step><para>Install &mbrola; to <filename>/usr/local/mbrola</filename> folder.</para></step>
<step><para>Download at least one german language file from the &mbrola; site.
Unzip to the <filename>/usr/local/mbrola</filename> folder.</para></step>
<step><para>Download txt2pho from</para>
<para>
<ulink url="http://www.ikp.uni-bonn.de/dt/forsch/phonetik/hadifix/HADIFIXforMBROLA.html">
http://www.ikp.uni-bonn.de/dt/forsch/phonetik/hadifix/HADIFIXforMBROLA.html</ulink>.</para>
</step>
<step><para>Unzip txt2pho to <filename>/usr/local/txt2pho</filename>.</para></step>
<step><para>Edit <command>txt2phorc</command> file, putting correct data paths in.</para></step>
<step><para>Either copy <command>txt2phorc</command> to <filename>~/.txt2phorc</filename> or to <filename>/etc/txt2pho</filename>.
Note that you drop the "rc" in file name.</para></step>
<step><para>In <application>kttsmgr</application>, choose the German language 
(<guilabel>de</guilabel>), and add <guilabel>Hadifix</guilabel>.</para></step>
<step><para>On the <guilabel>Configure Talker</guilabel> screen,
configure a voice and the paths to &mbrola; and txt2pho.</para></step>
<step><para>Click the <guibutton>Test</guibutton> button to test.</para></step>
</procedure>

<para>A Hungarian implementation for &mbrola; and txt2pho is available at</para>

<para>
<ulink url="http://tkltrans.sourceforge.net/">http://tkltrans.sourceforge.net/</ulink>.
</para>

</sect2>

<!-- ...................................................................... -->


<sect2 id="using-with-epos">
    <title>Using with Epos</title>

<para>Epos is a free Czeck and Slovak open source engine.
It is light weight, but sacrifices voice quality somewhat.
You cannot control the volume of this engine
from &ktts;.</para>

<para>Synthesizer Name: <guilabel>Epos TTS Synthesis System</guilabel></para>

<para>&URL;: <ulink url="http://epos.ure.cas.cz/">
http://epos.ure.cas.cz/</ulink>
</para>

<para>Debian Install Command: <userinput>apt-get install epos</userinput></para>

<para>Start <application>kttsmgr</application>.  On the <guilabel>Talkers</guilabel> tab,
click the <guibutton>Add</guibutton> button.  Choose Czeck or Slovak
language and <guilabel>Epos TTS Synthesis System</guilabel>.
If the epos server executable and client are not
in your <envar>PATH</envar>, specify the paths to these executables
in the <guilabel>Configure Talker</guilabel> screen.  The options boxes
permit you to pass additional options to the server and client.  In a 
&konsole;, type <userinput>epos -h</userinput> 
or <userinput>say -h</userinput> for information.</para>

</sect2>

<!-- ...................................................................... -->


<sect2 id="using-with-freetts">
    <title>Using with FreeTTS</title>

<para>FreeTTS is a free open source speech engine written in &Java;, which means
that you must have the &Java; Virtual Machine software installed on your
system to use it.  It currently has limited voice and language support.
You cannot control the pitch, volume, or speed of this engine
from &ktts;.</para>

<para>Synthesizer Name: <guilabel>FreeTTS</guilabel></para>

<para>&URL;: <ulink url="http://sourceforge.net/projects/freetts/">
http://sourceforge.net/projects/freetts/</ulink>
</para>

<para>Debian Install Command: none</para>

</sect2>

<!-- ...................................................................... -->


<sect2 id="using-with-command">
    <title>Using the Command Plugin</title>

<para>The command plugin permits you to use &ktts; with any
speech synthesis engine that can be run as a command in a 
&konsole;.</para>

<para>Synthesizer Name: <guilabel>Command</guilabel></para>

<para>&URL;: none</para>

<para>Debian Install Command: none</para>

<para>Ideally, you should use a command that synthesizes to a temporary audio
(wav) file, rather than send the speech directly to the audio device.</para>

<para>If the speech synthesis engine requires text to be encoded
differently from your desktop encoding setting, you must use the
<command>%f</command> parameter to pass the text to the engine.
&ktts; will encode the text in the setting you specify when
it writes the text to the temporary file.  If you attempt to pass text
on the command line using the <command>%t</command> parameter,
it will be encoded using your desktop locale setting.
You can also use the <guilabel>Send the data as standard input</guilabel>
option to solve this problem, if the engine accepts input from StdIn.
For example, here is a sample command to send polish text to Festival using
ISO 8859-2 encoding and removing unspeakable punctuation characters.</para>

<para><command>cat %f | tr '(){}[]"' ' ' | festival --tts --language polish</command>
</para>

</sect2>

<!-- ====================================================================== -->

</sect1>

</appendix>

&documentation.index;
</book>

<!--
Local Variables:
mode: xml
sgml-minimize-attributes:nil
sgml-general-insert-case:lower
sgml-indent-step:0
sgml-indent-data:nil
End:

vim:tabstop=2:shiftwidth=2:expandtab 
-->