Rich Widget Library
Comprehensive collection of 15+ pre-built widgets including buttons, labels, checkboxes, toggles, text boxes, lists, tables, charts, sliders, and more.
Build beautiful, responsive user interfaces for ComputerCraft with ease
Install PixelUI in your ComputerCraft environment:
local pixelui = require("pixelui")
-- Create an app instance
local app = pixelui.create()
-- Add widgets to the root frame
local root = app:getRoot()
-- Create a button
local button = app:createButton({
parent = root,
x = 5,
y = 5,
width = 20,
height = 3,
label = "Click Me!",
onClick = function()
print("Button clicked!")
end
})
-- Run the app
app:run()PixelUI provides a comprehensive set of widgets:
Create smooth animations with built-in easing functions:
app:animate({
duration = 1.0,
easing = "easeOutQuad",
update = function(progress)
widget.x = startX + (endX - startX) * progress
end,
onComplete = function()
print("Animation complete!")
end
})Run background tasks without blocking the UI:
local handle = app:spawnThread(function(ctx)
for i = 1, 100 do
ctx:setProgress(i / 100)
ctx:sleep(0.1)
ctx:checkCancelled()
end
return "Task complete!"
end, { name = "Background Task" })For detailed API documentation, see the API Reference.
PixelUI is released under the MIT License.