Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

keypress

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

keypress

Cross-Platform Key Handling Module: Effortlessly Detect and Describe Keyboard Events

  • 0.1.7
  • PyPI
  • Socket score

Maintainers
1

keypress

GitHub Actions Workflow Status Pypi versions

This module offers a comprehensive solution for handling keyboard input across platforms. Whether you’re detecting simple keypresses or complex key combinations, our get_key function and Keys constants deliver robust functionality with clear, descriptive outputs. Perfect for developers needing to implement precise keyboard interactions in their applications.

Installation

You can install keypress via pip:

pip install keypress

Example

You can run keypress in your terminal.

from keypress import Keys, get_key

if __name__ == "__main__":
    key = ""
    while key not in ["q", Keys.ENTER]:
        key = get_key()
        if key.is_printable:
            print(key)
        print(key.key_codes)
        print(key.description)

Contributing

Contributions are welcome! Please see our contributing guidelines for more information.

License

This project is licensed under the MIT License. See the LICENSE file for details.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc