You can open a new tab in the IDE and name it sevenseg.h, then go back to the first tab, include the code
#include"sevenseg.h"
this is a sample program of printing values on a seven segment display.
#include"sevenseg.h"
int val=0;
void setup(){
sevensegpins(13, 12, 11, 10, 9, 8, 7);
common_cathode(true);
}
void loop(){
val=(analogRead(0));
val=map(val, 0, 1023, 0, 9);
sevenseg(val);
}