Permalink
Browse files

Support searching selected text from SQL editor in help dialog. See h…

  • Loading branch information...
ansgarbecker committed Jan 29, 2019
1 parent 7dd603f commit 4585b3c8f7889616ec4dc05b37f5f71943fca4ae
Showing with 8 additions and 2 deletions.
  1. +8 −2 source/main.pas
@@ -4147,13 +4147,19 @@ procedure TMainForm.actSQLhelpExecute(Sender: TObject);
var
keyword: String;
Tree: TVirtualStringTree;
SynMemo: TSynMemo;
begin
// Call SQL Help from various places
keyword := '';

// Query-Tab
if ActiveControl is TSynMemo then
keyword := TSynMemo(ActiveControl).WordAtCursor
if ActiveControl is TSynMemo then begin
SynMemo := TSynMemo(ActiveControl);
keyword := SynMemo.WordAtCursor;
if keyword.IsEmpty then begin
keyword := SynMemo.SelText;
end;
end

// Data-Tab
else if (PageControlMain.ActivePage = tabData)

0 comments on commit 4585b3c

Please sign in to comment.