Skip to content

Commit

Permalink
configuration: show completion candidates right away!
Browse files Browse the repository at this point in the history
  • Loading branch information
vindarel committed May 23, 2024
1 parent a853390 commit e30dc44
Showing 1 changed file with 22 additions and 2 deletions.
24 changes: 22 additions & 2 deletions content/en/usage/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,30 @@ Otherwise, be sure to refer to Lem functions with the `lem:` prefix.

{{< toc >}}


## Show the completion list instantly

The completion pop-up, like the one we get with `M-x`, wants us to
press TAB before we get the completion candidates. If you want to open
it right away, add this to your init file:

```lisp
(add-hook *prompt-after-activate-hook*
(lambda ()
(call-command 'lem/prompt-window::prompt-completion nil)))
(add-hook *prompt-deactivate-hook*
(lambda ()
(lem/completion-mode:completion-end)))
```

You can start typing and the list will narrow down.


## Choosing the completion pop-up position: center, top, bottom

Lem's completion pop-up, for example the one that shows on `M-x`, is
by default centered on the middle of the screen.
Lem's completion pop-up is by default centered on the middle of the
screen.

Since May of 2024, it is possible to choose its position: à la Emacs at the bottom? À la VSCode at the top?

Expand Down

0 comments on commit e30dc44

Please sign in to comment.