Braille To Text Version 1 Copyright 10/06/2023, New Braille System Corp. Tsuneo Hoshika EMail : hoshika@nbs.co.jp Ver 1 からの変更点 Changes from Ver 1 We add the function that only one word is converted to English character after Latin letter code. 1単語のみ英字に変換する外字符(⠰)を採用しました。 Added ReIsEnglish to TOTEXT_INFO_MAP member. TOTEXT_INFO_MAP memberに ReIsEnglish を追加しました。 The items below were added to the Japanese conversion list 日本語変換リストに以下のものを追加しました。 ⠘⠁ ァ ⠘⠃ ィ ⠘⠉ ゥ ⠘⠋ ェ ⠘⠊ ォ ⠘⠌ ャ ⠘⠬ ュ ⠘⠜ ョ ⠘⠂ ゙ ⠰⠤ 『 ⠤⠆ 』 Purpose 点字ディスプレイ装置の点字キーから入力された点字コードを、テキスト文字に変換します。 Converts Braille codes entered from the Braille display device's Braille keys into text characters. file list Braille To Text Ver 2.txt : This File Conversion List2.txt : Braille to text character conversion list file for each conversion mode source(FOLDER) : MAIN.CPP : SAMPLE SOURCE totext_map.H : PARAMETER STRUCT Head File ToText.h : Head File ToText.CPP : c++ Source File execute(FOLDER) : プログラムのテスト実行環境。 Test execution environment for the program. input_brl.txtに記載されたユニコード点字文書をテキスト文字に変換し、output_text.txtを作成します。 Convert the Unicode Braille document in input_brl.txt to text characters and create output_text.txt. testu.txt : sample text file tobrl.exe : sample program file How to use ToText int Init(char *DataPath) : Set data path in DataPath and initialize. return : 0 : success 1 : kan.dat not open 2 : kan.dat not right int SetConvertMode(int Mode); 変換モードを設定します。 Sets the conversion mode. return : 0 : success 1: Invalid Mode value The Mode values that can be set are #define JAPAN_KANA 0 #define ENGLISH_SMALL 1 #define NUMBER_ONLEY 2 #define NABCC6 3 #define NABCC8 4 #define UNICODE_BRAILLE 5 See conversionList.txt for details on each conversion mode. int BrlToText(TOTEXT_INFO_MAP *Param); Perform the conversion. return : 0 : success The conversion result character is set in ReTextStr. 1 : success This is the first case where two Braille characters are required to determine the text character, and no text character is stored in ReTextStr. テキスト文字文字確定に、点字2文字必要な場合の1文字目で、ReTextStrにテキスト文字は格納されない場合。 2 : success When the conversion mode is changed by Braille characters and Voice Massage is set in ReVoiceMassageStr. 点字文字によって変換モードが変更された場合で、ReVoiceMassageStrに Voice Massage がセットされています。 3 : Error Input error, input that cannot be converted was made. 入力エラー、変換できない入力が行われた 4 : Error System internal error, value is not going to be returned. システム内部エラー、値が返されることはないつもり。 Contents of the TOTEXT_INFO_MAP member unsigned char BrlCode : Set the Braille input code. 点字入力コード 0 : Space Except for NABCC8, the range of 6 points from 0x01 to 0x3f is valid. NABCC8を除き、 0x01 から 0x3f の 6点の範囲が有効。 In NABCC8, a dot of 7 (0x40) is added to uppercase alphabetic characters and some symbol inputs. NABCC8 では、アルファベットの大文字と、一部の記号入力において 7の点(0x40)を付加する。 wchar_t *ReTextStr : Sets the conversion result text address. 変換結果テキストアドレス wchar_t *ReVoiceMassageStr : Set the voice message address. ボイスメッセージアドレスをセットします。 When the conversion mode is changed from Japanese to English or from English to Japanese by Braille input, a voice message is set. 点字入力によって、変換モードが Japanese から English に、 English から Japanese に変更された際、音声メッセージがセットされます。 int ReIsEnglish : 0 is set when the conversion mode is Japanese. 変換モードが Japanese のときは 0 がセットされます。 When the conversion mode is changed to English by ⠦, 1 is set. 変換モードが⠦によって English に変更された場合は、 1 がセットされます。