[Prime-cvs] CVS update: prime/lib

Back to archive index

Hiroyuki Komatsu komat****@users*****
2005年 3月 7日 (月) 21:19:15 JST


Index: prime/lib/composer.rb
diff -u prime/lib/composer.rb:1.3 prime/lib/composer.rb:1.4
--- prime/lib/composer.rb:1.3	Mon Mar  7 18:26:57 2005
+++ prime/lib/composer.rb	Mon Mar  7 21:19:15 2005
@@ -1,5 +1,5 @@
 # composer.rb: Module of composition for PrimeSession
-# $Id: composer.rb,v 1.3 2005/03/07 09:26:57 komatsu Exp $
+# $Id: composer.rb,v 1.4 2005/03/07 12:19:15 komatsu Exp $
 #
 # Copyright (C) 2005 Hiroyuki Komatsu <komat****@taiya*****>
 #     All rights reserved.
@@ -31,6 +31,10 @@
       return false
     end
 
+    if PRIME_ENV['hybrid_typing_use_dictionaries'] == false then
+      return true
+    end
+
     ## The following function is only supported with the Romaji mode.
     if PRIME_ENV['typing_method'] != 'romaji' then
       return true
@@ -55,6 +59,9 @@
     end
 
     rawinput = edit_get_raw_input()[0]
+    if rawinput.nil? then
+      return true
+    end
 
     words.each { | word |
       if word.pron.index(rawinput) != 0 then
Index: prime/lib/prime-config.rb.in
diff -u prime/lib/prime-config.rb.in:1.5 prime/lib/prime-config.rb.in:1.6
--- prime/lib/prime-config.rb.in:1.5	Mon Mar  7 16:51:32 2005
+++ prime/lib/prime-config.rb.in	Mon Mar  7 21:19:15 2005
@@ -1,5 +1,5 @@
 # prime-config.rb: Setting of global variables and default variables for PRIME.
-# $Id: prime-config.rb.in,v 1.5 2005/03/07 07:51:32 komatsu Exp $
+# $Id: prime-config.rb.in,v 1.6 2005/03/07 12:19:15 komatsu Exp $
 #
 # Copyright (C) 2003 Hiroyuki Komatsu <komat****@taiya*****>
 #     All rights reserved.
@@ -44,6 +44,9 @@
 ## If true, PRIME considers the validation of the preedition.
 ## ex). "あっplえ" => "apple".  The available values are [nil, true, false].
 PRIME_ENV['hybrid_typing']          = nil
+## If true, the Romaji validation method uses word dictionaries.
+## It improves the precision of the validation, but decrease the speed.
+PRIME_ENV['hybrid_typing_use_dictionaries'] = true
 
 #PRIME_ENV['suikyo_tables']         = ["romaji"]
 #PRIME_ENV['suikyo_reverse_tables'] = ["romaji_reverse"]


Prime-cvs メーリングリストの案内
Back to archive index