﻿This Homebrew is an entry for the PSP Genesis competition 2011, sponsored by npt, psp-hacks.com, pspgen.com, pspslimhacks.com, exophase.com, pspcustomfirmware.com, daxhordes.org, gamegaz.jp, xtreamlua.com and wololo.net

Official website: http://wololo.net/talk/viewtopic.php?f=26&t=3536&start=0

################################## 
#AnyLanguageStudy                #
#Copyright Nakano 2011.          #
######## VERSION HISTORY #########
# V0.1 02/27/2011 (by nakano)    #
# * Initial release              #
# V0.2 03/02/2011 (by nakano)    # 
# * New word lists               #
# * Increased stability          #
# * Bug fixes                    # 
# * Optimizations for showing    #
#   long phrases.                #
# V0.3 03/05/2011 (by nakano)    #
# * Verb conjugation practice    #
# * Question font size can be    #
#   increased                    #
# * Added options menu           #
# * If user answers wrong, right #
#   answer is given (option)     #
# * User may set a delay before  #
#   answers are shown (option)   #
# V0.4 03/08/2011 (by nakano)    #
# * Support for picture word list#
# * Added range (option)         #
# * Example sentences (option)   #
# * Keys menu                    #
# * Minor bug fixes and          #
#   other optimizations          #
# * Added sentences for japanese #
#   and word list for kana       #
# * Added picture word list      #
# V0.5 03/13/2011 (by nakano)    #
# * A possibility to search      #
#   English definitions (replaces#
#   show keys from V0.4)         #
# * Added an option to           #
#   wait after the right choice  #
# * Added an option to change    #
#   the font color 				 #
# * Fixed a typo sring to string,#
#   which caused crash in certain#
#   situation                    #
# * Slight text changes          #
# * Modified logic, if word was  #
#   not known immediately. Now   #
#   it's not marked right when   #
#   you correct yourself         #
# * Parsed tatoeba sentences     #
# V0.6 04/22/2011 (by nakano)    #
# * Updated competition splash   #
# * Added analog support for     #
#   selection a file             #
# * Minor bug fixes.             #
# * Sentence zoom support        #
# V0.7 05/01/2011 (by nakano)    #
# * Added a support for audio    #
#   files with sentences.        #
# * A better support for non-    #
#   Japanese word lists          #
# * Added Mandarin word lists    #
# V0.8 05/04/2011 (by nakano)    #
# * New Chinese vocabulary lists #
#   based on HKS profiency test  #
#   and others.                  #
# * A possibility to group       #
#   word lists.                  #
# * Remembers the last word list.#
# * Some code rewrite.           #
# * Fixed a freezing bug caused  #
#   by a bug in Euphoria V8.     #
# * Now search doesn't only      #
#   search definition but        #
#   also translation.            #
# V0.9 05/14/2011 (by Nakano)	 #
# * Implemented custom Japanese  #
#   OSK for searching words.     #
# * Better international support;#
#   now possible to do e.g.      #
#   Chinese-Korean word lists    #
# * Several optimizations for    #
#   better user experience.      #
# * Added Korean word lists and  #
#   others + divided kana for    #
#   separate hiragana / katakana.#
##################################

### About AnyLanguageStudy ###

AnyLanguageStudy is a PSP application for studying words, grammar and characters. It comes bundled with Japanese word lists to help you studying for Japanese Language Proficiency Test (JLPT). However, you may create your own study lists for any language. AnyLanguageStudy is an open source project without any specific license. You may use the source for non-commercial projects.

### Installation ###

Copy the folder AnyLanguageStudy to x:\PSP\GAME\. Works with Game Categories too.

### Word lists ###

AnyLanguageStudy folder includes a file dictionary.ini. The file contains info about fonts (used by a word list) and paths to word lists. If you create your own word list, simply add the a new line that has the primary and secondary font info and path separated by ; (for example jpn0.pgf;ltn0.pgf;language/myLanguage/myWordList.csv). Fonts supported (by Intrafont) are

	lnt0.pgf (usually a good choice for the secondary font)
	lnt1.pgf
	...
	lnt15.pgf
	jpn0.pgf (for Japanese)
	gb3s1518.bwfon (for Chinese)
	kr0.pgf (for Korean)
	arib.pgf

Fonts need to locate in flash0:/font/. If you have installed 1.50 kernel addon, you may be missing a few fonts (kr0.pfg and arib.pgf probably).

If you do not want to use some word list, comment the line with #.

Word list format is also comma-separated value (csv). Words are separated with ;. For example, Finnish-English word list might have the following words:

	auto;car
	kissa;cat
	aurinko;sun

Last word is always definition because same word might have multiple presentation formats. For example, Japanese-English word list might have the following words:

	kuruma;くるま;車;car
	neko;ねこ;猫;cat
	hi;ひ;日;sun

An easy way to create lists is to use OpenOffice Calc and save the file as csv. After this you need to convert the file to UTF-8 without BOM encoding. Notepad++ can be used to achieve this. You may also want to use Notepad++ to remove all " characters.

