prompt-toolkit / prompt-toolkit/python-prompt-toolkit

Page Up / Page Down in menu completion

Open
#961 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
10.6k
Forks
815
PR merge metrics
No merged PRs in 30d

Description

In examples/prompts/auto-completion/autocompletion.py and examples/prompts/auto-completion/multi-column-autocompletion.py, I would expect to be able to use the page up or page down keys to scroll through the completion menu, but this does not work. app.enable_page_navigation_bindings = True doesn't seem to help, and I've tried a bunch of other key equivalents in vi and emacs editing modes to no avail. (The keys work fine in other console-based apps.)

Am I doing something wrong? Is there a way to set these bindings manually? Or is this something that could be added in the future?

(Python 3.7.2, OSX, tried both 2.0 and master branches.)

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the behavior in examples/prompts/auto-completion/autocompletion.py and examples/prompts/auto-completion/multi-column-autocompletion.py, including with app.enable_page_navigation_bindings enabled in both editing modes. Trace the completion-menu key handling and existing bindings, then verify that Page Up and Page Down scroll the menu without breaking the documented examples.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.