How about doing it with direct port manipulation, speed it up quite a bit.
Or define it to drive the digits from an array:
display[] = {
B00111111, // 0
B00000110, // 1
B01011011, // 2
B01001111, // 3
B01100110, // 4
B01101101, // 5
B01111011, // 6
B00000111, // 7
B01111111, // 8
B01101111, // 9
}
// write the digits, assume PORTD with bit0 = asegment, 1=b,2=c,3=d,4=e,5-f,6=g, 7=decimal point it used
// a
// f b
// g
// e c
// d
// clear the bits
PORTD = PORTD & 0x00
// now set the font
PORTD = display[x]; // x = 0 to 9, or bigger if define some other characters: A,b,C,d,E,F,H,L,P,U, -,_,
and do the library stuff.
That would make it real quick!
Or share the 8 bits across 2 ports if you didn't want to commit D0,D1 to LED driver (serial pins).