aboutsummaryrefslogtreecommitdiffhomepage
path: root/gtk
diff options
context:
space:
mode:
authorNeil <nyamatongwe@gmail.com>2025-04-22 11:13:52 +1000
committerNeil <nyamatongwe@gmail.com>2025-04-22 11:13:52 +1000
commit99e69de57d94f4bcf8d72a69c9215684ee4152ee (patch)
treec9d4fb2406babae42a9772309becc59c017f3165 /gtk
parentac87d3e3b29fead6e30514535b8cf87dcc66304e (diff)
downloadscintilla-mirror-99e69de57d94f4bcf8d72a69c9215684ee4152ee.tar.gz
Move common IME code from platform layers to ScintillaBase.
Diffstat (limited to 'gtk')
-rwxr-xr-xgtk/ScintillaGTK.cxx23
-rwxr-xr-xgtk/ScintillaGTK.h2
2 files changed, 0 insertions, 25 deletions
diff --git a/gtk/ScintillaGTK.cxx b/gtk/ScintillaGTK.cxx
index 38e0d0376..d1cce0fbd 100755
--- a/gtk/ScintillaGTK.cxx
+++ b/gtk/ScintillaGTK.cxx
@@ -2375,29 +2375,6 @@ bool ScintillaGTK::KoreanIME() {
return lastNonCommonScript == G_UNICODE_SCRIPT_HANGUL;
}
-void ScintillaGTK::MoveImeCarets(Sci::Position pos) {
- // Move carets relatively by bytes
- for (size_t r=0; r<sel.Count(); r++) {
- const Sci::Position positionInsert = sel.Range(r).Start().Position();
- sel.Range(r) = SelectionRange(positionInsert + pos);
- }
-}
-
-void ScintillaGTK::DrawImeIndicator(int indicator, Sci::Position len) {
- // Emulate the visual style of IME characters with indicators.
- // Draw an indicator on the character before caret by the character bytes of len
- // so it should be called after InsertCharacter().
- // It does not affect caret positions.
- if (indicator < 8 || indicator > INDICATOR_MAX) {
- return;
- }
- pdoc->DecorationSetCurrentIndicator(indicator);
- for (size_t r=0; r<sel.Count(); r++) {
- const Sci::Position positionInsert = sel.Range(r).Start().Position();
- pdoc->DecorationFillRange(positionInsert - len, 1, len);
- }
-}
-
namespace {
std::vector<int> MapImeIndicators(PangoAttrList *attrs, const char *u8Str) {
diff --git a/gtk/ScintillaGTK.h b/gtk/ScintillaGTK.h
index 126072856..5f73d8174 100755
--- a/gtk/ScintillaGTK.h
+++ b/gtk/ScintillaGTK.h
@@ -243,8 +243,6 @@ private:
bool DeleteSurroundingThis(GtkIMContext *context, gint characterOffset, gint characterCount);
static gboolean DeleteSurrounding(GtkIMContext *context, gint characterOffset, gint characterCount,
ScintillaGTK *sciThis);
- void MoveImeCarets(Sci::Position pos);
- void DrawImeIndicator(int indicator, Sci::Position len);
void SetCandidateWindowPos();
static void StyleSetText(GtkWidget *widget, GtkStyle *previous, void *);