コード例 #1
0
ファイル: MainForm.cs プロジェクト: gulshan/Avro.net
 private void AlterMode()
 {
     if (phoneticMode)
     {
         textBoxPhonetic.TextChanged -= TextBoxPhonetic_TextChanged;
         Text         = TITLE_EN;
         phoneticMode = false;
         editor.Reset();
     }
     else
     {
         textBoxPhonetic.TextChanged += TextBoxPhonetic_TextChanged;
         Text         = TITLE_BN;
         phoneticMode = true;
     }
 }
コード例 #2
0
        private void Test1()
        {
            editor.Reset();
            editor.PutNewChar('k', 1);
            editor.PutNewChar('o', 2);
            editor.PutNewChar('r', 2);

            var result = editor.PutNewChar('r', 3);

            Assert.Equal(expected: "করর", result.output);

            result = editor.PutNewChar('m', 4);
            Assert.Equal(expected: "কর্ম", result.output);

            result = editor.PutNewChar(' ');
            Assert.Null(result.output);
        }