ok, joey, so you have provided the whole source code, thus faciliating some quick checks. for I have no c++ compiler at this pc at work, I canna do a test compile, but from what I see, you might have some small mistake in it:
It is this place here in your main function:
box_draw( 5, 5, 45, 15, "?????? ", 62, 23 );
Here is the declaration of your box_draw:
void box_draw( int lft, int top, int rgt, int btm,
char* border, int outline_clr, int contents_clr );
Mark the following: if you define somewhere a pointer, you have to pass an adress to it bofore you can use it further, else it points to nowhere in silicium hell.
This char* border pointer you have to provide with the adress of a string instead of a string for it is a POINTER!
Know about pointers and how to use the *-operator with them? It's nearby the same as with the brackets[] in nasm.
I'll tell you a bit about it:
with int *p you define a pointer to any integer var.
with p=&integervar you pass the adress of any integer to the pointer.
with p++/p-- you increment/decrement the adress of the pointer by the size of the datatype it points to. p. ex. for our int-pointer p p would then increase by 4 bytes.
with *p you access the content of the variable p points to.
so for your problem:
you ought define a string in your main function:
Code:
char border[8]="12345678"
you then call box_draw in this way:
box_draw( 5, 5, 45, 15, border, 62, 23 );
the parameter char *border is provided with the adress of the string you have defined, because the name of an array is also it's adress.(equal to &border[0])
it should do what you expect it to do then.
stay safe