qrterminal

package module
v3.0.0-...-8aa500e Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 14, 2022 License: MIT Imports: 3 Imported by: 1

Documentation

Index

Constants

View Source
const BLACK = "\033[40m  \033[0m"
View Source
const BLACK_BLACK = " "
View Source
const BLACK_WHITE = "▄"

Use ascii blocks to form the QR Code

View Source
const H = qr.H

Level - the QR Code's redundancy level

View Source
const L = qr.L
View Source
const M = qr.M
View Source
const QUIET_ZONE = 4

default is 4-pixel-wide white quiet zone

View Source
const WHITE = "\033[47m  \033[0m"
View Source
const WHITE_BLACK = "▀"
View Source
const WHITE_WHITE = "█"

Variables

This section is empty.

Functions

func Generate

func Generate(text string, l qr.Level, w io.Writer)

Generate a QR Code and write it out to io.Writer

func GenerateHalfBlock

func GenerateHalfBlock(text string, l qr.Level, w io.Writer)

Generate a QR Code with half blocks and write it out to io.Writer

func GenerateWithConfig

func GenerateWithConfig(text string, config Config)

GenerateWithConfig expects a string to encode and a config

Types

type Config

type Config struct {
	Level          qr.Level
	Writer         io.Writer
	HalfBlocks     bool
	BlackChar      string
	BlackWhiteChar string
	WhiteChar      string
	WhiteBlackChar string
	QuietZone      int
}

Config for generating a barcode

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL