tparm - retrieve capabilities from the terminfo database
#include <term.h> char *tparm(char *cap, long p1, long p2, long p3, long p4, long p5, long p6, long p7, long p8, long p9);
Refer to tigetflag().