This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <stdint.h> | |
#include <wchar.h> | |
#include <locale.h> | |
wchar_t byte_to_variant(char byte) { | |
if(byte < 16) { | |
return 0xfe00 + (uint32_t)byte; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# requires spectacle, xclip, zbar-tools, and dmtx-utils | |
# creates a spectacle "rectangle select box", highlight area with QR, barcode, or matrix and press enter - if successful the result will be in your clipboard | |
spectacle --background --region --nonotify --output /tmp/qrscreenshot.png | |
(zbarimg -q --raw /tmp/qrscreenshot.png || dmtxread /tmp/qrscreenshot.png) | xclip -selection clipboard |