package.cpath = package.cpath .. ";../target/debug/?.so" package.path = package.path .. ";../lua-bindings/?.lua" local dia = require("diaphragm") dia.draw({ draw = function(self) local p = io.popen("pygmentize -f pango -O style=nord ./pygments.lua") local content = p:read("a") if content == nil then return end local font = dia.text.font({ family = "Fira Code" }) local text = dia.text.new({ content = string.sub(content, 5, -6), font = font, width = 1920, }) dia.rectangle .surrounding(text, { -- fill_color = "#282828" fill_color = "#1e1e27", }) :draw() text:draw() dia.constraint.inset(text, self) end, output = {}, })