https://github.com/abertschi/sailfish-headless-keyboard
Headless keyboard layout for Sailfish OS
https://github.com/abertschi/sailfish-headless-keyboard
Last synced: 2 months ago
JSON representation
Headless keyboard layout for Sailfish OS
- Host: GitHub
- URL: https://github.com/abertschi/sailfish-headless-keyboard
- Owner: abertschi
- License: mit
- Created: 2015-04-09T18:29:37.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2015-04-25T18:50:40.000Z (about 10 years ago)
- Last Synced: 2025-02-01T09:22:45.987Z (4 months ago)
- Language: QML
- Size: 469 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README

# sailfish-headless-keyboard-layout
The headless keyboard layout provides an alternative keyboard layout for
sailfish os. It aims to enable applications to insert any text into a
currently focused widget on the screen.## Note
**For a more sophisticated implementation of the headless-keyboard layout, you may take a look at
the DBus based implementation: https://github.com/abertschi/sailfish-headless-keyboard-dbus**## Installation
- The keyboard layout is published on openrepos: https://openrepos.net/content/abertschi/headless-keyboard# API
This is the reference document for the headless-keyboard layout.
This api describes the available functionality to control the keyboard layout.If the keyboard layout is running,
it listens for text set to the system clipboard.
Commands in JSON format can be set to the clipboard
in order to access certain keyboard functionality.
The clipboard is cleared after a valid keyboard command was executed.## Clipboard
In order to execute certain keyboard functionality,
the clipboard can contain one or more commands to execute
in the provided order. The clipboard shall contain the JSON
format listed below.### One single command
```json
{ /* command 1 */ }
```### Multiple commands
```json
{
cmds: [
{ /* command 1 */ },
{ /* command 2 */ },
{ /* command 3 */ }
]
}
```## Commands
The following commands are supported by the keyboard.### Command 'set_label'
> Set a label shown in the statusbar of the keyboard layout.```json
{
"cmd": "set_label",
"arg": "any text you want to use as label"
}
```### Command 'insert_text'
> Insert text into currently focused widget```json
{
"cmd": "insert_text",
"arg": "any text ..."
}
```### Command 'key_backspace'
> Removes last character in currently focused widget.```json
{
"cmd": "key_backspace"
}
```### Command 'key_return'
> Fires return key on currently focused widget```json
{
"cmd": "key_return"
}
```## Projects that use headless-wlan-keyboard
- [sailfish-wlan-keyboard](https://github.com/abertschi/sailfish-wlan-keyboard):
Use your computer keyboard to type on your phone.