Code Monkey home page Code Monkey logo

go-keymapviz's Introduction

Go-Keymapviz

Go version of keymapviz with a different approach to extracting keymaps.

Command-line is tool to convert qmk_firmware keymap.c to ASCII art.

Installation

go install github.com/vunhatchuong/go-keymapviz

Usage

Basic usage:

go-keymapviz [-h] [-l LEGENDS] [-t {ascii,fancy}] [-w WRAPPERS] keymap_c

Example:

go-keymapviz -kb sofle -t fancy ./sofle.c

You can check out available keyboards and their ascii templates when running the program without any arguments.

go-keymapviz

image

Convention

The program looks for specific patterns in keymap.c to extract correctly.

Layout Zone

Layout zone is the entry point of your keymap, everything around it will be discarded.

It specifically has to end with };

const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
                        // ----
};

Keymap Layers

Keymap layers are things inside () and the closing ) must be on a new line.

It doesn't matter what the name of the layer is or what kind of layout it is.

[_QWERTY] = LAYOUT_ortho_4x12(
                        // ----
),

Keymaps

The final step is to extract keycodes inside layers, keycodes are defined as any word.

Ex: AU_OFF is a word, AU OFF is 2 words.

go-keymapviz's People

Contributors

vunhatchuong avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.