OSDN Git Service

added jpAnsiEditbox option rather than guessing Unicode-like behavior by editAPIVersion jp2014.1 jpbeta140324
authorTakuya Nishimoto <nishimotz@gmail.com>
Sun, 23 Mar 2014 14:44:16 +0000 (23:44 +0900)
committerTakuya Nishimoto <nishimotz@gmail.com>
Sun, 23 Mar 2014 14:44:16 +0000 (23:44 +0900)
source/NVDAObjects/window/edit.py
source/config/__init__.py
source/gui/settingsDialogs.py
source/locale/ja/LC_MESSAGES/nvda.po

index 1c69128..cd886e2 100644 (file)
@@ -419,9 +419,7 @@ class EditTextInfo(textInfos.offsets.OffsetsTextInfo):
                        return watchdog.cancellableSendMessage(self.obj.windowHandle,EM_LINEFROMCHAR,offset,0)\r
 \r
        def _needsWorkAroundEncoding(self):\r
-               return config.conf["language"]["workAroundEncoding"] and \\r
-                       (not self.obj.isWindowUnicode) and \\r
-                       (self.obj.editAPIVersion == 0)\r
+               return config.conf["language"]["jpAnsiEditbox"] and (not self.obj.isWindowUnicode)\r
 \r
        def _getLineOffsets(self,offset):\r
                if self._needsWorkAroundEncoding():\r
index cd5b26c..c65fb87 100644 (file)
@@ -70,7 +70,7 @@ confspec = ConfigObj(StringIO(
        jpPhoneticReadingLatin = boolean(default=false) \r
        jpPhoneticReadingKana = boolean(default=false)\r
        announceCandidateNumber = boolean(default=false)\r
-       workAroundEncoding = boolean(default=true)\r
+       jpAnsiEditbox = boolean(default=true)\r
 \r
 # Speech settings\r
 [speech]\r
index a595efd..56a6451 100644 (file)
@@ -1755,6 +1755,10 @@ class LanguageSettingsDialog(SettingsDialog):
                self.nvdajpEnableKeyEventsCheckBox.SetValue(config.conf["keyboard"]["nvdajpEnableKeyEvents"])\r
                settingsSizer.Add(self.nvdajpEnableKeyEventsCheckBox,border=10,flag=wx.BOTTOM)\r
 \r
+               self.jpAnsiEditCheckBox=wx.CheckBox(self,wx.NewId(),label=_("Work around ANSI editbox"))\r
+               self.jpAnsiEditCheckBox.SetValue(config.conf["language"]["jpAnsiEditbox"])\r
+               settingsSizer.Add(self.jpAnsiEditCheckBox,border=10,flag=wx.BOTTOM)\r
+\r
        def postInit(self):\r
                self.nconvAsNVDAModifierCheckBox.SetFocus()\r
 \r
@@ -1766,6 +1770,7 @@ class LanguageSettingsDialog(SettingsDialog):
                config.conf["keyboard"]["nvdajpEnableKeyEvents"]=self.nvdajpEnableKeyEventsCheckBox.IsChecked()\r
                config.conf["keyboard"]["nvdajpImeBeep"]=self.nvdajpImeBeepCheckBox.IsChecked()\r
                config.conf["language"]["announceCandidateNumber"]=self.announceCandidateNumberCheckBox.IsChecked()\r
+               config.conf["language"]["jpAnsiEditbox"]=self.jpAnsiEditCheckBox.IsChecked()\r
 \r
                jpKatakanaPitchChange=self.jpKatakanaPitchChangeEdit.Value\r
                try:\r
index f8a760d..de8401f 100755 (executable)
@@ -42,6 +42,10 @@ msgstr "日本語版の文字入力拡張"
 msgid "Beep for IME mode change"
 msgstr "半角全角キーが押されたらビープ音を鳴らす"
 
+#: gui\settingsDialogs.py:1758
+msgid "Work around ANSI editbox"
+msgstr "改行位置の不具合対策"
+
 #: source\gui\__init__.py:416 source\gui\settingsDialogs.py:469
 msgid "Use NonConvert as an NVDA modifier key"
 msgstr "無変換をNVDAキーとして使用"