Python API for HID-IO HID Layouts Repository
Project description
HID-IO layouts Python API
This is the Python API for the HID-IO layouts repository.
The purpose of this API is to acquire and merge the JSON HID layouts. With some additional helpers to deal with string composition.
Usage
Some basic usage examples.
List Layouts
import layouts
mgr = layouts.Layouts()
print(mgr.list_layouts()
Retrieve Layout
import layouts
mgr = layouts.Layouts()
layout = mgr.get_layout('default')
print(layout.name()) # Name of merged layout
print(layout.json()) # Fully merged JSON dict
Composition Example
import layouts
mgr = layouts.Layouts()
layout = mgr.get_layout('default')
input_str = "Hello World!"
print(layout.compose(input_str))
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
layouts-0.1.tar.gz
(7.7 kB
view hashes)
Built Distribution
layouts-0.1-py3-none-any.whl
(15.4 kB
view hashes)