Posts Tagged ‘Chinese’

很高兴!Chinese in TeX

Thursday, August 4th, 2011

Recently, good things have kept on coming my ways (see my previous posts).

One issue that’s been nagging me for quite a while is outputting simplifed Chinese in .tex files. Given all the information I had collected I knew I was really close but it never completely worked… until I got Japanese working in TeX.

From then on, it was a matter of changing some fonts and trying.

In the end, I found even two ways to produce Chinese in tex files:

The first:

1) Download this template for Japanese in TeX:
http://pastebin.com/tasDkhZ3

2) Replace the following lines:
\newenvironment{Japanese}{%
with
\newenvironment{Chinese}{%

and
\CJKfamily{min}%
with
\CJKfamily{gkai}%

and the tags \begin{Japanese} and \end{Japanese} must also be
replaced with \begin{Chinese} and \end{Chinese}

3) Install the following packages:
latex-cjk-common
latex-cjk-chinese
latex-cjk-chinese-arphic-gkai00mp

4) Compile using pdflatex <file.tex>

Then, compiling with pdflatex works provided you have the packages

Note:
For some reasons, the CJKfamily “bkai” does not contain all the
simplified Chinese characters, so “gkai” (or an equivalent font
alternative) is required.

The second:

1) Download this sample file:
http://scripts.sil.org/cms/scripts/render_download.php?&format=file&media_id=xetex_chinese_sample&filename=xetex_chinese_sample.zip

Unfortunately, the uploader created it on a mac where the fonts are
different. However, in XeTeX you can specify fonts that are available in
other programs and system-wide so you can just pick a nice font in
LibreOffice and specify that one.

2) Change the fonts in the .tex file to some different font. Use the complete name of the font as you can see it in LibreOffice’s font selection e.g. “AR PL UKai CN”.

3) Compile using “xetex <file>.tex”

4) Rejoice!

To be honest, this second template file is most likely a total overkill for a simple papers or some exercices as the output comes in vertical columns and must be read from right to left. But it’s awesome to see that such a thing is even possible in TeX!

HSK level woes

Sunday, January 17th, 2010

Another day, another failure…
In my quest to conquer another language I started learning Mandarin two years ago. I’ve taken an introductory course two years ago and am working on a second textbook which will soon be finished. So it was time to find a new textbook and I’ve decided on a textbook based on the HSK curriculum – but the research prior to acquiring the textbook was not sufficient.

What happened?

Taking a quick look at HSK in wikipedia I grabbed the info that there was a Elementary level. Thinking this level might suit me fine I ran off to a bookshop to order a textbook because I couldn’t find anything appropriate on Amazon. They ordered the book for me and I picked it up this weekend. By the way, between ordering the book and handing it over to me, the price was raised 5%. I think I will call them about this… Anyway, thumbing through the book I felt somewhat intimidated – the content looked quite tough. Many unknown words, long sentences – this is Elementary? I thought, suited for beginners (association: elementary school)

Some more googling revealed the following: HSK is divided into four levels: Basic, Elementary, Intermediate and Advanced where as Elementary and Intermediate are grouped into one. Unfortunately, the lowest level is not Elementary but Basic.

Looks like I’ll have to get a different book…

For the time being, from this page you can download vocabulary for the different levels in different formats, even pre-formatted for Mnemosyne, my favourite educational vocabulary tool:

http://hskflashcards.com/download.php

cheers

m.

Multilingual Posts

Saturday, January 9th, 2010

One of the requirements for my blog is the ability to post multilingual posts. Encoding is already UTF-8 so maybe this works without adding anything further…

もしこの文読めれば、もうゴールについた。

你的家是哪儿?我主瑞士。

Und natürli no e anderi Schprach womer susch au nöd so hüüfig gsehd im web….

*keeping fingers crossed*