feat(input): 予測候補の受理にConverterの新APIを利用する - #373
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tab で予測候補を受け入れる際、従来は読みの削除・追加だけを行っていたため、選んだ表記が後続の変換に引き継がれませんでした。azooKey/AzooKeyKanaKanjiConverter#357 で追加された
acceptPredictionCandidate(_:composingText:)を利用し、受理した表記を後続の Zenzai 変換・予測の先頭制約として引き継ぐようにします。変更内容
ad714fea8cb2fe113aea86ba5c42563cdaf77cfbに更新。rawCandidates.predictionResultsから候補を新 API に渡して再計算。表示用のPredictionCandidateは表示文字列・追加する読み・削除数だけを持つ。確認
swift test --package-path Core: 全71テスト成功(Core・ConverterServer のビルドを含む)。swiftlint lint --quiet --strict: 成功。git diff --check: 成功。