| 1 | = Unicode Support in Trac = |
| 2 | [[TracGuideToc]] |
| 3 | |
| 4 | Trac stores all text using UTF-8 encoding, including text in tickets and wiki pages. Internal processing of text uses true Unicode representations. |
| 5 | |
| 6 | As such, it supports most (all?) commonly used character encodings. |
| 7 | |
| 8 | If the default encoding in your source code repository is not UTF-8, you can specify it in the [TracIni#trac-section trac.ini], for example: |
| 9 | {{{ |
| 10 | default_charset = gbk |
| 11 | }}} |
| 12 | |
| 13 | You also must make sure that your [trac:DatabaseBackend database backend] stores its data in UTF-8; otherwise strange things will happen. |
| 14 | |
| 15 | To convert your database to UTF-8, the easiest way is to dump the database, convert the dump into UTF-8 and then import the converted dump back into the database.[[BR]] |
| 16 | You can use [http://www.gnu.org/software/libiconv/documentation/libiconv/iconv.1.html iconv] to convert the dump. |
| 17 | |
| 18 | |
| 19 | == Examples == |
| 20 | |
| 21 | === Arabic === |
| 22 | تراك يقوم بحفظ كل الكلمات باستخدام صيغة UTF-8، بما في ذلك الكلمات المستخدمة في صفحات التيكت والويكي. |
| 23 | |
| 24 | === Bulgarian === |
| 25 | Българският език работи ли? |
| 26 | |
| 27 | === Česky === |
| 28 | Čeština v kódování UTF-8, žádný problém. |
| 29 | |
| 30 | === Chinese === |
| 31 | Traditional: 繁體中文, 漢字測試; Simplified: 简体中文,汉字测试 |
| 32 | |
| 33 | === Croatian === |
| 34 | Ako podržava srpski i slovenski mora podržavati i Hrvatski - čćžšđ ČĆŽŠĐ |
| 35 | |
| 36 | === English === |
| 37 | Yes indeed, Trac supports English. Fully. |
| 38 | |
| 39 | === Français === |
| 40 | Il est possible d'écrire en Français : à, ç, û, ... |
| 41 | |
| 42 | === German === |
| 43 | Trac-Wiki muß auch deutsche Umlaute richtig anzeigen: ö, ä, ü, Ä, Ö, Ü; und das scharfe ß |
| 44 | |
| 45 | === Greek === |
| 46 | Τα Ελληνικά υποστηρίζονται επαρκώς επίσης. |
| 47 | |
| 48 | === Hebrew === |
| 49 | אני יכול לאכול זכוכית וזה לא מזיק לי |
| 50 | |
| 51 | === Hindi === |
| 52 | अब हिन्दी में। |
| 53 | |
| 54 | === Hungarian === |
| 55 | Árvíztűrő tükörfúrógép |
| 56 | |
| 57 | === Icelandic === |
| 58 | Ævar sagði við ömmu sína: Sjáðu hvað ég er stór! |
| 59 | |
| 60 | === Japanese === |
| 61 | 漢字 ひらがな カタカナ ハンカクカナ 日本語試験 |
| 62 | |
| 63 | === Korean === |
| 64 | 이번에는 한글로 써보겠습니다. 잘 보이나요? 한글 |
| 65 | |
| 66 | === Latvian === |
| 67 | |
| 68 | Latviešu valoda arī strādā! |
| 69 | |
| 70 | === Lithuanian === |
| 71 | Sudalyvaukime ir mes. Ar veikia lietuviškos raidės? ąčęėįšųūž ĄČĘĖĮŠŲŪŽ Žinoma, kad veikia :) |
| 72 | Kas tie mes? |
| 73 | |
| 74 | === Persian (Farsi) === |
| 75 | این یک متن فارسی است ولی امکان نوشتن مستقیم فارسی نیست چون حالت متن از راست به چپ و جود ندارد برای فارسی نوشتن باید از HTML استفاده کنید. |
| 76 | {{{ |
| 77 | #!html |
| 78 | <div dir="rtl"> |
| 79 | }}} |
| 80 | این نمونه یک متن از راست به چپ فارسی است که در HTML نوشته شده تا اعداد 12345 و حروف لاتین ABCDEF در محل خودشان نمایش داده شوند. |
| 81 | {{{ |
| 82 | #!html |
| 83 | </div> |
| 84 | }}} |
| 85 | |
| 86 | === Polish === |
| 87 | Pchnąć w tę łódź jeża lub osiem skrzyń fig; Nocna gżegżółka zawsze dzienną przekuka. |
| 88 | |
| 89 | === Portuguese === |
| 90 | É possível guardar caracteres especias da língua portuguesa, incluindo o símbolo da moeda européia '€', trema 'ü', crase 'à', agudos 'áéíóú', circunflexos 'âêô', til 'ãõ', cedilha 'ç', ordinais 'ªº', grau '°¹²³'. |
| 91 | |
| 92 | === Russian === |
| 93 | Проверка русского языка: кажется работает... И буква "ё" есть... |
| 94 | |
| 95 | === Serbian === |
| 96 | Podržan, uprkos činjenici da se za njegovo pisanje koriste чак два алфабета. |
| 97 | |
| 98 | === Slovenian === |
| 99 | Ta suhi škafec pušča vodo že od nekdaj! |
| 100 | |
| 101 | === Spanish === |
| 102 | Esto es un pequeño texto en Español, donde el veloz murciélago hindú comía cardlllo y kiwi |
| 103 | |
| 104 | === Swedish === |
| 105 | Räven raskar över isen med luva på. |
| 106 | |
| 107 | === Thai === |
| 108 | Trac แสดงภาษาไทยได้อย่างถูกต้อง! |
| 109 | |
| 110 | === Ukrainian === |
| 111 | Перевірка української мови... |
| 112 | |
| 113 | === Urdu === |
| 114 | ٹریک اردو بھی سپورٹ کرتا ہے۔ |
| 115 | |
| 116 | === Vietnamese === |
| 117 | Viết tiếng Việt cũng được. |