### Picture word lists ###

You may also create picture word lists. In this case csv-file's definition is picture path. For example, cat;language/images/cat.png. Picture must end with .png. It is recommended that picture size is less than or equal to 480x272 (PSP's screen size). If you need more examples, see study_verbs_with_pictures.csv file. Only mode 1 is supported with pictures.

### Grouping word lists ###

You can group word lists by adding a group name after the path of a word list. For example,

	jpn0.pgf;language/myLanguage/myWordList.csv;Japanese word list group name comes here
	
If you don't give a group name, it is shown as Unknown.

### Sentences ###

Sentences also use csv-format. Again last is definition. The sentence file should be put to the same folder as word lists that use the sentences. Sentence list must be named sentence.csv so that it is found. For example a line in sentence.csv might be:

	Auto on nopea;Car is fast

Let's assume that you're asked what "Car" is in Finnish (it's "Auto"). When you have answered right, the above sentence is shown as it has the word "Auto".

### Sentences with audio ###

You may also want to create and add a wav-audio file for a sentence. For this, you must tell in sentence.csv the location/name of the audio file. By default the location is the same folder where corresponding sentence.csv is located. Let's assume we have a file car.wav that says "Auto on nopea". We just move this file to the same folder as sentence.csv and tell the file name by adding ;car like this:

	Auto on nopea;Car is fast;car

The .wav ending is added automatically. If we want to use a sub folder called sound, we would move the wav file to the sound folder and do this:

	Auto on nopea;Car is fast;sound/car

### Keys ###

UP: Move up / Switch mode (e.g. English-Japanese -> Japanese-English) / Switch OSK (Normal / Hiragana / Katakana)
DOWN: Move down / Switch mode / Switch OSK
RIGHT: Next page / Switch show (e.g. romaji -> hiragana -> kanji)
LEFT: Previous page / Switch show
ANALOG UP/DOWN: Increase/decrease font size or move up/down
ANALOG LEFT/RIGHT: Increase/decrease range or move left/right or previous/next page
R: Next page / Clear list of learned words
L: Previous page / Search
SQUARE: Select / Answer / Play sound
TRIANGLE: Select / Answer
CIRCLE: Select / Answer
CROSS: Select / Answer
HOME: Quick quit (saving of learned words is done before quiting)
SELECT: Open word list menu (saving of learned words is done before menu shows up)
START: Open global options menu

### Thanks to ###
- Jonathan Waller (http://www.tanos.co.uk) for great JLPT and HSK lists!
- Meguro Language Center (http://www.mlcjapanese.co.jp/) for info about past JLPT tests and other vocabulary.
- Saora Inc JLPT-Practice website (http://www.jlpt-practice.com/Lesson/Verbs_Conjugation.aspx) for verbs conjucation exercise.
- Collin McCulley (http://www.epochrypha.com/japanese/) for example sentences.
- Japanese4All (http://www.japanese4all.com/learning/) for great study materials (e.g. picture word list).
- santhosh4gCode for providing a tool to convert kana to romaji (http://www.codeproject.com/KB/recipes/JapaneesTORomajiConverter.aspx). A fair warning it doesn't handle every situation, for example, hiragana "cha" becomes "chiya" when converted.
- MauveCloud for providing a javascript (http://www.mauvecloud.net/charsets/romaji.html) to solve the above mentioned problem (used in V0.2).
- HSK Flashcards (http://hskflashcards.com/download.php) for Chinese vocabulary lists.
- Grabiel for sharing chino vocabulary.
- Jun Da (http://lingua.mtsu.edu/chinese-computing/) for giving a permission to use word lists from his homepage (chineseWordList.csv).
- Japanese website (http://kajiritate-no-hangul.com/) for a list of Korean-Japanese basic TOPIK.
- Beginner Topik vocabulary is from here: http://sites.google.com/site/topikrevision/beginnertopikvocabulary
- KBS World Radio vocabulary is parsed from here: http://rki.kbs.co.kr/learn_korean/lessons/e_index.htm
- Excellent info about most common Korean words by levels are from this website: http://ezcorean.com/index.php?cfile=6000.php
- Finnish-Germany word list is based on this list: http://old.spiney.org/public/vocabulary/list/
- Zack (http://www.retroemu.com/forum/index.php?/topic/126-release-luaplayer-euphoria-v8-new-features-and-improvements/) for LuaPlayer Euphoria V8.
- BenHur for Intrafont (build within Euphoria).

### Special thanks to ###
 - cmbeke (from Qj.net forums) for helping with special file reading issue.
 - Everyone who voted, commented, reported bugs and requested features for AnyLanguageStudy.
 - Organizers, sponsors and participants of Genesis.

### My earlier Japanese related projects ###
2011: Japanese Sentence DataBase (http://jsdb.site88.net/)
2010: PSPEdict V0.4-V0.6 (http://forums.psp-hacks.com/f141/release-pspedict-v0-6-japanese-dictionary-t264609/)