From 2a15b94200abe8ee0df2dddc296f3dafd55655f8 Mon Sep 17 00:00:00 2001
From: mitchell
When the inline IME mode is active, characters are added tentatively before being finalised and an - notification is sent for each character.
+ notification (withcharacterSource set to SC_CHARACTERSOURCE_TENTATIVE_INPUT) is sent for each character.
SCI_GRABFOCUS
SCI_SETFOCUS(bool focus)
@@ -7303,7 +7303,7 @@ struct SCNotification {
int updated; /* SCN_UPDATEUI */
int listCompletionMethod;
/* SCN_AUTOCSELECTION, SCN_AUTOCCOMPLETED, SCN_USERLISTSELECTION */
-
+ int characterSource; /* SCN_CHARADDED */
};
@@ -7405,6 +7405,44 @@ href="#SCI_POSITIONFROMLINE">SCI_POSITIONFROMLINE(lineNumber);
for DBCS, it is (first byte * 256 + second byte) for 2 byte characters and the byte value for 1 byte characters.
This notification is sent before the character has been styled so processing that depends on
styling should instead be performed in the SCN_UPDATEUI notification.
The SCNotification::characterSource field is the source of the character.
| Symbol | +Value | +Meaning | +
|---|---|---|
SC_CHARACTERSOURCE_DIRECT_INPUT |
+ 0 | +Direct input characters, including characters generated by calling keyboard commands like SCI_NEWLINE. | +
SC_CHARACTERSOURCE_TENTATIVE_INPUT |
+ 1 | +Tentative input characters. They are used by IME (inline mode, see SCI_SETIMEINTERACTION) + to composite final string, normally different from final composited string (which is the string that has been truly added into current document), + and may be withdrawn when the user cancels typing (e.g. by pressing Esc key). + Some system (at least Cocoa) also use tentative input for non-IME features like using dead key to composite diacritical marks (grave accent, etc.). + These characters are not added to macro recording. Most applications can simply ignore the notification when this value is set. + | +
SC_CHARACTERSOURCE_IME_RESULT |
+ 2 | +IME (either inline or windowed mode) full composited string. Modern IME is able to composite English word or sentence, + when this value is set, current character may not a Chinese, Japanese or Korean character. + Currently, this is only set on Windows. | +
SCN_SAVEPOINTREACHED
SCN_SAVEPOINTLEFT
--
cgit v1.2.3