Sorry I did misread your post.
I thought you are looking for code completion, the drop down, that in the IDE proposes all matching functions and variables.
if you type "begin" followed by Enter key, you get "end" added to "begin"
This is not part of SynEdit. In the IDE this is done by codetools.
However you can almost archive it with code templates. But you need to write some handling yourself, to use return
SynAutoComplete1: TSynAutoComplete;
//Set SynAutoComplete1.AutoCompleteList to (TStrings) Use Append, or Add, or Text property
begin
=begin
=end
You can use any key (but just one):
SynAutoComplete1.ShortCut := KeyToShortCut(VK_RETURN, []);
But that shortcut looses its normal function (so return no longer creates a new line.
So instead, you need to add an event to SynEdit.OnProcessCommand
and check if the command is ecLineBreak, then you need to check yourself, if the text before the caret needs any special handling.
For just inserting an end, the TSynAutoComplete is not needed in this case, since you can insert it yourself.