Hepburn Romaji + Japanese lexical analysis & texifier.
I know nothing about parsing, Haskell and Japanese. This repository is purely for fun, and serving as a test-bed for some Haskell experiments.
Build the most convenient tool for Japanese beginners!
Input:
Output:
Full output:
Romaji should follow Hepburn romanization.
For an experimential online demo powered by GHCJS, see here for more details.
To build, at least ghc 7.10.2 is required.
$ cabal install parakeet.cabal
For stack users,
$ stack init
$ stack install
or
$ stack install --stack-yaml=stack-ghcjs.yaml
if you want to compile to JavaScript.
$ cabal sandbox init
$ cabal install --only-dependencies
$ cabal build
$ parakeet -j Butter-fly.j -r Butter-fly.r -o Butter-fly.tex
$ xelatex Butter-fly.tex
or directly,
$ parakeet -j Buffer-fly.j -r Buffer-fly.r -o Buffer-fly.pdf
You should guarantee that the two input files are encoded in UTF-8.
$
can avoid this trap.ō
is ambiguous in Hepburn romanization, which is interpreted to ou
or oo
. To resolve this, we always pick the former one. For example, 東京(Tōkyō)
is correctly translated to とうきょう
, while 大阪(Ōsaka)
is wrongly translated to おうさか
.zu
s and ji
s in romanization, namely ずづ
and じぢ
in hiragana respectively. We always pick ずじ
when translating zu
and ji
into furigana. If you want づぢ
, use du(dzu)
and di(dji)
instead.Since I haven’t find any potential users, so there will be no document available, please create an issue if you have trouble using it.
ō
warning.