py_curses_editor
Python curses text editor module. Provides a configurable pop-up window for entering text, passwords, etc.
Other Contributors:
- Yuri D'Elia wavexx@thregr.org (Unicode/python2 code from tabview)
Features
- Unicode support
- Configurable window size and location
- Text box can have a title and/or an outlined box
- Text box can be initialized with existing text to edit
- Password mode for hiding text entries
- Paste in large blocks of text from primary clipboard
- Pop-up help menu
Requires
Python 3+
Installation
# pip install py_curses_editorOR$ pip install --user py_curses_editorOR$ pip install --user -e .(install from local git clone for development)
License
- MIT
Usage
From non-curses application:
import editor.editor as e
e.editor(box=False, inittext="Hi", win_location=(5, 5))
From curses application with a predefined curses window object (stdscr):
from editor.editor import Editor
Editor(stdscr, win_size=(1,80), pw_mod=True, max_text_size=1)()
Keybindings
| Key | Action |
|---|---|
| F1 | Show popup help menu |
| F2 or Ctrl-x | Save and Quit |
| Enter | Enter new line, or Save and Quit in single line mode |
| F3, Ctrl-c or ESC | Cancel (no save) |
| Cursor keys | Movement |
| Ctrl-n/p Ctrl-f/b | Up/down right/left |
| Home/End Ctrl-a/e | Beginning or End of current line |
| PageUp/PageDown | PageUp/PageDown |
| Delete/Ctrl-d | Delete character under cursor |
| Backspace/Ctrl-h | Delete character to left |
| Ctrl-k/u | Delete to end/beginning of-line |
| Ctrl-v | Paste a block of text from primary clipboard (requires xclip or xsel) |
Notes
Using shift-insert to paste text will be quite slow, as it's pasting one character at a time. Use Ctrl-v to paste a large block of text from the primary clipboard.
Double-width characters are not yet supported.
Metadata
Release files for py-curses-editor 1.3.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| py_curses_editor-1.3.2.tar.gz | 9.3 kB | Without provenance | Details for py_curses_editor-1.3.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| py_curses_editor-1.3.2-py2.py3-none-any.whl | Python 3, Python 2 | none | any | Details for py_curses_editor-1.3.2-py2.py3-none-any.whl |
Total release size: 22.3 kB
Release files / py_curses_editor-1.3.2.tar.gz
| Download URL | py_curses_editor-1.3.2.tar.gz |
|---|---|
| Size | 9.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b9469c5a4f0142271b90fe679bf31f6b0209cf44eb395cb7df2be98d049bc09e
|
|
BLAKE2b-256 checksum How to use checksums |
8d84f873c4ad0335f7f84111e1d0b90b3344099177b6d9e8695453e7b798e439
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-httpx/0.23.0
|
Release files / py_curses_editor-1.3.2-py2.py3-none-any.whl
| Download URL | py_curses_editor-1.3.2-py2.py3-none-any.whl |
|---|---|
| Size | 13.0 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
2a24dbbade4a64bfb3d8c60ab9412b99a9e6120a92f6710b710442f1fc195fe2
|
|
BLAKE2b-256 checksum How to use checksums |
63ba79ae3296f01eb5cce4b1c67342be914d4905bc52344acd7266036295598a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
python-httpx/0.23.0
|
Security for py-curses-editor 1.3.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.