From d3e49fa3b505cce12a60cb1a2711fd6b4427303b Mon Sep 17 00:00:00 2001 From: crupest Date: Wed, 28 Oct 2020 17:56:30 +0800 Subject: ... --- src/ui/controls/TextControlService.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/ui/controls/TextControlService.hpp') diff --git a/src/ui/controls/TextControlService.hpp b/src/ui/controls/TextControlService.hpp index 376f9177..fe33f459 100644 --- a/src/ui/controls/TextControlService.hpp +++ b/src/ui/controls/TextControlService.hpp @@ -411,7 +411,10 @@ class TextControlService : public Object { input_method_context_ = GetUiApplication()->GetInputMethodManager()->GetContext(window); input_method_context_->EnableIME(); - auto sync = [this](std::nullptr_t) { this->SyncTextRenderObject(); }; + auto sync = [this](std::nullptr_t) { + this->SyncTextRenderObject(); + ScrollToCaret(); + }; input_method_context_->CompositionStartEvent()->AddHandler( [this](std::nullptr_t) { this->DeleteSelectedText(); }); input_method_context_->CompositionEvent()->AddHandler(sync); -- cgit v1.2.3