Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 

README.md

spin

Simple UTF-8 console spinners for C.

spinner gif

usage

Drop spin.h into your project directory.

#include "spin.h"
int func() {
    spinner *s = spin_new(utf8_pat1, "Working...", UTF8_CHAR_WIDTH);
    while(working) {
        // ... do work ...
        spin_drw(s);
        if(progress == .5)
            spin_upd_msg(s, "Half way through...") // update the message
    }
    spin_del(s);
    return 0;
}

expanding

It's possible to add new spinner patterns, but for now, they have to be UTF8 (since there are hard coded 3 byte jumps in the code).

About

simple c terminal spinners

Resources

License

Packages

No packages published

Languages

You can’t perform that action at this time.