diff --git a/Source/Modules/InputHandler_Core.swift b/Source/Modules/InputHandler_Core.swift index 9c0ce0b1..1d425f7b 100644 --- a/Source/Modules/InputHandler_Core.swift +++ b/Source/Modules/InputHandler_Core.swift @@ -28,6 +28,7 @@ public protocol InputHandlerProtocol { func clearComposerAndCalligrapher() func ensureKeyboardParser() func handleEvent(_ event: NSEvent) -> Bool + func generateStateOfCandidates() -> IMEStateProtocol func generateStateOfInputting(sansReading: Bool) -> IMEStateProtocol func generateStateOfAssociates(withPair pair: Megrez.Compositor.KeyValuePaired) -> IMEStateProtocol func consolidateNode(candidate: (String, String), respectCursorPushing: Bool, preConsolidate: Bool) diff --git a/Source/Modules/InputHandler_HandleStates.swift b/Source/Modules/InputHandler_HandleStates.swift index 6c2c73de..e36d874f 100644 --- a/Source/Modules/InputHandler_HandleStates.swift +++ b/Source/Modules/InputHandler_HandleStates.swift @@ -90,7 +90,7 @@ extension InputHandler { /// 拿著給定的候選字詞陣列資料內容,切換至選字狀態。 /// - Returns: 回呼一個新的選詞狀態,來就給定的候選字詞陣列資料內容顯示選字窗。 - func generateStateOfCandidates() -> IMEStateProtocol { + public func generateStateOfCandidates() -> IMEStateProtocol { IMEState.ofCandidates( candidates: generateArrayOfCandidates(fixOrder: prefs.useFixecCandidateOrderOnSelection), displayTextSegments: compositor.walkedNodes.values,