Zaher Dirkey wrote:
syncompletion.pas in synedit component


3 - The Auto Complete in TSynCompletion not worked fine with me, it is
just 2 char and then stop search for the keyword, after that pressing
Enter not close the AutoComplete
Search should work better now. Keystrokes where handled twice (utf8 and plain). The searchstring therefore contained every char twice, so it couldn't be found.


--------
procedure TMainForm.LoadCompletion;
  procedure FillNow(Name: string; SchemaItems: TmncSchemaItems);
  var
    i: Integer;
  begin
    for i := 0 to SchemaItems.Count - 1 do
      Completion.ItemList.Add(SchemaItems[i].Name);
  end;
begin
  //Completion.AddEditor(SQLEdit);
  Completion.Editor := SQLEdit;
  Completion.EndOfTokenChr := Completion.EndOfTokenChr + #13;
  Completion.TheForm.Font.Assign(SQLEdit.Font);
  //Completion.CaseSensitive := True;
  EnumerateKeywords(Ord(tkDatatype), SqliteTypes, SQLEdit.IdentChars,
@DoAddKeyword);
  FillNow('Table', sqlvEngine.Session.Tables);
--------------

Thanks



--
_______________________________________________
Lazarus mailing list
Lazarus@lists.lazarus.freepascal.org
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to