Ticalc
Small, modern, hardware accelerated UI calculator
Install / Use
/learn @cococry/TicalcREADME
ticalc
<div style="display: flex;"> <img src="https://github.com/cococry/ticalc/blob/main/branding/ticalc-showcase.png" style="flex: 50%; padding: 20px;" width="250px"> </div>Overview
Ticalc is built to be very small and minimalistic while still retaining aesthetics and functionality. The codebase is contained in only about 450 lines of code that are structured in 2 .c files.
The UI enigne/library used for the interface is libleif which is a minimalistic stb-like immediate mode UI library. (~3500 lines of code). The library uses OpenGL as a graphics backend and glfw is used for window handling.
The calculator is highly configurable and easily extendable due to its very small and readable codebase. As a sidenote, the entire application can be used by only using keyboard shortcuts and number input.
Installation
- Install the dependencies
On arch:
paru -S make gcc cglm libclipboard glfw ttf-roboto-mono
On debian:
Note: You will have to build libclipboard yourself. Follow the instructions here.
sudo apt-get install make gcc libglfw3 libglfw3-dev libcglm-dev fonts-roboto
- Clone the repository
git clone https://github.com/cococry/ticalc
cd ticalc
- Build & Install
sudo make && sudo make install
Uninstalling
sudo make uninstall
Running
There is a .desktop file that is automatically installed on install that you can access or just run the binary via terminal:
ticalc
Build Dependencies
| Dependency | Reason of Usage | | ----------------|-------------| | leif | Creating the entire UI Frontend | | libm | Mathematical functions | | llibclipboard | Handling clipboard | | libGL | OpenGL Functionality | | GLFW | Handling windowing, input etc. | | glad | Loading OpenGL functions | | stb_image | Loading image files into memory | | stb_image_resize2 | Resizing images | | stb_truetype | Loading font glyphs from font files | | cglm | Linear Algebra Math |
Lines of Code
| File | Lines of Code | | -------------|----------------| | ticalc.c | 345 | | config.h | 43 | | eval.h | 2 | | eval.c | 73 | | Total | 463 |
Contributing
You can contribute to ticalc by:
Related Skills
node-connect
349.2kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
109.5kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
349.2kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
qqbot-media
349.2kQQBot 富媒体收发能力。使用 <qqmedia> 标签,系统根据文件扩展名自动识别类型(图片/语音/视频/文件)。
