質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
Python

Pythonは、コードの読みやすさが特徴的なプログラミング言語の1つです。 強い型付け、動的型付けに対応しており、後方互換性がないバージョン2系とバージョン3系が使用されています。 商用製品の開発にも無料で使用でき、OSだけでなく仮想環境にも対応。Unicodeによる文字列操作をサポートしているため、日本語処理も標準で可能です。

Sublime Text

SublimeTextとは、オーストラリアのSublime HQ Pty Ltdが提供しているテキストエディターのことです。Mac/Windows/Linuxでの利用が可能で、柔軟にカスタマイズできたり、多くの言語に対応していくこともあり、海外や日本国内でも人気のあるエディターです。

Q&A

1回答

2968閲覧

OSX/SublimeText3で、日本語を入力しているとEnterで変換中の文字が消える

horse_n_deer

総合スコア452

Python

Pythonは、コードの読みやすさが特徴的なプログラミング言語の1つです。 強い型付け、動的型付けに対応しており、後方互換性がないバージョン2系とバージョン3系が使用されています。 商用製品の開発にも無料で使用でき、OSだけでなく仮想環境にも対応。Unicodeによる文字列操作をサポートしているため、日本語処理も標準で可能です。

Sublime Text

SublimeTextとは、オーストラリアのSublime HQ Pty Ltdが提供しているテキストエディターのことです。Mac/Windows/Linuxでの利用が可能で、柔軟にカスタマイズできたり、多くの言語に対応していくこともあり、海外や日本国内でも人気のあるエディターです。

0グッド

0クリップ

投稿2016/06/17 16:28

編集2016/06/17 16:29

イメージ説明

上記のように、OSX 10.11.5SublimeText3(Build 3114)で、日本語を入力している途中でEnterキーで入力内容が消えてしまいます。

10月 27, 2014/Sublime Text 3 で日本語を検索したとき文字が消える不具合を直す

こちらの記事を参考に、/Library/Application Support/Sublime Text 3/Packages/Default/Default (OSX).sublime-keymapの下記の箇所をコメントアウトしました。

diff

