Ejemplo n.º 1
0
 public bool InsertAction(EditViewControl textArea, char ch)
 {
     if (dotnetName != null)
     {
         CodeCompletionDataUsageCache.IncrementUsage(dotnetName);
     }
     if (c != null && text.Length > c.Name.Length)
     {
         textArea.InsertText(text.Substring(0, c.Name.Length + 1));
         TextPoint start = textArea.Caret.Position;
         TextPoint end;
         int       pos = text.IndexOf(',');
         if (pos < 0)
         {
             textArea.InsertText(text.Substring(c.Name.Length + 1));
             end    = textArea.Caret.Position;
             end.X -= 1;
         }
         else
         {
             textArea.InsertText(text.Substring(c.Name.Length + 1, pos - c.Name.Length - 1));
             end = textArea.Caret.Position;
             textArea.InsertText(text.Substring(pos));
         }
         textArea.Caret.Position     = start;
         textArea.Selection.SelStart = start.X;
         textArea.Selection.SelEnd   = end.X;
         //textArea.Selection.se.SelectionManager.SetSelection(start, end);
         if (!char.IsLetterOrDigit(ch))
         {
             return(true);
         }
     }
     else
     {
         textArea.InsertText(text);
     }
     return(false);
 }
Ejemplo n.º 2
0
 public virtual bool InsertAction(EditViewControl textArea, char ch)
 {
     textArea.InsertText(text);
     return(false);
 }
Ejemplo n.º 3
0
		public virtual bool InsertAction(EditViewControl textArea, char ch)
		{
			textArea.InsertText(text);
			return false;
		}