heres a function I wrote ages ago to draw a box of whatever size, and before ANYONE says its not compatible because of cprintf, they can save there breath, I needed colour, i needed it to work on a ibm and this is the easiest, quickest and simplest way, also used ibm ascii characters for the border but change them as you wish and change it to a printf if you like:
Code:
void border(int x1,int y1,int x2,int y2)
{
int temppos;
gotoxy(x1,y1);
cprintf("É");
for (temppos=x1;x2-temppos>1;temppos++)
cprintf("Í");
cprintf("»");
for (temppos=y1+1;y2-temppos>0;temppos++)
{
gotoxy(x1,temppos);
cprintf("º");
gotoxy(x2,temppos);
cprintf("º");
}
gotoxy(x1,y2);
cprintf("È");
for (temppos=x1;x2-temppos>1;temppos++)
cprintf("Í");
cprintf("¼");
gotoxy(x1,y1);
}
acsii chars dont show up in windows though.