1--- /Users/59naga/Library/Application Support/Sublime Text 3/Packages/Default/Default (OSX).sublime-keymap 2+++ (clipboard) 3@@ -174,12 +174,12 @@ 4 5 { "keys": ["super+enter"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Add Line.sublime-macro"} }, 6 { "keys": ["super+shift+enter"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Add Line Before.sublime-macro"} }, 7- { "keys": ["enter"], "command": "commit_completion", "context": 8- [ 9- { "key": "auto_complete_visible" }, 10- { "key": "setting.auto_complete_commit_on_tab", "operand": false } 11- ] 12- }, 13+ // { "keys": ["enter"], "command": "commit_completion", "context": 14+ // [ 15+ // { "key": "auto_complete_visible" }, 16+ // { "key": "setting.auto_complete_commit_on_tab", "operand": false } 17+ // ] 18+ // }, 19 20 { "keys": ["super+t"], "command": "show_overlay", "args": {"overlay": "goto", "show_files": true} }, 21 { "keys": ["super+p"], "command": "show_overlay", "args": {"overlay": "goto", "show_files": true} }, 22@@ -422,7 +422,15 @@ 23 ] 24 }, 25 26- { "keys": ["enter"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Add Line in Braces.sublime-macro"}, "context": 27+ // { "keys": ["enter"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Add Line in Braces.sublime-macro"}, "context": 28+ // [ 29+ // { "key": "setting.auto_indent", "operator": "equal", "operand": true }, 30+ // { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 31+ // { "key": "preceding_text", "operator": "regex_contains", "operand": "\\{$", "match_all": true }, 32+ // { "key": "following_text", "operator": "regex_contains", "operand": "^\\}", "match_all": true } 33+ // ] 34+ // }, 35+ { "keys": ["shift+enter"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Add Line in Braces.sublime-macro"}, "context": 36 [ 37 { "key": "setting.auto_indent", "operator": "equal", "operand": true }, 38 { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 39@@ -430,24 +438,16 @@ 40 { "key": "following_text", "operator": "regex_contains", "operand": "^\\}", "match_all": true } 41 ] 42 }, 43- { "keys": ["shift+enter"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Add Line in Braces.sublime-macro"}, "context": 44- [ 45- { "key": "setting.auto_indent", "operator": "equal", "operand": true }, 46- { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 47- { "key": "preceding_text", "operator": "regex_contains", "operand": "\\{$", "match_all": true }, 48- { "key": "following_text", "operator": "regex_contains", "operand": "^\\}", "match_all": true } 49- ] 50- }, 51- 52- { "keys": ["enter"], "command": "auto_indent_tag", "context": 53- [ 54- { "key": "setting.auto_indent", "operator": "equal", "operand": true }, 55- { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 56- { "key": "selector", "operator": "equal", "operand": "punctuation.definition.tag.begin", "match_all": true }, 57- { "key": "preceding_text", "operator": "regex_contains", "operand": ">$", "match_all": true }, 58- { "key": "following_text", "operator": "regex_contains", "operand": "^</", "match_all": true }, 59- ] 60- }, 61+ 62+ // { "keys": ["enter"], "command": "auto_indent_tag", "context": 63+ // [ 64+ // { "key": "setting.auto_indent", "operator": "equal", "operand": true }, 65+ // { "key": "selection_empty", "operator": "equal", "operand": true, "match_all": true }, 66+ // { "key": "selector", "operator": "equal", "operand": "punctuation.definition.tag.begin", "match_all": true }, 67+ // { "key": "preceding_text", "operator": "regex_contains", "operand": ">$", "match_all": true }, 68+ // { "key": "following_text", "operator": "regex_contains", "operand": "^</", "match_all": true }, 69+ // ] 70+ // }, 71 { "keys": ["shift+enter"], "command": "auto_indent_tag", "context": 72 [ 73 { "key": "setting.auto_indent", "operator": "equal", "operand": true }, 74@@ -636,9 +636,9 @@ 75 }, 76 77 // Find panel key bindings 78- { "keys": ["enter"], "command": "find_next", "context": 79- [{"key": "panel", "operand": "find"}, {"key": "panel_has_focus"}] 80- }, 81+ // { "keys": ["enter"], "command": "find_next", "context": 82+ // [{"key": "panel", "operand": "find"}, {"key": "panel_has_focus"}] 83+ // }, 84 { "keys": ["shift+enter"], "command": "find_prev", "context": 85 [{"key": "panel", "operand": "find"}, {"key": "panel_has_focus"}] 86 }, 87@@ -647,9 +647,9 @@ 88 }, 89 90 // Replace panel key bindings 91- { "keys": ["enter"], "command": "find_next", "context": 92- [{"key": "panel", "operand": "replace"}, {"key": "panel_has_focus"}] 93- }, 94+ // { "keys": ["enter"], "command": "find_next", "context": 95+ // [{"key": "panel", "operand": "replace"}, {"key": "panel_has_focus"}] 96+ // }, 97 { "keys": ["shift+enter"], "command": "find_prev", "context": 98 [{"key": "panel", "operand": "replace"}, {"key": "panel_has_focus"}] 99 }, 100@@ -661,9 +661,9 @@ 101 }, 102 103 // Incremental find panel key bindings 104- { "keys": ["enter"], "command": "hide_panel", "context": 105- [{"key": "panel", "operand": "incremental_find"}, {"key": "panel_has_focus"}] 106- }, 107+ // { "keys": ["enter"], "command": "hide_panel", "context": 108+ // [{"key": "panel", "operand": "incremental_find"}, {"key": "panel_has_focus"}] 109+ // }, 110 { "keys": ["shift+enter"], "command": "find_prev", "context": 111 [{"key": "panel", "operand": "incremental_find"}, {"key": "panel_has_focus"}] 112 },

結果に変化はなく、冒頭のgif画像のように、変換中の日本語が削除されてしまいます。
この不具合に関して、修正方法をご存知でしょうか?

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答1

0

該当するかはわかりませんが、こんな情報もありますので、お試しください。
http://qiita.com/akippiko/items/1382faa29833379621f6

Sublime Textは日本語のようなIMEを用いた入力をサポートしていませんし、日本語周りの不具合は5年も前から放置なのでサポートする気もありません。Macでうまく動いていたのは偶然であり、本来はWindowsでのIMESupportやLinuxでのSublimeMozcInputのような外部パッケージを使わない限り、まともに動くことは期待するだけ無駄です。日本語を使いたい場合は他のエディタをお勧めします。Sublime Textはソースコードに日本語を一切使わないオレスゲーな人が使うエディタです。

投稿2016/06/17 20:03

raccy

総合スコア21735

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

まだベストアンサーが選ばれていません

会員登録して回答してみよう

アカウントをお持ちの方は

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問