Right now, to keep it simple, it’s only black and white, but you can change that easily.
Line (xPos, yPos)-Step(boxWidth, boxheight), 0, BF: Line (x + xPos + maxWidth + 1, y + yPos)-Step(0, boxheight), -1 'draw box
That one simple line statement is what draws our black background. (Color 0 black background, color -1 white frame.) Change it, or make it variables to pass via parameter or shared values, and you can have any color background you want. Changing the font color is just as simple as using a COLOR fg, bg statement at the top of the routine. (Just be certain to change it back when the routine’s over.)
As for that last set of numbers overwriting the line…. I’m not certain why it’s doing that, off the top of my head. I’ll have to dig into it a little more this evening and get back to you on it. It might just need a slightly larger offset to shift it a pixel or two to the right, as QB64’s default font rendering can be slightly lacking sometimes. (Like all the cases where parts of the font aren’t rendered at all, cutting them off completely, for instance…)