Skip to content

Instantly share code, notes, and snippets.

View lygaret's full-sized avatar

Jonathan Raphaelson lygaret

View GitHub Profile
@lygaret
lygaret / .yardopts
Last active June 9, 2022 08:02
gem - string-inquirer
-m markdown
--private
--protected
--embed-mixins
--default-return void
**/*.rb
@lygaret
lygaret / .yardopts
Last active June 9, 2022 07:57
gem - method hooks
-m markdown
--private
--protected
--embed-mixins
--default-return void
**/*.rb
@lygaret
lygaret / psf.zig
Created September 16, 2022 03:27
PSF (PC Screen Font) comptime loader in zig
const std = @import("std");
/// PSF font-file loading, into an easy to render format
///
/// {buildFont} takes a path to a font file, and returns a struct wrapping that
/// font with the ability to easily get an iterator of pixels over charactors
///
/// @see https://www.win.tue.nl/~aeb/linux/kbd/font-formats-1.html
const PSF1_MAGIC: [2]u8 = .{ 0x36, 0x04 };