diff --git a/Editor/Completion/XmlCompletionCommitManager.cs b/Editor/Completion/XmlCompletionCommitManager.cs index 022f5ef..a445cb6 100644 --- a/Editor/Completion/XmlCompletionCommitManager.cs +++ b/Editor/Completion/XmlCompletionCommitManager.cs @@ -92,6 +92,13 @@ public CommitResult TryCommit (IAsyncCompletionSession session, ITextBuffer buff return CommitResult.Unhandled; } + // per-item CommitCharacters overrides the default commit chars + if (!item.CommitCharacters.IsDefaultOrEmpty) { + if (item.CommitCharacters.Contains (typedChar)) { + return CommitCancel; + } + } + var span = session.ApplicableToSpan.GetSpan (buffer.CurrentSnapshot); bool wasTypedInFull = span.Length == item.InsertText.Length;